Webhooks

Create a webhook

Register an HTTPS endpoint to receive link events. Requires the Pro plan or above; each plan has a maximum number of endpoints (Pro 3, Growth 5, Advanced 10, Team 20, Enterprise 50). The response includes the signing secret exactly once.

POST https://u2l.ai/api/v1/webhooks

Authorizations

Authorizationstringrequired

Bearer authentication header of the form Bearer <token>, where <token> is your U2L API key (u2l_live_...). Create one in the dashboard under Settings > API.

Body

urlstringrequired

HTTPS URL that receives event POSTs.

eventsstring[]

Events to subscribe to. Defaults to all.

Errors

401 Error
403 Error
422 Error

See Rate Limits & Errors for the error envelope and per-plan limits.

curl -X POST https://u2l.ai/api/v1/webhooks \
  -H "Authorization: Bearer u2l_live_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
  "url": "https://example.com/u2l-webhook"
}'
const response = await fetch("https://u2l.ai/api/v1/webhooks", {
  method: "POST",
  headers: {
    "Authorization": "Bearer u2l_live_your_api_key",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    "url": "https://example.com/u2l-webhook"
  }),
});

const data = await response.json();
console.log(data);
import requests

response = requests.post(
    "https://u2l.ai/api/v1/webhooks",
    headers={"Authorization": "Bearer u2l_live_your_api_key"},
    json={
      "url": "https://example.com/u2l-webhook"
    },
)

print(response.json())
package main

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

func main() {
	body := strings.NewReader(`{
  "url": "https://example.com/u2l-webhook"
}`)
	req, _ := http.NewRequest("POST", "https://u2l.ai/api/v1/webhooks", body)
	req.Header.Set("Authorization", "Bearer u2l_live_your_api_key")
	req.Header.Set("Content-Type", "application/json")
	res, _ := http.DefaultClient.Do(req)
	defer res.Body.Close()

	data, _ := io.ReadAll(res.Body)
	fmt.Println(string(data))
}
{
  "id": "we_f9ae3c2a1ee24e1b9321e359c9830b96",
  "url": "https://example.com/u2l-webhook",
  "events": [
    "link.created",
    "link.updated",
    "link.deleted"
  ],
  "active": true,
  "failureCount": 0,
  "lastDeliveryAt": null,
  "createdAt": "2026-07-25 08:52:02",
  "secret": "u2lwh_833a6fd24a7215aa68e2137925f2b6edf1c3e02700dfdcef"
}