cic-schema/schema/json/opensea_part.in.json

67 lines
1.9 KiB
JSON
Raw Normal View History

2023-03-05 09:47:07 +01:00
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "/opensea",
"title": "Partial implementation of the OpenSea token metadata standard",
"type": "object",
"properties": {
"image_data": {
"type": "string",
2023-03-05 11:33:40 +01:00
"description": "Raw SVG image data, if you want to generate images on the fly (not recommended). Only use this if you're not including the image parameter.",
"contentEncoding": "base64",
"contentMediaType": "image/svg+xml"
2023-03-05 09:47:07 +01:00
},
"image": {
"type": "string",
2023-03-05 11:33:40 +01:00
"description": "A URI pointing to a resource with mime type image/* representing the asset to which this NFT represents. Consider making any images at a width between 320 and 1080 pixels and aspect ratio between 1.91:1 and 4:5 inclusive.",
"format": "uri"
2023-03-05 09:47:07 +01:00
},
"external_url": {
"type": "string",
2023-03-05 11:33:40 +01:00
"description": "This is the URL that will appear below the asset's image on OpenSea and will allow users to leave OpenSea and view the item on your site.",
"format": "uri"
2023-03-05 09:47:07 +01:00
},
"attributes": {
"type": "array",
"description": "These are the attributes for the item, which will show up on the OpenSea page for the item. (see below)",
"items": {
"type": "object",
"properties": {
"trait_type": {
"type": "string"
},
"value": {
"oneOf": [
{
"type": "string"
},
{
"type": "number"
}
]
},
"display_type": {
"type": "string"
}
},
"required": ["trait_type", "value"]
}
2023-03-05 09:47:07 +01:00
},
"animation_url": {
"type": "string",
2023-03-05 11:33:40 +01:00
"description": "Animation_url also supports HTML pages, allowing you to build rich experiences and interactive NFTs using JavaScript canvas, WebGL, and more. Scripts and relative paths within the HTML page are now supported. However, access to browser extensions is not supported.",
"format": "uri"
2023-03-05 09:47:07 +01:00
}
},
"required": ["attributes"],
"oneOf": [
{
"required": ["image"]
},
{
"required": ["image_data"]
}
]
}