client

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2024 License: Unlicense Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlobDescriptor

type BlobDescriptor struct {
	Pubkey  string `json:"pubkey"`
	Url     string `json:"url"`
	Sha256  string `json:"sha256"`
	Size    int64  `json:"size"`
	Type    string `json:"type"`
	Blob    []byte `json:"-"`
	Created int64  `json:"created"`
}

type Client

type Client struct {
	// contains filtered or unexported fields
}

func New

func New(sk string) (*Client, error)

func (*Client) Delete

func (c *Client) Delete(blobHash string) (bool, error)

func (*Client) Get

func (c *Client) Get(blobHash string) ([]byte, error)

func (*Client) Has

func (c *Client) Has(blobHash string) (bool, error)

func (*Client) List

func (c *Client) List(pubkeyHex string) ([]BlobDescriptor, error)

func (*Client) Mirror

func (c *Client) Mirror(blobUrl string) (*BlobDescriptor, error)

func (*Client) Upload

func (c *Client) Upload(blob []byte) (*BlobDescriptor, error)

Jump to

Keyboard shortcuts

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