cognitoidentity

package
v1.5.4-0...-4729f8b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 3, 2017 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package cognitoidentity provides a client for Amazon Cognito Identity.

Index

Examples

Constants

View Source
const (
	// ErrorCodeAccessDenied is a ErrorCode enum value
	ErrorCodeAccessDenied = "AccessDenied"

	// ErrorCodeInternalServerError is a ErrorCode enum value
	ErrorCodeInternalServerError = "InternalServerError"
)
View Source
const ServiceName = "cognito-identity"

A ServiceName is the name of the service the client will make API calls to.

Variables

This section is empty.

Functions

This section is empty.

Types

type CognitoIdentity

type CognitoIdentity struct {
	*client.Client
}

Amazon Cognito is a web service that delivers scoped temporary credentials to mobile devices and other untrusted environments. Amazon Cognito uniquely identifies a device and supplies the user with a consistent identity over the lifetime of an application.

Using Amazon Cognito, you can enable authentication with one or more third-party identity providers (Facebook, Google, or Login with Amazon), and you can also choose to support unauthenticated access from your app. Cognito delivers a unique identifier for each user and acts as an OpenID token provider trusted by AWS Security Token Service (STS) to access temporary, limited-privilege AWS credentials.

To provide end-user credentials, first make an unsigned call to GetId. If the end user is authenticated with one of the supported identity providers, set the Logins map with the identity provider token. GetId returns a unique identifier for the user.

Next, make an unsigned call to GetCredentialsForIdentity. This call expects the same Logins map as the GetId call, as well as the IdentityID originally returned by GetId. Assuming your identity pool has been configured via the SetIdentityPoolRoles operation, GetCredentialsForIdentity will return AWS credentials for your use. If your pool has not been configured with SetIdentityPoolRoles, or if you want to follow legacy flow, make an unsigned call to GetOpenIdToken, which returns the OpenID token necessary to call STS and retrieve AWS credentials. This call expects the same Logins map as the GetId call, as well as the IdentityID originally returned by GetId. The token returned by GetOpenIdToken can be passed to the STS operation AssumeRoleWithWebIdentity (http://docs.aws.amazon.com/STS/latest/APIReference/API_AssumeRoleWithWebIdentity.html) to retrieve AWS credentials.

If you want to use Amazon Cognito in an Android, iOS, or Unity application, you will probably want to make API calls via the AWS Mobile SDK. To learn more, see the AWS Mobile SDK Developer Guide (http://docs.aws.amazon.com/mobile/index.html). The service client's operations are safe to be used concurrently. It is not safe to mutate any of the client's properties though.

func New

New creates a new instance of the CognitoIdentity client with a session. If additional configuration is needed for the client instance use the optional aws.Config parameter to add your extra config.

Example:

// Create a CognitoIdentity client from just a session.
svc := cognitoidentity.New(mySession)

// Create a CognitoIdentity client with additional configuration
svc := cognitoidentity.New(mySession, aws.NewConfig().WithRegion("us-west-2"))

func (*CognitoIdentity) CreateIdentityPool

func (c *CognitoIdentity) CreateIdentityPool(input *CreateIdentityPoolInput) (*IdentityPool, error)

CreateIdentityPool API operation for Amazon Cognito Identity.

Creates a new identity pool. The identity pool is a store of user identity information that is specific to your AWS account. The limit on identity pools is 60 per account. The keys for SupportedLoginProviders are as follows: Facebook: graph.facebook.com Google: accounts.google.com Amazon: www.amazon.com Twitter: api.twitter.com Digits: www.digits.com

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation CreateIdentityPool for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

  • LimitExceededException Thrown when the total number of user pools has exceeded a preset limit.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.CreateIdentityPoolInput{
		AllowUnauthenticatedIdentities: aws.Bool(true),                 // Required
		IdentityPoolName:               aws.String("IdentityPoolName"), // Required
		CognitoIdentityProviders: []*cognitoidentity.Provider{
			{ // Required
				ClientId:     aws.String("ProviderClientId"),
				ProviderName: aws.String("ProviderName"),
			},
			// More values...
		},
		DeveloperProviderName: aws.String("DeveloperProviderName"),
		OpenIdConnectProviderARNs: []*string{
			aws.String("ARNString"), // Required
			// More values...
		},
		SamlProviderARNs: []*string{
			aws.String("ARNString"), // Required
			// More values...
		},
		SupportedLoginProviders: map[string]*string{
			"Key": aws.String("IdentityProviderId"), // Required
			// More values...
		},
	}
	resp, err := svc.CreateIdentityPool(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) CreateIdentityPoolRequest

func (c *CognitoIdentity) CreateIdentityPoolRequest(input *CreateIdentityPoolInput) (req *request.Request, output *IdentityPool)

CreateIdentityPoolRequest generates a "aws/request.Request" representing the client's request for the CreateIdentityPool operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See CreateIdentityPool for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the CreateIdentityPool method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the CreateIdentityPoolRequest method.
req, resp := client.CreateIdentityPoolRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) DeleteIdentities

func (c *CognitoIdentity) DeleteIdentities(input *DeleteIdentitiesInput) (*DeleteIdentitiesOutput, error)

DeleteIdentities API operation for Amazon Cognito Identity.

Deletes identities from an identity pool. You can specify a list of 1-60 identities that you want to delete.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation DeleteIdentities for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.DeleteIdentitiesInput{
		IdentityIdsToDelete: []*string{ // Required
			aws.String("IdentityId"), // Required
			// More values...
		},
	}
	resp, err := svc.DeleteIdentities(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) DeleteIdentitiesRequest

func (c *CognitoIdentity) DeleteIdentitiesRequest(input *DeleteIdentitiesInput) (req *request.Request, output *DeleteIdentitiesOutput)

DeleteIdentitiesRequest generates a "aws/request.Request" representing the client's request for the DeleteIdentities operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See DeleteIdentities for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the DeleteIdentities method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the DeleteIdentitiesRequest method.
req, resp := client.DeleteIdentitiesRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) DeleteIdentityPool

func (c *CognitoIdentity) DeleteIdentityPool(input *DeleteIdentityPoolInput) (*DeleteIdentityPoolOutput, error)

DeleteIdentityPool API operation for Amazon Cognito Identity.

Deletes a user pool. Once a pool is deleted, users will not be able to authenticate with the pool.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation DeleteIdentityPool for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.DeleteIdentityPoolInput{
		IdentityPoolId: aws.String("IdentityPoolId"), // Required
	}
	resp, err := svc.DeleteIdentityPool(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) DeleteIdentityPoolRequest

func (c *CognitoIdentity) DeleteIdentityPoolRequest(input *DeleteIdentityPoolInput) (req *request.Request, output *DeleteIdentityPoolOutput)

DeleteIdentityPoolRequest generates a "aws/request.Request" representing the client's request for the DeleteIdentityPool operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See DeleteIdentityPool for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the DeleteIdentityPool method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the DeleteIdentityPoolRequest method.
req, resp := client.DeleteIdentityPoolRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) DescribeIdentity

func (c *CognitoIdentity) DescribeIdentity(input *DescribeIdentityInput) (*IdentityDescription, error)

DescribeIdentity API operation for Amazon Cognito Identity.

Returns metadata related to the given identity, including when the identity was created and any associated linked logins.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation DescribeIdentity for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.DescribeIdentityInput{
		IdentityId: aws.String("IdentityId"), // Required
	}
	resp, err := svc.DescribeIdentity(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) DescribeIdentityPool

func (c *CognitoIdentity) DescribeIdentityPool(input *DescribeIdentityPoolInput) (*IdentityPool, error)

DescribeIdentityPool API operation for Amazon Cognito Identity.

Gets details about a particular identity pool, including the pool name, ID description, creation date, and current number of users.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation DescribeIdentityPool for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.DescribeIdentityPoolInput{
		IdentityPoolId: aws.String("IdentityPoolId"), // Required
	}
	resp, err := svc.DescribeIdentityPool(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) DescribeIdentityPoolRequest

func (c *CognitoIdentity) DescribeIdentityPoolRequest(input *DescribeIdentityPoolInput) (req *request.Request, output *IdentityPool)

DescribeIdentityPoolRequest generates a "aws/request.Request" representing the client's request for the DescribeIdentityPool operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See DescribeIdentityPool for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the DescribeIdentityPool method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the DescribeIdentityPoolRequest method.
req, resp := client.DescribeIdentityPoolRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) DescribeIdentityRequest

func (c *CognitoIdentity) DescribeIdentityRequest(input *DescribeIdentityInput) (req *request.Request, output *IdentityDescription)

DescribeIdentityRequest generates a "aws/request.Request" representing the client's request for the DescribeIdentity operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See DescribeIdentity for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the DescribeIdentity method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the DescribeIdentityRequest method.
req, resp := client.DescribeIdentityRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) GetCredentialsForIdentity

GetCredentialsForIdentity API operation for Amazon Cognito Identity.

Returns credentials for the provided identity ID. Any provided logins will be validated against supported login providers. If the token is for cognito-identity.amazonaws.com, it will be passed through to AWS Security Token Service with the appropriate role for the token.

