Skip to main content

How to Choose NFT Subscription Mode?

tokenviewAbout 4 min

How to Choose NFT Subscription Mode?

Tokenview launches NFT subscription data serviceopen in new window ! Choose from four subscription topics: Account, Token, NFT Collection, Event. Monitor events on the NFT chain at any time, users can easily get the latest news on NFT mingting/trading/buying/selling/destroying, and provide stable, easy-to-operate, and friendly NFT event notification reminders. In addition, NFT subscription is applicable to all Layer1 and Layer2 public chains that support NFT, no node data is required, no limit on the number of address monitoring, configuration on demand, and one-click activation through APIKey. Simplify all on-chain application building!

Tokenview NFT subscription provided four notification mode:

1. Account Subscription

Two types for Account Subscription:

  • 1.1 Account Assets Change. All NFT-related events of an account in a transaction are returned at one time. Return 1 notification.
  • 1.2 Account + Token Assets Change. For multiple NFT-related events that occur in one account in one transaction, each NFT sends a message notification. Return multiple notifications.

Note: An account refer to the account with private keys; for contracts, tokens and other non-entity accounts do not support NFT subscription function;

Account Assets Change

For example 0xad229685025e3c8a9a4a98f752e7f743b46151e1909dbb69f2f0bc32aedc20a6open in new window

Account 0x6186…9cfeopen in new windowreceived 6 NFTs: KUMA #1024,1204,2451,643,922,970, value 0.377 ETH.
When subscribe the address of 0x6186…9cfeopen in new window,return the content of Json:

❗️ Each notification of "msgType" is "address-s"

{
  "address": "0x6186290b28d511bff971631c916244a9fc539cfe",
  "ens": "barthazian.eth",
  "height": "15866281",
  "in": [         // content list
    {
      "amount": "1",
      "from": "0xc4416a182489671fb96de08a4d1bcc588214e78e",
      "nftid": "1024",
      "symbol": "KUMA",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe",
      "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
      "type": "rc721"
    },
    {
      "amount": "1",
      "from": "0xc29c546064e8fb5506c5e5beaf1594866df7177e",
      "nftid": "1204",
      "symbol": "KUMA",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe",
      "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
      "type": "rc721"
    },
    {
      "amount": "1",
      "from": "0x0ddf9101626a4971a530e0bb17b1ebc2741fe89f",
      "nftid": "2451",
      "symbol": "KUMA",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe",
      "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
      "type": "rc721"
    },
    {
      "amount": "1",
      "from": "0xb0a0bcac1f8010af6c63e7190824ff93186d54e3",
      "nftid": "643",
      "symbol": "KUMA",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe",
      "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
      "type": "rc721"
    },
    {
      "amount": "1",
      "from": "0x6f04aeb4562b56f48ee29893ff89a19e4e837b6a",
      "nftid": "922",
      "symbol": "KUMA",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe",
      "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
      "type": "rc721"
    },
    {
      "amount": "1",
      "from": "0x1fc9345beb50cea9f4ccd0f2a83c2271aa721b90",
      "nftid": "970",
      "symbol": "KUMA",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe",
      "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
      "type": "rc721"
    }
  ],
  "msgType": "address-s",
  "network": "ETH",
  "out": [    // List of contents lost by address
    {
      "amount": "0.377",
      "from": "0x6186290b28d511bff971631c916244a9fc539cfe",
      "to": "0x00000000006c3852cbef3e08e8df289169ede581",
      "type": "ETH"
    }
  ],
  "time": "1667198135",
  "txid": "0xad229685025e3c8a9a4a98f752e7f743b46151e1909dbb69f2f0bc32aedc20a6"
}

Account + Token Assets Change

Account of 0x6186…9cfeopen in new window receive 6 NFTs: KUMA #1024,1204,2451,643,922,970,value 0.377 ETH.

When subscribe the account 0x6186…9cfeopen in new window, you will receive 6 notifications for each events.

❗️ Each notification of "msgType" is "address-m"

