Description Collects a list of all the clients associated with the requesting account. Users with admin role privileges have access to all clients. Permissions client.access Resource URL https://app.klipfolio.com/api/1.0/clients Parameters external_id (string) — show only clients that have the specified external id
status (active, trial, setup, disabled) — show only clients that have the specified account status.
Clients Clients by Status
GET https://app.klipfolio.com/api/1/clientsGET https://app.klipfolio.com/api/1.0/clients?status=active
{
"meta": {
"success": true,
"status": 200,
"count": 3,
"total": 3
},
"data": {
"clients": [
{
"id": "0123456789abcdef0123456789abcdef",
"name": "Company A",
"description": "Testing for demo",
"status": "Active",
"seats": -1,
"last_sign_in": "2015-02-26T23:58:29Z"
},
{
"id": "0123456789abcdef0123456789abcdef",
"name": "Company B,
"description": "Marketing",
"status": "Active",
"seats": -1,
"last_sign_in": "2017-03-02T18:03:07Z"
},
{
"id": "0123456789abcdef0123456789abcdef",
"name": "Company C",
"description": "Stats for Google Analytics",
"status": "Active",
"seats": -1,
"last_sign_in": null
}
]
}
}
Note : The external_id is not shown if the client’s external ID is null
GET https://app.klipfolio.com/api/1/clients/0123456789abcdef0123456789abcdef?full=true
Note : custom_theme is shown only if the feature is enabled in the parent account
external_id is not shown if the client’s external id is null
trial_remaining is shown only if the client is a trial user
{
"data": {
"custom_theme": true,
"description": Company C,
"groups": [
"0123456789abcdef0123456789abcdef",
"23456789abcdef0123456789abcdef01",
"456789abcdef0123456789abcdef0123"
],
"id": "0123456789abcdef0123456789abcdef",
"is_direct_billed": false,
"last_sign_in": null,
"name": "Client C",
"primary_contact": null,
"seats": 50,
"share_rights": [
{
"group_id": "6789abcdef0123456789abcdef012345",
"group_name": "Management",
"can_manage": true
}],
"status": "Trial",
"trial_remaining": 5,
"users": [
"0123456789abcdef0123456789abcdef",
"23456789abcdef0123456789abcdef01",
"456789abcdef0123456789abcdef0123"
]
},
"meta": {
"status": 200,
"success": true
}
}
Note : 'status' can be 'setup', 'trial', 'active' or 'disabled'. 'custom_theme' is optional, optionally include 'external_id' in the post data to add an external id to the new client
POST https://app.klipfolio.com/api/1/clients -d {
'name': 'Client From API',
'description': 'Hello there',
'seats': 20,
'status': 'trial',
'custom_theme': true
}
{
"data": {},
"meta": {
"location": "/clients/0123456789abcdef0123456789abcdef",
"status": 201,
"success": true
}
}
Description Update the specified client. Permissions client.edit Resource URL https://app.klipfolio.com/api/1.0/clients/{id}Fields name, description, status, seats, custom_theme, external_id
PUT https://app.klipfolio.com/api/1/clients/0123456789abcdef0123456789abcdef -d {"status": "disabled"}
{
"data": {},
"meta": {
"status": 200,
"success": true
}
}
Description Delete a client. Permissions client.delete Resource URL https://app.klipfolio.com/api/1.0/clients/{id}Parameters None.
DELETE https://app.klipfolio.com/api/1/clients/0123456789abcdef0123456789abcdef
{
"data": {},
"meta": {
"status": 200,
"success": true
}
}
Description Switch a client to direct billing. This cannot be undone. This command is only available to Partner accounts. Permissions client.access Resource URL https://app.klipfolio.com/api/1.0/clients/{id}/@/enable_direct_billingFields None.
POST https://app.klipfolio.com/api/1/clients/0123456789abcdef01234589abcdef/@/enable_direct_billing
{
"data": {
"op_requested":"enable_direct_billing"
},
"meta": {
"status": 200,
"success": true
}
}
POST https://app.klipfolio.com/api/1/clients/0123456789abcdef0123456789abcdef/@/extend_trial -d {'days':'7'}
{
"data": {
"op_requested":""extend_trial"
},
"meta": {
"status": 200,
"success": true
}
}