apikey

package
v0.12.1 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ApiKey

type ApiKey struct {
	KeyHash string     `json:"keyHash"`
	Type    ApiKeyType `json:"type"`
	// Project or client name
	Name string `json:"name"`

} // @name ApiKey

type ApiKeyType

type ApiKeyType string
const (
	ApiKeyTypeClient  ApiKeyType = "client"
	ApiKeyTypeProject ApiKeyType = "project"
)

type Store

type Store interface {
	List() ([]*ApiKey, error)
	Find(key string) (*ApiKey, error)
	FindByName(name string) (*ApiKey, error)
	Save(apiKey *ApiKey) error
	Delete(apiKey *ApiKey) error
}

Jump to

Keyboard shortcuts

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