Guides
Webhooks
Webhooks allow you to receive HTTP callbacks when events occur in your Liveday account. Instead of polling the API, you configure a URL and Liveday will send a POST request to it whenever a subscribed event fires.
Setup
Webhooks are configured through the Integrations section of your Liveday dashboard. Create a new webhook integration, provide a URL, and select which events you want to subscribe to.
Events
| Event | Description |
|---|---|
OrderCompleted | Fired when an order is successfully completed |
Delivery
When an event fires, Liveday sends an HTTP POST request to your configured URL with the event payload as JSON.
Headers
Every webhook request includes these headers:
| Header | Description |
|---|---|
Content-Type | application/json |
X-Webhook-Delivery-ID | Unique ID for this delivery (UUID) |
X-Webhook-Event-Type | The event type (e.g. OrderCompleted) |
X-Webhook-Attempt | Attempt number (starts at 1) |
Example payload (OrderCompleted)
{
"uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"email": "anna@example.com",
"phone_number": "+46701234567",
"shipping": {
"name": "Anna Svensson",
"address": "Storgatan 1",
"city": "Stockholm",
"postal_code": "11122"
},
"billing": null,
"terminal_id": null,
"order_id": "ord_abc123",
"transaction_id": "txn_xyz789",
"payment_intent": "pi_stripe_123",
"original_order_uuid": null,
"is_refunded": false,
"total_price": 59800,
"payment_method": "card",
"payment_method_brand": "visa",
"split_payment_methods": null,
"control_code": null,
"control_server_id": null,
"control_server_terminal_id": null,
"live_sales_point_id": null,
"live_sales_point_table": null,
"live_sales_point_status": null,
"cart": {
"organization": "your-org-id",
"event": "evt_summer2026",
"currency": "SEK",
"items": [
{
"product_type": "Ticket",
"name": "General Admission",
"quantity": 2,
"price": 29900,
"vat": 6.0,
"event": "evt_summer2026",
"event_name": "Summer Festival 2026",
"section": "sec_ga",
"section_name": "General Admission",
"row": null,
"seat": null,
"item_id": "item_abc",
"category": "ticket"
}
],
"total_price": 59800,
"original_price": 69800,
"campaigns": [
{
"uuid": "camp_earlybird",
"name": "Early Bird",
"code": "EARLY2026",
"discount_amount": 10000
}
]
},
"created_at": "2026-03-01T14:30:00Z",
"order_number": 10042,
"order_source": "webshop",
"refund_reason": null,
"refund_reason_comment": null,
"settled_status": null
}
Responding
Your endpoint should return a 2xx status code to acknowledge receipt. Any other status code is treated as a failure and triggers a retry.
Respond quickly
Your endpoint should return a response within 30 seconds. If processing takes longer, acknowledge the webhook immediately and process it asynchronously.
Retries
Failed deliveries are retried with exponential backoff:
| Attempt | Delay |
|---|---|
| 1 | Immediate |
| 2 | ~5 seconds |
| 3 | ~10 seconds |
| 4 | ~20 seconds |
| 5 | ~40 seconds |
| 6 | ~80 seconds (capped at 5 minutes) |
- Maximum 5 retry attempts per delivery
- Backoff includes ±15% jitter to avoid thundering herds
- After all retries are exhausted, the delivery is marked as
PermanentlyFailed
Delivery statuses
| Status | Description |
|---|---|
Pending | Queued for delivery |
InProgress | Currently being delivered |
Success | Endpoint returned 2xx |
Failed | Attempt failed, will retry |
PermanentlyFailed | All retry attempts exhausted |
Monitoring deliveries
You can monitor webhook delivery status through the API:
List deliveries
curl -G "https://api.liveday.se/webhooks/deliveries" \
-H "Authorization: Bearer sk_your_api_key"
Get delivery details
curl "https://api.liveday.se/webhooks/deliveries/{delivery_uuid}" \
-H "Authorization: Bearer sk_your_api_key"
Get delivery attempts
curl "https://api.liveday.se/webhooks/deliveries/{delivery_uuid}/attempts" \
-H "Authorization: Bearer sk_your_api_key"
Each attempt record includes the HTTP status code, response body (truncated to 5000 characters), duration in milliseconds, and any error message.
Payload reference
OrderCompleted fields
| Field | Type | Description |
|---|---|---|
uuid | string | Unique order identifier |
email | string? | Customer email |
phone_number | string? | Customer phone number |
shipping | object? | Shipping address (name, address, city, postal_code) |
billing | object? | Billing address (same structure as shipping) |
terminal_id | string? | Physical terminal ID (POS orders) |
order_id | string? | External order reference |
transaction_id | string? | Payment transaction ID |
payment_intent | string? | Payment provider intent ID |
original_order_uuid | string? | Original order UUID (for refund orders) |
is_refunded | boolean? | Whether the order has been refunded |
total_price | integer | Total price in smallest currency unit (e.g. öre) |
payment_method | string? | Payment method (card, swish, invoice, etc.) |
payment_method_brand | string? | Card brand (visa, mastercard, etc.) |
split_payment_methods | string[]? | Payment methods used in split payment |
control_code | string? | Fiscal control unit code |
control_server_id | string? | Control server identifier |
control_server_terminal_id | string? | Control server terminal ID |
live_sales_point_id | string? | Live sales point ID (restaurant/kiosk) |
live_sales_point_table | string? | Table number |
live_sales_point_status | string? | Order status at POS |
cart | object | Cart contents (see below) |
created_at | string? | ISO 8601 timestamp |
order_number | integer? | Sequential order number |
order_source | string? | Order source (webshop, pos, app, etc.) |
refund_reason | string? | Reason for refund |
refund_reason_comment | string? | Additional refund comment |
settled_status | string? | Payment settlement status |
Cart object
| Field | Type | Description |
|---|---|---|
organization | string? | Organization ID |
event | string? | Event ID |
currency | string? | ISO 4217 currency code |
items | array | Cart items (see below) |
total_price | integer? | Cart total in smallest currency unit |
original_price | integer? | Price before discounts |
campaigns | array? | Applied campaigns |
Cart item object
| Field | Type | Description |
|---|---|---|
product_type | string? | Ticket, Item, Membership, Restaurant, Kiosk, Fee, Package, Form, GenericItem |
name | string? | Product name |
quantity | integer? | Quantity |
price | integer? | Unit price in smallest currency unit |
vat | number? | VAT percentage |
event | string? | Event ID |
event_name | string? | Event name |
section | string? | Section ID |
section_name | string? | Section name |
row | integer? | Row number (seated tickets) |
seat | integer? | Seat number (seated tickets) |
item_id | string? | Item identifier |
category | string? | Product category |
Campaign object
| Field | Type | Description |
|---|---|---|
uuid | string? | Campaign ID |
name | string? | Campaign name |
code | string? | Discount code used |
discount_amount | integer? | Discount in smallest currency unit |
Best practices
- Verify the event type — check the
X-Webhook-Event-Typeheader before processing - Use the delivery ID for idempotency — the
X-Webhook-Delivery-IDheader uniquely identifies each delivery; use it to avoid processing duplicates - Return 2xx quickly — acknowledge receipt immediately and process asynchronously if needed
- Handle retries gracefully — your endpoint may receive the same event multiple times if a previous acknowledgement was lost