Search Usability Fix: Address, tokenId, and type


October 26, 2022


← Back

We’ve added new fields to the search result document:

  • type: Collection or Asset
  • address : The NFT contract’s address
  • tokenId: The NFT token ID, if the result is an asset.

Example: Asset search

$ curl <https://api.center.dev/v1/ethereum-mainnet/search?query=meebits+12&type=asset>
{
  "results": [
    {
      "id": "ethereum-mainnet/0x7Bd29408f11D2bFC23c34f18275bBf23bB716Bc7/12",
      "name": "Meebit #12",
      "previewImageUrl": "<https://cdn.center.app/1/0x7Bd29408f11D2bFC23c34f18275bBf23bB716Bc7/12/a5fbd22d8a8c89db66d26300615e2b7cae18c7c06e914e6e518da0e9dd1ebf45.jpeg>",
      "relevance": 14.188332,
      "url": "<https://center.app/collections/0x7Bd29408f11D2bFC23c34f18275bBf23bB716Bc7/12>",
      "address": "0x7Bd29408f11D2bFC23c34f18275bBf23bB716Bc7",
      "tokenId": "12",
      "type": "Asset"
    },
    ...
  ]
}

Example: Collection search

$ curl <https://api.center.dev/v1/ethereum-mainnet/search?query=bayc&type=collection>
{
  "results": [
    {
      "id": "ethereum-mainnet/0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D",
      "name": "BoredApeYachtClub",
      "previewImageUrl": "<https://cdn.center.app/1/0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D/3746/5de4b840fc2bd496bb57fe01c7e1562e696e6b1902dc4fef03cbd8b9ce4dcd81.png>",
      "relevance": 17.5425,
      "url": "<https://center.app/collections/0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D>",
      "address": "0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D",
      "type": "Collection"
    },
    ...
  ]
}

Other requests or ideas? Please submit a feature request or reach out to our support team.