Search…
Cargo Metadata
Cargo has a unique metadata structure to support audio, video, and 3D files.
Cargo extends the ERC-721 metadata shape to be able to support audio, video, and 3D files. If you would like to display Cargo's metadata on your platform, or if you'd like to create a collectible on another platform and would like Cargo to support audio, video, or 3D please use the following metadata structure:

Supported file types

Audio - MP3
Video - MP4, WEBM
3D - GLB, GLTF files + Associated files

Cargo Metadata Structure

1
// TypeScript type
2
type Metadata = {
3
// Standard ERC-721 fields
4
name: string;
5
image: string;
6
description: string;
7
8
// Cargo specific fields
9
cargoDisplayContent: {
10
type: "3D" | "audio" | "video";
11
// Array of files
12
// 3D files can have multiple files. There will be one .gltf file which
13
// may have associated files.
14
files: string[];
15
16
// 3D files have some additonal customizable options
17
// Set initial camera position
18
position?: {
19
x: number;
20
y: number;
21
z: number;
22
}
23
24
// You can set the background using valid css values
25
cssBackground?: {
26
backgroundColor?: string;
27
backgroundImage?: string;
28
backgroundPosition?: string;
29
backgroundSize?: string;
30
backgroundRepeat?: string;
31
}
32
}
33
}
Copied!

Updating Metadata

When you create a new project on Cargo you will be able to update the metadata of the NFTs within that collection. You can update metadata directly from your Cargo dashboard, or using Cargo JS.
Last modified 28d ago