Group rooms (sipgroups)
Requests
HTTP verb | Endpoint | Description |
---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Creating a new group number
Request
Field Description: group entity
POST /rest/v1/uc/sipgroups HTTP/1.1
Content-Type: application/json; charset=utf-8
group entity
Response
Field Description: group entity
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
{
"id": "ba18a3e4-016c-d758-54da-50e54938780c",
"phonenumber": "500",
"type": "cascade",
"dialplan": [
{
"dial": ["511"],
"timeout": 10000
},
{
"dial": ["512", "513"]
}
],
"pickup": 1,
"opts": {
"title": "",
"comment": ""
},
"ext": {
"ct": "2019-08-28T08:29:46.74Z",
"lwt": "2019-08-28T08:29:46.74Z"
}
}
Getting the list of group numbers
Request
Name | Type | Description |
---|---|---|
|
|
Filter by field values. |
|
|
List of fields to output. Available fields for output: id, phonenumber, type, dialplan, pickup, opts.title, ext.lwt, ext.ct. |
|
|
Offset in the list of resources to be issued. |
|
|
The maximum number of resources in the list. |
|
|
The sort order of the resources in the list. |
|
|
Conversion to flat form of composite fields. |
GET /rest/v1/uc/sipgroups?offset=0&limit=2 HTTP/1.1
Response
Field Description: group entity
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
[
{
"id": "495079be-016c-d757-e913-50e54938780c",
"phonenumber": "200",
"type": "random",
"dialplan": [
{"dial": ["211", "212"]}
],
"pickup": 0,
"opts": {
"title": ""
},
"ext": {
"ct": "2019-08-28T08:29:18.48Z",
"lwt": "2019-08-28T08:29:18.48Z"
}
},
{
"id": "ba18a3e4-016c-d758-54da-50e54938780c",
"phonenumber": "500",
"type": "random",
"dialplan": [
{"dial": ["511"]},
{"dial": ["511", "512"]}
],
"pickup": 1,
"opts": {
"title": ""
},
"ext": {
"ct": "2019-08-28T08:29:46.74Z",
"lwt": "2019-09-08T12:13:55.01Z"
}
}
]
Receiving group number data
Request
Name | Type | Description |
---|---|---|
|
|
A list of fields to output. |
|
|
Conversion to flat form of composite fields. |
GET /rest/v1/uc/sipgroups/ba18a3e4-016c-d758-54da-50e54938780c HTTP/1.1
Response
Field Description: group entity
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
{
"id": "ba18a3e4-016c-d758-54da-50e54938780c",
"phonenumber": "500",
"type": "cascade",
"dialplan": [
{
"dial": ["511"],
"timeout": 10000
},
{
"dial": ["512", "513"]
}
],
"pickup": 1,
"opts": {
"title": "",
"comment": ""
},
"ext": {
"ct": "2019-08-28T08:29:46.74Z",
"lwt": "2019-08-28T08:29:46.74Z"
}
}
Changing group number data
Fields prohibited for modification: id
Request
Field Description: group entity
PATCH /rest/v1/uc/sipgroups/ba18a3e4-016c-d758-54da-50e54938780c HTTP/1.1
Content-Type: application/json; charset=utf-8
group entity
Response
Field Description: group entity
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
{
"id": "ba18a3e4-016c-d758-54da-50e54938780c",
"phonenumber": "500",
"type": "parallel",
"dialplan": [
{
"dial": [
"511"
]
},
{
"dial": [
"512"
]
},
{
"dial": [
"513"
]
}
],
"pickup": 1,
"opts": {
"title": "Marketing Department",
"comment": ""
},
"ext": {
"ct": "2019-08-28T08:29:46.74Z",
"lwt": "2019-09-08T12:38:24.39Z"
}
}
Searching for the group number identifier
Searches the resource for the specified key, returns the identifier(s) to build the endpoint.
Key fields to search for: id, phonenumber
Request
LOOKUP /rest/v1/uc/sipgroups HTTP/1.1
Content-Type: application/json; charset=utf-8
"500"
Response
HTTP/1.1 200 OK
content-type: application/json; charset=utf-8
[
"ba18a3e4-016c-d758-54da-50e54938780c"
]
HTTP/1.1 404 Not Found
Content-Type: application/json; charset=utf-8
{
"error_code": 1404,
"error_message": "Lookup failed"
}