Search Destination Resources
Searches the resources that are available as direct destinations of DIDs, filtered by destination type.
Request URL
POST {base_url}/uc-cconfig/api/v1/tenant-dids/resources/search-page
Request parameters
- Headers
-
Parameter Required Type Description Authorization Yes String The access token used for authentication. Format: Bearer
{access_token}.x-tenant-code Yes String The tenant name. Note: You can obtain tenant name using the Query Tenants interface.
- Body parameters
-
Parameter Required Type Description destinationType Yes String The type of the destination to search resources for.
Valid value:
USER: An extension user.QUEUE: A queue.IVR: An IVR.RING_GROUP: A ring group.AI_ROUTE: An AI receptionist.
keyword No String The keyword used to search for resources by extension number or name. An empty value returns all resources of the type. pageSize Yes Integer The number of records per page. The value 0returns all records without pagination; otherwise the value ranges from 1 to 500.pageNumber No Integer The page number to retrieve.
Response parameters
| Parameter | Type | Description |
|---|---|---|
| requestId | String | The unique ID of the request, which can be used to quickly locate the request. |
| code | String | The HTTP status code of the request.
|
| message | String | The status message of the request. |
| detailMessage | String | The detailed error information. When the request is successful, this parameter returns empty. |
| result | Object<Resources_Result> | The list of available resources. |
- Resources_Result
-
Parameter Type Description pageSize Integer The number of records per page. pageNumber Integer The current page number. count String The total number of matching records. results Array<Destination_Resource> The list of resources on the current page.
- Destination_Resource
-
Parameter Type Description id String The resource ID, which is passed as destinationId in the Assign a DID Direct Destination interface. extension String The extension number of the resource. name String The name of the resource. For a user, the value is assembled from the first and last names according to the tenant preference.
Example
Request example
POST /uc-cconfig/api/v1/tenant-dids/resources/search-page HTTP/1.1
Host: api.cn.novoone.com
Authorization: Bearer eyJraWQiOiJjbi0wLWtleS0xIiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiIxMDAwQGNvbG9ydGVzdDIiLCJncmFudF90eXBlIjoicGFzc3dvcmQiLCJ1c2VyX25hbWUiOiIxMDAwQGNvbG9ydGVzdDIiLCJzY29wZSI6WyJyZWFkIiwid3JpdGUiXSwiY2xpZW50X2V4dCI6eyJkZXNjcmlwdGlvbiI6IueuoeeQhuWQjuWPsFdlYuW6lOeUqCIsInBsYXRmb3JtIjoid2ViIn0sImV4cCI6MTc5MzYyMzU3MywiaWF0IjoxNzkzNjAxOTczLCJqdGkiOiI3OTlmMzNkYS0yNmI0LTRkNDEtYmZkMC0zZGJiMjIxYzRhNmYiLCJjbGllbnRfaWQiOiJub3ZvLWFkbWluLXdlYiIsInNpZCI6ImMwZjlmOGU3LWQ1M2QtNDFjOS04ZmZmLTNhYTQzZWUyNzU2YyIsInVzZXJfZXh0Ijp7InJvbGVJZHMiOlsxMDJdLCJwdWlkIjozMDc2OTEzNjQ0OTE1OTk4NzIwLCJ0ZW5hbnRJZCI6MjA3OTUwNDIwNTMwOTE5NDI0MSwicGFyZW50VWNJZCI6MzA3NjkxMzY0NDg5MDgzMjg5NiwidGVuYW50Q29kZSI6ImNvbG9ydGVzdDIiLCJ0eXBlIjoiVF9VU0VSIiwidXNlcklkIjoyMDc5NzQ2OTE1Mzg4MDc2MDMzLCJlbWFpbCI6Imxlb0BzYW1wbGUuY29tIiwidXNlcm5hbWUiOiIxMDAwQGNvbG9ydGVzdDIiLCJ1Y0lkIjozMDc2OTEzNjQ0ODkwODMyODk2fX0.Pi7k5H5k8i02gpC3ry4JWNlkc836SfaD6a3wITzgerCEjyz9YFwX5VDYuqrQiYIsL6raVkBz_vwUaTnPdRN0xQxOeRIKOLEPaCBZCjJ_lB7IXyNrNU3O62nXefT6OpWbas6rap9K-3zpppBzxorHWD57yso1OzD-kWUhCRb3rkybe-gtOFhExl7gc3WqBgJA1V7IGoQfX4aRGhwuJ1DAC_CY5oqhE6vjw5rxWx_nCoMiN-wmsY2ou22Py7oeC83b0W21lEQY0nyECk-GCYKdJ0CBSeNKTY5ridST_QX9FBn3ETj2GrjlODRWj4tniWY2PJszVp2XswULShQoXuMsXw
x-tenant-code: jint
Content-Type: application/json
{
"destinationType": "USER",
"pageSize": 5
}
Response example
HTTP/1.1 200 OK { "requestId": "bb4ec4fe4eb6a7163a1eabb1e239c08c", "code": "200", "message": "SUCCESS", "detailMessage": "", "result": { "pageSize": 5, "pageNumber": 1, "count": "6", "results": [ { "id": "338136731335409664", "extension": "1000", "name": "Leo Ball" }, { "id": "342552093490561024", "extension": "1001", "name": "Terrell Smith" }, { "id": "338855950145581056", "extension": "1002", "name": "Philip Huff" }, { "id": "345441128009715712", "extension": "1003", "name": "Troy Daniel" }, { "id": "345860923599089664", "extension": "1004", "name": "Example Lee" } ] } }