{
  "typeName" : "AWS::Cognito::UserPool",
  "description" : "Resource Type definition for AWS::Cognito::UserPool",
  "additionalProperties" : false,
  "properties" : {
    "UserPoolTags" : {
      "type" : "object"
    },
    "Policies" : {
      "$ref" : "#/definitions/Policies"
    },
    "Schema" : {
      "type" : "array",
      "uniqueItems" : false,
      "items" : {
        "$ref" : "#/definitions/SchemaAttribute"
      }
    },
    "AdminCreateUserConfig" : {
      "$ref" : "#/definitions/AdminCreateUserConfig"
    },
    "UsernameConfiguration" : {
      "$ref" : "#/definitions/UsernameConfiguration"
    },
    "UserPoolName" : {
      "type" : "string"
    },
    "SmsVerificationMessage" : {
      "type" : "string"
    },
    "UserAttributeUpdateSettings" : {
      "$ref" : "#/definitions/UserAttributeUpdateSettings"
    },
    "EmailConfiguration" : {
      "$ref" : "#/definitions/EmailConfiguration"
    },
    "SmsConfiguration" : {
      "$ref" : "#/definitions/SmsConfiguration"
    },
    "EmailVerificationSubject" : {
      "type" : "string"
    },
    "AccountRecoverySetting" : {
      "$ref" : "#/definitions/AccountRecoverySetting"
    },
    "VerificationMessageTemplate" : {
      "$ref" : "#/definitions/VerificationMessageTemplate"
    },
    "ProviderURL" : {
      "type" : "string"
    },
    "MfaConfiguration" : {
      "type" : "string"
    },
    "DeletionProtection" : {
      "type" : "string"
    },
    "SmsAuthenticationMessage" : {
      "type" : "string"
    },
    "ProviderName" : {
      "type" : "string"
    },
    "UserPoolAddOns" : {
      "$ref" : "#/definitions/UserPoolAddOns"
    },
    "AliasAttributes" : {
      "type" : "array",
      "uniqueItems" : false,
      "items" : {
        "type" : "string"
      }
    },
    "EnabledMfas" : {
      "type" : "array",
      "uniqueItems" : false,
      "items" : {
        "type" : "string"
      }
    },
    "LambdaConfig" : {
      "$ref" : "#/definitions/LambdaConfig"
    },
    "Id" : {
      "type" : "string"
    },
    "Arn" : {
      "type" : "string"
    },
    "UsernameAttributes" : {
      "type" : "array",
      "uniqueItems" : false,
      "items" : {
        "type" : "string"
      }
    },
    "AutoVerifiedAttributes" : {
      "type" : "array",
      "uniqueItems" : false,
      "items" : {
        "type" : "string"
      }
    },
    "DeviceConfiguration" : {
      "$ref" : "#/definitions/DeviceConfiguration"
    },
    "EmailVerificationMessage" : {
      "type" : "string"
    }
  },
  "definitions" : {
    "Policies" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "PasswordPolicy" : {
          "$ref" : "#/definitions/PasswordPolicy"
        }
      }
    },
    "VerificationMessageTemplate" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "EmailMessageByLink" : {
          "type" : "string"
        },
        "EmailMessage" : {
          "type" : "string"
        },
        "SmsMessage" : {
          "type" : "string"
        },
        "EmailSubject" : {
          "type" : "string"
        },
        "DefaultEmailOption" : {
          "type" : "string"
        },
        "EmailSubjectByLink" : {
          "type" : "string"
        }
      }
    },
    "NumberAttributeConstraints" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "MinValue" : {
          "type" : "string"
        },
        "MaxValue" : {
          "type" : "string"
        }
      }
    },
    "InviteMessageTemplate" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "EmailSubject" : {
          "type" : "string"
        },
        "EmailMessage" : {
          "type" : "string"
        },
        "SMSMessage" : {
          "type" : "string"
        }
      }
    },
    "AdminCreateUserConfig" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "InviteMessageTemplate" : {
          "$ref" : "#/definitions/InviteMessageTemplate"
        },
        "UnusedAccountValidityDays" : {
          "type" : "integer"
        },
        "AllowAdminCreateUserOnly" : {
          "type" : "boolean"
        }
      }
    },
    "UsernameConfiguration" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "CaseSensitive" : {
          "type" : "boolean"
        }
      }
    },
    "UserPoolAddOns" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "AdvancedSecurityMode" : {
          "type" : "string"
        }
      }
    },
    "RecoveryOption" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "Priority" : {
          "type" : "integer"
        },
        "Name" : {
          "type" : "string"
        }
      }
    },
    "StringAttributeConstraints" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "MaxLength" : {
          "type" : "string"
        },
        "MinLength" : {
          "type" : "string"
        }
      }
    },
    "UserAttributeUpdateSettings" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "AttributesRequireVerificationBeforeUpdate" : {
          "type" : "array",
          "uniqueItems" : false,
          "items" : {
            "type" : "string"
          }
        }
      },
      "required" : [ "AttributesRequireVerificationBeforeUpdate" ]
    },
    "CustomSMSSender" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "LambdaArn" : {
          "type" : "string"
        },
        "LambdaVersion" : {
          "type" : "string"
        }
      }
    },
    "EmailConfiguration" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "ReplyToEmailAddress" : {
          "type" : "string"
        },
        "ConfigurationSet" : {
          "type" : "string"
        },
        "EmailSendingAccount" : {
          "type" : "string"
        },
        "From" : {
          "type" : "string"
        },
        "SourceArn" : {
          "type" : "string"
        }
      }
    },
    "SmsConfiguration" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "SnsCallerArn" : {
          "type" : "string"
        },
        "SnsRegion" : {
          "type" : "string"
        },
        "ExternalId" : {
          "type" : "string"
        }
      }
    },
    "PasswordPolicy" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "RequireNumbers" : {
          "type" : "boolean"
        },
        "MinimumLength" : {
          "type" : "integer"
        },
        "TemporaryPasswordValidityDays" : {
          "type" : "integer"
        },
        "RequireUppercase" : {
          "type" : "boolean"
        },
        "RequireLowercase" : {
          "type" : "boolean"
        },
        "RequireSymbols" : {
          "type" : "boolean"
        }
      }
    },
    "LambdaConfig" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "CreateAuthChallenge" : {
          "type" : "string"
        },
        "PreSignUp" : {
          "type" : "string"
        },
        "KMSKeyID" : {
          "type" : "string"
        },
        "UserMigration" : {
          "type" : "string"
        },
        "PostAuthentication" : {
          "type" : "string"
        },
        "VerifyAuthChallengeResponse" : {
          "type" : "string"
        },
        "PreAuthentication" : {
          "type" : "string"
        },
        "DefineAuthChallenge" : {
          "type" : "string"
        },
        "PreTokenGeneration" : {
          "type" : "string"
        },
        "CustomSMSSender" : {
          "$ref" : "#/definitions/CustomSMSSender"
        },
        "PostConfirmation" : {
          "type" : "string"
        },
        "CustomMessage" : {
          "type" : "string"
        },
        "CustomEmailSender" : {
          "$ref" : "#/definitions/CustomEmailSender"
        }
      }
    },
    "CustomEmailSender" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "LambdaArn" : {
          "type" : "string"
        },
        "LambdaVersion" : {
          "type" : "string"
        }
      }
    },
    "SchemaAttribute" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "DeveloperOnlyAttribute" : {
          "type" : "boolean"
        },
        "Mutable" : {
          "type" : "boolean"
        },
        "AttributeDataType" : {
          "type" : "string"
        },
        "StringAttributeConstraints" : {
          "$ref" : "#/definitions/StringAttributeConstraints"
        },
        "Required" : {
          "type" : "boolean"
        },
        "NumberAttributeConstraints" : {
          "$ref" : "#/definitions/NumberAttributeConstraints"
        },
        "Name" : {
          "type" : "string"
        }
      }
    },
    "DeviceConfiguration" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "DeviceOnlyRememberedOnUserPrompt" : {
          "type" : "boolean"
        },
        "ChallengeRequiredOnNewDevice" : {
          "type" : "boolean"
        }
      }
    },
    "AccountRecoverySetting" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "RecoveryMechanisms" : {
          "type" : "array",
          "uniqueItems" : false,
          "items" : {
            "$ref" : "#/definitions/RecoveryOption"
          }
        }
      }
    }
  },
  "primaryIdentifier" : [ "/properties/Id" ],
  "readOnlyProperties" : [ "/properties/Id", "/properties/Arn", "/properties/ProviderName", "/properties/ProviderURL" ]
}