generateNftRecs

Endpoint calls to NFT recommendation engine. Engine deploys machine learning to create AI-powered recommendations for a given NFT on-the-fly.

Request

Endpoint

GET https://api.metcy.io/v1/eth/generateNftRecs/

Headers

Key
Value

Authorization

Token { YOUR-API-KEY }

Parameters

Parameter
Description

contractAddress

Hexadecimal address that defines the NFT collection.

tokenId

Unique identifier that specifies the NFT within the contract address.

numberRecs

The number of recommendations user wishes to receive. 20 recommendations is the max.

Example

curl --location --request GET 'https://api.metcy.io/v1/eth/generateNftRecs/?contractAddress=0xf32e1bde889ecf672ffae863721c8f7d280f853b&tokenId=8985&numberRecs=13'
--header 'Authorization: Token 81fc29d081f2f2836e187837a221be**********'

Response

Request Status Code

Response
Interpretation

200

Success! Recommendations are provided in JSON format.

401

User authentication details failed.

Body

{
    "recommendations_requested": 13,
    "recommendations_provided": 13,
    "recommendations": [
        {
            "contractaddress": "0x1a2f71468f656e97c2f86541e57189f59951efe7",
            "tokenid": 4122
        },
        {
            "contractaddress": "0x436fbf52faf705b6f82404bd06fb637bc4cc44ae",
            "tokenid": 2782
        },
        {
            "contractaddress": "0x4f9835dbb442b263bbd20ff2731162101d9c3a89",
            "tokenid": 5786
        },
        {
            "contractaddress": "0x41f57e862c863721322d0dd0fe8ea8091a459439",
            "tokenid": 1060
        },
        {
            "contractaddress": "0xf32e1bde889ecf672ffae863721c8f7d280f853b",
            "tokenid": 8921
        },
        {
            "contractaddress": "0xf32e1bdE889eCf672FFAe863721C8f7d280F853b",
            "tokenid": 4941
        },
        {
            "contractaddress": "0xf32e1bdE889eCf672FFAe863721C8f7d280F853b",
            "tokenid": 1282
        },
        {
            "contractaddress": "0xf32e1bdE889eCf672FFAe863721C8f7d280F853b",
            "tokenid": 3610
        },
        {
            "contractaddress": "0x80549075471291d8e7e14e1defe4280c743d86af",
            "tokenid": 3304
        },
        {
            "contractaddress": "0x343f999eaacdfa1f201fb8e43ebb35c99d9ae0c1",
            "tokenid": 3072
        },
        {
            "contractaddress": "0x414c5e3716bcec4b2373108b187914215695627a",
            "tokenid": 315
        },
        {
            "contractaddress": "0xaf615b61448691fc3e4c61ae4f015d6e77b6cca8",
            "tokenid": 928
        },
        {
            "contractaddress": "0x7509615baf2f9d2ee3274bda6cc1fc444e0488e8",
            "tokenid": 1750
        }
    ]
}

Interpretation

Engine only currently compatible with ERC-721 ABI contract types.

Note that the number of recommendations provided may sometimes be fewer than the number of recommendations requested. This is by design. The recommendation engine seeks to provide high quality recommendations only. If there is insufficient quality data to make good the full number of good recommendations, the engine will cull bad recs. This is more likely with very newly minted NFTs.

Last updated