Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrValidationFailed = errors.New("api key validation failed")
ErrValidationFailed marks errors where a provider rejected a supplied API key.
Functions ¶
This section is empty.
Types ¶
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
Registry stores provider-specific key validators.
func DefaultRegistry ¶
DefaultRegistry creates the built-in validator set.
func NewRegistry ¶
NewRegistry creates a validator registry from an explicit provider map.
func (*Registry) HasValidator ¶
HasValidator reports whether the registry has a validator for the provider.
type ValidationError ¶
ValidationError is returned when a provider rejects a key during validation.
func (*ValidationError) Error ¶
func (e *ValidationError) Error() string
func (*ValidationError) Unwrap ¶
func (e *ValidationError) Unwrap() error
Click to show internal directories.
Click to hide internal directories.