From Bright Pattern Documentation
Jump to: navigation, search
imported>Tracy
m
 
(Updated via BpDeleteTranslateTags script)
 
Line 1: Line 1:
<translate>= Create Trunk=
+
= Create Trunk=
 
This method creates a trunk with the name ''<trunk_name>'' and appropriate registration data. Carrier, registration, and prefixes parameters are optional. If registration data exists in the request, outgoing registration to the carrier will be configured. Otherwise, static registration will be used.   
 
This method creates a trunk with the name ''<trunk_name>'' and appropriate registration data. Carrier, registration, and prefixes parameters are optional. If registration data exists in the request, outgoing registration to the carrier will be configured. Otherwise, static registration will be used.   
  
Line 60: Line 60:
  
 
<center>[[trunk-and-sms-account-api-specification/RequestAccessToken|< Previous]]  |  [[trunk-and-sms-account-api-specification/DeleteTrunk|Next >]]</center>
 
<center>[[trunk-and-sms-account-api-specification/RequestAccessToken|< Previous]]  |  [[trunk-and-sms-account-api-specification/DeleteTrunk|Next >]]</center>
</translate>
 

Latest revision as of 04:14, 29 May 2024

• 5.19 • 5.2 • 5.3 • 5.8

Create Trunk

This method creates a trunk with the name <trunk_name> and appropriate registration data. Carrier, registration, and prefixes parameters are optional. If registration data exists in the request, outgoing registration to the carrier will be configured. Otherwise, static registration will be used.


Request Body

URL http[s]://<host>:<port>/configapi/v2/selfservice/trunk/<trunk_name>
Method POST
Content Type Application/JSON
Body
{
   "domain":"sip.external.net",
   "carrier":"the best provider",
   "registration":{
        "number":"123456789",
        "user":"user_name",
        "password":"top_secret"
    },
   "prefixes": [
       {
         "prefix":"*",
         "cost":9
       },
       {
         "prefix":"8",
         "cost":0
       }
    ]
} 


Response

Code Description
200 Success
400 Bad arguments
403 Access denied
500 Server error



< Previous | Next >
< Previous | Next >