CollectionItem SubType

When the top level type is collectionItem the subTypeData is defined here.

subTypeData data

The following properties define the subTypeData object and should be used if your collectionItem ordinal has additional information that should be associated with it. A collectionId at the top level is required for collectionItem ordinals. Since a collection is an ordinal, all top level required fields are still required as well.

Name & DescriptionRequiredTypeExample

collectionId A unique identifier, txid_vout of the collection subType.

Y

txid_vout

TODO: use a good example aaff22a9568dacfa6b90d64e31218b89bb5ef1ab3995e17540870fbf46bb990b_0 or for self: _0

mintNumber An integer, position the ordinal exists at within the collection

N

int

3

rank A integer starting at 1 where 1 is the most 'rare'

N

int

10

rarityLabel The overall rarity label for this ordinal

N

string enum based on subTypeData

"legendary"

traits Array of traits that describe the ordinal

N

traits as defined by collection subTypeData

see examples below

attachments

N

Attachment[]

https://... b://... c://...

Trait

The definition of trait within the traits array:

NameDescriptionRequiredType

name

The name of the trait

Y

string

value

The value of the trait

Y

string

rarityLabel

A rarity label to associate with the trait

N

RarityLabel

occurrencePercent

The percentage which this trait occurs within this collection

N

string

Attachment

NameDescriptionRequiredType

name

The name of the attachment

Y

string

description

The description of the attachment

N

string

content-type

The content-type of the attachment

Y

string

url

The url of the attachment

Y

string

Transaction Structure

This pseudo-script creates an ordinal with metadata called "The Awesome Ordinal" with only the minimum required fields, and adds a signature via AIP so the issuer can be verified.

Output 1:

1SAT_P2PKH <INSCRIPTION> OP_RETURN MAP SET app <mint_platform> type ord name "The Awesome Ordinal" | AIP <address> "BITCOIN_ECDSA" <signature> [-1]

Example ord type data

{
 "name": "Pepe with Fire",
 "previewUrl": "https://somepreview.com/image.png",
 "royalties": [
    {"type": "paymail", "destination": "[email protected]", "percentage": "0.03"}, 
    {"type": "address", "destination": "1MvYhFajARJ82sbgxuAXziq1FmgSY1XQwD", "percentage": "0.025"}
  ]
}

Last updated