{
    "address": "0x6186290b28d511bff971631c916244a9fc539cfe",
    "amount": "1",
    "ens": "barthazian.eth",
    "height": "15866281",
    "msgType": "address-m",
    "network": "ETH",
    "nftid": "1024",
    "time": "1667198135",
    "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
    "tokenSymbol": "KUMA",
    "txType": "Buy",
    "txid": "0xad229685025e3c8a9a4a98f752e7f743b46151e1909dbb69f2f0bc32aedc20a6",
    "type": "rc721"
  }
{
    "address": "0x6186290b28d511bff971631c916244a9fc539cfe",
    "amount": "1",
    "ens": "barthazian.eth",
    "height": "15866281",
    "msgType": "address-m",
    "network": "ETH",
    "nftid": "1204",
    "time": "1667198135",
    "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
    "tokenSymbol": "KUMA",
    "txType": "Buy",
    "txid": "0xad229685025e3c8a9a4a98f752e7f743b46151e1909dbb69f2f0bc32aedc20a6",
    "type": "rc721"
  }
{
    "address": "0x6186290b28d511bff971631c916244a9fc539cfe",
    "amount": "1",
    "ens": "barthazian.eth",
    "height": "15866281",
    "msgType": "address-m",
    "network": "ETH",
    "nftid": "2451",
    "time": "1667198135",
    "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
    "tokenSymbol": "KUMA",
    "txType": "Buy",
    "txid": "0xad229685025e3c8a9a4a98f752e7f743b46151e1909dbb69f2f0bc32aedc20a6",
    "type": "rc721"
  }
{
    "address": "0x6186290b28d511bff971631c916244a9fc539cfe",
    "amount": "1",
    "ens": "barthazian.eth",
    "height": "15866281",
    "msgType": "address-m",
    "network": "ETH",
    "nftid": "643",
    "time": "1667198135",
    "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
    "tokenSymbol": "KUMA",
    "txType": "Buy",
    "txid": "0xad229685025e3c8a9a4a98f752e7f743b46151e1909dbb69f2f0bc32aedc20a6",
    "type": "rc721"
  }	
{
    "address": "0x6186290b28d511bff971631c916244a9fc539cfe",
    "amount": "1",
    "ens": "barthazian.eth",
    "height": "15866281",
    "msgType": "address-m",
    "network": "ETH",
    "nftid": "922",
    "time": "1667198135",
    "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
    "tokenSymbol": "KUMA",
    "txType": "Buy",
    "txid": "0xad229685025e3c8a9a4a98f752e7f743b46151e1909dbb69f2f0bc32aedc20a6",
    "type": "rc721"
  }
{
    "address": "0x6186290b28d511bff971631c916244a9fc539cfe",
    "amount": "1",
    "ens": "barthazian.eth",
    "height": "15866281",
    "msgType": "address-m",
    "network": "ETH",
    "nftid": "970",
    "time": "1667198135",
    "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
    "tokenSymbol": "KUMA",
    "txType": "Buy",
    "txid": "0xad229685025e3c8a9a4a98f752e7f743b46151e1909dbb69f2f0bc32aedc20a6",
    "type": "rc721"
  }	

2. TokenID Subscription

The example as above, if subscribe the token ID of #1024, return the content of Json:

❗️ Each notification of "msgType" is "token"

{
  "address": "0x8270fc3b2d23de703b265b2abe008883954fea8e-1024",
  "amount": "1",
  "from": "0xc4416a182489671fb96de08a4d1bcc588214e78e",
  "height": "15866281",
  "msgType": "token",
  "network": "ETH",
  "nftid": "1024",
  "time": "1667198135",
  "to": "0x6186290b28d511bff971631c916244a9fc539cfe",
  "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
  "tokenSymbol": "KUMA",
  "txType": "Exchange",
  "txid": "0xad229685025e3c8a9a4a98f752e7f743b46151e1909dbb69f2f0bc32aedc20a6",
  "type": "rc721"
}

3. Collection Subscription

The example as above, if subscribe the Collection of KUMA, return the content of Json:

❗️Each notification of "msgType" is "collection"

{
  "address": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
  "height": "15866281",
  "ids": [
    {
      "amount": "1",
      "from": "0xc4416a182489671fb96de08a4d1bcc588214e78e",
      "nftid": "1024",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe"
    },
    {
      "amount": "1",
      "from": "0xc29c546064e8fb5506c5e5beaf1594866df7177e",
      "nftid": "1204",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe"
    },
    {
      "amount": "1",
      "from": "0x0ddf9101626a4971a530e0bb17b1ebc2741fe89f",
      "nftid": "2451",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe"
    },
    {
      "amount": "1",
      "from": "0xb0a0bcac1f8010af6c63e7190824ff93186d54e3",
      "nftid": "643",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe"
    },
    {
      "amount": "1",
      "from": "0x6f04aeb4562b56f48ee29893ff89a19e4e837b6a",
      "nftid": "922",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe"
    },
    {
      "amount": "1",
      "from": "0x1fc9345beb50cea9f4ccd0f2a83c2271aa721b90",
      "nftid": "970",
      "to": "0x6186290b28d511bff971631c916244a9fc539cfe"
    }
  ],
  "msgType": "collection",
  "network": "ETH",
  "time": "1667198135",
  "tokenAddress": "0x8270fc3b2d23de703b265b2abe008883954fea8e",
  "tokenSymbol": "KUMA",
  "txid": "0xad229685025e3c8a9a4a98f752e7f743b46151e1909dbb69f2f0bc32aedc20a6",
  "type": "rc721"
}

