Retrieve a client
Read one client of your hierarchy by its ID.
Returns one client: the authenticated client or one of its descendants.
The Clients API must be enabled for your account. Until it is, this endpoint responds with 404.
Request
GET /v2/clients/{id}
idstring (UUID)requiredThe client's ID.
GET /v2/clients/{id} in the API referencecurl "https://api.sandbox.squake.earth/v2/clients/4fb3ec7a-92cb-471f-b75f-c3fe7c2a34d5" \
--header "Authorization: Bearer $SQUAKE_API_KEY"The endpoint takes the client's UUID only. To find a client by your own reference, use List clients with the external_reference filter.
Response
{
"id": "4fb3ec7a-92cb-471f-b75f-c3fe7c2a34d5",
"name": "Example Travel Germany",
"external_reference": "example-de",
"parent_id": "0f1f3d3b-2775-4cc0-885e-8d51db6d6de1",
"status": "active",
"metadata": { "crm_id": "ACC-1042" },
"methodology_options": [
{ "activity_type": "flight", "methodology": "TIM", "version": "AT_TIME_OF_TRAVEL", "default": true },
{ "activity_type": "flight", "methodology": "DEFRA", "version": "AT_TIME_OF_TRAVEL", "default": false },
{ "activity_type": "train", "methodology": "REM", "version": null, "default": true },
{ "activity_type": "car", "methodology": "DEFRA", "version": "AT_TIME_OF_TRAVEL", "default": true },
{ "activity_type": "hotel", "methodology": "GREENVIEW", "version": "AT_TIME_OF_TRAVEL", "default": true }
]
}For every field, see Retrieve the authenticated client.
Errors
| Status | Code | Meaning |
|---|---|---|
401 | The API key is missing or invalid. | |
404 | client_not_found | No client has this ID, or the client is outside your hierarchy. |
A client outside your hierarchy returns the same response as one that doesn't exist.
Related
- Update a client
- Retrieve a Client in the API reference