api

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: May 13, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrErrResponse = errors.New("invalid response")
)

Functions

This section is empty.

Types

type Api

type Api struct {
	ServerURL string
}

func API

func API() *Api

func (*Api) GetContent

func (a *Api) GetContent(path, passphrase string) (res string, err error)

func (*Api) GetHash

func (a *Api) GetHash(path string) (res string, err error)

func (*Api) SetContent

func (a *Api) SetContent(path, passphrase, content string) (err error)

func (*Api) UrlGetContents

func (a *Api) UrlGetContents(anywhere, secret string) string

func (*Api) UrlGetHash

func (a *Api) UrlGetHash(anywhere string) string

func (*Api) UrlSetContents

func (a *Api) UrlSetContents(anywhere, hash, secret string, ttl time.Duration) string

Jump to

Keyboard shortcuts

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