cognitoidentity

package
v0.6.5-0...-469e9fb Latest Latest
Warning

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

Go to latest
Published: Jul 1, 2015 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package cognitoidentity provides a client for Amazon Cognito Identity.

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CognitoIdentity

type CognitoIdentity struct {
	*aws.Service
}

CognitoIdentity is a client for Amazon Cognito Identity.

func New

func New(config *aws.Config) *CognitoIdentity

New returns a new CognitoIdentity client.

func (*CognitoIdentity) CreateIdentityPool

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

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. You must use AWS Developer credentials to call this API.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

	params := &cognitoidentity.CreateIdentityPoolInput{
		AllowUnauthenticatedIdentities: aws.Boolean(true),              // Required
		IdentityPoolName:               aws.String("IdentityPoolName"), // Required
		DeveloperProviderName:          aws.String("DeveloperProviderName"),
		OpenIDConnectProviderARNs: []*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 {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) CreateIdentityPoolRequest

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

CreateIdentityPoolRequest generates a request for the CreateIdentityPool operation.

func (*CognitoIdentity) DeleteIdentities

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

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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

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

	if err != nil {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) DeleteIdentitiesRequest

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

DeleteIdentitiesRequest generates a request for the DeleteIdentities operation.

func (*CognitoIdentity) DeleteIdentityPool

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

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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

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

	if err != nil {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) DeleteIdentityPoolRequest

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

DeleteIdentityPoolRequest generates a request for the DeleteIdentityPool operation.

func (*CognitoIdentity) DescribeIdentity

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

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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

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

	if err != nil {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) DescribeIdentityPool

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

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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

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

	if err != nil {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) DescribeIdentityPoolRequest

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

DescribeIdentityPoolRequest generates a request for the DescribeIdentityPool operation.

func (*CognitoIdentity) DescribeIdentityRequest

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

DescribeIdentityRequest generates a request for the DescribeIdentity operation.

func (*CognitoIdentity) GetCredentialsForIdentity

Returns credentials for the 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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

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

	if err != nil {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) GetCredentialsForIdentityRequest

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

GetCredentialsForIdentityRequest generates a request for the GetCredentialsForIdentity operation.

func (*CognitoIdentity) GetID

func (c *CognitoIdentity) GetID(input *GetIDInput) (*GetIDOutput, error)

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

token+";"+tokenSecret.

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

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

	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 {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) GetIDRequest

func (c *CognitoIdentity) GetIDRequest(input *GetIDInput) (req *aws.Request, output *GetIDOutput)

GetIDRequest generates a request for the GetID operation.

func (*CognitoIdentity) GetIdentityPoolRoles

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

Gets the roles for an identity pool.

You must use AWS Developer credentials to call this API.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

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

	if err != nil {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) GetIdentityPoolRolesRequest

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

GetIdentityPoolRolesRequest generates a request for the GetIdentityPoolRoles operation.

func (*CognitoIdentity) GetOpenIDToken

func (c *CognitoIdentity) GetOpenIDToken(input *GetOpenIDTokenInput) (*GetOpenIDTokenOutput, error)

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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

	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 {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) GetOpenIDTokenForDeveloperIdentity

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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

	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.Long(1),
	}
	resp, err := svc.GetOpenIDTokenForDeveloperIdentity(params)

	if err != nil {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) GetOpenIDTokenForDeveloperIdentityRequest

func (c *CognitoIdentity) GetOpenIDTokenForDeveloperIdentityRequest(input *GetOpenIDTokenForDeveloperIdentityInput) (req *aws.Request, output *GetOpenIDTokenForDeveloperIdentityOutput)

GetOpenIDTokenForDeveloperIdentityRequest generates a request for the GetOpenIDTokenForDeveloperIdentity operation.

func (*CognitoIdentity) GetOpenIDTokenRequest

