cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible to pass a property as access token in SOAP UI?

Highlighted
New Contributor

Is it possible to pass a property as access token in SOAP UI?

The thing is I am getting authentication token from a json responce, so I cannot use OAuth2 for automating the process of getting token.

I was able to put token in property through property transfer, but now I need to pass a value of that property to Access token. I usually do it manually, but recently started researching in order to automate this process. I am using SOAP UI, not PRO version.
Anybody have an idea?

6 REPLIES 6
Highlighted
Community Hero

Re: Is it possible to pass a property as access token in SOAP UI?

Highlighted
New Contributor

Re: Is it possible to pass a property as access token in SOAP UI?

Thank you for the answer, but I need to pass response to Access token, not in another request. Like on the image attached.

Highlighted
Community Hero

Re: Is it possible to pass a property as access token in SOAP UI?

Have you tried using property expansion for the mentioned?


Regards,
Rao.
Highlighted
New Contributor

Re: Is it possible to pass a property as access token in SOAP UI?

I did try property transfer, I created a project level property with my access token and put it in header for the request, that requires token, but it still fails. Is property extension very different from property transfer?

Highlighted
Super Contributor

Re: Is it possible to pass a property as access token in SOAP UI?

Checking the request - Raw tab it seems that property expansion does not work for the authorization tab access token field, but it does work for headers.

 

Change the name of your header to

Authorization

value to

Bearer ${#Project#access_token}

 

This would override the authorization tab access token if manually entered.

 

More threads

https://www.soapui.org/oauth2/reference/oauth-2-advanced-options.html

https://stackoverflow.com/questions/11068892/oauth-2-0-authorization-header

https://community.smartbear.com/t5/SoapUI-Open-Source/How-to-transfer-TestCase-properties-value-in-A...

https://community.smartbear.com/t5/SoapUI-Pro/Dynamically-Set-client-credentials/m-p/141040

 

Highlighted
Occasional Contributor

Re: Is it possible to pass a property as access token in SOAP UI?

thank you so much

works fine for me

New Here?
Join us and watch the welcome video:
Announcements
Top Kudoed Authors