agent

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2021 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Agent

type Agent struct {
	ID   int
	UUID string `json:"id"`
	Name string `json:"name"`

	Credentials
	account.Account
}

func NewBlankAgent

func NewBlankAgent(name string, a account.Account) *Agent

func ParseAgentHeaders

func ParseAgentHeaders(headers map[string]string) (Agent, error)

func (Agent) Create

func (a Agent) Create() (*Agent, error)

func (Agent) LookupDetails

func (a Agent) LookupDetails() (Agent, error)

func (Agent) ValidateID

func (a Agent) ValidateID() (bool, error)

type AgentClient

type AgentClient struct {
	Config  config.Config
	Context context.Context
}

func NewAgent

func NewAgent(c config.Config) *AgentClient

func (AgentClient) Find

func (ac AgentClient) Find(a *Agent) error

type Agents

type Agents interface {
	Create() (*Agent, error)
	Delete(a Agent) error
}

type Credentials

type Credentials struct {
	Key    string `json:"key"`
	Secret string `json:"secret"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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