func (c *CognitoIdentity) GetOpenIDTokenRequest(input *GetOpenIDTokenInput) (req *aws.Request, output *GetOpenIDTokenOutput)

GetOpenIDTokenRequest generates a request for the GetOpenIDToken operation.

func (*CognitoIdentity) ListIdentities

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

Lists the identities in a pool.

You must use AWS Developer credentials to call this API.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

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

	if err != nil {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) ListIdentitiesRequest

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

ListIdentitiesRequest generates a request for the ListIdentities operation.

func (*CognitoIdentity) ListIdentityPools

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

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

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

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

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

	if err != nil {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) ListIdentityPoolsRequest

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

ListIdentityPoolsRequest generates a request for the ListIdentityPools operation.

func (*CognitoIdentity) LookupDeveloperIdentity

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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

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

	if err != nil {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) LookupDeveloperIdentityRequest

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

LookupDeveloperIdentityRequest generates a request for the LookupDeveloperIdentity operation.

func (*CognitoIdentity) MergeDeveloperIdentities

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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

	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 {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) MergeDeveloperIdentitiesRequest

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

MergeDeveloperIdentitiesRequest generates a request for the MergeDeveloperIdentities operation.

func (*CognitoIdentity) SetIdentityPoolRoles

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

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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

	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 {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) SetIdentityPoolRolesRequest

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

SetIdentityPoolRolesRequest generates a request for the SetIdentityPoolRoles operation.

func (*CognitoIdentity) UnlinkDeveloperIdentity

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.

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

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

	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 {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) UnlinkDeveloperIdentityRequest

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

UnlinkDeveloperIdentityRequest generates a request for the UnlinkDeveloperIdentity operation.

func (*CognitoIdentity) UnlinkIdentity

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

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.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

	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 {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) UnlinkIdentityRequest

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

UnlinkIdentityRequest generates a request for the UnlinkIdentity operation.

func (*CognitoIdentity) UpdateIdentityPool

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

Updates a user pool.

You must use AWS Developer credentials to call this API.

Example
package main

