Skip to main content

Get Client (v1)

Method + Path

GET /v1/workspace/:workspaceId/clients/:clientId

Actual backend path: /v1/workspace/:workspaceId/clients/:clientId

Description

Get a single client (customer) by ID.

Authentication

Required - JWT token in Authorization header

Required Permissions:

  • clients.view

Headers

HeaderTypeRequiredDescription
AuthorizationstringYesBearer token: Bearer <token>

Path Parameters

ParameterTypeRequiredDescription
workspaceIdstringYesWorkspace identifier
clientIdstringYesClient identifier

Response (200)

{
"client": {
"id": "507f1f77bcf86cd799439011",
"name": "John Doe",
"avatarUrl": "https://example.com/avatar.jpg",
"contactMethods": [
{
"type": "phone",
"value": "+1234567890",
"isPreferred": true
}
],
"customFields": [
{
"fieldId": "field-id-123",
"fieldKey": "notes",
"value": "Preferred contact time: 9am-5pm"
}
],
"createdAt": "2024-01-15T10:00:00Z",
"updatedAt": "2024-01-15T10:00:00Z"
}
}

Common Errors

  • 401 Unauthorized: Missing or invalid authentication token
  • 403 Forbidden: Insufficient permissions (requires clients.view)
  • 404 Not Found: Client or workspace not found
  • 500 Internal Server Error: Server error