Struct secret_toolkit_snip721::metadata::Extension
source · [−]pub struct Extension {
pub image: Option<String>,
pub image_data: Option<String>,
pub external_url: Option<String>,
pub description: Option<String>,
pub name: Option<String>,
pub attributes: Option<Vec<Trait>>,
pub background_color: Option<String>,
pub animation_url: Option<String>,
pub youtube_url: Option<String>,
pub media: Option<Vec<MediaFile>>,
pub protected_attributes: Option<Vec<String>>,
}
Expand description
metadata extension
You can add any metadata fields you need here. These fields are based on
https://docs.opensea.io/docs/metadata-standards and are the metadata fields that
Stashh uses for robust NFT display. Urls should be prefixed with http://
, https://
, ipfs://
, or
ar://
Fields
image: Option<String>
url to the image
image_data: Option<String>
raw SVG image data (not recommended). Only use this if you’re not including the image parameter
external_url: Option<String>
url to allow users to view the item on your site
description: Option<String>
item description
name: Option<String>
name of the item
attributes: Option<Vec<Trait>>
item attributes
background_color: Option<String>
background color represented as a six-character hexadecimal without a pre-pended #
animation_url: Option<String>
url to a multimedia attachment
youtube_url: Option<String>
url to a YouTube video
media: Option<Vec<MediaFile>>
media files as specified on Stashh that allows for basic authenticatiion and decryption keys.
Most of the above is used for bridging public eth NFT metadata easily, whereas media
will be used
when minting NFTs on Stashh
protected_attributes: Option<Vec<String>>
a select list of trait_types that are in the private metadata. This will only ever be used in public metadata
Trait Implementations
sourceimpl<'de> Deserialize<'de> for Extension
impl<'de> Deserialize<'de> for Extension
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl JsonSchema for Extension
impl JsonSchema for Extension
sourcefn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
sourcefn json_schema(gen: &mut SchemaGenerator) -> Schema
fn json_schema(gen: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
sourcefn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the $ref
keyword. Read more
impl StructuralPartialEq for Extension
Auto Trait Implementations
impl RefUnwindSafe for Extension
impl Send for Extension
impl Sync for Extension
impl Unpin for Extension
impl UnwindSafe for Extension
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more