import (
	"fmt"

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

func main() {
	svc := cognitoidentity.New(nil)

	params := &cognitoidentity.IdentityPool{
		AllowUnauthenticatedIdentities: aws.Boolean(true),              // Required
		IdentityPoolID:                 aws.String("IdentityPoolId"),   // Required
		IdentityPoolName:               aws.String("IdentityPoolName"), // Required
		DeveloperProviderName:          aws.String("DeveloperProviderName"),
		OpenIDConnectProviderARNs: []*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 {
		if awsErr, ok := err.(awserr.Error); ok {
			// Generic AWS Error with Code, Message, and original error (if any)
			fmt.Println(awsErr.Code(), awsErr.Message(), awsErr.OrigErr())
			if reqErr, ok := err.(awserr.RequestFailure); ok {
				// A service error occurred
				fmt.Println(reqErr.Code(), reqErr.Message(), reqErr.StatusCode(), reqErr.RequestID())
			}
		} else {
			// This case should never be hit, the SDK should always return an
			// error which satisfies the awserr.Error interface.
			fmt.Println(err.Error())
		}
	}

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

func (*CognitoIdentity) UpdateIdentityPoolRequest

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

UpdateIdentityPoolRequest generates a request for the UpdateIdentityPool operation.

type CreateIdentityPoolInput

type CreateIdentityPoolInput struct {
	// TRUE if the identity pool supports unauthenticated logins.
	AllowUnauthenticatedIdentities *bool `type:"boolean" required:"true"`

	// 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 `type:"string"`

	// A string that you provide.
	IdentityPoolName *string `type:"string" required:"true"`

	// A list of OpendID Connect provider ARNs.
	OpenIDConnectProviderARNs []*string `locationName:"OpenIdConnectProviderARNs" 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) String

func (s CreateIdentityPoolInput) String() string

String returns the string representation

type Credentials

type Credentials struct {
	// The Access Key portion of the credentials.
	AccessKeyID *string `locationName:"AccessKeyId" 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 the provided identity ID.

func (Credentials) GoString

func (s Credentials) GoString() string

GoString returns the string representation

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 []*string `locationName:"IdentityIdsToDelete" 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) String

func (s DeleteIdentitiesInput) String() string

String returns the string representation

type DeleteIdentitiesOutput

type DeleteIdentitiesOutput struct {
	// An array of UnprocessedIdentityId objects, each of which contains an ErrorCode
	// and IdentityId.
	UnprocessedIdentityIDs []*UnprocessedIdentityID `locationName:"UnprocessedIdentityIds" 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) 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 *string `locationName:"IdentityPoolId" 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) String

func (s DeleteIdentityPoolInput) String() string

String returns the string representation

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 *string `locationName:"IdentityId" 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) String

func (s DescribeIdentityInput) String() string

String returns the string representation

type DescribeIdentityPoolInput

type DescribeIdentityPoolInput struct {
	// An identity pool ID in the format REGION:GUID.
	IdentityPoolID *string `locationName:"IdentityPoolId" 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) String

func (s DescribeIdentityPoolInput) String() string

String returns the string representation

type GetCredentialsForIdentityInput

type GetCredentialsForIdentityInput struct {
	// A unique identifier in the format REGION:GUID.
	IdentityID *string `locationName:"IdentityId" 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) String

String returns the string representation

type GetCredentialsForIdentityOutput

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

	// A unique identifier in the format REGION:GUID.
	IdentityID *string `locationName:"IdentityId" 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) String

String returns the string representation

type GetIDInput

type GetIDInput struct {
	// A standard AWS account ID (9+ digits).
	AccountID *string `locationName:"AccountId" type:"string"`

	// An identity pool ID in the format REGION:GUID.
	IdentityPoolID *string `locationName:"IdentityPoolId" 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: www.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) String

func (s GetIDInput) String() string

String returns the string representation

type GetIDOutput

type GetIDOutput struct {
	// A unique identifier in the format REGION:GUID.
	IdentityID *string `locationName:"IdentityId" 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) 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 *string `locationName:"IdentityPoolId" 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) String

func (s GetIdentityPoolRolesInput) String() string

String returns the string representation

type GetIdentityPoolRolesOutput

type GetIdentityPoolRolesOutput struct {
	// An identity pool ID in the format REGION:GUID.
	IdentityPoolID *string `locationName:"IdentityPoolId" 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) String

String returns the string representation

type GetOpenIDTokenForDeveloperIdentityInput

type GetOpenIDTokenForDeveloperIdentityInput struct {
	// A unique identifier in the format REGION:GUID.
	IdentityID *string `locationName:"IdentityId" type:"string"`

	// An identity pool ID in the format REGION:GUID.
	IdentityPoolID *string `locationName:"IdentityPoolId" 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 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 `type:"long"`
	// contains filtered or unexported fields
}

Input to the GetOpenIdTokenForDeveloperIdentity action.

func (GetOpenIDTokenForDeveloperIdentityInput) GoString

GoString returns the string representation

func (GetOpenIDTokenForDeveloperIdentityInput) String

String returns the string representation

type GetOpenIDTokenForDeveloperIdentityOutput

type GetOpenIDTokenForDeveloperIdentityOutput struct {
	// A unique identifier in the format REGION:GUID.
	IdentityID *string `locationName:"IdentityId" 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) String

String returns the string representation

type GetOpenIDTokenInput

type GetOpenIDTokenInput struct {
	// A unique identifier in the format REGION:GUID.
	IdentityID *string `locationName:"IdentityId" 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) String

func (s GetOpenIDTokenInput) String() string

String returns the string representation

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 `locationName:"IdentityId" 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) 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 `locationName:"IdentityId" 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) 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 *bool `type:"boolean" required:"true"`

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

	// An identity pool ID in the format REGION:GUID.
	IdentityPoolID *string `locationName:"IdentityPoolId" type:"string" required:"true"`

	// A string that you provide.
	IdentityPoolName *string `type:"string" required:"true"`

	// A list of OpendID Connect provider ARNs.
	OpenIDConnectProviderARNs []*string `locationName:"OpenIdConnectProviderARNs" 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) String

func (s IdentityPool) String() string

String returns the string representation

type IdentityPoolShortDescription

type IdentityPoolShortDescription struct {
	// An identity pool ID in the format REGION:GUID.
	IdentityPoolID *string `locationName:"IdentityPoolId" type:"string"`

	// A string that you provide.
	IdentityPoolName *string `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) 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 *string `locationName:"IdentityPoolId" type:"string" required:"true"`

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

	// A pagination token.
	NextToken *string `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) String

func (s ListIdentitiesInput) String() string

String returns the string representation

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 `locationName:"IdentityPoolId" type:"string"`

	// A pagination token.
	NextToken *string `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) String

