Amazon Cognito Identity Provider
  1. Root
Amazon Cognito Identity Provider
  • Root
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
  1. Root

/

POST
/
Generates a user attribute verification code for the specified attribute name. Sends a message to a user with a code that they must return in a VerifyUserAttribute request.
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST '/' \
--header 'X-Amz-Target;' \
--header 'Content-Type: application/json' \
--data-raw '{
    "AccessToken": "string",
    "AttributeName": "string",
    "ClientMetadata": {
        "property1": "string",
        "property2": "string"
    }
}'
Response Response Example
200 - Example 1
{
    "CodeDeliveryDetails": {
        "Destination": "string",
        "DeliveryMedium": "SMS",
        "AttributeName": "string"
    }
}

Request

Header Params
X-Amz-Target
string 
required
Body Params application/json
Represents the request to get user attribute verification.
AccessToken
string <password>
required
A non-expired access token for the user whose attribute verification code you want to generate.
Match pattern:
[A-Za-z0-9-_=.]+
AttributeName
string 
required
The attribute name returned by the server response to get the user attribute verification code.
>= 1 characters<= 32 characters
Match pattern:
[\p{L}\p{M}\p{S}\p{N}\p{P}]+
ClientMetadata
object 
optional
A map of custom key-value pairs that you can provide as input for any custom workflows that this action triggers.
You create custom workflows by assigning Lambda functions to user pool triggers. When you use the GetUserAttributeVerificationCode API action, Amazon Cognito invokes the function that is assigned to the custom message trigger. When Amazon Cognito invokes this function, it passes a JSON payload, which the function receives as input. This payload contains a clientMetadata attribute, which provides the data that you assigned to the ClientMetadata parameter in your GetUserAttributeVerificationCode request. In your function code in Lambda, you can process the clientMetadata value to enhance your workflow for your specific needs.
For more information, see Customizing user pool Workflows with Lambda Triggers in the Amazon Cognito Developer Guide.
Examples

Responses

🟢200Success
application/json
Body
The verification code response returned by the server response to get the user attribute verification code.
CodeDeliveryDetails
object 
optional
The code delivery details returned by the server in response to the request to get the user attribute verification code.
Destination
string 
optional
The email address or phone number destination where Amazon Cognito sent the code.
DeliveryMedium
enum<string> 
optional
The method that Amazon Cognito used to send the code.
Allowed values:
SMSEMAIL
AttributeName
string 
optional
The name of the attribute that Amazon Cognito verifies with the code.
>= 1 characters<= 32 characters
Match pattern:
[\p{L}\p{M}\p{S}\p{N}\p{P}]+
🟠480ResourceNotFoundException
🟠481InvalidParameterException
🟠482TooManyRequestsException
🟠483NotAuthorizedException
🟠484UnexpectedLambdaException
🟠485UserLambdaValidationException
🟠486InvalidLambdaResponseException
🟠487InvalidSmsRoleAccessPolicyException
🟠488InvalidSmsRoleTrustRelationshipException
🟠489InvalidEmailRoleAccessPolicyException
🟠490CodeDeliveryFailureException
🟠491LimitExceededException
🟠492PasswordResetRequiredException
🟠493UserNotFoundException
🟠494UserNotConfirmedException
🟠495InternalErrorException
🟠496ForbiddenException
Modified at 2023-08-15 07:11:07
Previous
/
Next
/
Built with