curl --request POST \
--url https://{host}/cleemy-procurement/api/costcenters \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"code": "<string>",
"ownerId": 123,
"owner": {
"id": 123
},
"state": "Disabled",
"establishmentIds": [
123
]
}
'{
"items": [
{
"name": "<string>",
"code": "<string>",
"id": 123,
"owner": {
"id": 123,
"href": "<string>",
"name": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"pictureHref": "<string>"
},
"state": "Disabled",
"establishments": [
{
"id": 123,
"name": "<string>",
"href": "<string>"
}
]
}
]
}Create a new cost-center.
curl --request POST \
--url https://{host}/cleemy-procurement/api/costcenters \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"code": "<string>",
"ownerId": 123,
"owner": {
"id": 123
},
"state": "Disabled",
"establishmentIds": [
123
]
}
'{
"items": [
{
"name": "<string>",
"code": "<string>",
"id": 123,
"owner": {
"id": 123,
"href": "<string>",
"name": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"pictureHref": "<string>"
},
"state": "Disabled",
"establishments": [
{
"id": 123,
"name": "<string>",
"href": "<string>"
}
]
}
]
}API key. Value must be formatted like so: lucca application={api_key}.
Cost-center to create.
Cost-center.
ID of the user who will be the owner of the cost-center.
Read-only. Owner of the cost-center.
Show child attributes
Disabled: the cost-center is disabled. Enabled: the cost-center is enabled.
Disabled, Enabled Write-only. IDs of the establishments to which the cost-center belongs."
OK
Show child attributes
Was this page helpful?