# Webhooks

Vessel can make server-to-server notification callbacks to your external server. The goal of the callbacks is to provide a convenient method to notify developers of changes to the state of NFT transactions on the block chain.

## Add a Webhook

Click **Webhooks** on the top menu. Enter your own endpoint URL to get Vessel's callbacks and click **ADD WEBHOOK** button. You need to enter the full path of the callback URL like `http://yourserver.com/callbacks`

![](https://1785276440-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MlS5g6RKJvRGb_KKP5m%2Fuploads%2Fqqn66d5YFZ5rWSdDOEpM%2FScreen%20Shot%202022-07-27%20at%2016.38.49.png?alt=media\&token=0fc6a66b-bea9-4309-acbf-a519bb8dd17b)

## How it works

Vessel sends POST requests with a JSON body payload once the NFT transaction is completed on the blockchain. Vessel makes these callbacks as soon as the transaction is processed but it may be delayed.

If the callback gets non-200 HTTP response code, Vessel will retry the callback multiple times with an exponential delay.

## JSON body

JSON body payload has the following fields:

<table><thead><tr><th width="150">Field Name</th><th>Description</th></tr></thead><tbody><tr><td>fqTn</td><td>Fully Qualified Token Name</td></tr><tr><td>from</td><td>Wallet address from which the NFT is transferred</td></tr><tr><td>to</td><td>Wallet address to which the NFT is transferred</td></tr><tr><td>amount</td><td>Amount of the token</td></tr><tr><td>type</td><td>NFT transaction types. The following types are supported:<br>TOKEN_MINTED<br>TOKEN_MARKETPLACE_ADD_BUY_OFFER<br>TOKEN_MARKETPLACE_REMOVE_BUY_OFFER<br>TOKEN_MARKETPLACE_TAKE_BUY_OFFER<br>TOKEN_MARKETPLACE_ADD_SELL_OFFER<br>TOKEN_MARKETPLACE_REMOVE_SELL_OFFER<br>TOKEN_MARKETPLACE_TAKE_SELL_OFFER</td></tr><tr><td>messageSignature</td><td>The unique message signature</td></tr><tr><td>messageDigest</td><td><code>sha256</code>(messageSignature + <code>Your_Webhook_Salt</code>), <code>Your_Webhook_Salt</code> can be found on the Webhooks page in the Vessel dashboard.</td></tr></tbody></table>

The example of the JSON payload:

```json
{
  "fqTn":"com.develop.collections.my-collection.best-token",
  "amount":9,
  "from":"0x96c8d60cb56755deced90787766415a1d3b0807b",
  "to":"0x629393a107306bdf3e11212945ace6ce640e62ce",
  "type":"TOKEN_MINTED",
  "messageSignature":"token_event_com.develop.collections.my-collection.best-tojken_948a41aa-82fb-3a46-a833-ce838071d2e3",
  "messageDigest":"RXQN5GHx4M5xyHizK5nUw9V9PPOPZ7c8QmZ3g6T2/1o=",
}
```
