Documentation ¶
Overview ¶
Infura is a freemium pinning service that doesn't require any additional setup. Please bear in mind that Infura is a free service, so there is probably a rate-limiting. Docs: https://infura.io/docs
Index ¶
- func PinFile(fp string) (string, error)deprecated
- func PinHash(hash string) (bool, error)
- type Infura
- func (inf *Infura) PinDir(mfr *files.MultiFileReader) (string, error)
- func (inf *Infura) PinFile(fp string) (string, error)
- func (inf *Infura) PinHash(hash string) (bool, error)
- func (inf *Infura) PinWithBytes(buf []byte) (string, error)
- func (inf *Infura) PinWithReader(rd io.Reader) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Infura ¶
Infura represents an Infura configuration. If there is no Apikey or Secret, it will make API calls using anonymous requests.
func (*Infura) PinDir ¶
func (inf *Infura) PinDir(mfr *files.MultiFileReader) (string, error)
PinDir pins a directory to the Infura pinning service.
func (*Infura) PinFile ¶
PinFile pins content to Infura by providing a file path, it returns an IPFS hash and an error.
func (*Infura) PinHash ¶
PinHash pins content to Infura by giving an IPFS hash, it returns the result and an error.
func (*Infura) PinWithBytes ¶
PinWithBytes pins content to Infura by given byte slice, it returns an IPFS hash and an error.