/api/v2/{coin}/wallet/{walletId}/webhooks
Add a webhook that will result in an HTTP callback at the specified URL from BitGo when events are triggered. There is a limit of 10 webhooks of each type per wallet.
Types of wallet webhooks available:
coin
stringRequired"btc"
walletId
stringRequired"59cd72485007a239fb00282ed480da1f"
^[0-9a-f]{32}$
type
string required transfer
transaction
pendingapproval
address_confirmation
lowFee
transfer
allToken
boolean false
url
string <uri>
required http://your.server.com/webhook
label
string numConfirmations
integer >= 0
6
listenToFailureStates
boolean 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
var walletId = '58d99…39604'; var url = 'http://your.server.com/webhook'; bitgo .coin('tbtc') .wallets() .get({ id: walletId }) .then(function (wallet) { return wallet.addWebhook({ url: url, type: 'transfer', }); }) .then(function (webhook) { // print the new webhook console.dir(webhook); });
allToken
boolean false
id
string 59cd72485007a239fb00282ed480da1f
^[0-9a-f]{32}$
label
string Test Webhook
created
string <date-time>
{}
coin
string btc
type
string transfer
transaction
pendingapproval
address_confirmation
lowFee
transfer
url
string <uri>
required https://your.server.com/webhook
version
integer 2
numConfirmations
integer 6
state
string active
suspended
active
lastAttempt
string <date-time>
{}
failingSince
string <date-time>
{}
successiveFailedAttempts
integer 0
walletId
string allowBlockedHosts
boolean error
string required requestId
string required context
object name
string required