# List cost centers This endpoint lists cost centers of a company. Endpoint: POST /v3/companies/{companyId}/cost-centers/list Version: v2 Security: Bearer ## Path parameters: - `companyId` (string, required) Identifier for company. Example: "4974a66b-7493-4f41-908c-58ba81093947" ## Request fields (application/json): - `searchText` (string) Search string entered by the user Example: "Credit" - `paginationParams` (object, required) Pagination information. - `paginationParams.offset` (integer) The starting index in the list from which results are returned. The value must be greater than or equal to 0. - `paginationParams.limit` (integer) Maximum number of results to be fetched. - `filters` (array) List of filters. Cost centers matching with any filter would be returned. - `filters.externalIds` (array) List of external ids. Example: ["external-id"] - `filters.costCenterIds` (array) List of cost center ids. Example: ["731ccbca-0415-6fe1-d235-c324dfbe7423"] ## Response 200 fields (application/json): - `paginationParams` (object, required) Pagination information. - `paginationParams.totalNumResults` (integer, required) Total number of results. - `costCenters` (array) List of cost centers containing id and name. - `costCenters.id` (string, required) Example: "731ccbca-0415-6fe1-d235-c324dfbe7423" - `costCenters.name` (string) Example: "Credit" ## Response 401 fields (application/json): - `debugIdentifier` (string) Link to debug the error internally. - `errorMessages` (array) - `errorMessages.errorCode` (string) Error code to identify the specific errors. - `errorMessages.message` (string) Message containing details of error. - `errorMessages.errorParameters` (array) Error message parameters. - `errorMessages.errorParameters.name` (string) Parameter name - `errorMessages.errorParameters.value` (string) Parameter value - `errorMessages.errorDetail` (string) More details about the error. ## Response 403 fields (application/json): - `debugIdentifier` (string) Link to debug the error internally. - `errorMessages` (array) - `errorMessages.errorCode` (string) Error code to identify the specific errors. - `errorMessages.message` (string) Message containing details of error. - `errorMessages.errorParameters` (array) Error message parameters. - `errorMessages.errorParameters.name` (string) Parameter name - `errorMessages.errorParameters.value` (string) Parameter value - `errorMessages.errorDetail` (string) More details about the error. ## Response 404 fields (application/json): - `debugIdentifier` (string) Link to debug the error internally. - `errorMessages` (array) - `errorMessages.errorCode` (string) Error code to identify the specific errors. - `errorMessages.message` (string) Message containing details of error. - `errorMessages.errorParameters` (array) Error message parameters. - `errorMessages.errorParameters.name` (string) Parameter name - `errorMessages.errorParameters.value` (string) Parameter value - `errorMessages.errorDetail` (string) More details about the error.