oauthgoogle

package module
v0.1.10 Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package oauthgoogle provides a Google OAuth provider for the Limen OAuth plugin.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(opts ...ConfigOption) oauth.Provider

New creates a Google OAuth provider that implements oauth.Provider.

Types

type ConfigOption

type ConfigOption func(*config)

ConfigOption configures the Google OAuth plugin.

func WithClientID

func WithClientID(id string) ConfigOption

WithClientID sets the Google OAuth2 client ID. Defaults to env var GOOGLE_CLIENT_ID.

func WithClientSecret

func WithClientSecret(secret string) ConfigOption

WithClientSecret sets the Google OAuth2 client secret. Defaults to env var GOOGLE_CLIENT_SECRET.

func WithIDTokenVerifier

func WithIDTokenVerifier(verifier oauth.IDTokenVerifier) ConfigOption

func WithOption

func WithOption(key, value string) ConfigOption

WithOption sets any additional OAuth2 options such as "prompt", "access_type", etc.

func WithRedirectURL

func WithRedirectURL(url string) ConfigOption

WithRedirectURL sets the callback URL registered in Google Cloud Console.

func WithScopes

func WithScopes(scopes ...string) ConfigOption

WithScopes sets the OAuth2 scopes (e.g. "openid", "email", "profile").

Jump to

Keyboard shortcuts

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