Skip to main content
Question

REST Web Service using Credential Values from Locker w


Forum|alt.badge.img+1

Hello,

I’m trying to do the following authenticate using the post method instructed here - Authenticate with username and password (automationanywhere.com)

And while the following works:

{

"username": "your-domain\\jdoe",

"password": "mypassword@123"

}

I want to use my credential variables from my locker instead but that throws up an error:


{

  "username": "DOMAIN\\$TEST(Username)$",

  "password": "$TEST(Password)$"

}

 

The resulting error is - {"code":"UM1110","details":"This may be due to a misspelling or because your Caps Lock is on. To continue, please retype your username and password.","message":"Either your domain or your username or your password is incorrect"}

I would like to make it so that it’d be able to run no matter who is using it (so $$User$(Username)$) but at the moment I can’t even seem to get it to retrieve the Username correctly from the vault. Is there any way to assign it dynamically?

10 replies

Forum|alt.badge.img+6
  • Navigator | Tier 3
  • 142 replies
  • February 10, 2023

There’s a new option, this will automatically authenticate with current user.

 

Other option:

You can try following: https://botstore.automationanywhere.com/bot/a2019-credential-manager-package

This will allow you to read credential and assign to string.


Forum|alt.badge.img+1
  • Author
  • Cadet | Tier 2
  • 3 replies
  • February 10, 2023
Sumit.K7 wrote:

There’s a new option, this will automatically authenticate with current user.

 

Other option:

You can try following: https://botstore.automationanywhere.com/bot/a2019-credential-manager-package

This will allow you to read credential and assign to string.

Sorry, I forgot to mention I’m using Enterprise 11.3.5


rbkadiyam
Forum|alt.badge.img+16
  • Navigator | Tier 3
  • 578 replies
  • February 13, 2023

@Trent RPA You have to use x-authentication key 

 


rbkadiyam
Forum|alt.badge.img+16
  • Navigator | Tier 3
  • 578 replies
  • February 13, 2023

Forum|alt.badge.img+19
  • Most Valuable Pathfinder
  • 2693 replies
  • February 13, 2023

Hi @Trent RPA 

Make sure you mast sensitive information like Auth key while sharing the screenshots in public forums.


Forum|alt.badge.img+1
  • Author
  • Cadet | Tier 2
  • 3 replies
  • February 13, 2023
rbkadiyam wrote:

Hello @rbkadiyam 

Is there anyway to do this in the client version by anychance?

I’ve created a POST with the same parameters and it seems to not be working.


Forum|alt.badge.img+19
  • Most Valuable Pathfinder
  • 2693 replies
  • February 13, 2023

Hi @Trent RPA 

Have you passed this in the header? Can you share the error screenshot?


rbkadiyam
Forum|alt.badge.img+16
  • Navigator | Tier 3
  • 578 replies
  • February 13, 2023

Forum|alt.badge.img+1
  • Author
  • Cadet | Tier 2
  • 3 replies
  • February 13, 2023
rbkadiyam wrote:

I’ve passed the parameters into the headers earlier but it seems to be throwing back a 400 error.

I appreciate the time and effort though man - even if we can’t get it working this way we’ll figure something out on side 🙂


rbkadiyam
Forum|alt.badge.img+16
  • Navigator | Tier 3
  • 578 replies
  • February 14, 2023

@Trent RPA  have you added ‘authorization’ as name and values as ‘Bearer <token>’ there should be space between bearer and token… This should work 


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings