Cowdidocs

List the caller's team customers

GET
/v1/agents/me/customers

List customers assigned to the caller and to the agents the caller supervises. Requires the org:agents:read permission. Filter with q for a case-insensitive match on the customer's name, email, or phone number, and with activity_status. Set exclude_agent_user_id to hide one agent's customers, for example the caller's own when looking for customers to transfer. Page with size, after, and before.

AuthorizationBearer <token>

Create a client with POST /v1/oauth/clients, then exchange its credentials for an access token. AUTHORIZATION_CODE clients act on behalf of a signed-in user and always use PKCE; CLIENT_CREDENTIALS clients act as themselves. A client may only be granted scopes its creator already holds — read the grantable list from GET /v1/oauth/clients/scopes.

In: header

Query Parameters

size?integer

Maximum number of customers to return. Defaults to 20, capped at 100.

Range0 < value
Default20
after?string

Opaque cursor for the page after this one, taken from a previous response's links.next. Omit for the first page.

before?string

Opaque cursor for the page before this one, taken from a previous response's links.prev.

q?string

Case-insensitive partial match on the customer's name, email, or phone number.

activity_status?string

Filter by the customer's activity status. See CustomerActivityStatus for what each value means.

Value in

  • "ACTIVE"
  • "INACTIVE"
  • "OVERDUE"
inactive_threshold_days?integer

Days without a disbursement before a customer is INACTIVE rather than ACTIVE, for the activity_status filter. Defaults to 60.

Default60
exclude_agent_user_id?string

Agent whose customers are left out of the list, for example the caller's own user ID when looking for customers to transfer.

Formatuuid

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/v1/agents/me/customers?size=20&after=eyJpZCI6IjZmOTYxOWZmLThiODYtNGQxMS05YTZlLThiMWEzZDNhMmYxMCJ9&before=eyJpZCI6IjZmOTYxOWZmLThiODYtNGQxMS05YTZlLThiMWEzZDNhMmYxMSJ9&q=jane&activity_status=OVERDUE&inactive_threshold_days=60&exclude_agent_user_id=550e8400-e29b-41d4-a716-446655440000"
{  "data": [    {      "id": "6f9619ff-8b86-4d11-9a6e-8b1a3d3a2f10",      "agent_user_id": "550e8400-e29b-41d4-a716-446655440000",      "agent_user_name": "Jane Wanjiru",      "agent_phone_number": "+254712345678",      "agent_email": "jane.wanjiru@example.com",      "customer_user_id": "550e8400-e29b-41d4-a716-446655440001",      "customer_name": "John Otieno",      "customer_email": "john.otieno@example.com",      "customer_phone_number": "+254798765432",      "assigned_at": "2026-01-15T09:30:00Z",      "unassigned_at": "2026-02-20T14:00:00Z",      "assigned_by": "550e8400-e29b-41d4-a716-446655440002",      "unassigned_by": "550e8400-e29b-41d4-a716-446655440002",      "assignment_reason": "Territory reassignment",      "unassignment_reason": "Customer transferred to another agent",      "is_active": true,      "resource_id": "string"    }  ],  "links": {    "next": "/v1/payees?after=eyJpZCI6MX0",    "prev": "/v1/payees?before=eyJpZCI6MX0"  }}
{  "code": "BAD_REQUEST",  "description": "Bad Request"}
{  "code": "UNAUTHORISED",  "description": "Unauthorised"}
{  "code": "FORBIDDEN",  "description": "Forbidden"}
{  "code": "RATE_LIMIT_EXCEEDED",  "description": "Too Many Requests"}
{  "code": "INTERNAL_ERROR",  "description": "Internal Server Error"}