Versions in this module Expand all Collapse all v6 v6.9.3 Mar 25, 2026 Changes in this version + const AccessProviderTypeConfigAPIKey + const DefaultAccessProviderName + func IsAuthErrorCode(authErr *AuthError, code AuthErrorCode) bool + func RegisterProvider(typ string, provider Provider) + func UnregisterProvider(typ string) + type AccessConfig struct + Providers []AccessProvider + type AccessProvider struct + APIKeys []string + Config map[string]any + Name string + SDK string + Type string + func MakeInlineAPIKeyProvider(keys []string) *AccessProvider + type AuthError struct + Cause error + Code AuthErrorCode + Message string + StatusCode int + func NewInternalAuthError(message string, cause error) *AuthError + func NewInvalidCredentialError() *AuthError + func NewNoCredentialsError() *AuthError + func NewNotHandledError() *AuthError + func (e *AuthError) Error() string + func (e *AuthError) HTTPStatusCode() int + func (e *AuthError) Unwrap() error + type AuthErrorCode string + const AuthErrorCodeInternal + const AuthErrorCodeInvalidCredential + const AuthErrorCodeNoCredentials + const AuthErrorCodeNotHandled + type Manager struct + func NewManager() *Manager + func (m *Manager) Authenticate(ctx context.Context, r *http.Request) (*Result, *AuthError) + func (m *Manager) Providers() []Provider + func (m *Manager) SetProviders(providers []Provider) + type Provider interface + Authenticate func(ctx context.Context, r *http.Request) (*Result, *AuthError) + Identifier func() string + func RegisteredProviders() []Provider + type Result struct + Metadata map[string]string + Principal string + Provider string v6.9.2-rc1 Mar 25, 2026