4. Event Subscription

Event-based subscriptions can be divided into two types for pushing the messages:

  • 4.1 Multiple messages one-time。For multiple NFT-related events of a subscription account in one transaction, each NFT sends a message notification, and returned notifications count: 1 message;
  • 4.2 Messages are sent individually。All NFT-related events of a subscription account in one transaction are returned at one time, and returned notification count: multiple message;

4.1 Multiple messages one-time

Transaction hash 0x470ed9ae...e5a3open in new window for example:

Address 0x0b28…1d2eopen in new window mint 2 NFT: UACD #1504,#1505.

Two messages have been pushed,the "msgType" of each message is "event-m", the pushed json example is as follows:

{
    "address": "0x0b28beacf76d1efe9ade22dde6e23f6f4d611d2e",
    "amount": "1",
    "from": "0x0000000000000000000000000000000000000000",
    "height": "16686117",
    "msgType": "event-m",
    "network": "ETH",
    "nftid": "1505",
    "time": "1677094895",
    "to": "0x0b28beacf76d1efe9ade22dde6e23f6f4d611d2e",
    "tokenAddress": "0xb95712ac7fbf54ab3fd10c86fd1e9463c8461bf5",
    "tokenSymbol": "UACD",
    "txType": "Mint",
    "txid": "0x470ed9ae058d85a69c34dc2ea6be62145ba8daf63694e8d3d9dcd35c187de5a3",
    "type": "rc721"
}
{
    "address": "0x0b28beacf76d1efe9ade22dde6e23f6f4d611d2e",
    "amount": "1",
    "from": "0x0000000000000000000000000000000000000000",
    "height": "16686117",
    "msgType": "event-m",
    "network": "ETH",
    "nftid": "1504",
    "time": "1677094895",
    "to": "0x0b28beacf76d1efe9ade22dde6e23f6f4d611d2e",
    "tokenAddress": "0xb95712ac7fbf54ab3fd10c86fd1e9463c8461bf5",
    "tokenSymbol": "UACD",
    "txType": "Mint",
    "txid": "0x470ed9ae058d85a69c34dc2ea6be62145ba8daf63694e8d3d9dcd35c187de5a3",
    "type": "rc721"
}

4.2 Single Message

Address 0x0b28…1d2eopen in new window mint 2 NFT: UACD #1504,1505

One message have been pushed, the "msgType" of each message is "event-s", the pushed json example is as follows:

{
    "address": "0x0b28beacf76d1efe9ade22dde6e23f6f4d611d2e",
    "height": "16686117",
    "list": [
    {
        "amount": "1",
        "from": "0x0000000000000000000000000000000000000000",
        "nftid": "1504",
        "symbol": "UACD",
        "to": "0x0b28beacf76d1efe9ade22dde6e23f6f4d611d2e",
        "tokenAddress": "0xb95712ac7fbf54ab3fd10c86fd1e9463c8461bf5",
        "type": "rc721"
    },
    {
        "amount": "1",
        "from": "0x0000000000000000000000000000000000000000",
        "nftid": "1505",
        "symbol": "UACD",
        "to": "0x0b28beacf76d1efe9ade22dde6e23f6f4d611d2e",
        "tokenAddress": "0xb95712ac7fbf54ab3fd10c86fd1e9463c8461bf5",
        "type": "rc721"
    }],
    "msgType": "event-s",
    "network": "ETH",
    "time": "1677094895",
    "txType": "Mint",
    "txid": "0x470ed9ae058d85a69c34dc2ea6be62145ba8daf63694e8d3d9dcd35c187de5a3"
} 

Click Loginopen in new window and start NFT subcription!

About Tokenview Blockchain APIs & Data Service Platform:

Tokenview blockchain APIs & data service platform contained 120+ blockchains has powerful endpoints that simplify complex blockchain data into single API calls. Code for all supported blockchains using unified API calls. From here to easily get transaction, address, gas, contract, token, NFT, logs and any information from chain. And Yes you can also send tx to chain. One-click configuration with APIKey helps developers to Use, to Create, to Build.
Last update: