Skip to main content
Solved

Access token expected in the 'X-Authorization' header

  • April 26, 2024
  • 3 replies
  • 1080 views

Forum|alt.badge.img+1

   Hello,
I got this error with the Queue, the programme can not insert data into the queue trought the api, any suggestion please?

"code": "UM1117",
    "details": null,
    "message": "Access token expected in the 'X-Authorization' header"

 

 

Thank you.

Best answer by Aaron Gleason

For anyone looking at this post currently, you must now use the /v2/authenticate API call. The above-mentioned /v1/authenticate has been deprecated. 

When you start off with this API call, you will receive a JSON message with a “token” key. That value must be saved as it is needed for subsequent API calls. That token is passed into these API calls in the header key “X-Authorization”. 

If you receive a “code” in the JSON message, that means something went wrong including the UM1117 error. Check your JSON message sent in the body to make sure it matches the expected info (e.g., for the authentication call {“username”:”abc”,”password”:”def”}).

This topic has been closed for replies.

3 replies

jon.stueveapeople
Automation Anywhere Team
Forum|alt.badge.img+7

You’ll need to Authorize via the API to retrieve an access token, or Update the access token for the user. Looking at the your message, the bot didn’t even execute the API, because it wasn’t authorized or shared the access token in the REST API command



see:https://docs.automationanywhere.com/bundle/enterprise-v2019/page/enterprise-cloud/topics/control-room/control-room-api/cloud-control-room-apis.html

v1 Authentication API: https://docs.automationanywhere.com/bundle/enterprise-v2019/page/auth-api-supported.html#tag/auth
v1 Authentication API: https://docs.automationanywhere.com/bundle/enterprise-v2019/page/auth-api-supported-v2.html

 


Forum|alt.badge.img
  • Cadet | Tier 2
  • June 19, 2024

Hi!

How did you solve it?


Forum|alt.badge.img+2
  • Cadet | Tier 2
  • Answer
  • July 24, 2025

For anyone looking at this post currently, you must now use the /v2/authenticate API call. The above-mentioned /v1/authenticate has been deprecated. 

When you start off with this API call, you will receive a JSON message with a “token” key. That value must be saved as it is needed for subsequent API calls. That token is passed into these API calls in the header key “X-Authorization”. 

If you receive a “code” in the JSON message, that means something went wrong including the UM1117 error. Check your JSON message sent in the body to make sure it matches the expected info (e.g., for the authentication call {“username”:”abc”,”password”:”def”}).