AWS SDK for Go (PILOT)
API Reference

PREVIEW DOCUMENTATION - This is a preview of a new format for the AWS SDK for Go API Reference documentation. For the current AWS SDK for Go API Reference, see https://docs.aws.amazon.com/sdk-for-go/api/.

We welcome your feedback on this new version of the documentation. Send your comments to aws-sdkdocs-feedback@amazon.com.

AdminCreateUserInput

import "github.com/aws/aws-sdk-go/service/cognitoidentityprovider"

type AdminCreateUserInput struct { DesiredDeliveryMediums []*string `type:"list"` ForceAliasCreation *bool `type:"boolean"` MessageAction *string `type:"string" enum:"MessageActionType"` TemporaryPassword *string `min:"6" type:"string" sensitive:"true"` UserAttributes []*AttributeType `type:"list"` UserPoolId *string `min:"1" type:"string" required:"true"` Username *string `min:"1" type:"string" required:"true" sensitive:"true"` ValidationData []*AttributeType `type:"list"` }

Represents the request to create a user in the specified user pool.

DesiredDeliveryMediums

Type: []*string

Specify "EMAIL" if email will be used to send the welcome message. Specify "SMS" if the phone number will be used. The default value is "SMS". More than one value can be specified.

ForceAliasCreation

Type: *bool

This parameter is only used if the phone_number_verified or email_verified attribute is set to True. Otherwise, it is ignored.

If this parameter is set to True and the phone number or email address specified in the UserAttributes parameter already exists as an alias with a different user, the API call will migrate the alias from the previous user to the newly created user. The previous user will no longer be able to log in using that alias.

If this parameter is set to False, the API throws an AliasExistsException error if the alias already exists. The default value is False.

MessageAction

Type: *string

Set to "RESEND" to resend the invitation message to a user that already exists and reset the expiration limit on the user's account. Set to "SUPPRESS" to suppress sending the message. Only one value can be specified.

TemporaryPassword

Type: *string

The user's temporary password. This password must conform to the password policy that you specified when you created the user pool.

The temporary password is valid only once. To complete the Admin Create User flow, the user must enter the temporary password in the sign-in page along with a new password to be used in all future sign-ins.

This parameter is not required. If you do not specify a value, Amazon Cognito generates one for you.

The temporary password can only be used until the user account expiration limit that you specified when you created the user pool. To reset the account after that time limit, you must call AdminCreateUser again, specifying "RESEND" for the MessageAction parameter.

UserAttributes

Specifies whether the attribute is standard or custom.

UserPoolId

Type: *string

The user pool ID for the user pool where the user will be created.

UserPoolId is a required field

Username

Type: *string

The username for the user. Must be unique within the user pool. Must be a UTF-8 string between 1 and 128 characters. After the user is created, the username cannot be changed.

Username is a required field

ValidationData

Specifies whether the attribute is standard or custom.

Method

GoString

func (s AdminCreateUserInput) GoString() string

GoString returns the string representation

SetDesiredDeliveryMediums

func (s *AdminCreateUserInput) SetDesiredDeliveryMediums(v []*string) *AdminCreateUserInput

SetDesiredDeliveryMediums sets the DesiredDeliveryMediums field's value.

SetForceAliasCreation

func (s *AdminCreateUserInput) SetForceAliasCreation(v bool) *AdminCreateUserInput

SetForceAliasCreation sets the ForceAliasCreation field's value.

SetMessageAction

func (s *AdminCreateUserInput) SetMessageAction(v string) *AdminCreateUserInput

SetMessageAction sets the MessageAction field's value.

SetTemporaryPassword

func (s *AdminCreateUserInput) SetTemporaryPassword(v string) *AdminCreateUserInput

SetTemporaryPassword sets the TemporaryPassword field's value.

SetUserAttributes

func (s *AdminCreateUserInput) SetUserAttributes(v []*AttributeType) *AdminCreateUserInput

SetUserAttributes sets the UserAttributes field's value.

SetUserPoolId

func (s *AdminCreateUserInput) SetUserPoolId(v string) *AdminCreateUserInput

SetUserPoolId sets the UserPoolId field's value.

SetUsername

func (s *AdminCreateUserInput) SetUsername(v string) *AdminCreateUserInput

SetUsername sets the Username field's value.

SetValidationData

func (s *AdminCreateUserInput) SetValidationData(v []*AttributeType) *AdminCreateUserInput

SetValidationData sets the ValidationData field's value.

String

func (s AdminCreateUserInput) String() string

String returns the string representation

Validate

func (s *AdminCreateUserInput) Validate() error

Validate inspects the fields of the type to determine if they are valid.

On this page: