Clear NFT DBAPI-v2clear_nft_db

This method will clear the NFT database data stored in the local database for selected (or all) networks.

Request Parameters

ParameterTypeDescription
clear_allbooleanDefaults to false. If true all NFT data for all networks will be purged.
chainsarrayOptional. List of networks to remove NFT data for. Options are: POLYGON, FANTOM, ETH, BSC, or AVALANCHE.

📌 Example to clear Binance Smart chain and Polygon NFT data

POST Clear NFT Database clear_nft_db
{
  "userpass": "RPC_UserP@SSW0RD",
  "method": "clear_nft_db",
  "mmrpc": "2.0",
  "params": {
    "chains": [
      "POLYGON",
      "BSC"
    ]
  }
}
Show Response
    {
        "mmrpc": "2.0",
        "result": null,
        "id": null
    }

📌 Example to clear all NFT data

POST Clear NFT Database clear_nft_db
{
  "userpass": "RPC_UserP@SSW0RD",
  "method": "clear_nft_db",
  "mmrpc": "2.0",
  "params": {
    "clear_all": true
  }
}
Show Response
    {
        "mmrpc": "2.0",
        "result": null,
        "id": null
    }

Error responses

UnsupportedChainType

Returned when the chains parameter contains an unsupported network.

{
    "mmrpc": "2.0",
    "error": "Error parsing request: UnsupportedChainType",
    "error_path": "dispatcher",
    "error_trace": "dispatcher:110]",
    "error_type": "InvalidRequest",
    "error_data": "UnsupportedChainType",
    "id": null
}

InvalidRequest

Returned when neither the chains or clear_all parameters are present.

{
    "mmrpc":"2.0",
    "error":"Invalid request: Nothing to clear was specified","error_path":"nft","error_trace":"nft:1512]",
    "error_type":"InvalidRequest",
    "error_data":"Nothing to clear was specified",
    "id":null
}