This is a public API. You do not need any credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation GetCredentialsForIdentity for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InvalidIdentityPoolConfigurationException Thrown if the identity pool has no role associated for the given auth type (auth/unauth) or if the AssumeRole fails.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

  • ExternalServiceException An exception thrown when a dependent service such as Facebook or Twitter is not responding

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.GetCredentialsForIdentityInput{
		IdentityId:    aws.String("IdentityId"), // Required
		CustomRoleArn: aws.String("ARNString"),
		Logins: map[string]*string{
			"Key": aws.String("IdentityProviderToken"), // Required
			// More values...
		},
	}
	resp, err := svc.GetCredentialsForIdentity(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) GetCredentialsForIdentityRequest

func (c *CognitoIdentity) GetCredentialsForIdentityRequest(input *GetCredentialsForIdentityInput) (req *request.Request, output *GetCredentialsForIdentityOutput)

GetCredentialsForIdentityRequest generates a "aws/request.Request" representing the client's request for the GetCredentialsForIdentity operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See GetCredentialsForIdentity for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the GetCredentialsForIdentity method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the GetCredentialsForIdentityRequest method.
req, resp := client.GetCredentialsForIdentityRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) GetId

func (c *CognitoIdentity) GetId(input *GetIdInput) (*GetIdOutput, error)

GetId API operation for Amazon Cognito Identity.

Generates (or retrieves) a Cognito ID. Supplying multiple logins will create an implicit linked account.

This is a public API. You do not need any credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation GetId for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

  • LimitExceededException Thrown when the total number of user pools has exceeded a preset limit.

  • ExternalServiceException An exception thrown when a dependent service such as Facebook or Twitter is not responding

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.GetIdInput{
		IdentityPoolId: aws.String("IdentityPoolId"), // Required
		AccountId:      aws.String("AccountId"),
		Logins: map[string]*string{
			"Key": aws.String("IdentityProviderToken"), // Required
			// More values...
		},
	}
	resp, err := svc.GetId(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) GetIdRequest

func (c *CognitoIdentity) GetIdRequest(input *GetIdInput) (req *request.Request, output *GetIdOutput)

GetIdRequest generates a "aws/request.Request" representing the client's request for the GetId operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See GetId for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the GetId method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the GetIdRequest method.
req, resp := client.GetIdRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) GetIdentityPoolRoles

func (c *CognitoIdentity) GetIdentityPoolRoles(input *GetIdentityPoolRolesInput) (*GetIdentityPoolRolesOutput, error)

GetIdentityPoolRoles API operation for Amazon Cognito Identity.

Gets the roles for an identity pool.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation GetIdentityPoolRoles for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.GetIdentityPoolRolesInput{
		IdentityPoolId: aws.String("IdentityPoolId"), // Required
	}
	resp, err := svc.GetIdentityPoolRoles(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) GetIdentityPoolRolesRequest

func (c *CognitoIdentity) GetIdentityPoolRolesRequest(input *GetIdentityPoolRolesInput) (req *request.Request, output *GetIdentityPoolRolesOutput)

GetIdentityPoolRolesRequest generates a "aws/request.Request" representing the client's request for the GetIdentityPoolRoles operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See GetIdentityPoolRoles for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the GetIdentityPoolRoles method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the GetIdentityPoolRolesRequest method.
req, resp := client.GetIdentityPoolRolesRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) GetOpenIdToken

func (c *CognitoIdentity) GetOpenIdToken(input *GetOpenIdTokenInput) (*GetOpenIdTokenOutput, error)

GetOpenIdToken API operation for Amazon Cognito Identity.

Gets an OpenID token, using a known Cognito ID. This known Cognito ID is returned by GetId. You can optionally add additional logins for the identity. Supplying multiple logins creates an implicit link.

The OpenId token is valid for 15 minutes.

This is a public API. You do not need any credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation GetOpenIdToken for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

  • ExternalServiceException An exception thrown when a dependent service such as Facebook or Twitter is not responding

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.GetOpenIdTokenInput{
		IdentityId: aws.String("IdentityId"), // Required
		Logins: map[string]*string{
			"Key": aws.String("IdentityProviderToken"), // Required
			// More values...
		},
	}
	resp, err := svc.GetOpenIdToken(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) GetOpenIdTokenForDeveloperIdentity

GetOpenIdTokenForDeveloperIdentity API operation for Amazon Cognito Identity.

Registers (or retrieves) a Cognito IdentityId and an OpenID Connect token for a user authenticated by your backend authentication process. Supplying multiple logins will create an implicit linked account. You can only specify one developer provider as part of the Logins map, which is linked to the identity pool. The developer provider is the "domain" by which Cognito will refer to your users.

You can use GetOpenIdTokenForDeveloperIdentity to create a new identity and to link new logins (that is, user credentials issued by a public provider or developer provider) to an existing identity. When you want to create a new identity, the IdentityId should be null. When you want to associate a new login with an existing authenticated/unauthenticated identity, you can do so by providing the existing IdentityId. This API will create the identity in the specified IdentityPoolId.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation GetOpenIdTokenForDeveloperIdentity for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

  • DeveloperUserAlreadyRegisteredException The provided developer user identifier is already registered with Cognito under a different identity ID.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.GetOpenIdTokenForDeveloperIdentityInput{
		IdentityPoolId: aws.String("IdentityPoolId"), // Required
		Logins: map[string]*string{ // Required
			"Key": aws.String("IdentityProviderToken"), // Required
			// More values...
		},
		IdentityId:    aws.String("IdentityId"),
		TokenDuration: aws.Int64(1),
	}
	resp, err := svc.GetOpenIdTokenForDeveloperIdentity(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) GetOpenIdTokenForDeveloperIdentityRequest

func (c *CognitoIdentity) GetOpenIdTokenForDeveloperIdentityRequest(input *GetOpenIdTokenForDeveloperIdentityInput) (req *request.Request, output *GetOpenIdTokenForDeveloperIdentityOutput)

GetOpenIdTokenForDeveloperIdentityRequest generates a "aws/request.Request" representing the client's request for the GetOpenIdTokenForDeveloperIdentity operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See GetOpenIdTokenForDeveloperIdentity for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the GetOpenIdTokenForDeveloperIdentity method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the GetOpenIdTokenForDeveloperIdentityRequest method.
req, resp := client.GetOpenIdTokenForDeveloperIdentityRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) GetOpenIdTokenRequest

func (c *CognitoIdentity) GetOpenIdTokenRequest(input *GetOpenIdTokenInput) (req *request.Request, output *GetOpenIdTokenOutput)

GetOpenIdTokenRequest generates a "aws/request.Request" representing the client's request for the GetOpenIdToken operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See GetOpenIdToken for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the GetOpenIdToken method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the GetOpenIdTokenRequest method.
req, resp := client.GetOpenIdTokenRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) ListIdentities

func (c *CognitoIdentity) ListIdentities(input *ListIdentitiesInput) (*ListIdentitiesOutput, error)

ListIdentities API operation for Amazon Cognito Identity.

Lists the identities in a pool.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation ListIdentities for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.ListIdentitiesInput{
		IdentityPoolId: aws.String("IdentityPoolId"), // Required
		MaxResults:     aws.Int64(1),                 // Required
		HideDisabled:   aws.Bool(true),
		NextToken:      aws.String("PaginationKey"),
	}
	resp, err := svc.ListIdentities(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) ListIdentitiesRequest

func (c *CognitoIdentity) ListIdentitiesRequest(input *ListIdentitiesInput) (req *request.Request, output *ListIdentitiesOutput)

ListIdentitiesRequest generates a "aws/request.Request" representing the client's request for the ListIdentities operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See ListIdentities for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the ListIdentities method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the ListIdentitiesRequest method.
req, resp := client.ListIdentitiesRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) ListIdentityPools

func (c *CognitoIdentity) ListIdentityPools(input *ListIdentityPoolsInput) (*ListIdentityPoolsOutput, error)

ListIdentityPools API operation for Amazon Cognito Identity.

Lists all of the Cognito identity pools registered for your account.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation ListIdentityPools for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.ListIdentityPoolsInput{
		MaxResults: aws.Int64(1), // Required
		NextToken:  aws.String("PaginationKey"),
	}
	resp, err := svc.ListIdentityPools(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) ListIdentityPoolsRequest

func (c *CognitoIdentity) ListIdentityPoolsRequest(input *ListIdentityPoolsInput) (req *request.Request, output *ListIdentityPoolsOutput)

ListIdentityPoolsRequest generates a "aws/request.Request" representing the client's request for the ListIdentityPools operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See ListIdentityPools for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the ListIdentityPools method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the ListIdentityPoolsRequest method.
req, resp := client.ListIdentityPoolsRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) LookupDeveloperIdentity

LookupDeveloperIdentity API operation for Amazon Cognito Identity.

