Webhooks allow Cliplink to send real-time POST requests to your server when certain events occur. It’s a great way to keep your systems in sync.
You can configure Cliplink to notify your systems when a URL is created, updated, deleted, clicked, or scanned via QR code.
Once set up, Cliplink will send a POST request to your configured URL with event data when a webhook is triggered.
Cliplink supports two distinct webhook environments:
Each environment has its own webhook URLs and secret token. Events triggered in test mode only go to test URLs.
Cliplink webhooks are grouped into two main categories:
Each category can be configured independently with its own URL and toggle.
| Event Name | Category | Description |
|---|---|---|
url.created | Lifecycle | A new short URL is created |
url.updated | Lifecycle | A short URL is updated |
url.deleted | Lifecycle | A short URL is deleted |
url.clicked | Analytics | A shortened URL is clicked |
qr.scanned | Analytics | A QR code is scanned |
Every webhook request sent by Cliplink contains:
Content-Type: application/jsonX-Cliplink-Signature: The secret token provided in the Webhook config pageThe signature is calculated using your secret token and the raw request body.
{
"event": "url.updated",
"timestamp": "2025-03-30T14:22:01Z",
"data": {
"id": "abc123",
"originalUrl": "https://youtube.com/xyz",
"domain": "cliplink.in",
"title": "My Video Link",
"shortUrl": "xyz321",
"shortUrlFullPath": "https://cliplink.in/xyz321",
"createdAt": "2025-03-25T12:00:00Z",
"qrCodeData": {
"enableQrCodeGen": true,
"qrCodeColour": "#000000",
"size": 300,
"qrCodeConfig": {
"shape": "square",
"quietZone": 4
}
}
}
}{
"event": "url.clicked",
"timestamp": "2025-03-30T14:26:42Z",
"data": {
"shortUrl": "xyz321",
"ip": "192.0.2.25",
"geoData": {
"city": "Chicago",
"region": "Illinois",
"country": "USA",
"loc": "41.8781,-87.6298",
"timezone": "America/Chicago"
},
"referer": "Twitter",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7)...",
"userAgentData": {
"browser": {
"name": "Safari",
"version": "15.2",
"major": "15"
},
"cpu": {
"architecture": "x86_64"
},
"device": {
"type": "desktop"
},
"os": {
"name": "macOS",
"version": "10.15.7"
}
},
"isQrCodeScanned": false
}
}Prefer a programmatic alternative to server-side webhooks? Use the Cliplink ingress API to create, update, or delete short links from your own backend. All requests must include your personal API key in the x-cliplink-signature header; only active, non-revoked keys can perform these operations.
Base URL : https://cliplink.in/api/ingress.
x-cliplink-signature: <your-api-key>X-Idempotency-Key: <unique-request-id>Content-Type: application/jsondata or success payloadsImportant
Reuse of an X-Idempotency-Key within five minutes returns the original response instead of performing the action again. Always generate a fresh, unique key for every mutation to avoid hidden retries or loops.
Endpoint: POST /api/ingress/create
{
"method": "POST",
"headers": {
"x-cliplink-signature": "YOUR_API_KEY",
"X-Idempotency-Key": "create-pricing-landing",
"Content-Type": "application/json"
},
"body": {
"originalUrl": "https://example.com/pricing",
"domain": "https://go.cliplink.in/",
"title": "Pricing Landing",
"shortUrl": "pricing-landing",
"qrCodeData": {
"enableQrCodeGen": true,
"qrCodeColour": "#1A73E8",
"size": 256
}
}
}On success, the API returns 201 Created with the full URL mapping (including id, shortUrlFullPath, and ingress metadata).
Endpoint: PATCH /api/ingress/update
{
"method": "PATCH",
"headers": {
"x-cliplink-signature": "YOUR_API_KEY",
"X-Idempotency-Key": "update-pricing-q3",
"Content-Type": "application/json"
},
"body": {
"id": "64f9f1a5c2d6e31234567890",
"title": "Pricing Landing – Q3",
"shortUrl": "pricing-q3",
"domain": "https://go.cliplink.in/"
}
}If the short code already exists for the requested domain, the API responds with status 409.
Endpoint: DELETE /api/ingress/delete
{
"method": "DELETE",
"headers": {
"x-cliplink-signature": "YOUR_API_KEY",
"X-Idempotency-Key": "update-pricing-q3",
"Content-Type": "application/json"
},
"body": {
"id": "64f9f1a5c2d6e31234567890"
}
}Deletions are soft deletes; future lookups return 404 after removal. Successful deletions return { success: true }.
Tip: Rotate API keys regularly and store them in a secure secret manager. Revoked keys are blocked immediately.