cognito

package module
v0.0.0-...-211a7e7 Latest Latest
Warning

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

Go to latest
Published: Mar 9, 2019 License: Unlicense Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DoPost

func DoPost(url string, target string, request interface{}, response interface{}) error

DoPost - web call to AWS

func GetCredentialsFor

func GetCredentialsFor(identity string) (*credentials.Credentials, error)

GetCredentialsFor - Create a provider, and trigger the provider to fetch the credentials

func GetIdentityFor

func GetIdentityFor(poolID string) (string, error)

GetIdentityFor - If this is a new client, then we need to get a new identity from the configured pool. Once we have that we should cache that identity for later use.

func SetRegionURL

func SetRegionURL(url string)

SetRegionURL - We need to target the correct AWS Cognito region. example: "https://cognito-identity.eu-west-1.amazonaws.com"

Types

type CustomCognitoCredentialsProvider

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

CustomCognitoCredentialsProvider a small provider that supports Cognito identity pools

func (*CustomCognitoCredentialsProvider) IsExpired

func (m *CustomCognitoCredentialsProvider) IsExpired() bool

IsExpired - ...

func (*CustomCognitoCredentialsProvider) Retrieve

Retrieve - ...

type IdentityCredentials

type IdentityCredentials struct {
	Key     string  `json:"AccessKeyId"`
	Expires float64 `json:"Expiration"`
	Secret  string  `json:"SecretKey"`
	Token   string  `json:"SessionToken"`
}

IdentityCredentials - ...

Jump to

Keyboard shortcuts

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