IPFS

Metadata storage on Ethereum

This module simplifies the process of uploading files and metadata to IPFS, allowing you to generate IPFS URLs for media files such as images, audio, and video, as well as metadata json files.

If you are using on-chain metadata, the media file URLs can be passed directly as initialization data to the deploy methods of Edition, Rentable, Crescendo, as well as the bulkUpdate function on MetadataRenderer.

*Note: This module is a lightweight wrapper utilzing the nft.storage JavaScript client library.

Getting Started
Module Methods

Getting Started

To begin we'll import the IPFS module.

// Import the IPFS module
import { ipfs } from "@decent.xyz/sdk";

Module Methods

createMetadata
Create an IPFS URL for media files, metadata json files, optionally in a single operation.

createMetadata

Create an IPFS URL for media files, metadata json files, optionally in a single operation.

const ipfs = ipfs.createMetadata(metadata);

metadata (any)
A media file, or an object containing both media files and metadata.

*Note: For further details refer to the store method of the nft.storage JavaScript client library.


What’s Next