# Get cost centre by ID

`GET /api/configuration/cost-centres/{id}`

- **Success:** `200 OK`
- **Products:** Operator (`FOH`)
- **Features:** Front of House Generic Access (`FOHGENERIC`)

HTML version: [Get cost centre by ID](https://support.gladstonesoftware.cloud/reference/configuration/get-cost-centre-by-id)

## Overview

Returns one cost centre. A cost centre is the upper level of the operator's two-level financial
reporting structure: each [department](get-all-departments.md) belongs to
exactly one cost centre, and a department cannot exist without one. Nothing else in the API
references a cost centre — a department is the only thing that holds a cost centre reference — so
treat a cost centre as a grouping over departments rather than as something that affects pricing,
availability or booking behaviour. Products sit one level further down again: every product belongs
to a department, and the department fixes which cost centre its income rolls up into.

The record is deliberately small: an identifier, a description and a free-text reference. There is
no budget, no financial total and no operational setting on it.

Cost centres are operator-defined and tenant-scoped. Ids are not allocated by Gladstone, are not
stable across tenants, and mean nothing outside the tenant that created them, so an integration
must discover them at runtime through
[Get all cost centres](get-all-cost-centres.md) rather than shipping a
hard-coded list.

There is no active, inactive or archived flag on a cost centre. Every cost centre the operator has
ever created is returned until it is explicitly deleted, and a cost centre cannot be deleted while
any department still references it. Expect to encounter cost centres that are no longer in use, and
do not infer from a successful response that the cost centre is one the operator still works with.

## Endpoint

`GET {base_url}/api/configuration/cost-centres/{id}`

`{base_url}` is the environment URL issued to your integration. See [Authenticating with Gladstone APIs](../../guides/authenticating-with-gladstone-apis.md).

## Path parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `id` | string | Yes | The cost centre's identifier, unique within your tenant; maximum 15 characters. Matching is currently case-insensitive but otherwise exact — no trimming and no partial matching. Send the id as it was returned to you regardless; the case-insensitivity is current behaviour, not a guarantee. Take the value from [Get all cost centres](get-all-cost-centres.md) or from the `costCentreId` of a department. Ids are set by the operator when the cost centre is created; if they leave it blank at creation, the platform generates one of the form `CCTR` followed by 11 digits, zero-padded, such as `CCTR00000000007`. Do not rely on that shape — an operator-supplied id can be any string of 15 characters or fewer. |

## Sample request

```bash title="cURL"
curl -X GET '{base_url}/api/configuration/cost-centres/{id}' \
  -H 'Authorization: Bearer {accessToken}' \
  -H 'X-Use-SSO: true'
```

## Response fields

| Field | Type | Description |
|-------|------|-------------|
| `id` | string | The cost centre's identifier as the platform holds it, maximum 15 characters. Because the lookup is case-insensitive, this may differ in case from the `id` you sent — use this value, not your own, when you store the reference or send it back in a department request. |
| `description` | string | The operator's label for the cost centre, maximum 255 characters. This is the only human-readable name a cost centre has and it is what staff see in the product, so use it for display. It is required when the cost centre is created, but a record created by an older route can return `null`. It is not translated and is not unique — two cost centres may share a description, which is why you must key on `id`. |
| `reference` | string | An optional free-text field, maximum 255 characters, kept verbatim and never validated, parsed or matched against anything by the platform. Returned as `null` when the operator has not set one. |

## Sample response

```json title="200 OK"
{
  "id": "string",
  "description": "string",
  "reference": "string"
}
```

## Errors

| Status | Meaning | When |
|--------|---------|------|
| `404` | Not found | No cost centre with that id exists in this tenant. The response body is **empty** — there is no message, no problem-details object and nothing to parse, so branch on the status code alone. Note that a mistyped id and a deleted cost centre are indistinguishable here. |
| `500` | Internal server error | An unexpected server-side failure while reading the record. The response has no body. It is not a signal about your request, so retry rather than altering the id. |
