After an end user provides the input required by the flow, the callback endpoint returns the flow to the authorization server. This endpoint requires an authorization code query parameter for authorization_code grant use cases. It also supports optional parameters such as state and session_state query parameters in the request URL. The sample shows the GET {{authPath}}/{{envID}}/davinci/oauth2/callback?code={{code}}&state={{state}}&session_state={{sessionState}} operation.

Property Description
code A string that specifies the authorization code returned by the authorization server, which will be exchanged for an access token.
state A string used to validate the response. A state value can be sent with the initial authorization request and then used later to check for a match when processing the flow response.
session_state A string that represents the end user’s login state.