kodadot / rubick

Implementation SubSquid indexer for Kusama NFTs
https://github.com/kodadot/rubick
9 stars 15 forks source link

meta type on nftEntities are always null? #114

Open roiLeo opened 2 years ago

roiLeo commented 2 years ago
query {
  nftEntities(limit: 10, where: {meta: {type_isNull: false}}) {
    id
    name
    price
    issuer
    meta {
      attributes {
        display
        value
        trait
      }
      description
      id
      image
      name
      type
    }
  }
}

return

{
  "data": {
    "nftEntities": []
  }
}

What kind of data "type" is supposed to store?

vikiival commented 2 years ago

What kind of data "type" is supposed to store?

It should store the mime type of the main resource (animation_url or image if empty).

When users mint via KodaDot, this information should stored in the IPFS metadata. Maybe good thing would be to request the head of the IPFS content

roiLeo commented 2 years ago

Maybe good thing would be to request the head of the IPFS content

Do you mean on the client side? "type" should store mime type or file extension?

When users mint via KodaDot, this information should stored in the IPFS metadata.

currently not implemented on kodadot?

vikiival commented 2 years ago

currently not implemented on kodadot?

It should be! We are using this function from kodadot/minimark

Do you mean on the client side?

No on the indexer's side

"type" should store mime type or file extension?

mime type eg (image/png)

roiLeo commented 1 year ago

From https://github.com/ma-shulgin/rmrk2-integration

enum BaseType {
    svg
    audio
    mixed
    video
    png
}