BedrockAgentCore / Client / complete_resource_token_auth

complete_resource_token_auth

BedrockAgentCore.Client.complete_resource_token_auth(**kwargs)

Confirms the user authentication session for obtaining OAuth2.0 tokens for a resource.

See also: AWS API Documentation

Request Syntax

response = client.complete_resource_token_auth(
    userIdentifier={
        'userToken': 'string',
        'userId': 'string'
    },
    sessionUri='string'
)
Parameters:
  • userIdentifier (dict) –

    [REQUIRED]

    The OAuth2.0 token or user ID that was used to generate the workload access token used for initiating the user authorization flow to retrieve OAuth2.0 tokens.

    Note

    This is a Tagged Union structure. Only one of the following top level keys can be set: userToken, userId.

    • userToken (string) –

      The OAuth2.0 token issued by the user’s identity provider

    • userId (string) –

      The ID of the user for whom you have retrieved a workload access token for

  • sessionUri (string) –

    [REQUIRED]

    Unique identifier for the user’s authentication session for retrieving OAuth2 tokens. This ID tracks the authorization flow state across multiple requests and responses during the OAuth2 authentication process.

Return type:

dict

Returns:

Response Syntax

{}

Response Structure

  • (dict) –

Exceptions

  • BedrockAgentCore.Client.exceptions.UnauthorizedException

  • BedrockAgentCore.Client.exceptions.ValidationException

  • BedrockAgentCore.Client.exceptions.AccessDeniedException

  • BedrockAgentCore.Client.exceptions.ResourceNotFoundException

  • BedrockAgentCore.Client.exceptions.ThrottlingException

  • BedrockAgentCore.Client.exceptions.InternalServerException