Skip to main content

IStorage interface

Interface for any storage provider

Signature:

export interface IStorage

Methods

MethodDescription
get(hash)Fetches data from storage. This method expects to fetch JSON formatted data
getRaw(hash)Fetches data from storage. This method does not make any assumptions on the retrieved data format
upload(data, contractAddress, signerAddress, options)Uploads a file to the storage.
uploadBatch(files, fileStartNumber, contractAddress, signerAddress, options)Uploads a folder to storage.
uploadMetadata(metadata, contractAddress, signerAddress, options)Uploads JSON metadata to IPFS
uploadMetadataBatch(metadatas, fileStartNumber, contractAddress, signerAddress, options)Uploads JSON metadata to IPFS