Jump to content

Need help generating session key for Rest API


Recommended Posts

Im stuck the first step - being the steps to generate a session key.


I have enabled my ip address under the 'access' settings on the pbx


Right now I am getting a HTTP 200OK however in the Response, all i get is 'false'.


Also i dont quite understand this - {"name":"auth","value":"admin 97c9bb5fec29bfbfbd0069adb232d610"} username and md5 encrypted password - from the Rest API documentation


1) How does one generate an md5 encrypted password based on a plain text one?

When inserting the form fields for the header, - assuming the username is admin:


does name = admin

auth = password?

or value = password


Im confused as there is "name", "auth" as well as "value"


Thanks for your help

Link to comment
Share on other sites

Hi again Admin,


Just some follow up questions. I can generate the session key, but im not having much success using the session key to retrieve other data such as licensing information etc.


Also within the PBX, there is an a parameter where you can add IP addresses for 'API Access'. Can you clarify what this is for? The retrieve session key command works regardless if my public IP is in this list or not.


In terms of retrieving other information using the session key, I am getting a 403 Permission denied.


I had mistakenly thought i got it working, but it was simply a matter of me having logged into the admin interface of the PBX and the rest API call was pre-authenticating therefore was retrieving the data. If I log out of the web interface, I get 403 Permission denied.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...