Skip to content

List clients

Request

Retrieve all clients with basic pagination support

This endpoint provides simple client listing capabilities without any filtering restrictions. It's designed for scenarios where you need to browse through the entire client database with standard pagination controls.

Key Features:

  • Basic pagination with configurable page sizes (default: 50 records)
  • Default sorting by client name (ascending) then creation date (descending)
  • Complete client information including contact details and staff assignments
  • Total count aggregation for pagination metadata
  • No filtering logic - returns all clients in the system
  • Optimized for dashboard displays and data export operations

Performance Considerations:

  • Default 50-record pageSize prevents memory issues with large datasets
  • Indexed sorting on name and createdAt fields for optimal query performance
  • Consider using filtered queries for large client databases (1000+ records)
  • Suitable for datasets up to 10,000 clients with reasonable response times

Real Example:

curl --location 'https://{{host}}/v1/clients' \
--data '{
  "pageSize": 25,
  "page": 0
}'
Security
BearerAuth
Bodyapplication/json
pageSizeinteger, [ 1 .. 1000 ]

Maximum number of client records to return

Default:50
Example:25
pageinteger, >= 0

Number of records to skip for pagination navigation

Default:0
Example:0
curl -i -X POST \
  https://api.doc.aiwyn.ai/_mock/bundle/gql/v1/clients \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "pageSize": 25,
    "page": 0
  }'

Responses

Successfully retrieved client list

Bodyapplication/json
clientsArray of objects(Client)
totalobject
Response
{ "clients": [ {}, {}, {}, {}, {} ], "total": { "aggregate": {} } }