API Request for authorization code by redirecting the user in JAMA connect

Rizwana Fathima
Rizwana Fathima Member Posts: 3

I am trying to get the Authorize API in Jama but can't find anything. I have attached the Document link. I saw something similar to the question I am asking in Jira.

Is there any API request available for an authorization code by redirecting the user to JAMA Connect?

For More Information:

As the same type, the request that is available in Jira and the Following Steps are,

  1. Request authorization code by redirecting the user to the "/rest/oauth2/latest/authorize" page with the following query parameters:

Postman API - "https://atlassian.example.com/rest/oauth2/latest/authorize?client_id=CLIENT_ID&redirect_uri=REDIRECT_URI&response_type=code&state=STATE&scope=SCOPE&code_challenge=CODE_CHALLENGE&code_challenge_method=S256"

  1. This consent screen asks the user to approve the application's request to access their account with the scopes specified in the scope. The user is then redirected to the URL specified in redirect_uri. The redirect includes the authorization code, like in the following example:

Postman API - https://atlassian.example.com/plugins/servlet/oauth2/consent?client_id=CLIENT_ID&redirect_uri=REDIRECT_URI&response_type=code&scope=SCOPE&state=STATE&code_challenge_method=CODE_CHALLENGE_METHOD&code_challenge=CODE_CHALLENGE

Image Reference

  1. With the authorization code returned from the previous request, you can request an access_token, with any HTTP client. The following example uses curl:

Postman API - https://atlassian.example.com/rest/oauth2/latest/token?client_id=CLIENT_ID&client_secret=CLIENT_SECRET&code=CODE&grant_type=authorization_code&redirect_uri=REDIRECT_URI&code_verifier=CODE_VERIFIER

Example response { "access_token": "eyJhbGciOiJIUzI1NiJ9.eyJpZCI6IjNmMTQ3NTUzYjg3OTQ2Y2FhMWJhYWJkZWQ0MzgwYTM4In0.EDnpBl0hd1BQzIRP--xEvyW1F6gDuiFranQCvi98b2c", "token_type": "bearer", "expires_in": 7200, "refresh_token": "eyJhbGciOiJIUzI1NiJ9.eyJpZCI6ImMwZTMxYmZjYTI2NWI0YTkwMzBiOGM2OTJjNWIyMTYwIn0.grHOsso3B3kaSxNd0QJfj1H3ayjRUuA75SiEt0usmiM", "created_at": 1607635748 }

I need just the same as this in JAMA to authorize code for reference to Jira here the link

Kindly help me to solve this!!!

------------------------------
Rizwana Fathima
SSIN
Chennai
------------------------------