---
title: "Create webhook subscription"
url: "https://docs.unified.to/unified/webhook/Create_webhook_subscription"
description: "API reference for Create webhook subscription. Launch multiple pre-built Webhook integrations today with zero maintenance — all through a single API."
generated_at: "2026-06-19T21:04:18.453Z"
---
# Create webhook subscription

 POST/unified/webhook

The data payload received by your server is described at https://docs.unified.to/unified/overview. The \`interval\` field can be set as low as 1 minute for paid accounts, and 60 minutes for free accounts.

## Parameters

**include\_all**boolean 

When set, all of the existing data will sent back to your server.

## Payload

A webhook is used to POST new/updated information to your server.

**id**string  read-only 

**created\_at**date  read-only 

(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)

**updated\_at**date  read-only 

(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)

**workspace\_id**string  read-only 

(reference to KmsSpace)

**connection\_id**string  required 

**hook\_url**string 

The URL of the webhook

**object\_type** enum required 

Valid values:

 "accounting\_account" 

 "accounting\_transaction" 

 "accounting\_journal" 

 "accounting\_contact" 

 "accounting\_invoice" 

The object to return (eg. CRM "contact")

**interval**number 

The interval (in minutes) to check for updated/new objets. 

**checked\_at**date  read-only 

The last date/time that a check was done on this object (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)

**integration\_type**string  read-only 

**environment**string  read-only 

**event** enum required 

Valid values:

 "updated" 

 "created" 

 "deleted" 

**runs**string array  read-only 

An array of the most revent virtual webhook runs

**fields**string 

**webhook\_type** enum

Valid values:

 "virtual" 

 "native" 

**meta**any  read-only 

**is\_healthy**boolean  read-only 

**page\_max\_limit**number 

**filters**string dictionary 

**db\_type** enum

Valid values:

 "mongodb" 

 "mysql" 

 "postgres" 

 "mssql" 

 "mariadb" 

**db\_url**string 

**db\_schema**string 

**db\_name\_prefix**string 

**is\_paused**boolean 

**is\_beta**boolean 

## Returns

[Webhook](/unified/webhook/model)

A webhook is used to POST new/updated information to your server.

**id**string  read-only 

**created\_at**date  read-only 

(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)

**updated\_at**date  read-only 

(ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)

**workspace\_id**string  read-only 

(reference to KmsSpace)

**connection\_id**string  required 

**hook\_url**string 

The URL of the webhook

**object\_type** enum required 

Valid values:

 "accounting\_account" 

 "accounting\_transaction" 

 "accounting\_journal" 

 "accounting\_contact" 

 "accounting\_invoice" 

The object to return (eg. CRM "contact")

**interval**number 

The interval (in minutes) to check for updated/new objets. 

**checked\_at**date  read-only 

The last date/time that a check was done on this object (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)

**integration\_type**string  read-only 

**environment**string  read-only 

**event** enum required 

Valid values:

 "updated" 

 "created" 

 "deleted" 

**runs**string array  read-only 

An array of the most revent virtual webhook runs

**fields**string 

**webhook\_type** enum

Valid values:

 "virtual" 

 "native" 

**meta**any  read-only 

**is\_healthy**boolean  read-only 

**page\_max\_limit**number 

**filters**string dictionary 

**db\_type** enum

Valid values:

 "mongodb" 

 "mysql" 

 "postgres" 

 "mssql" 

 "mariadb" 

**db\_url**string 

**db\_schema**string 

**db\_name\_prefix**string 

**is\_paused**boolean 

**is\_beta**boolean 

## Code Samples

### Node.js SDK

```
import { UnifiedTo } from '@unified-api/typescript-sdk';

const sdk = new UnifiedTo({
    security: {
        jwt: '<YOUR_API_KEY_HERE>',
    },
});

const results = await sdk.unified.createUnifiedWebhook({ 
    include_all: false,
 });
```

### Node.js (axios)

```
const options = {
  method: 'POST',
  url: 'https://api.unified.to/unified/webhook',
  headers: {
    authorization: 'bearer .....'
  },
  data: undefined,
  params: {
    include_all: false,
  }
};

const results = await axios.request(options);
```

### Java

```
AsyncHttpClient client = new DefaultAsyncHttpClient();

client.prepare("POST", "https://api.unified.to/unified/webhook?include_all=false")
  .setHeader("accept", "application/json")
  .setHeader("authorization", ".....")
  .execute()
  .toCompletableFuture()
  .thenAccept(System.out::println)
  .join();

client.close();
```

### Go

```
import (
	"fmt"
	"net/http"
	"io/ioutil"
)

url := `https://api.unified.to/unified/webhook?include_all=false

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

req.Header.Add("accept", "application/json")
req.Header.Add("authorization", ".....")

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

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

### Python

```
import requests

url = "https://api.unified.to/unified/webhook?include_all=false"

headers = {
    "accept": "application/json",
    "authorization": "....."
}

response = requests.post(url, headers=headers)
```

### PHP

```
$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => "https://api.unified.to/unified/webhook?include_all=false",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_HTTPHEADER => [
    "accept: application/json",
    "authorization: ....."
  ],
]);
```

### Ruby

```
require 'uri'
require 'net/http'
require 'openssl'

url = URI("https://api.unified.to/unified/webhook?include_all=false")

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

request = Net::HTTP::Post.new(url)
request["accept"] = 'application/json'
request["authorization"] = '....'

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

### cURL

```
curl --request POST \
  --url 'https://api.unified.to/unified/webhook?include_all=false' \
  --header 'accept: application/json' \
  --header 'authorization: .....'
```