Retrieves the IdentityID associated with a DeveloperUserIdentifier or the list of DeveloperUserIdentifiers associated with an IdentityId for an existing identity. Either IdentityID or DeveloperUserIdentifier must not be null. If you supply only one of these values, the other value will be searched in the database and returned as a part of the response. If you supply both, DeveloperUserIdentifier will be matched against IdentityID. If the values are verified against the database, the response returns both values and is the same as the request. Otherwise a ResourceConflictException is thrown.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation LookupDeveloperIdentity for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.LookupDeveloperIdentityInput{
		IdentityPoolId:          aws.String("IdentityPoolId"), // Required
		DeveloperUserIdentifier: aws.String("DeveloperUserIdentifier"),
		IdentityId:              aws.String("IdentityId"),
		MaxResults:              aws.Int64(1),
		NextToken:               aws.String("PaginationKey"),
	}
	resp, err := svc.LookupDeveloperIdentity(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) LookupDeveloperIdentityRequest

func (c *CognitoIdentity) LookupDeveloperIdentityRequest(input *LookupDeveloperIdentityInput) (req *request.Request, output *LookupDeveloperIdentityOutput)

LookupDeveloperIdentityRequest generates a "aws/request.Request" representing the client's request for the LookupDeveloperIdentity operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See LookupDeveloperIdentity for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the LookupDeveloperIdentity method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the LookupDeveloperIdentityRequest method.
req, resp := client.LookupDeveloperIdentityRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) MergeDeveloperIdentities

MergeDeveloperIdentities API operation for Amazon Cognito Identity.

Merges two users having different IdentityIds, existing in the same identity pool, and identified by the same developer provider. You can use this action to request that discrete users be merged and identified as a single user in the Cognito environment. Cognito associates the given source user (SourceUserIdentifier) with the IdentityId of the DestinationUserIdentifier. Only developer-authenticated users can be merged. If the users to be merged are associated with the same public provider, but as two different users, an exception will be thrown.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation MergeDeveloperIdentities for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.MergeDeveloperIdentitiesInput{
		DestinationUserIdentifier: aws.String("DeveloperUserIdentifier"), // Required
		DeveloperProviderName:     aws.String("DeveloperProviderName"),   // Required
		IdentityPoolId:            aws.String("IdentityPoolId"),          // Required
		SourceUserIdentifier:      aws.String("DeveloperUserIdentifier"), // Required
	}
	resp, err := svc.MergeDeveloperIdentities(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) MergeDeveloperIdentitiesRequest

func (c *CognitoIdentity) MergeDeveloperIdentitiesRequest(input *MergeDeveloperIdentitiesInput) (req *request.Request, output *MergeDeveloperIdentitiesOutput)

MergeDeveloperIdentitiesRequest generates a "aws/request.Request" representing the client's request for the MergeDeveloperIdentities operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See MergeDeveloperIdentities for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the MergeDeveloperIdentities method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the MergeDeveloperIdentitiesRequest method.
req, resp := client.MergeDeveloperIdentitiesRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) SetIdentityPoolRoles

func (c *CognitoIdentity) SetIdentityPoolRoles(input *SetIdentityPoolRolesInput) (*SetIdentityPoolRolesOutput, error)

SetIdentityPoolRoles API operation for Amazon Cognito Identity.

Sets the roles for an identity pool. These roles are used when making calls to GetCredentialsForIdentity action.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation SetIdentityPoolRoles for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

  • ConcurrentModificationException Thrown if there are parallel requests to modify a resource.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.SetIdentityPoolRolesInput{
		IdentityPoolId: aws.String("IdentityPoolId"), // Required
		Roles: map[string]*string{ // Required
			"Key": aws.String("ARNString"), // Required
			// More values...
		},
	}
	resp, err := svc.SetIdentityPoolRoles(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) SetIdentityPoolRolesRequest

func (c *CognitoIdentity) SetIdentityPoolRolesRequest(input *SetIdentityPoolRolesInput) (req *request.Request, output *SetIdentityPoolRolesOutput)

SetIdentityPoolRolesRequest generates a "aws/request.Request" representing the client's request for the SetIdentityPoolRoles operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See SetIdentityPoolRoles for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the SetIdentityPoolRoles method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the SetIdentityPoolRolesRequest method.
req, resp := client.SetIdentityPoolRolesRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) UnlinkDeveloperIdentity

UnlinkDeveloperIdentity API operation for Amazon Cognito Identity.

Unlinks a DeveloperUserIdentifier from an existing identity. Unlinked developer users will be considered new identities next time they are seen. If, for a given Cognito identity, you remove all federated identities as well as the developer user identifier, the Cognito identity becomes inaccessible.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation UnlinkDeveloperIdentity for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.UnlinkDeveloperIdentityInput{
		DeveloperProviderName:   aws.String("DeveloperProviderName"),   // Required
		DeveloperUserIdentifier: aws.String("DeveloperUserIdentifier"), // Required
		IdentityId:              aws.String("IdentityId"),              // Required
		IdentityPoolId:          aws.String("IdentityPoolId"),          // Required
	}
	resp, err := svc.UnlinkDeveloperIdentity(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) UnlinkDeveloperIdentityRequest

func (c *CognitoIdentity) UnlinkDeveloperIdentityRequest(input *UnlinkDeveloperIdentityInput) (req *request.Request, output *UnlinkDeveloperIdentityOutput)

UnlinkDeveloperIdentityRequest generates a "aws/request.Request" representing the client's request for the UnlinkDeveloperIdentity operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See UnlinkDeveloperIdentity for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the UnlinkDeveloperIdentity method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the UnlinkDeveloperIdentityRequest method.
req, resp := client.UnlinkDeveloperIdentityRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) UnlinkIdentity

func (c *CognitoIdentity) UnlinkIdentity(input *UnlinkIdentityInput) (*UnlinkIdentityOutput, error)

UnlinkIdentity API operation for Amazon Cognito Identity.

Unlinks a federated identity from an existing account. Unlinked logins will be considered new identities next time they are seen. Removing the last linked login will make this identity inaccessible.

This is a public API. You do not need any credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation UnlinkIdentity for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

  • ExternalServiceException An exception thrown when a dependent service such as Facebook or Twitter is not responding

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.UnlinkIdentityInput{
		IdentityId: aws.String("IdentityId"), // Required
		Logins: map[string]*string{ // Required
			"Key": aws.String("IdentityProviderToken"), // Required
			// More values...
		},
		LoginsToRemove: []*string{ // Required
			aws.String("IdentityProviderName"), // Required
			// More values...
		},
	}
	resp, err := svc.UnlinkIdentity(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) UnlinkIdentityRequest

func (c *CognitoIdentity) UnlinkIdentityRequest(input *UnlinkIdentityInput) (req *request.Request, output *UnlinkIdentityOutput)

UnlinkIdentityRequest generates a "aws/request.Request" representing the client's request for the UnlinkIdentity operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See UnlinkIdentity for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the UnlinkIdentity method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the UnlinkIdentityRequest method.
req, resp := client.UnlinkIdentityRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

func (*CognitoIdentity) UpdateIdentityPool

func (c *CognitoIdentity) UpdateIdentityPool(input *IdentityPool) (*IdentityPool, error)

UpdateIdentityPool API operation for Amazon Cognito Identity.

Updates a user pool.

You must use AWS Developer credentials to call this API.

Returns awserr.Error for service API and SDK errors. Use runtime type assertions with awserr.Error's Code and Message methods to get detailed information about the error.

See the AWS API reference guide for Amazon Cognito Identity's API operation UpdateIdentityPool for usage and error information.

Returned Error Codes:

  • InvalidParameterException Thrown for missing or bad input parameter(s).

  • ResourceNotFoundException Thrown when the requested resource (for example, a dataset or record) does not exist.

  • NotAuthorizedException Thrown when a user is not authorized to access the requested resource.

  • ResourceConflictException Thrown when a user tries to use a login which is already linked to another account.

  • TooManyRequestsException Thrown when a request is throttled.

  • InternalErrorException Thrown when the service encounters an error during processing the request.

  • ConcurrentModificationException Thrown if there are parallel requests to modify a resource.

  • LimitExceededException Thrown when the total number of user pools has exceeded a preset limit.

Example
package main

import (
	"fmt"

	"github.com/aws/aws-sdk-go/aws"
	"github.com/aws/aws-sdk-go/aws/session"
	"github.com/aws/aws-sdk-go/service/cognitoidentity"
)

func main() {
	sess, err := session.NewSession()
	if err != nil {
		fmt.Println("failed to create session,", err)
		return
	}

	svc := cognitoidentity.New(sess)

	params := &cognitoidentity.IdentityPool{
		AllowUnauthenticatedIdentities: aws.Bool(true),                 // Required
		IdentityPoolId:                 aws.String("IdentityPoolId"),   // Required
		IdentityPoolName:               aws.String("IdentityPoolName"), // Required
		CognitoIdentityProviders: []*cognitoidentity.Provider{
			{ // Required
				ClientId:     aws.String("ProviderClientId"),
				ProviderName: aws.String("ProviderName"),
			},
			// More values...
		},
		DeveloperProviderName: aws.String("DeveloperProviderName"),
		OpenIdConnectProviderARNs: []*string{
			aws.String("ARNString"), // Required
			// More values...
		},
		SamlProviderARNs: []*string{
			aws.String("ARNString"), // Required
			// More values...
		},
		SupportedLoginProviders: map[string]*string{
			"Key": aws.String("IdentityProviderId"), // Required
			// More values...
		},
	}
	resp, err := svc.UpdateIdentityPool(params)

	if err != nil {
		// Print the error, cast err to awserr.Error to get the Code and
		// Message from an error.
		fmt.Println(err.Error())
		return
	}

	// Pretty-print the response data.
	fmt.Println(resp)
}
Output:

