[Spce-user] Can anybody help me with a REST call?

Gerhard Jungwirth gjungwirth at sipwise.com
Wed Feb 7 06:09:40 EST 2018


the api uses relations to point you to the correct related items. (HAL[1])

So you need to start by querying the subscriber which you are interested
in. For example if you want to query it by its e164 number:

curl --user youruser:youpassword

from there you will see related item "ngcp:subscriberregistrations"
which you can use. you can also just use the "id" attribute returned for
the subscriber you want.

Hope this helps


[1]: https://en.wikipedia.org/wiki/Hypertext_Application_Language

On 2018-02-06 18:22, Walter Klomp wrote:
> Hi,
> I need to create a permanent registration via a REST call to the platform.  (Usin JSON from PHP, but any example language will do)
> for instance for user “11223344" I want a permanent registration to "+55667788 at sip.host.com:5060”
> How would I create that ?   I can’t seem to find it anywhere in the documentation examples…
> it always refers to an “id” of the subscriber, but where/how do I find that if I only have the number?  (without going into the database directly) ?  I want this to be “portable” between versions…
> Hope anybody can help.
> Yours sincerely,
> Walter Klomp
> _______________________________________________
> Spce-user mailing list
> Spce-user at lists.sipwise.com
> https://lists.sipwise.com/listinfo/spce-user

More information about the Spce-user mailing list