Customer module
Endpoints for managing customers and users
GET
/queuegroups Returns collection of QueueGroup resources
Example Request
GET /v1.1/voipstudio/queuegroups HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": [
{
"id": 2423,
"name": "value"
}
],
"total": 59
}
POST
/queuegroups Creates new QueueGroup resource
Example Request
POST /v1.1/voipstudio/queuegroups HTTP/1.1
Host: l7api.com
Responses
201 Created
400 Validation error
Example Response
HTTP/1.1 201 OK
Content-Type: application/json
{
"data": {
"id": 5127,
"name": "value"
},
"links": {}
}
GET
/queuegroups/{id} Returns QueueGroup resource for given Id
Parameters
Endpoint URL:
{id} integer
QueueGroup identifier
Example Request
GET /v1.1/voipstudio/queuegroups/57 HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
403 Access denied
404 Resource not found
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 3751,
"name": "value"
},
"links": {}
}
PATCH
/queuegroups/{id} Updates existing QueueGroup resource
Parameters
Endpoint URL:
{id} integer
QueueGroup identifier
Example Request
PATCH /v1.1/voipstudio/queuegroups/44 HTTP/1.1
Host: l7api.com
Responses
200 Success
400 Validation error
404 Resource not found
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 9217,
"name": "value"
},
"links": {}
}
DELETE
/queuegroups/{id} Deletes existing QueueGroups resources
Parameters
Endpoint URL:
{id} integer
QueueGroup identifier
Example Request
DELETE /v1.1/voipstudio/queuegroups/53 HTTP/1.1
Host: l7api.com
Responses
204 Success
401 Unauthorized
403 Access denied
404 Resource not found
DELETE
/customers/{id} Deletes customer account
Parameters
Endpoint URL:
{id} integer
Resource identifier
Example Request
DELETE /v1.1/voipstudio/customers/25 HTTP/1.1
Host: l7api.com
Responses
204 Success
401 Unauthorized
403 Access denied
GET
/users Returns collection of User resources
Example Request
GET /v1.1/voipstudio/users HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": [
{
"id": 8593,
"active": true,
"created_at": "2019-01-11 04:31:04",
"customer": 4403,
"email": "value",
"first_name": "value",
"is_initial": true,
"is_root": true,
"last_name": "value",
"roles": "value",
"two_factor_auth": 1,
"visited_apps": "value"
}
],
"total": 59
}
PATCH
/users [BULK] Updates location and/or teams of existing User resources
Parameters
JSON body attributes:
id integer
location_id integer
groups array
Example Request
PATCH /v1.1/voipstudio/users HTTP/1.1
Host: l7api.com
[
{
"id": 253,
"location_id": 577,
"groups": "abcd"
},
{
"id": 5631,
"location_id": 577,
"groups": "abcd"
}
]
Responses
200 Success
400 Validation error
401 Unauthorized
403 Access denied
404 Resource not found
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 767,
"active": true,
"created_at": "2018-05-10 20:05:00",
"customer": 371,
"email": "value",
"first_name": "value",
"is_initial": true,
"is_root": true,
"last_name": "value",
"roles": "value",
"two_factor_auth": 0,
"visited_apps": "value"
},
"links": {}
}
GET
/users/{id} Returns User resource for given Id
Parameters
Endpoint URL:
{id} integer
User identifier
Example Request
GET /v1.1/voipstudio/users/41 HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
403 Access denied
404 Resource not found
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 8964,
"active": true,
"created_at": "2021-10-11 14:46:48",
"customer": 6946,
"email": "value",
"first_name": "value",
"is_initial": true,
"is_root": true,
"last_name": "value",
"roles": "value",
"two_factor_auth": 1,
"visited_apps": "value"
},
"links": {}
}
DELETE
/users/{id} Deletes existing User resource
Parameters
Endpoint URL:
{id} integer
User identifier
Example Request
DELETE /v1.1/voipstudio/users/63 HTTP/1.1
Host: l7api.com
Responses
204 Success
401 Unauthorized
403 Access denied
GET
/me Returns User metadata
Example Request
GET /v1.1/voipstudio/me HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
403 Access denied
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": [
{
"id": "value",
"balance": 9.33,
"cc": "value",
"cli": "value",
"currency_iso": "value",
"is_root": "value",
"language": "value"
}
],
"total": 59
}
GET
/users/{id}/contacts Returns collection of Contact resources only for given user
Parameters
Endpoint URL:
{id} integer
User identifier
Example Request
GET /v1.1/voipstudio/users/25/contacts HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 3753,
"active": true,
"created_at": "2021-09-21 11:31:59",
"customer": 3099,
"email": "value",
"first_name": "value",
"is_initial": true,
"is_root": true,
"last_name": "value",
"roles": "value",
"two_factor_auth": 0,
"visited_apps": "value"
},
"links": {}
}
GET
/users/{id}/cdrs Returns collection of Cdr resources for given user
Parameters
Endpoint URL:
{id} integer
User identifier
Example Request
GET /v1.1/voipstudio/users/23/cdrs HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 1541,
"active": true,
"created_at": "2019-12-31 14:28:00",
"customer": 3120,
"email": "value",
"first_name": "value",
"is_initial": true,
"is_root": true,
"last_name": "value",
"roles": "value",
"two_factor_auth": 1,
"visited_apps": "value"
},
"links": {}
}
GET
/users/{id}/chatmsgs Returns collection of Chat nessage resources for given user
Parameters
Endpoint URL:
{id} integer
User identifier
Example Request
GET /v1.1/voipstudio/users/37/chatmsgs HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 1915,
"active": true,
"created_at": "2024-03-08 23:12:14",
"customer": 3599,
"email": "value",
"first_name": "value",
"is_initial": true,
"is_root": true,
"last_name": "value",
"roles": "value",
"two_factor_auth": 0,
"visited_apps": "value"
},
"links": {}
}
GET
/users/{id}/calls Returns collection of Call resources for given user
Parameters
Endpoint URL:
{id} integer
User identifier
Example Request
GET /v1.1/voipstudio/users/51/calls HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 2126,
"active": true,
"created_at": "2016-05-30 15:24:19",
"customer": 2489,
"email": "value",
"first_name": "value",
"is_initial": true,
"is_root": true,
"last_name": "value",
"roles": "value",
"two_factor_auth": 0,
"visited_apps": "value"
},
"links": {}
}
GET
/usergroups Returns collection of UserGroup resources
Example Request
GET /v1.1/voipstudio/usergroups HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": [
{
"id": 8864,
"color": "value",
"name": "value"
}
],
"total": 59
}
POST
/usergroups Creates new UserGroup resource
Parameters
JSON body attributes:
name string
color string
Example Request
POST /v1.1/voipstudio/usergroups HTTP/1.1
Host: l7api.com
{
"name": "abcd",
"color": "abcd"
}
Responses
201 Created
400 Validation error
Example Response
HTTP/1.1 201 OK
Content-Type: application/json
{
"data": {
"id": 7030,
"color": "value",
"name": "value"
},
"links": {}
}
GET
/usergroups/{id} Returns UserGroup resource for given Id
Parameters
Endpoint URL:
{id} integer
UserGroup identifier
Example Request
GET /v1.1/voipstudio/usergroups/20 HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
403 Access denied
404 Resource not found
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 6094,
"color": "value",
"name": "value"
},
"links": {}
}
PATCH
/usergroups/{id} Updates existing UserGroup resource
Parameters
Endpoint URL:
{id} integer
UserGroup identifier
JSON body attributes:
name string
color string
Example Request
PATCH /v1.1/voipstudio/usergroups/53 HTTP/1.1
Host: l7api.com
{
"name": "abcd",
"color": "abcd"
}
Responses
200 Success
400 Validation error
404 Resource not found
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 9988,
"color": "value",
"name": "value"
},
"links": {}
}
DELETE
/usergroups/{id} Deletes existing UserGroups resources
Parameters
Endpoint URL:
{id} integer
UserGroup identifier
Example Request
DELETE /v1.1/voipstudio/usergroups/16 HTTP/1.1
Host: l7api.com
Responses
204 Success
401 Unauthorized
403 Access denied
404 Resource not found
GET
/usergrouppolicies Returns collection of UserGroup resources
Example Request
GET /v1.1/voipstudio/usergrouppolicies HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": [
{
"id": 5757,
"color": "value",
"name": "value"
}
],
"total": 59
}
POST
/usergrouppolicies Creates new UserGroup resource
Parameters
JSON body attributes:
name string
color string
Example Request
POST /v1.1/voipstudio/usergrouppolicies HTTP/1.1
Host: l7api.com
{
"name": "abcd",
"color": "abcd"
}
Responses
201 Created
400 Validation error
Example Response
HTTP/1.1 201 OK
Content-Type: application/json
{
"data": {
"id": 6247,
"color": "value",
"name": "value"
},
"links": {}
}
GET
/usergrouppolicies/{id} Returns UserGroup resource for given Id
Parameters
Endpoint URL:
{id} integer
UserGroup identifier
Example Request
GET /v1.1/voipstudio/usergrouppolicies/71 HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
403 Access denied
404 Resource not found
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 1828,
"color": "value",
"name": "value"
},
"links": {}
}
PATCH
/usergrouppolicies/{id} Updates existing UserGroup resource
Parameters
Endpoint URL:
{id} integer
UserGroup identifier
JSON body attributes:
name string
color string
Example Request
PATCH /v1.1/voipstudio/usergrouppolicies/55 HTTP/1.1
Host: l7api.com
{
"name": "abcd",
"color": "abcd"
}
Responses
200 Success
400 Validation error
404 Resource not found
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 4283,
"color": "value",
"name": "value"
},
"links": {}
}
DELETE
/usergrouppolicies/{id} Deletes existing UserGroups resources
Parameters
Endpoint URL:
{id} integer
UserGroup identifier
Example Request
DELETE /v1.1/voipstudio/usergrouppolicies/22 HTTP/1.1
Host: l7api.com
Responses
204 Success
401 Unauthorized
403 Access denied
404 Resource not found
GET
/users/{id}/audio Returns User resource for given Id
Parameters
Endpoint URL:
{id} integer
User identifier
Example Request
GET /v1.1/voipstudio/users/74/audio HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
403 Access denied
404 Resource not found
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 6410,
"active": true,
"created_at": "2016-07-18 08:47:15",
"customer": 3016,
"email": "value",
"first_name": "value",
"is_initial": true,
"is_root": true,
"last_name": "value",
"roles": "value",
"two_factor_auth": 1,
"visited_apps": "value"
},
"links": {}
}
DELETE
/users/{id}/audio Reset existing User audio resource
Parameters
Endpoint URL:
{id} integer
User identifier
Example Request
DELETE /v1.1/voipstudio/users/11/audio HTTP/1.1
Host: l7api.com
Responses
204 Success
401 Unauthorized
403 Access denied
GET
/users/{id}/smsthreads/{from}/{to} Returns collection of grouped SMS resources for given user
Parameters
Endpoint URL:
{id} integer
User identifier
Example Request
GET /v1.1/voipstudio/users/97/smsthreads/{from}/{to} HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 1576,
"active": true,
"created_at": "2022-10-30 03:52:55",
"customer": 5868,
"email": "value",
"first_name": "value",
"is_initial": true,
"is_root": true,
"last_name": "value",
"roles": "value",
"two_factor_auth": 0,
"visited_apps": "value"
},
"links": {}
}
GET
/users/{id}/sms/threads/{from}/{to} Returns collection of grouped SMS resources for given user
Parameters
Endpoint URL:
{id} integer
User identifier
Example Request
GET /v1.1/voipstudio/users/9/sms/threads/{from}/{to} HTTP/1.1
Host: l7api.com
Responses
200 Success
401 Unauthorized
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
{
"data": {
"id": 3867,
"active": true,
"created_at": "2018-09-02 13:16:30",
"customer": 2581,
"email": "value",
"first_name": "value",
"is_initial": true,
"is_root": true,
"last_name": "value",
"roles": "value",
"two_factor_auth": 0,
"visited_apps": "value"
},
"links": {}
}