graph LR
Collection --> 1[Item 1]
Collection --> 2[Item 2]
Collection --> 3[Item X...]
The most common use of ordinal inscriptions today is to inscribe a collection of collectables. Particularly relevant metadata protocols are Collection and Attributes:
Protocol
interface Collection {
name: string;
description?: string;
totalCount?: number;
url?: string;
allAttributes?: { [_: string]: (string | number)[] };
}
Protocol
interface Attributes {
[name: string]: (string | number)[];
}
First, inscribe the collection parent for the collection, follwing the Collection metadata protocol:
Metadata
{
"collection": {
"name": "Tiny Vikings",
"description": "Tiny Vikings are the vikings of Bitcoin.",
"totalCount": 20000,
"url": "https://tinyvikings.xyz",
"allAttributes": {
"Background": [ "Snowy", "Gold", "..." ],
"Outfit": [ "Green Cloak", "Wizard", "..." ],
"Skin": [ "Classic", "..." ],
"Headwear": [ "Fire", "..." ],
"Beard": [ "Loki’s Mischief (Blonde)", "..." ],
"Eyewear": [ "Night Vision", "..." ],
"Tool": [ "Axe" "..." ],
}
}
}
Note that the Collection should include all available attributes that is present in the Collection.
Then, inscribe the items as a child of the collection, following a combination of the Common and Attributes protocol:
Metadata
{
"name": "Tiny Viking #0",
"attributes": {
"Background": "Snowy",
"Outfit": "Green Cloak",
"Skin": "Classic",
"Headwear": "Fire",
"Beard": "Loki’s Mischief (Blonde)",
"Eyewear": "Night Vision",
"Tool": "Axe"
}
}