0

I'm trying to understand EOA / internal / token transfer events better because I'm using the Alchemy Notify webhooks on address activity and I want to know which type of transactions to expect.

This is the ERC721A contract address on Goerli: https://goerli.etherscan.io/address/0x0a71632Ad538A5B24e72BF80a1840E2Efc575429

Here is a mint transaction that was mined: https://goerli.etherscan.io/tx/0xe29271d1c537430f0afa8618c1ae4196204bfb20fadf800c197fcbca1a0d0bd2

And this is the webhooks response body that I get from the Alchemy Notify API:

{
    "webhookId": "<redacted>",
    "id": "<redacted>",
    "createdAt": "2022-08-03T14:45:19.798Z",
    "type": "ADDRESS_ACTIVITY",
    "event": {
        "network": "ETH_GOERLI",
        "activity": [
            {
                "fromAddress": "0xa423bb1f81568f464296050d9a3ea678ac5a2064",
                "toAddress": "0x0a71632ad538a5b24e72bf80a1840e2efc575429",
                "blockNum": "0x700090",
                "hash": "0xe29271d1c537430f0afa8618c1ae4196204bfb20fadf800c197fcbca1a0d0bd2",
                "value": 0.0015,
                "asset": "ETH",
                "category": "external",
                "rawContract": {
                    "rawValue": "0x5543df729c000",
                    "decimals": 18
                }
            }
        ]
    }
}

I expect NFT mints to be token transfers (from 0x0 address -> to the minter's wallet address). That means I'd also expect this webhook to notify me about a token transfer event, but all I got was this "category": "external" transaction.

  1. Why is this transaction marked as external?
  2. Why are no log events returned?
  3. How do I get the Notify webhook to return these NFT mint transfer event logs? https://goerli.etherscan.io/tx/0xe29271d1c537430f0afa8618c1ae4196204bfb20fadf800c197fcbca1a0d0bd2#eventlog
1
  • my goal is to track NFT mints and then change some metadata based on the minted tokenID, so I might just use this guide on tracking NFT mints via the Subscriptions API: docs.alchemy.com/alchemy/enhanced-apis/…, but it would be nice to use a Notify webhook directly from the Alchemy dashboard Aug 4, 2022 at 3:35

1 Answer 1

1

The semantics of Alchemy Notify for address activity are that it matches on the from/to address of the given category to the address you are subscribed to. In this case, you are subscribed to events for the following addresses: 0x0a71632Ad538A5B24e72BF80a1840E2Efc575429, 0x0aa32ace6a4e447310cc145dda5d984a6b5733ea. If you look at https://goerli.etherscan.io/tx/0xe29271d1c537430f0afa8618c1ae4196204bfb20fadf800c197fcbca1a0d0bd2, you will see that for the “external” transaction there is a match for the to address 0x0a71632Ad538A5B24e72BF80a1840E2Efc575429, so you received a external transaction event. If you look at the event logs for the NFT transfer events https://goerli.etherscan.io/tx/0xe29271d1c537430f0afa8618c1ae4196204bfb20fadf800c197fcbca1a0d0bd2#eventlog you will see that the from address is 0x0000000000000000000000000000000000000000 and the to address is 0xa423bb1f81568f464296050d9a3ea678ac5a2064, neither of which you are subscribed to, which is why you didn’t get that event. However, as a workaround to achieve your goal, given the “external” transaction, you can always call eth_getTransactionReceipt to get the corresponding logs (which will show you the transfers).

1
  • ah totally makes sense, I'm subscribed to the contract (which isn't receiving or sending NFTs itself) thank you!! Aug 4, 2022 at 22:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.