func (*CognitoIdentity) UpdateIdentityPoolRequest

func (c *CognitoIdentity) UpdateIdentityPoolRequest(input *IdentityPool) (req *request.Request, output *IdentityPool)

UpdateIdentityPoolRequest generates a "aws/request.Request" representing the client's request for the UpdateIdentityPool operation. The "output" return value can be used to capture response data after the request's "Send" method is called.

See UpdateIdentityPool for usage and error information.

Creating a request object using this method should be used when you want to inject custom logic into the request's lifecycle using a custom handler, or if you want to access properties on the request object before or after sending the request. If you just want the service response, call the UpdateIdentityPool method directly instead.

Note: You must call the "Send" method on the returned request object in order to execute the request.

// Example sending a request using the UpdateIdentityPoolRequest method.
req, resp := client.UpdateIdentityPoolRequest(params)

err := req.Send()
if err == nil { // resp is now filled
    fmt.Println(resp)
}

type CreateIdentityPoolInput

type CreateIdentityPoolInput struct {

	// TRUE if the identity pool supports unauthenticated logins.
	//
	// AllowUnauthenticatedIdentities is a required field
	AllowUnauthenticatedIdentities *bool `type:"boolean" required:"true"`

	// An array of Amazon Cognito Identity user pools.
	CognitoIdentityProviders []*Provider `type:"list"`

	// The "domain" by which Cognito will refer to your users. This name acts as
	// a placeholder that allows your backend and the Cognito service to communicate
	// about the developer provider. For the DeveloperProviderName, you can use
	// letters as well as period (.), underscore (_), and dash (-).
	//
	// Once you have set a developer provider name, you cannot change it. Please
	// take care in setting this parameter.
	DeveloperProviderName *string `min:"1" type:"string"`

	// A string that you provide.
	//
	// IdentityPoolName is a required field
	IdentityPoolName *string `min:"1" type:"string" required:"true"`

	// A list of OpendID Connect provider ARNs.
	OpenIdConnectProviderARNs []*string `type:"list"`

	// An array of Amazon Resource Names (ARNs) of the SAML provider for your identity
	// pool.
	SamlProviderARNs []*string `type:"list"`

	// Optional key:value pairs mapping provider names to provider app IDs.
	SupportedLoginProviders map[string]*string `type:"map"`
	// contains filtered or unexported fields
}

Input to the CreateIdentityPool action.

func (CreateIdentityPoolInput) GoString

func (s CreateIdentityPoolInput) GoString() string

GoString returns the string representation

func (*CreateIdentityPoolInput) SetAllowUnauthenticatedIdentities

func (s *CreateIdentityPoolInput) SetAllowUnauthenticatedIdentities(v bool) *CreateIdentityPoolInput

SetAllowUnauthenticatedIdentities sets the AllowUnauthenticatedIdentities field's value.

func (*CreateIdentityPoolInput) SetCognitoIdentityProviders

func (s *CreateIdentityPoolInput) SetCognitoIdentityProviders(v []*Provider) *CreateIdentityPoolInput

SetCognitoIdentityProviders sets the CognitoIdentityProviders field's value.

func (*CreateIdentityPoolInput) SetDeveloperProviderName

func (s *CreateIdentityPoolInput) SetDeveloperProviderName(v string) *CreateIdentityPoolInput

SetDeveloperProviderName sets the DeveloperProviderName field's value.

func (*CreateIdentityPoolInput) SetIdentityPoolName

func (s *CreateIdentityPoolInput) SetIdentityPoolName(v string) *CreateIdentityPoolInput

SetIdentityPoolName sets the IdentityPoolName field's value.

func (*CreateIdentityPoolInput) SetOpenIdConnectProviderARNs

func (s *CreateIdentityPoolInput) SetOpenIdConnectProviderARNs(v []*string) *CreateIdentityPoolInput

SetOpenIdConnectProviderARNs sets the OpenIdConnectProviderARNs field's value.

func (*CreateIdentityPoolInput) SetSamlProviderARNs

func (s *CreateIdentityPoolInput) SetSamlProviderARNs(v []*string) *CreateIdentityPoolInput

SetSamlProviderARNs sets the SamlProviderARNs field's value.

func (*CreateIdentityPoolInput) SetSupportedLoginProviders

func (s *CreateIdentityPoolInput) SetSupportedLoginProviders(v map[string]*string) *CreateIdentityPoolInput

SetSupportedLoginProviders sets the SupportedLoginProviders field's value.

func (CreateIdentityPoolInput) String

func (s CreateIdentityPoolInput) String() string

String returns the string representation

func (*CreateIdentityPoolInput) Validate

func (s *CreateIdentityPoolInput) Validate() error

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

type Credentials

type Credentials struct {

	// The Access Key portion of the credentials.
	AccessKeyId *string `type:"string"`

	// The date at which these credentials will expire.
	Expiration *time.Time `type:"timestamp" timestampFormat:"unix"`

	// The Secret Access Key portion of the credentials
	SecretKey *string `type:"string"`

	// The Session Token portion of the credentials
	SessionToken *string `type:"string"`
	// contains filtered or unexported fields
}

Credentials for the provided identity ID.

func (Credentials) GoString

func (s Credentials) GoString() string

GoString returns the string representation

func (*Credentials) SetAccessKeyId

func (s *Credentials) SetAccessKeyId(v string) *Credentials

SetAccessKeyId sets the AccessKeyId field's value.

func (*Credentials) SetExpiration

func (s *Credentials) SetExpiration(v time.Time) *Credentials

SetExpiration sets the Expiration field's value.

func (*Credentials) SetSecretKey

func (s *Credentials) SetSecretKey(v string) *Credentials

SetSecretKey sets the SecretKey field's value.

func (*Credentials) SetSessionToken

func (s *Credentials) SetSessionToken(v string) *Credentials

SetSessionToken sets the SessionToken field's value.

func (Credentials) String

func (s Credentials) String() string

String returns the string representation

type DeleteIdentitiesInput

type DeleteIdentitiesInput struct {

	// A list of 1-60 identities that you want to delete.
	//
	// IdentityIdsToDelete is a required field
	IdentityIdsToDelete []*string `min:"1" type:"list" required:"true"`
	// contains filtered or unexported fields
}

Input to the DeleteIdentities action.

func (DeleteIdentitiesInput) GoString

func (s DeleteIdentitiesInput) GoString() string

GoString returns the string representation

func (*DeleteIdentitiesInput) SetIdentityIdsToDelete

func (s *DeleteIdentitiesInput) SetIdentityIdsToDelete(v []*string) *DeleteIdentitiesInput

SetIdentityIdsToDelete sets the IdentityIdsToDelete field's value.

func (DeleteIdentitiesInput) String

func (s DeleteIdentitiesInput) String() string

String returns the string representation

func (*DeleteIdentitiesInput) Validate

func (s *DeleteIdentitiesInput) Validate() error

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

type DeleteIdentitiesOutput

type DeleteIdentitiesOutput struct {

	// An array of UnprocessedIdentityId objects, each of which contains an ErrorCode
	// and IdentityId.
	UnprocessedIdentityIds []*UnprocessedIdentityId `type:"list"`
	// contains filtered or unexported fields
}

Returned in response to a successful DeleteIdentities operation.

func (DeleteIdentitiesOutput) GoString

func (s DeleteIdentitiesOutput) GoString() string

GoString returns the string representation

func (*DeleteIdentitiesOutput) SetUnprocessedIdentityIds

func (s *DeleteIdentitiesOutput) SetUnprocessedIdentityIds(v []*UnprocessedIdentityId) *DeleteIdentitiesOutput

SetUnprocessedIdentityIds sets the UnprocessedIdentityIds field's value.

func (DeleteIdentitiesOutput) String

func (s DeleteIdentitiesOutput) String() string

String returns the string representation

type DeleteIdentityPoolInput

type DeleteIdentityPoolInput struct {

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`
	// contains filtered or unexported fields
}

Input to the DeleteIdentityPool action.

func (DeleteIdentityPoolInput) GoString

func (s DeleteIdentityPoolInput) GoString() string

GoString returns the string representation

func (*DeleteIdentityPoolInput) SetIdentityPoolId

func (s *DeleteIdentityPoolInput) SetIdentityPoolId(v string) *DeleteIdentityPoolInput

SetIdentityPoolId sets the IdentityPoolId field's value.

func (DeleteIdentityPoolInput) String

func (s DeleteIdentityPoolInput) String() string

String returns the string representation

func (*DeleteIdentityPoolInput) Validate

func (s *DeleteIdentityPoolInput) Validate() error

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

type DeleteIdentityPoolOutput

type DeleteIdentityPoolOutput struct {
	// contains filtered or unexported fields
}

func (DeleteIdentityPoolOutput) GoString

func (s DeleteIdentityPoolOutput) GoString() string

GoString returns the string representation

func (DeleteIdentityPoolOutput) String

func (s DeleteIdentityPoolOutput) String() string

String returns the string representation

type DescribeIdentityInput

type DescribeIdentityInput struct {

	// A unique identifier in the format REGION:GUID.
	//
	// IdentityId is a required field
	IdentityId *string `min:"1" type:"string" required:"true"`
	// contains filtered or unexported fields
}

Input to the DescribeIdentity action.

func (DescribeIdentityInput) GoString

func (s DescribeIdentityInput) GoString() string

GoString returns the string representation

func (*DescribeIdentityInput) SetIdentityId

func (s *DescribeIdentityInput) SetIdentityId(v string) *DescribeIdentityInput

SetIdentityId sets the IdentityId field's value.

func (DescribeIdentityInput) String

func (s DescribeIdentityInput) String() string

String returns the string representation

func (*DescribeIdentityInput) Validate

func (s *DescribeIdentityInput) Validate() error

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

type DescribeIdentityPoolInput

type DescribeIdentityPoolInput struct {

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`
	// contains filtered or unexported fields
}

Input to the DescribeIdentityPool action.

func (DescribeIdentityPoolInput) GoString

func (s DescribeIdentityPoolInput) GoString() string

GoString returns the string representation

func (*DescribeIdentityPoolInput) SetIdentityPoolId

SetIdentityPoolId sets the IdentityPoolId field's value.

func (DescribeIdentityPoolInput) String

func (s DescribeIdentityPoolInput) String() string

String returns the string representation

func (*DescribeIdentityPoolInput) Validate

func (s *DescribeIdentityPoolInput) Validate() error

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

type GetCredentialsForIdentityInput

type GetCredentialsForIdentityInput struct {

	// The Amazon Resource Name (ARN) of the role to be assumed when multiple roles
	// were received in the token from the identity provider. For example, a SAML-based
	// identity provider. This parameter is optional for identity providers that
	// do not support role customization.
	CustomRoleArn *string `min:"20" type:"string"`

	// A unique identifier in the format REGION:GUID.
	//
	// IdentityId is a required field
	IdentityId *string `min:"1" type:"string" required:"true"`

	// A set of optional name-value pairs that map provider names to provider tokens.
	Logins map[string]*string `type:"map"`
	// contains filtered or unexported fields
}

Input to the GetCredentialsForIdentity action.

func (GetCredentialsForIdentityInput) GoString

GoString returns the string representation

func (*GetCredentialsForIdentityInput) SetCustomRoleArn

SetCustomRoleArn sets the CustomRoleArn field's value.

func (*GetCredentialsForIdentityInput) SetIdentityId

SetIdentityId sets the IdentityId field's value.

func (*GetCredentialsForIdentityInput) SetLogins

SetLogins sets the Logins field's value.

func (GetCredentialsForIdentityInput) String

String returns the string representation

func (*GetCredentialsForIdentityInput) Validate

func (s *GetCredentialsForIdentityInput) Validate() error

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

type GetCredentialsForIdentityOutput

