Search code examples
bitcoincoinbase-apicryptocurrency

How can I receive a payment notification when I receive Bitcoin in a wallet on Coinbase?


I am building a bitcoin payment processor based on Coinbase. I will receive Bitcoin from end users.

Coinbase lets wallet owners receive notifications of various events via a webhook.

Which event will be generated when a user sends Bitcoin to my Coinbase wallet addresses?

And how can I know from that notification webhook whether the transaction has been confirmed or not? If confirmed, how many times it has been confirmed?

I know there are transaction APIs, but I also need a response from the webhook, because this information is important.


Solution

  • I have got clear understanding after making payment.

    I thought Coinbase will call my webhook each time when transaction get confirmed, But they call only once.

    And the event responnsible for new payment is wallet:addresses:new-payment. Which is available in their post data

    {"id":"5a6956f9-94bb-5c15-99f3-a90347674","type":"wallet:addresses:new-payment" ....