Type alias NFT

NFT: {
    collection: string;
    contract: string;
    creator: string;
    description: string;
    identifier: string;
    image_url: string;
    is_disabled: boolean;
    is_nsfw: boolean;
    metadata_url: string;
    name: string;
    opensea_url: string;
    owners: {
        address: string;
        quantity: number;
    }[];
    rarity: null | {
        calculated_at: string;
        max_rank: number | null;
        rank: number | null;
        ranking_features: null | {
            unique_attribute_count: number;
        };
        score: number | null;
        strategy_id: string | null;
        strategy_version: string | null;
        tokens_scored: number | null;
    };
    token_standard: string;
    traits: Trait[] | null;
    updated_at: string;
}

NFT type returned by OpenSea API.

Type declaration

  • collection: string

    Slug identifier of collection

  • contract: string

    Address of contract

  • creator: string

    Creator of the NFT

  • description: string

    Description of NFT

  • identifier: string

    NFT Identifier (also commonly referred to as tokenId)

  • image_url: string

    URL of image

  • is_disabled: boolean

    Whether NFT is disabled for trading on OpenSea

  • is_nsfw: boolean

    Whether NFT is NSFW (Not Safe For Work)

  • metadata_url: string

    URL of metadata

  • name: string

    Name of NFT

  • opensea_url: string

    URL on OpenSea

  • owners: {
        address: string;
        quantity: number;
    }[]

    Owners of the NFT

  • rarity: null | {
        calculated_at: string;
        max_rank: number | null;
        rank: number | null;
        ranking_features: null | {
            unique_attribute_count: number;
        };
        score: number | null;
        strategy_id: string | null;
        strategy_version: string | null;
        tokens_scored: number | null;
    }

    Rarity of the NFT

  • token_standard: string

    Token standard, i.e. ERC721, ERC1155, etc.

  • traits: Trait[] | null

    Traits for the NFT, returns null if the NFT has than 50 traits

  • updated_at: string

    Date of latest NFT update