type GetCredentialsForIdentityOutput struct {

	// Credentials for the provided identity ID.
	Credentials *Credentials `type:"structure"`

	// A unique identifier in the format REGION:GUID.
	IdentityId *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

Returned in response to a successful GetCredentialsForIdentity operation.

func (GetCredentialsForIdentityOutput) GoString

GoString returns the string representation

func (*GetCredentialsForIdentityOutput) SetCredentials

SetCredentials sets the Credentials field's value.

func (*GetCredentialsForIdentityOutput) SetIdentityId

SetIdentityId sets the IdentityId field's value.

func (GetCredentialsForIdentityOutput) String

String returns the string representation

type GetIdInput

type GetIdInput struct {

	// A standard AWS account ID (9+ digits).
	AccountId *string `min:"1" type:"string"`

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`

	// A set of optional name-value pairs that map provider names to provider tokens.
	//
	// The available provider names for Logins are as follows: Facebook: graph.facebook.com
	//
	// Google: accounts.google.com
	// Amazon: www.amazon.com
	// Twitter: api.twitter.com
	// Digits: www.digits.com
	Logins map[string]*string `type:"map"`
	// contains filtered or unexported fields
}

Input to the GetId action.

func (GetIdInput) GoString

func (s GetIdInput) GoString() string

GoString returns the string representation

func (*GetIdInput) SetAccountId

func (s *GetIdInput) SetAccountId(v string) *GetIdInput

SetAccountId sets the AccountId field's value.

func (*GetIdInput) SetIdentityPoolId

func (s *GetIdInput) SetIdentityPoolId(v string) *GetIdInput

SetIdentityPoolId sets the IdentityPoolId field's value.

func (*GetIdInput) SetLogins

func (s *GetIdInput) SetLogins(v map[string]*string) *GetIdInput

SetLogins sets the Logins field's value.

func (GetIdInput) String

func (s GetIdInput) String() string

String returns the string representation

func (*GetIdInput) Validate

func (s *GetIdInput) Validate() error

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

type GetIdOutput

type GetIdOutput struct {

	// A unique identifier in the format REGION:GUID.
	IdentityId *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

Returned in response to a GetId request.

func (GetIdOutput) GoString

func (s GetIdOutput) GoString() string

GoString returns the string representation

func (*GetIdOutput) SetIdentityId

func (s *GetIdOutput) SetIdentityId(v string) *GetIdOutput

SetIdentityId sets the IdentityId field's value.

func (GetIdOutput) String

func (s GetIdOutput) String() string

String returns the string representation

type GetIdentityPoolRolesInput

type GetIdentityPoolRolesInput struct {

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`
	// contains filtered or unexported fields
}

Input to the GetIdentityPoolRoles action.

func (GetIdentityPoolRolesInput) GoString

func (s GetIdentityPoolRolesInput) GoString() string

GoString returns the string representation

func (*GetIdentityPoolRolesInput) SetIdentityPoolId

SetIdentityPoolId sets the IdentityPoolId field's value.

func (GetIdentityPoolRolesInput) String

func (s GetIdentityPoolRolesInput) String() string

String returns the string representation

func (*GetIdentityPoolRolesInput) Validate

func (s *GetIdentityPoolRolesInput) Validate() error

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

type GetIdentityPoolRolesOutput

type GetIdentityPoolRolesOutput struct {

	// An identity pool ID in the format REGION:GUID.
	IdentityPoolId *string `min:"1" type:"string"`

	// The map of roles associated with this pool. Currently only authenticated
	// and unauthenticated roles are supported.
	Roles map[string]*string `type:"map"`
	// contains filtered or unexported fields
}

Returned in response to a successful GetIdentityPoolRoles operation.

func (GetIdentityPoolRolesOutput) GoString

func (s GetIdentityPoolRolesOutput) GoString() string

GoString returns the string representation

func (*GetIdentityPoolRolesOutput) SetIdentityPoolId

SetIdentityPoolId sets the IdentityPoolId field's value.

func (*GetIdentityPoolRolesOutput) SetRoles

SetRoles sets the Roles field's value.

func (GetIdentityPoolRolesOutput) String

String returns the string representation

type GetOpenIdTokenForDeveloperIdentityInput

type GetOpenIdTokenForDeveloperIdentityInput struct {

	// A unique identifier in the format REGION:GUID.
	IdentityId *string `min:"1" type:"string"`

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`

	// A set of optional name-value pairs that map provider names to provider tokens.
	// Each name-value pair represents a user from a public provider or developer
	// provider. If the user is from a developer provider, the name-value pair will
	// follow the syntax "developer_provider_name": "developer_user_identifier".
	// The developer provider is the "domain" by which Cognito will refer to your
	// users; you provided this domain while creating/updating the identity pool.
	// The developer user identifier is an identifier from your backend that uniquely
	// identifies a user. When you create an identity pool, you can specify the
	// supported logins.
	//
	// Logins is a required field
	Logins map[string]*string `type:"map" required:"true"`

	// The expiration time of the token, in seconds. You can specify a custom expiration
	// time for the token so that you can cache it. If you don't provide an expiration
	// time, the token is valid for 15 minutes. You can exchange the token with
	// Amazon STS for temporary AWS credentials, which are valid for a maximum of
	// one hour. The maximum token duration you can set is 24 hours. You should
	// take care in setting the expiration time for a token, as there are significant
	// security implications: an attacker could use a leaked token to access your
	// AWS resources for the token's duration.
	TokenDuration *int64 `min:"1" type:"long"`
	// contains filtered or unexported fields
}

Input to the GetOpenIdTokenForDeveloperIdentity action.

func (GetOpenIdTokenForDeveloperIdentityInput) GoString

GoString returns the string representation

func (*GetOpenIdTokenForDeveloperIdentityInput) SetIdentityId

SetIdentityId sets the IdentityId field's value.

func (*GetOpenIdTokenForDeveloperIdentityInput) SetIdentityPoolId

SetIdentityPoolId sets the IdentityPoolId field's value.

func (*GetOpenIdTokenForDeveloperIdentityInput) SetLogins

SetLogins sets the Logins field's value.

func (*GetOpenIdTokenForDeveloperIdentityInput) SetTokenDuration

SetTokenDuration sets the TokenDuration field's value.

func (GetOpenIdTokenForDeveloperIdentityInput) String

String returns the string representation

func (*GetOpenIdTokenForDeveloperIdentityInput) Validate

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

type GetOpenIdTokenForDeveloperIdentityOutput

type GetOpenIdTokenForDeveloperIdentityOutput struct {

	// A unique identifier in the format REGION:GUID.
	IdentityId *string `min:"1" type:"string"`

	// An OpenID token.
	Token *string `type:"string"`
	// contains filtered or unexported fields
}

Returned in response to a successful GetOpenIdTokenForDeveloperIdentity request.

func (GetOpenIdTokenForDeveloperIdentityOutput) GoString

GoString returns the string representation

func (*GetOpenIdTokenForDeveloperIdentityOutput) SetIdentityId

SetIdentityId sets the IdentityId field's value.

func (*GetOpenIdTokenForDeveloperIdentityOutput) SetToken

SetToken sets the Token field's value.

func (GetOpenIdTokenForDeveloperIdentityOutput) String

String returns the string representation

type GetOpenIdTokenInput

type GetOpenIdTokenInput struct {

	// A unique identifier in the format REGION:GUID.
	//
	// IdentityId is a required field
	IdentityId *string `min:"1" type:"string" required:"true"`

	// A set of optional name-value pairs that map provider names to provider tokens.
	// When using graph.facebook.com and www.amazon.com, supply the access_token
	// returned from the provider's authflow. For accounts.google.com or any other
	// OpenId Connect provider, always include the id_token.
	Logins map[string]*string `type:"map"`
	// contains filtered or unexported fields
}

Input to the GetOpenIdToken action.

func (GetOpenIdTokenInput) GoString

func (s GetOpenIdTokenInput) GoString() string

GoString returns the string representation

func (*GetOpenIdTokenInput) SetIdentityId

func (s *GetOpenIdTokenInput) SetIdentityId(v string) *GetOpenIdTokenInput

SetIdentityId sets the IdentityId field's value.

func (*GetOpenIdTokenInput) SetLogins

func (s *GetOpenIdTokenInput) SetLogins(v map[string]*string) *GetOpenIdTokenInput

SetLogins sets the Logins field's value.

func (GetOpenIdTokenInput) String

func (s GetOpenIdTokenInput) String() string

String returns the string representation

func (*GetOpenIdTokenInput) Validate

func (s *GetOpenIdTokenInput) Validate() error

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

type GetOpenIdTokenOutput

type GetOpenIdTokenOutput struct {

	// A unique identifier in the format REGION:GUID. Note that the IdentityId returned
	// may not match the one passed on input.
	IdentityId *string `min:"1" type:"string"`

	// An OpenID token, valid for 15 minutes.
	Token *string `type:"string"`
	// contains filtered or unexported fields
}

Returned in response to a successful GetOpenIdToken request.

func (GetOpenIdTokenOutput) GoString

func (s GetOpenIdTokenOutput) GoString() string

GoString returns the string representation

func (*GetOpenIdTokenOutput) SetIdentityId

func (s *GetOpenIdTokenOutput) SetIdentityId(v string) *GetOpenIdTokenOutput

SetIdentityId sets the IdentityId field's value.

func (*GetOpenIdTokenOutput) SetToken

SetToken sets the Token field's value.

func (GetOpenIdTokenOutput) String

func (s GetOpenIdTokenOutput) String() string

String returns the string representation

type IdentityDescription

type IdentityDescription struct {

	// Date on which the identity was created.
	CreationDate *time.Time `type:"timestamp" timestampFormat:"unix"`

	// A unique identifier in the format REGION:GUID.
	IdentityId *string `min:"1" type:"string"`

	// Date on which the identity was last modified.
	LastModifiedDate *time.Time `type:"timestamp" timestampFormat:"unix"`

	// A set of optional name-value pairs that map provider names to provider tokens.
	Logins []*string `type:"list"`
	// contains filtered or unexported fields
}

A description of the identity.

func (IdentityDescription) GoString

func (s IdentityDescription) GoString() string

GoString returns the string representation

func (*IdentityDescription) SetCreationDate

func (s *IdentityDescription) SetCreationDate(v time.Time) *IdentityDescription

SetCreationDate sets the CreationDate field's value.

func (*IdentityDescription) SetIdentityId

func (s *IdentityDescription) SetIdentityId(v string) *IdentityDescription

SetIdentityId sets the IdentityId field's value.

func (*IdentityDescription) SetLastModifiedDate

func (s *IdentityDescription) SetLastModifiedDate(v time.Time) *IdentityDescription

SetLastModifiedDate sets the LastModifiedDate field's value.

func (*IdentityDescription) SetLogins

func (s *IdentityDescription) SetLogins(v []*string) *IdentityDescription

SetLogins sets the Logins field's value.

func (IdentityDescription) String

func (s IdentityDescription) String() string

String returns the string representation

type IdentityPool

type IdentityPool struct {

	// TRUE if the identity pool supports unauthenticated logins.
	//
	// AllowUnauthenticatedIdentities is a required field
	AllowUnauthenticatedIdentities *bool `type:"boolean" required:"true"`

	// A list representing an Amazon Cognito Identity User Pool and its client ID.
	CognitoIdentityProviders []*Provider `type:"list"`

	// The "domain" by which Cognito will refer to your users.
	DeveloperProviderName *string `min:"1" type:"string"`

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`

	// A string that you provide.
	//
	// IdentityPoolName is a required field
	IdentityPoolName *string `min:"1" type:"string" required:"true"`

	// A list of OpendID Connect provider ARNs.
	OpenIdConnectProviderARNs []*string `type:"list"`

	// An array of Amazon Resource Names (ARNs) of the SAML provider for your identity
	// pool.
	SamlProviderARNs []*string `type:"list"`

	// Optional key:value pairs mapping provider names to provider app IDs.
	SupportedLoginProviders map[string]*string `type:"map"`
	// contains filtered or unexported fields
}

An object representing a Cognito identity pool.

func (IdentityPool) GoString

func (s IdentityPool) GoString() string

GoString returns the string representation

func (*IdentityPool) SetAllowUnauthenticatedIdentities

func (s *IdentityPool) SetAllowUnauthenticatedIdentities(v bool) *IdentityPool

SetAllowUnauthenticatedIdentities sets the AllowUnauthenticatedIdentities field's value.

func (*IdentityPool) SetCognitoIdentityProviders

func (s *IdentityPool) SetCognitoIdentityProviders(v []*Provider) *IdentityPool

SetCognitoIdentityProviders sets the CognitoIdentityProviders field's value.

func (*IdentityPool) SetDeveloperProviderName

func (s *IdentityPool) SetDeveloperProviderName(v string) *IdentityPool

SetDeveloperProviderName sets the DeveloperProviderName field's value.

func (*IdentityPool) SetIdentityPoolId

func (s *IdentityPool) SetIdentityPoolId(v string) *IdentityPool

SetIdentityPoolId sets the IdentityPoolId field's value.

func (*IdentityPool) SetIdentityPoolName

func (s *IdentityPool) SetIdentityPoolName(v string) *IdentityPool

SetIdentityPoolName sets the IdentityPoolName field's value.

func (*IdentityPool) SetOpenIdConnectProviderARNs

func (s *IdentityPool) SetOpenIdConnectProviderARNs(v []*string) *IdentityPool

SetOpenIdConnectProviderARNs sets the OpenIdConnectProviderARNs field's value.

func (*IdentityPool) SetSamlProviderARNs

func (s *IdentityPool) SetSamlProviderARNs(v []*string) *IdentityPool

SetSamlProviderARNs sets the SamlProviderARNs field's value.

func (*IdentityPool) SetSupportedLoginProviders

func (s *IdentityPool) SetSupportedLoginProviders(v map[string]*string) *IdentityPool

SetSupportedLoginProviders sets the SupportedLoginProviders field's value.

func (IdentityPool) String

func (s IdentityPool) String() string

String returns the string representation

func (*IdentityPool) Validate

func (s *IdentityPool) Validate() error

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

type IdentityPoolShortDescription

type IdentityPoolShortDescription struct {

	// An identity pool ID in the format REGION:GUID.
	IdentityPoolId *string `min:"1" type:"string"`

	// A string that you provide.
	IdentityPoolName *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

A description of the identity pool.

func (IdentityPoolShortDescription) GoString

func (s IdentityPoolShortDescription) GoString() string

GoString returns the string representation

func (*IdentityPoolShortDescription) SetIdentityPoolId

SetIdentityPoolId sets the IdentityPoolId field's value.

func (*IdentityPoolShortDescription) SetIdentityPoolName

SetIdentityPoolName sets the IdentityPoolName field's value.

func (IdentityPoolShortDescription) String

String returns the string representation

type ListIdentitiesInput

type ListIdentitiesInput struct {

	// An optional boolean parameter that allows you to hide disabled identities.
	// If omitted, the ListIdentities API will include disabled identities in the
	// response.
	HideDisabled *bool `type:"boolean"`

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`

	// The maximum number of identities to return.
	//
	// MaxResults is a required field
	MaxResults *int64 `min:"1" type:"integer" required:"true"`

	// A pagination token.
	NextToken *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

Input to the ListIdentities action.

func (ListIdentitiesInput) GoString

func (s ListIdentitiesInput) GoString() string

GoString returns the string representation

func (*ListIdentitiesInput) SetHideDisabled

func (s *ListIdentitiesInput) SetHideDisabled(v bool) *ListIdentitiesInput

SetHideDisabled sets the HideDisabled field's value.

func (*ListIdentitiesInput) SetIdentityPoolId

func (s *ListIdentitiesInput) SetIdentityPoolId(v string) *ListIdentitiesInput

SetIdentityPoolId sets the IdentityPoolId field's value.

func (*ListIdentitiesInput) SetMaxResults

func (s *ListIdentitiesInput) SetMaxResults(v int64) *ListIdentitiesInput

SetMaxResults sets the MaxResults field's value.

func (*ListIdentitiesInput) SetNextToken

func (s *ListIdentitiesInput) SetNextToken(v string) *ListIdentitiesInput

SetNextToken sets the NextToken field's value.

func (ListIdentitiesInput) String

func (s ListIdentitiesInput) String() string

String returns the string representation

func (*ListIdentitiesInput) Validate

func (s *ListIdentitiesInput) Validate() error

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

type ListIdentitiesOutput

type ListIdentitiesOutput struct {

	// An object containing a set of identities and associated mappings.
	Identities []*IdentityDescription `type:"list"`

	// An identity pool ID in the format REGION:GUID.
	IdentityPoolId *string `min:"1" type:"string"`

	// A pagination token.
	NextToken *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

The response to a ListIdentities request.

func (ListIdentitiesOutput) GoString

func (s ListIdentitiesOutput) GoString() string

GoString returns the string representation

func (*ListIdentitiesOutput) SetIdentities

SetIdentities sets the Identities field's value.

func (*ListIdentitiesOutput) SetIdentityPoolId

func (s *ListIdentitiesOutput) SetIdentityPoolId(v string) *ListIdentitiesOutput

SetIdentityPoolId sets the IdentityPoolId field's value.

func (*ListIdentitiesOutput) SetNextToken

func (s *ListIdentitiesOutput) SetNextToken(v string) *ListIdentitiesOutput

SetNextToken sets the NextToken field's value.

func (ListIdentitiesOutput) String

func (s ListIdentitiesOutput) String() string

String returns the string representation

type ListIdentityPoolsInput

type ListIdentityPoolsInput struct {

	// The maximum number of identities to return.
	//
	// MaxResults is a required field
	MaxResults *int64 `min:"1" type:"integer" required:"true"`

	// A pagination token.
	NextToken *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

Input to the ListIdentityPools action.

func (ListIdentityPoolsInput) GoString

func (s ListIdentityPoolsInput) GoString() string

GoString returns the string representation

func (*ListIdentityPoolsInput) SetMaxResults

SetMaxResults sets the MaxResults field's value.

func (*ListIdentityPoolsInput) SetNextToken

SetNextToken sets the NextToken field's value.

func (ListIdentityPoolsInput) String

func (s ListIdentityPoolsInput) String() string

String returns the string representation

func (*ListIdentityPoolsInput) Validate

func (s *ListIdentityPoolsInput) Validate() error

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

type ListIdentityPoolsOutput

type ListIdentityPoolsOutput struct {

	// The identity pools returned by the ListIdentityPools action.
	IdentityPools []*IdentityPoolShortDescription `type:"list"`

	// A pagination token.
	NextToken *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

The result of a successful ListIdentityPools action.

func (ListIdentityPoolsOutput) GoString

func (s ListIdentityPoolsOutput) GoString() string

GoString returns the string representation

func (*ListIdentityPoolsOutput) SetIdentityPools

SetIdentityPools sets the IdentityPools field's value.

func (*ListIdentityPoolsOutput) SetNextToken

SetNextToken sets the NextToken field's value.

func (ListIdentityPoolsOutput) String

func (s ListIdentityPoolsOutput) String() string

String returns the string representation

type LookupDeveloperIdentityInput

type LookupDeveloperIdentityInput struct {

	// A unique ID used by your backend authentication process to identify a user.
	// Typically, a developer identity provider would issue many developer user
	// identifiers, in keeping with the number of users.
	DeveloperUserIdentifier *string `min:"1" type:"string"`

	// A unique identifier in the format REGION:GUID.
	IdentityId *string `min:"1" type:"string"`

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`

	// The maximum number of identities to return.
	MaxResults *int64 `min:"1" type:"integer"`

	// A pagination token. The first call you make will have NextToken set to null.
	// After that the service will return NextToken values as needed. For example,
	// let's say you make a request with MaxResults set to 10, and there are 20
	// matches in the database. The service will return a pagination token as a
	// part of the response. This token can be used to call the API again and get
	// results starting from the 11th match.
	NextToken *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

Input to the LookupDeveloperIdentityInput action.

func (LookupDeveloperIdentityInput) GoString

func (s LookupDeveloperIdentityInput) GoString() string

GoString returns the string representation

func (*LookupDeveloperIdentityInput) SetDeveloperUserIdentifier

func (s *LookupDeveloperIdentityInput) SetDeveloperUserIdentifier(v string) *LookupDeveloperIdentityInput

SetDeveloperUserIdentifier sets the DeveloperUserIdentifier field's value.

func (*LookupDeveloperIdentityInput) SetIdentityId

SetIdentityId sets the IdentityId field's value.

func (*LookupDeveloperIdentityInput) SetIdentityPoolId

SetIdentityPoolId sets the IdentityPoolId field's value.

func (*LookupDeveloperIdentityInput) SetMaxResults

SetMaxResults sets the MaxResults field's value.

func (*LookupDeveloperIdentityInput) SetNextToken

SetNextToken sets the NextToken field's value.

func (LookupDeveloperIdentityInput) String

String returns the string representation

func (*LookupDeveloperIdentityInput) Validate

func (s *LookupDeveloperIdentityInput) Validate() error

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

type LookupDeveloperIdentityOutput

type LookupDeveloperIdentityOutput struct {

	// This is the list of developer user identifiers associated with an identity
	// ID. Cognito supports the association of multiple developer user identifiers
	// with an identity ID.
	DeveloperUserIdentifierList []*string `type:"list"`

	// A unique identifier in the format REGION:GUID.
	IdentityId *string `min:"1" type:"string"`

	// A pagination token. The first call you make will have NextToken set to null.
	// After that the service will return NextToken values as needed. For example,
	// let's say you make a request with MaxResults set to 10, and there are 20
	// matches in the database. The service will return a pagination token as a
	// part of the response. This token can be used to call the API again and get
	// results starting from the 11th match.
	NextToken *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

Returned in response to a successful LookupDeveloperIdentity action.

func (LookupDeveloperIdentityOutput) GoString

GoString returns the string representation

func (*LookupDeveloperIdentityOutput) SetDeveloperUserIdentifierList

func (s *LookupDeveloperIdentityOutput) SetDeveloperUserIdentifierList(v []*string) *LookupDeveloperIdentityOutput

SetDeveloperUserIdentifierList sets the DeveloperUserIdentifierList field's value.

func (*LookupDeveloperIdentityOutput) SetIdentityId

SetIdentityId sets the IdentityId field's value.

func (*LookupDeveloperIdentityOutput) SetNextToken

SetNextToken sets the NextToken field's value.

func (LookupDeveloperIdentityOutput) String

String returns the string representation

type MergeDeveloperIdentitiesInput

type MergeDeveloperIdentitiesInput struct {

	// User identifier for the destination user. The value should be a DeveloperUserIdentifier.
	//
	// DestinationUserIdentifier is a required field
	DestinationUserIdentifier *string `min:"1" type:"string" required:"true"`

	// The "domain" by which Cognito will refer to your users. This is a (pseudo)
	// domain name that you provide while creating an identity pool. This name acts
	// as a placeholder that allows your backend and the Cognito service to communicate
	// about the developer provider. For the DeveloperProviderName, you can use
	// letters as well as period (.), underscore (_), and dash (-).
	//
	// DeveloperProviderName is a required field
	DeveloperProviderName *string `min:"1" type:"string" required:"true"`

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`

	// User identifier for the source user. The value should be a DeveloperUserIdentifier.
	//
	// SourceUserIdentifier is a required field
	SourceUserIdentifier *string `min:"1" type:"string" required:"true"`
	// contains filtered or unexported fields
}

Input to the MergeDeveloperIdentities action.

func (MergeDeveloperIdentitiesInput) GoString

GoString returns the string representation

func (*MergeDeveloperIdentitiesInput) SetDestinationUserIdentifier

func (s *MergeDeveloperIdentitiesInput) SetDestinationUserIdentifier(v string) *MergeDeveloperIdentitiesInput

SetDestinationUserIdentifier sets the DestinationUserIdentifier field's value.

func (*MergeDeveloperIdentitiesInput) SetDeveloperProviderName

func (s *MergeDeveloperIdentitiesInput) SetDeveloperProviderName(v string) *MergeDeveloperIdentitiesInput

SetDeveloperProviderName sets the DeveloperProviderName field's value.

func (*MergeDeveloperIdentitiesInput) SetIdentityPoolId

SetIdentityPoolId sets the IdentityPoolId field's value.

func (*MergeDeveloperIdentitiesInput) SetSourceUserIdentifier

SetSourceUserIdentifier sets the SourceUserIdentifier field's value.

func (MergeDeveloperIdentitiesInput) String

String returns the string representation

func (*MergeDeveloperIdentitiesInput) Validate

func (s *MergeDeveloperIdentitiesInput) Validate() error

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

type MergeDeveloperIdentitiesOutput

type MergeDeveloperIdentitiesOutput struct {

	// A unique identifier in the format REGION:GUID.
	IdentityId *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

Returned in response to a successful MergeDeveloperIdentities action.

func (MergeDeveloperIdentitiesOutput) GoString

GoString returns the string representation

func (*MergeDeveloperIdentitiesOutput) SetIdentityId

SetIdentityId sets the IdentityId field's value.

func (MergeDeveloperIdentitiesOutput) String

String returns the string representation

type Provider

type Provider struct {

	// The client ID for the Amazon Cognito Identity User Pool.
	ClientId *string `min:"1" type:"string"`

	// The provider name for an Amazon Cognito Identity User Pool. For example,
	// cognito-idp.us-east-1.amazonaws.com/us-east-1_123456789.
	ProviderName *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

A provider representing an Amazon Cognito Identity User Pool and its client ID.

func (Provider) GoString

func (s Provider) GoString() string

GoString returns the string representation

func (*Provider) SetClientId

func (s *Provider) SetClientId(v string) *Provider

SetClientId sets the ClientId field's value.

func (*Provider) SetProviderName

func (s *Provider) SetProviderName(v string) *Provider

SetProviderName sets the ProviderName field's value.

func (Provider) String

func (s Provider) String() string

String returns the string representation

func (*Provider) Validate

func (s *Provider) Validate() error

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

type SetIdentityPoolRolesInput

type SetIdentityPoolRolesInput struct {

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`

	// The map of roles associated with this pool. For a given role, the key will
	// be either "authenticated" or "unauthenticated" and the value will be the
	// Role ARN.
	//
	// Roles is a required field
	Roles map[string]*string `type:"map" required:"true"`
	// contains filtered or unexported fields
}

Input to the SetIdentityPoolRoles action.

func (SetIdentityPoolRolesInput) GoString

func (s SetIdentityPoolRolesInput) GoString() string

GoString returns the string representation

func (*SetIdentityPoolRolesInput) SetIdentityPoolId

SetIdentityPoolId sets the IdentityPoolId field's value.

func (*SetIdentityPoolRolesInput) SetRoles

SetRoles sets the Roles field's value.

func (SetIdentityPoolRolesInput) String

func (s SetIdentityPoolRolesInput) String() string

String returns the string representation

func (*SetIdentityPoolRolesInput) Validate

func (s *SetIdentityPoolRolesInput) Validate() error

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

type SetIdentityPoolRolesOutput

type SetIdentityPoolRolesOutput struct {
	// contains filtered or unexported fields
}

func (SetIdentityPoolRolesOutput) GoString

func (s SetIdentityPoolRolesOutput) GoString() string

GoString returns the string representation

func (SetIdentityPoolRolesOutput) String

String returns the string representation

type UnlinkDeveloperIdentityInput

type UnlinkDeveloperIdentityInput struct {

	// The "domain" by which Cognito will refer to your users.
	//
	// DeveloperProviderName is a required field
	DeveloperProviderName *string `min:"1" type:"string" required:"true"`

	// A unique ID used by your backend authentication process to identify a user.
	//
	// DeveloperUserIdentifier is a required field
	DeveloperUserIdentifier *string `min:"1" type:"string" required:"true"`

	// A unique identifier in the format REGION:GUID.
	//
	// IdentityId is a required field
	IdentityId *string `min:"1" type:"string" required:"true"`

	// An identity pool ID in the format REGION:GUID.
	//
	// IdentityPoolId is a required field
	IdentityPoolId *string `min:"1" type:"string" required:"true"`
	// contains filtered or unexported fields
}

Input to the UnlinkDeveloperIdentity action.

func (UnlinkDeveloperIdentityInput) GoString

func (s UnlinkDeveloperIdentityInput) GoString() string

GoString returns the string representation

func (*UnlinkDeveloperIdentityInput) SetDeveloperProviderName

func (s *UnlinkDeveloperIdentityInput) SetDeveloperProviderName(v string) *UnlinkDeveloperIdentityInput

SetDeveloperProviderName sets the DeveloperProviderName field's value.

func (*UnlinkDeveloperIdentityInput) SetDeveloperUserIdentifier

func (s *UnlinkDeveloperIdentityInput) SetDeveloperUserIdentifier(v string) *UnlinkDeveloperIdentityInput

SetDeveloperUserIdentifier sets the DeveloperUserIdentifier field's value.

func (*UnlinkDeveloperIdentityInput) SetIdentityId

SetIdentityId sets the IdentityId field's value.

func (*UnlinkDeveloperIdentityInput) SetIdentityPoolId

SetIdentityPoolId sets the IdentityPoolId field's value.

func (UnlinkDeveloperIdentityInput) String

String returns the string representation

func (*UnlinkDeveloperIdentityInput) Validate

func (s *UnlinkDeveloperIdentityInput) Validate() error

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

type UnlinkDeveloperIdentityOutput

type UnlinkDeveloperIdentityOutput struct {
	// contains filtered or unexported fields
}

func (UnlinkDeveloperIdentityOutput) GoString

GoString returns the string representation

func (UnlinkDeveloperIdentityOutput) String

String returns the string representation

type UnlinkIdentityInput

type UnlinkIdentityInput struct {

	// A unique identifier in the format REGION:GUID.
	//
	// IdentityId is a required field
	IdentityId *string `min:"1" type:"string" required:"true"`

	// A set of optional name-value pairs that map provider names to provider tokens.
	//
	// Logins is a required field
	Logins map[string]*string `type:"map" required:"true"`

	// Provider names to unlink from this identity.
	//
	// LoginsToRemove is a required field
	LoginsToRemove []*string `type:"list" required:"true"`
	// contains filtered or unexported fields
}

Input to the UnlinkIdentity action.

func (UnlinkIdentityInput) GoString

func (s UnlinkIdentityInput) GoString() string

GoString returns the string representation

func (*UnlinkIdentityInput) SetIdentityId

func (s *UnlinkIdentityInput) SetIdentityId(v string) *UnlinkIdentityInput

SetIdentityId sets the IdentityId field's value.

func (*UnlinkIdentityInput) SetLogins

func (s *UnlinkIdentityInput) SetLogins(v map[string]*string) *UnlinkIdentityInput

SetLogins sets the Logins field's value.

func (*UnlinkIdentityInput) SetLoginsToRemove

func (s *UnlinkIdentityInput) SetLoginsToRemove(v []*string) *UnlinkIdentityInput

SetLoginsToRemove sets the LoginsToRemove field's value.

func (UnlinkIdentityInput) String

func (s UnlinkIdentityInput) String() string

String returns the string representation

func (*UnlinkIdentityInput) Validate

func (s *UnlinkIdentityInput) Validate() error

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

type UnlinkIdentityOutput

type UnlinkIdentityOutput struct {
	// contains filtered or unexported fields
}

func (UnlinkIdentityOutput) GoString

func (s UnlinkIdentityOutput) GoString() string

GoString returns the string representation

func (UnlinkIdentityOutput) String

func (s UnlinkIdentityOutput) String() string

String returns the string representation

type UnprocessedIdentityId

type UnprocessedIdentityId struct {

	// The error code indicating the type of error that occurred.
	ErrorCode *string `type:"string" enum:"ErrorCode"`

	// A unique identifier in the format REGION:GUID.
	IdentityId *string `min:"1" type:"string"`
	// contains filtered or unexported fields
}

An array of UnprocessedIdentityId objects, each of which contains an ErrorCode and IdentityId.

func (UnprocessedIdentityId) GoString

func (s UnprocessedIdentityId) GoString() string

GoString returns the string representation

func (*UnprocessedIdentityId) SetErrorCode

SetErrorCode sets the ErrorCode field's value.

func (*UnprocessedIdentityId) SetIdentityId

func (s *UnprocessedIdentityId) SetIdentityId(v string) *UnprocessedIdentityId

SetIdentityId sets the IdentityId field's value.

func (UnprocessedIdentityId) String

func (s UnprocessedIdentityId) String() string

String returns the string representation

Directories

Path Synopsis
Package cognitoidentityiface provides an interface to enable mocking the Amazon Cognito Identity service client for testing your code.
Package cognitoidentityiface provides an interface to enable mocking the Amazon Cognito Identity service client for testing your code.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL