GET /accounts
Get a paginated list of accounts
Authentication Required
Authorization: Bearer {token}
header string This header is required to access this endpoint
Optional Parameters
Click here to view an exhaustive list of all available parameters
page
query integer Page number
pageSize
query integer Number of accounts per page
name
query string Filter accounts by name
repcode
query string Filter accounts by repcode
Try it out
Loading...
Output:
Responses
Description
Successful response
{ "accounts": [ { "accountName": "string", "accountId": "string", "usersPrimaryAccount": false, "accountAdmin": false, "id": "string", "uniqueId": "string", "name": "string", "repcode": "string", "customerServicePhone": "string", "customerServiceEmail": "string", "whitelabelSettings": {}, "permissions": [ "string" ], "roles": [ "string" ] } ], "totalCount": 0, "totalPages": 0, "currentPage": 0}Description
Unauthorized - User not authenticated
Description
Forbidden - User does not have the required permissions
Description
Internal server error
References
#/components/schemas/Account
type: objectrequired: - accountName - accountId - id - nameproperties: accountName: type: string description: Name of the account accountId: type: string description: Unique identifier of the account usersPrimaryAccount: type: boolean description: Whether this is the user's primary account accountAdmin: type: boolean description: Whether the user is an administrator of this account id: type: string uniqueId: type: string name: type: string repcode: type: string customerServicePhone: type: string description: Customer service phone number customerServiceEmail: type: string description: Customer service email address whitelabelSettings: type: object description: WhiteLabel Settings permissions: type: array items: type: string roles: type: array items: type: string|export interface Account { /** Name of the account */ accountName: string; /** Unique identifier of the account */ accountId: string; /** Whether this is the user's primary account */ usersPrimaryAccount?: boolean; /** Whether the user is an administrator of this account */ accountAdmin?: boolean; id: string; uniqueId?: string; name: string; repcode?: string; /** Customer service phone number */ customerServicePhone?: string; /** Customer service email address */ customerServiceEmail?: string; /** WhiteLabel Settings */ whitelabelSettings?: {}; permissions?: string[]; roles?: string[];}Route Source Code
Check out the source code for this route entrypoint here: /accounts/route.ts
Or the swagger.yaml spec this documentation was generated from:
/accounts/swagger.yaml