> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://developers.webflow.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://developers.webflow.com/_mcp/server.

# Create Webhook

POST https://api.webflow.com/v2/sites/{site_id}/webhooks
Content-Type: application/json

Create a new Webhook.

Limit of 75 registrations per `triggerType`, per site.

Access to this endpoint requires a bearer token from a [Data Client App](/data/docs/data-clients/getting-started).
Required scope | `sites:write`

Reference: https://developers.webflow.com/data/reference/webhooks/create

## Authentication

- `Authorization` header (bearer token, required)
- `Authorization` header (bearer token, required)

## Request

### Path parameters

- `site_id` (string, required) — Unique identifier for a Site

### Body (application/json)

- `id` (string, optional) — Unique identifier for the Webhook registration
- `triggerType` (enum, optional) — The type of event that triggered the request. See the the documentation for details on [supported events](/data/reference/all-events).
  - Allowed values: `form_submission`, `site_publish`, `page_created`, `page_metadata_updated`, `page_deleted`, `ecomm_new_order`, `ecomm_order_changed`, `ecomm_inventory_changed`, `collection_item_created`, `collection_item_changed`, `collection_item_deleted`, `collection_item_published`, `collection_item_unpublished`, `comment_created`
- `url` (string, optional) — URL to send the Webhook payload to
- `workspaceId` (string, optional) — Unique identifier for the Workspace the Webhook is registered in
- `siteId` (string, optional) — Unique identifier for the Site the Webhook is registered in
- `filter` (object, optional) — Only supported for the `form_submission` trigger type. Filter for the form you want Webhooks to be sent for.
  - `name` (string, optional) — The name of the form you'd like to recieve notifications for.
- `lastTriggered` (string, optional) — Date the Webhook instance was last triggered
- `createdOn` (string, optional) — Date the Webhook registration was created

## Response

### 201

Request was successful

- `id` (string, optional) — Unique identifier for the Webhook registration
- `triggerType` (enum, optional) — The type of event that triggered the request. See the the documentation for details on [supported events](/data/reference/all-events).
  - Allowed values: `form_submission`, `site_publish`, `page_created`, `page_metadata_updated`, `page_deleted`, `ecomm_new_order`, `ecomm_order_changed`, `ecomm_inventory_changed`, `collection_item_created`, `collection_item_changed`, `collection_item_deleted`, `collection_item_published`, `collection_item_unpublished`, `comment_created`
- `url` (string, optional) — URL to send the Webhook payload to
- `workspaceId` (string, optional) — Unique identifier for the Workspace the Webhook is registered in
- `siteId` (string, optional) — Unique identifier for the Site the Webhook is registered in
- `filter` (object, optional) — Only supported for the `form_submission` trigger type. Filter for the form you want Webhooks to be sent for.
  - `name` (string, optional) — The name of the form you'd like to recieve notifications for.
- `lastTriggered` (string, optional) — Date the Webhook instance was last triggered
- `createdOn` (string, optional) — Date the Webhook registration was created

## Examples

**Request**

```json
{
  "triggerType": "form_submission",
  "url": "https://webhook.site/7f7f7f7f-7f7f-7f7f-7f7f-7f7f7f7f7f7f"
}
```

**Response**

```json
{
  "id": "582266e0cd48de0f0e3c6d8b",
  "triggerType": "form_submission",
  "url": "https://webhook.site/7f7f7f7f-7f7f-7f7f-7f7f-7f7f7f7f7f7f",
  "workspaceId": "4f4e46fd476ea8c507000001",
  "siteId": "562ac0395358780a1f5e6fbd",
  "lastTriggered": "2023-02-08T23:59:28.572Z",
  "createdOn": "2022-11-08T23:59:28.572Z"
}
```

**SDK Code**

```typescript
import { WebflowClient } from "webflow-api";

async function main() {
    const client = new WebflowClient({
        accessToken: "YOUR_TOKEN_HERE",
    });
    await client.webhooks.create("580e63e98c9a982ac9b8b741", {
        triggerType: "form_submission",
        url: "https://webhook.site/7f7f7f7f-7f7f-7f7f-7f7f-7f7f7f7f7f7f",
    });
}
main();

```

```python
from webflow import Webflow

client = Webflow(
    access_token="YOUR_TOKEN_HERE",
)

client.webhooks.create(
    site_id_="580e63e98c9a982ac9b8b741",
    trigger_type="form_submission",
    url="https://webhook.site/7f7f7f7f-7f7f-7f7f-7f7f-7f7f7f7f7f7f",
)

```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/webhooks"

	payload := strings.NewReader("{\n  \"triggerType\": \"form_submission\",\n  \"url\": \"https://webhook.site/7f7f7f7f-7f7f-7f7f-7f7f-7f7f7f7f7f7f\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/webhooks")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"triggerType\": \"form_submission\",\n  \"url\": \"https://webhook.site/7f7f7f7f-7f7f-7f7f-7f7f-7f7f7f7f7f7f\"\n}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/webhooks")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"triggerType\": \"form_submission\",\n  \"url\": \"https://webhook.site/7f7f7f7f-7f7f-7f7f-7f7f-7f7f7f7f7f7f\"\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/webhooks', [
  'body' => '{
  "triggerType": "form_submission",
  "url": "https://webhook.site/7f7f7f7f-7f7f-7f7f-7f7f-7f7f7f7f7f7f"
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/webhooks");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"triggerType\": \"form_submission\",\n  \"url\": \"https://webhook.site/7f7f7f7f-7f7f-7f7f-7f7f-7f7f7f7f7f7f\"\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [
  "triggerType": "form_submission",
  "url": "https://webhook.site/7f7f7f7f-7f7f-7f7f-7f7f-7f7f7f7f7f7f"
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.webflow.com/v2/sites/580e63e98c9a982ac9b8b741/webhooks")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```