Skip to Content
avatar image
Former Member

IOT HCP - Access to the requested resource is not authorized (HTTP 401)

Hi!

I am trying to post a simple message using postman but repeatedly get this error message

Access to the requested resource is not authorized (HTTP 401)

Chrome extension has been set to run incognito.

Any ideas on how to fix this?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Feb 03, 2017 at 05:37 PM

    Postman will reuse your current browser session. If you are already signed into IoT Cockpit with SAML it will ignore your Bearer authorization header. Close all browser windows (maybe even clear cache) and launch Postman new. Regards, Anton

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Feb 04, 2017 at 11:47 AM

    Hi Parminder,

    As you say that you are trying to post a message & hence you need to pass the Bearer code in Authorization header, this is generated the time you create your device.

    Use "Headers" section in Postman and under it, add "Authorization" with "Bearer <token of the device>" & it shall work, in case not, post the URL (without your SID/PID) along with parameters you are passing in the request so we can see what the problem is.

    Thanks.

    Add comment
    10|10000 characters needed characters exceeded