Documentation ¶
Index ¶
- type VerifyMyAgeProvider
- func (p *VerifyMyAgeProvider) AuthCodeURL(state string, opts ...oauth2.AuthCodeOption) string
- func (p *VerifyMyAgeProvider) Client(ctx context.Context, token *oauth2.Token) *http.Client
- func (p *VerifyMyAgeProvider) Exchange(ctx context.Context, code string, opts ...oauth2.AuthCodeOption) (*oauth2.Token, error)
- func (p *VerifyMyAgeProvider) UseSandbox()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type VerifyMyAgeProvider ¶
type VerifyMyAgeProvider struct {
// contains filtered or unexported fields
}
VerifyMyAgeProvider struct to hold provider specific details
func NewVerifyMyAgeProvider ¶
func NewVerifyMyAgeProvider(clientID, clientSecret, redirectURL string) *VerifyMyAgeProvider
NewVerifyMyAgeProvider creates a new VerifyMyAgeProvider with the given clientID, clientSecret, and redirectURL
func (*VerifyMyAgeProvider) AuthCodeURL ¶
func (p *VerifyMyAgeProvider) AuthCodeURL(state string, opts ...oauth2.AuthCodeOption) string
AuthCodeURL generates the URL for the authorization endpoint
func (*VerifyMyAgeProvider) Client ¶
Client returns an *http.Client configured with the provided token
func (*VerifyMyAgeProvider) Exchange ¶
func (p *VerifyMyAgeProvider) Exchange(ctx context.Context, code string, opts ...oauth2.AuthCodeOption) (*oauth2.Token, error)
Exchange converts an authorization code into a token
func (*VerifyMyAgeProvider) UseSandbox ¶
func (p *VerifyMyAgeProvider) UseSandbox()
UseSandbox switches the API base URLs to the sandbox environment
Click to show internal directories.
Click to hide internal directories.