Forum Discussion

sguru's avatar
sguru
Occasional Contributor
6 years ago

How to use Oauth 2.0 with grant type password? I also need to supply Authorizatio header value.

1. I get access token like this:  (POST)

    https://url/auth-service/oauth/token?grant_type=password&username=username&password=password

2. I also set header Authorization value in the header (Authorization: Basic <token>).

 

How can I use the Authorization Profiler for the same?

 

4 Replies

  • New2API's avatar
    New2API
    Frequent Contributor

    sguru, are you using SoapUI pro or OS version. In Pro you can use Auth manager to configure OAuth 2.0. Then use that auth profile in your REST calls. Authorization token will be automatically moved to header section.

     

    In OS version, Rest testStep's Authorization section has an option to select oauth2.0. 

    • sguru's avatar
      sguru
      Occasional Contributor

      I am using Soap UI PRO 2.3.0.

      I have explored those already, the auth manager is not supporting this.

      We retrieve the auth token by giving username/password with grant=password through URL & supplying Basic Authorization as part of the header.

       

      Can you eloborate more on this how to do it in PRO?