API, webhooks and embeds
Get entrants into your other tools, react when things happen, and put giveaways on your website. Set everything up in your dashboard under Integrations.
- Embeds (every plan)
- Email lists: Mailchimp, Klaviyo, Brevo (Plus and Pro)
- Webhooks and Zapier (Pro)
- REST API (Pro)
Embeds
The Share popup gives you this code for each giveaway. It shows the prize, closing time and seal, with an Enter button, and sizes itself.
<div data-unrigd="your-org/your-giveaway"></div> <script src="https://unrigd.app/embed.js" async></script>
People enter on unrigd's own page, in a new tab, where the terms, consent and bot check live. If your site doesn't allow scripts, the Share popup also has a plain fixed-height iframe.
WordPress
Download the plugin, upload it under Plugins → Add New → Upload Plugin and activate it, then add a Shortcode block: [unrigd giveaway="your-org/your-giveaway"].
Shopify
Download the section, add it to your theme under Edit code → Sections → Add a new section (name it unrigd-giveaway), then add the “unrigd giveaway” section in the theme editor and enter your-org/your-giveaway.
Email lists
Connect Mailchimp, Klaviyo or Brevo with an API key and a list ID. We check them before saving. From then on, each entrant who ticked “send me news from the promoter” is added with their email and first name, once their email is confirmed if your giveaway asks for that. Anyone who later stops marketing, or erases their details, is taken off the list. Mailchimp members who unsubscribed in Mailchimp are never re-subscribed. Entrants from before you connected aren't copied.
Built to each service's published API. Failures are retried and shown in the Integrations slide-out with the service's own error.
Webhooks
Add an https address and choose events. When one happens we POST JSON to it, usually within a minute. Your endpoint should reply with any 2xx status within 10 seconds. Redirects aren't followed.
{
"id": "evt_4182",
"type": "entry.created",
"created": "2026-11-26T14:02:11.000Z",
"org": "<your organisation id>",
"data": {
"campaign": "<giveaway id>",
"entry": "K7Q2-9XJD",
"name": "Sam Taylor",
"email": "sam@example.com",
"source": "online",
"status": "valid",
"marketing": true,
"tickets": 1
}
}Events
entry.created | Someone entered (online, by post, or bought their first tickets) |
entry.confirmed | An entrant confirmed their email address (when a giveaway asks for it) |
entry.decided | A held entry was approved or rejected |
entry.marketing_withdrawn | An entrant stopped marketing, or erased their details |
entry.erased | An entrant erased their details |
campaign.published | A giveaway or competition was published and sealed |
campaign.cancelled | A giveaway or competition was cancelled |
campaign.frozen | The entry list was frozen |
draw.completed | The draw ran |
winner.notified | A winner was emailed their claim link |
winner.claimed | A winner claimed their prize |
order.paid | A ticket order was paid |
order.refunded | A ticket order was refunded |
test.ping | Sent when you press “Send test” |
Checking the signature
Each request has an Unrigd-Signature header: t=<unix time>,v1=<hex>, where v1 is HMAC-SHA256 of t + "." + raw body using your endpoint's secret (shown once when you add it; you can make a new one at any time). Reject requests that don't match or are more than 5 minutes old.
import crypto from "node:crypto";
// header: the Unrigd-Signature request header; body: the raw request body (a string)
export function verifyUnrigd(header, body, secret, toleranceSeconds = 300) {
const parts = Object.fromEntries(header.split(",").map((p) => p.split("=")));
const t = Number(parts.t);
if (!t || Math.abs(Date.now() / 1000 - t) > toleranceSeconds) return false;
const expected = crypto.createHmac("sha256", secret).update(`${t}.${body}`).digest("hex");
return parts.v1?.length === expected.length &&
crypto.timingSafeEqual(Buffer.from(parts.v1), Buffer.from(expected));
}Retries
A failed delivery is retried after 1 min, 5 min, 30 min, 2 h, 12 h, 24 h: 7 tries in all over about two days, then given up and shown in red in the dashboard. Use the event id to ignore repeats.
Zapier, Make and n8n
- In Zapier, start a Zap with the trigger “Webhooks by Zapier → Catch Hook” and copy its URL.
- In unrigd, open Integrations, add that URL as a webhook and choose events (for example
entry.created). - Press “Send test”, then continue in Zapier: add a Google Sheets row, a Slack message, a CRM contact.
Make (“Custom webhook”) and n8n (“Webhook” node) work the same way.
REST API
Read-only. Create a key in Integrations and send it as Authorization: Bearer unr_…. Keys are shown once. Each key can make 600 requests per 15 minutes.
curl https://unrigd.app/api/v1/campaigns \ -H "Authorization: Bearer unr_your_key"
GET /api/v1/campaigns | Your giveaways and competitions, newest first |
GET /api/v1/campaigns/:id | One, including its seal, commitment hash and drand round |
GET /api/v1/campaigns/:id/entries | Entries, oldest first. ?limit= up to 500 (default 100); pass the next value back as ?after= for the next page. Erased entrants have null name and email. |
GET /api/v1/campaigns/:id/orders | Ticket orders (competitions) |
GET /api/v1/campaigns/:id/winners | Winners and reserves, in draw order |
Errors come back as { "error": { "code": "…", "message": "…" } } with a 4xx status that says what's wrong: 401 bad or revoked key, 403 plan or suspended, 404 not found, 429 too many requests.
The data you get through the API and webhooks is your entrants' personal data. You're responsible for it once it leaves unrigd; see the privacy notice.