client

package
v0.0.0-...-edf233a Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2021 License: MIT Imports: 10 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CallEndpoint

func CallEndpoint(url, method, authorization string, insecureSkipVerify bool, v interface{}, o interface{}) (interface{}, error)

CallEndpoint calls endpoint

Types

type PasswordService

type PasswordService struct {
	Authorization      string
	InsecureSkipVerify bool

	Token      string
	Expiration int64
	// contains filtered or unexported fields
}

PasswordService password service

func NewPasswordService

func NewPasswordService() (*PasswordService, error)

NewPasswordService returns new instance of password service

func NewPasswordServiceWithServerAddress

func NewPasswordServiceWithServerAddress(serverAddr string) (*PasswordService, error)

NewPasswordServiceWithServerAddress instantiates service with given server addr

func (*PasswordService) CreatePassword

func (ps *PasswordService) CreatePassword(input model.PasswordInput) (*model.PasswordOutput, error)

CreatePassword creates password

func (*PasswordService) DeletePassword

func (ps *PasswordService) DeletePassword(ID string) error

DeletePassword deletes password

func (*PasswordService) GetEndpoint

func (ps *PasswordService) GetEndpoint() string

GetEndpoint returns endpoint base url

func (*PasswordService) ListPasswords

ListPasswords finds passwords by title

func (*PasswordService) ReadPassword

func (ps *PasswordService) ReadPassword(ID string) (*model.PasswordOutput, error)

ReadPassword creates password

func (*PasswordService) RefreshToken

func (ps *PasswordService) RefreshToken() error

RefreshToken refreshes auth token

func (*PasswordService) Signin

func (ps *PasswordService) Signin(input model.Credentials) error

Signin authenticates

func (*PasswordService) UpdatePassword

func (ps *PasswordService) UpdatePassword(input model.PasswordInput) error

UpdatePassword updates password

type RestfulService

type RestfulService interface {
	GetEndpoint() string
}

RestfulService restful service

Jump to

Keyboard shortcuts

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