# Webhook

To integrate the webhook with your system, such as an ERP, ensure that the webhook URL uses a secure connection. Only **HTTPS** addresses are accepted.

## Setup

To set up the webhook, follow these steps:

1. Go to **Shopify Admin**.
2. Navigate to **Apps** > **My Product Registration**.
3. Select **Forms**.
4. Choose the form you want to integrate with the webhook.
5. Go to **Settings** > **General**.

![](https://4168782644-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fm4vguP4EvKgU8vwxKCJR%2Fuploads%2Fgit-blob-cdd6bf0be71d5b67bf756d2f05ec8b583f851e8c%2FScreenshot%202022-01-18%20at%2012.01.13.png?alt=media)

Once the webhook is set up, every time a registration occurs, the app will send an **HTTP POST** request to the webhook address with the following payload:

```
{
  "type": "product-registration",
  "items": [
    {
      "product": {
        "id": 11651617295,
        "title": "Short sleeve t shirt",
        "handle": "short-sleeve-t-shirt",
        "imageUrl": "https://cdn.shopify.com/s/files/1/1893/1973/products/mens-dark-grey-long-sleeve-basketball-t-shirt-p18984-15470_image.jpg?v=1498345705"
      },
      "purchaseDate": "2018-05-28T10:58:17.597Z",
      "serialNumbers": [
        "123"
      ],
      "extraFields": [
        {
          "name": "Title",
          "type": "text",
          "value": "Mr"
        },
        {
          "name": "where did you buy it?",
          "type": "selection",
          "value": "Ebay"
        },
        {
          "name": "Upload Image (Receipt)",
          "type": "image",
          "value": "https://www.example.com/test.jpg"
        },
      ]
    }
  ],
  "customer": {
    "name": "James Hunt",
    "firstName": "James",
    "surname": "Hunt",
    "email": "james@hunt.com",
    "address1": "1 Highstreet",
    "address2": "Haham",
    "city": "New York",
    "country": "US",
    "state": "NY",
    "postCode": "1234567",
    "phone": "1234567",
  }
}
```
