Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

456
Views
Where to find External Id for SmsConfiguration in Cognito user pool

I use create_user_pool for creating new Cognito user pools. I see there's a SmsConfiguration option which takes an ExternalId. If you set up MFA for your user pool using the Cognito portal, this External Id (which looks like an UUID) will be used in the automatically generated IAM SMS-Role.

Where do I find/generate the value for ExternalId if I want to manually (using boto3 or AWS CLI) create the user pool and the IAM SMS role?

My MFA setup looks like this: enter image description here

over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

You're right, it's a UUID that you define in the IAM Role. Here is an example CloudFormation Template with an External ID -

CognitoSMSRole:
  Type: AWS::IAM::Role
  Properties:
    AssumeRolePolicyDocument: 
      Version: "2012-10-17"
      Statement: 
        - Effect: "Allow"
          Principal: 
            Service: 
              - "cognito-idp.amazonaws.com"
          Action: 
            - "sts:AssumeRole"
          Condition:
            StringEquals:
              "sts:ExternalId": 'this-is-my-external-id'
    Path: "/"
CognitoSMSPolicy: 
  Type: "AWS::IAM::Policy"
  Properties: 
    PolicyName: "CognitoSMSPolicy"
    PolicyDocument: 
      Version: "2012-10-17"
      Statement: 
        - Effect: "Allow"
          Action: 
            - "sns:publish"
          Resource: 
            - "*"
    Roles: 
      - Ref: CognitoSMSRole

You can also find the External ID in the console.

IAM -> Roles -> Select your Role -> Trusted Relationships

ExternalID - AWS Console

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!