POST
/
public
/
v1
/
submit
/
oauth2_authenticate
Authorizations
Body
Enum options:
ACTIVITY_TYPE_OAUTH2_AUTHENTICATETimestamp (in milliseconds) of the request, used to verify liveness of user requests.
Unique identifier for a given Organization.
The parameters object containing the specific intent data for this activity.
Show details
Show details
The OAuth 2.0 credential id whose client_id and client_secret will be used in the OAuth 2.0 flow
The auth_code provided by the OAuth 2.0 provider to the end user to be exchanged for a Bearer token in the OAuth 2.0 flow
The URI the user is redirected to after they have authenticated with the OAuth 2.0 provider
An optional nonce used by the client to prevent replay/substitution of an ID token
Response
A successful response returns the following fields:The activity object containing type, intent, and result
Show activity details
Show activity details
The intent of the activity
Show intent details
Show intent details
The oauth2AuthenticateIntent object
Show oauth2AuthenticateIntent details
Show oauth2AuthenticateIntent details
The OAuth 2.0 credential id whose client_id and client_secret will be used in the OAuth 2.0 flow
The auth_code provided by the OAuth 2.0 provider to the end user to be exchanged for a Bearer token in the OAuth 2.0 flow
The URI the user is redirected to after they have authenticated with the OAuth 2.0 provider
The code verifier used by OAuth 2.0 PKCE providers
An optional nonce used by the client to prevent replay/substitution of an ID token
The result of the activity
A list of objects representing a particular User’s approval or rejection of a Consensus request, including all relevant metadata.
Copy
Ask AI
curl --request POST \
--url https://api.turnkey.com/public/v1/submit/oauth2_authenticate \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <string> (see Authorizations)" \
--data '{
"type": "ACTIVITY_TYPE_OAUTH2_AUTHENTICATE",
"timestampMs": "<string> (e.g. 1746736509954)",
"organizationId": "<string> (Your Organization ID)",
"parameters": {
"oauth2CredentialId": "<string>",
"authCode": "<string>",
"redirectUri": "<string>",
"codeVerifier": "<string>",
"nonce": "<string>",
"bearerTokenTargetPublicKey": "<string>"
}
}'
Copy
Ask AI
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_OAUTH2_AUTHENTICATE",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g. 1746736509954)",
"result": {
"activity": {
"id": "<string>",
"organizationId": "<string>",
"status": "<string>",
"type": "<string>",
"intent": {
"oauth2AuthenticateIntent": {
"oauth2CredentialId": "<string>",
"authCode": "<string>",
"redirectUri": "<string>",
"codeVerifier": "<string>",
"nonce": "<string>",
"bearerTokenTargetPublicKey": "<string>"
}
},
"result": {
"oauth2AuthenticateResult": {
"oidcToken": "<string>"
}
},
"votes": "<array>",
"fingerprint": "<string>",
"canApprove": "<boolean>",
"canReject": "<boolean>",
"createdAt": "<string>",
"updatedAt": "<string>"
}
}
}
}