Get Trunk Assignments
Retrieves the assignment configuration of a trunk, including whether it is assigned to My Tenant and the reseller assignment list.
Request URL
GET {base_url}/uc-cconfig/api/v1/trunks/{trunkId}/assignments
Request parameters
- Headers
-
Parameter Required Type Description Authorization Yes String The access token used for authentication. Format: Bearer
{access_token}.
- Path parameters
-
Parameter Required Type Description trunkId Yes String The ID of the trunk. You can obtain the ID using the Search Trunks interface.
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<Trunk_Assignments_Result> | The trunk assignment configuration. |
- Trunk_Assignments_Result
-
Parameter Type Description trunkId String The ID of the trunk. assignedToMyTenant Boolean Whether the trunk is assigned to My Tenant.
true: Assigned.false: Not assigned.
resellerAssignments Array<Reseller_Assignment> The list of reseller assignments for this trunk.
- Reseller_Assignment
-
Parameter Type Description id String The ID of the assignment record. resellerId String The ID of the reseller. resellerName String The display name of the reseller. inboundLimit Integer The concurrent inbound call limit. The value -1 indicates that it inherits the trunk limit. outboundLimit Integer The concurrent outbound call limit. The value -1 indicates that it inherits the trunk limit. totalLimit Integer The total concurrent call limit. The value -1 indicates that it inherits the trunk limit. createdAt String The time when the assignment was created, in Unix timestamp format (milliseconds). updatedAt String The time when the assignment was last updated, in Unix timestamp format (milliseconds). didIds Array<String> The list of DID IDs that are assigned to this reseller and bound to this trunk. dids Array<Trunk_Assignment_DID> The DID summary list, in the same order as didIds.
- Trunk_Assignment_DID
-
Parameter Type Description didId String The ID of the DID. didDisplay String The DID number in default display format. didName String The name of the DID.
Example
Request example
GET /uc-cconfig/api/v1/trunks/367177966216302592/assignments HTTP/1.1
Host: api.cn.novoone.com
Authorization: Bearer eyJraWQiOiJjbi0wLWtleS0xIiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiJkaXN0cmlidXRvcmV4YW1wbGVAb3V0bG9vay5jb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ed28f9da4a0cad81ff763c2571", "code": "200", "message": "SUCCESS", "detailMessage": "", "result": { "trunkId": "367177966216302592", "assignedToMyTenant": true, "resellerAssignments": [] } }