identity

package
v0.0.0-...-c3cab01 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2025 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// AuthRedirectDefault redirects to a generic success page.
	AuthRedirectDefault = build.SuccessRedirect()

	// AuthRedirectCache redirects to the "Cache" tab in the dashboard for
	// the authenticated organization.
	AuthRedirectCache = path.Join(build.DashboardHostname(), "team", "cache")
)

Common redirect URLs for use with AuthClient.

Functions

func AuthClient

func AuthClient(redirect string) (*auth.Client, error)

AuthClient returns a new client that redirects to a given URL upon success.

func GenSession

func GenSession(ctx context.Context) (*session.Token, error)

func GetOrgSlug

func GetOrgSlug(ctx context.Context) (string, error)

func IsRefreshTokenError

func IsRefreshTokenError(err error) bool

invalid_grant or invalid_request usually means the refresh token is expired, revoked, or malformed. this belongs in opensource/pkg/auth

func Peek

func Peek() (*session.Token, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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