func (s ListIdentitiesOutput) String() string

String returns the string representation

type ListIdentityPoolsInput

type ListIdentityPoolsInput struct {
	// The maximum number of identities to return.
	MaxResults *int64 `type:"integer" required:"true"`

	// A pagination token.
	NextToken *string `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) String

func (s ListIdentityPoolsInput) String() string

String returns the string representation

type ListIdentityPoolsOutput

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

	// A pagination token.
	NextToken *string `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) 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 `type:"string"`

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

	// An identity pool ID in the format REGION:GUID.
	IdentityPoolID *string `locationName:"IdentityPoolId" type:"string" required:"true"`

	// The maximum number of identities to return.
	MaxResults *int64 `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 `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) String

String returns the string representation

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 `locationName:"IdentityId" 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 `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) String

String returns the string representation

type MergeDeveloperIdentitiesInput

type MergeDeveloperIdentitiesInput struct {
	// User identifier for the destination user. The value should be a DeveloperUserIdentifier.
	DestinationUserIdentifier *string `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 *string `type:"string" required:"true"`

	// An identity pool ID in the format REGION:GUID.
	IdentityPoolID *string `locationName:"IdentityPoolId" type:"string" required:"true"`

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

Input to the MergeDeveloperIdentities action.

func (MergeDeveloperIdentitiesInput) GoString

GoString returns the string representation

func (MergeDeveloperIdentitiesInput) String

String returns the string representation

type MergeDeveloperIdentitiesOutput

type MergeDeveloperIdentitiesOutput struct {
	// A unique identifier in the format REGION:GUID.
	IdentityID *string `locationName:"IdentityId" 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) String

String returns the string representation

type SetIdentityPoolRolesInput

type SetIdentityPoolRolesInput struct {
	// An identity pool ID in the format REGION:GUID.
	IdentityPoolID *string `locationName:"IdentityPoolId" 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 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) String

func (s SetIdentityPoolRolesInput) String() string

String returns the string representation

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 *string `type:"string" required:"true"`

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

	// A unique identifier in the format REGION:GUID.
	IdentityID *string `locationName:"IdentityId" type:"string" required:"true"`

	// An identity pool ID in the format REGION:GUID.
	IdentityPoolID *string `locationName:"IdentityPoolId" 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) String

String returns the string representation

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 *string `locationName:"IdentityId" type:"string" required:"true"`

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

	// Provider names to unlink from this identity.
	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) String

func (s UnlinkIdentityInput) String() string

String returns the string representation

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"`

	// A unique identifier in the format REGION:GUID.
	IdentityID *string `locationName:"IdentityId" 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) String

func (s UnprocessedIdentityID) String() string

String returns the string representation

Directories

Path Synopsis
Package cognitoidentityiface provides an interface for the Amazon Cognito Identity.
Package cognitoidentityiface provides an interface for the Amazon Cognito Identity.

Jump to

Keyboard shortcuts

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