The API of V5 allows you to:
* request cdrs,
* request to export cdrs (for larger sets),
* modify dids/phonenumbers configuration,
* create, modify, delete routing profiles for did's,
* create, modify, delete sip users
using these endpoints:
{ "cdr_direct": "http://sbcng.3starsnet.com/api/cdr_direct/", "cdr": "http://sbcng.3starsnet.com/api/cdr/", "dids": "http://sbcng.3starsnet.com/api/dids/", "sip_users": "http://sbcng.3starsnet.com/api/sip_users/", "did_profile": "http://sbcng.3starsnet.com/api/did_profile/" }
To start you need to get an authentication Token. You can get that by sending a JSON object with your username and password as a POST request to https://sbcng.3starsnet.com/api/login.
e.g. {'username': 'mylogin', 'password': 'mypassword'} . Remember to set the Content-Type as application/json. This should give you a Token to use.
This token can then be used in any subsequent request, by putting it in the header as Authorization: Token <yourtoken> , e.g.
To get the CDRs directly, you can consult them with the api-endpoint cdr_direct:
To have the system create you a exportable file, in xlsx, json or csv, you can do so using the endpoint cdr, as a POST request:
With GET you will get an overview and status of the exported files.
Comments
0 comments
Please sign in to leave a comment.