Tell Nurdge
when a service is done.

For hotels, restaurants, shops and software teams: how your system sends Nurdge an event when a guest checks out or a bill is paid.

How it works

  1. In the dashboard, open Collect → API and webhooks and create a key for your system. It is shown once.
  2. When a visit finishes (check-out, bill paid, appointment done), your system sends one request to Nurdge.
  3. Nurdge checks the customer opted in, isn’t on the STOP list and wasn’t asked recently, then sends the review request on WhatsApp.

Nurdge never reads your system. Your system pushes events to us, so it works with anything that can make a web request, including Zapier and Make.

Consent comes first

WhatsApp review requests may only go to people who agreed to receive WhatsApp messages from your business. consent: true means you confirm that. A check-out or a purchase is not consent by itself. Collect it at booking or check-in (a tick box, a QR code or the opt-in form), and record it in your own system. The terms put this responsibility on the business, and the wording is still to be reviewed by a lawyer.

The request

POST https://YOUR_NURDGE_ADDRESS/api/v1/events with the header Authorization: Bearer ndg_…. Your own address is shown in the dashboard next to your keys.

curl -X POST https://YOUR_NURDGE_ADDRESS/api/v1/events \
  -H "Authorization: Bearer ndg_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "type": "service.completed",
    "phone": "+2348012345678",
    "name": "Ada Obi",
    "reference": "folio-88231",
    "consent": true,
    "branch": "Lekki"
  }'
FieldWhat it is
typeservice.completed or customer.created (required)
phoneWhatsApp number with country code, like +2348012345678. Send this, an email, or both (at least one).
emailCustomer’s email address, like ada@example.com. Review requests go by email when there is no phone number, or when you choose email first.
nameThe customer’s name (optional)
referenceYour own id for this event, such as a folio or booking number. The same reference is processed once, so retries are safe. Recommended.
consenttrue if the customer agreed to receive WhatsApp messages from you. Needed to add a new customer.
branchThe name of one of your branches (optional)
  • customer.created adds the customer up front (needs consent: true).
  • service.completed marks the visit done. It also creates the customer if you send consent: true.

Sending several at once

Up to 100 events in one request. The answer lists a status for each.

{
  "events": [
    { "type": "service.completed", "phone": "+2348012345678", "reference": "folio-1", "consent": true },
    { "type": "service.completed", "phone": "+2348098765432", "reference": "folio-2", "consent": true }
  ]
}

The answer

A 200 with a status per event, for example { "results": [ { "reference": "folio-88231", "status": "served" } ] }.

createdA new customer was added.
servedThe visit was marked as done. The review request follows.
updated / already_servedNothing new to do: the customer already existed or was already done.
duplicateYou already sent this reference, so it was ignored. Retrying is safe.
consent_requiredTo add a new customer you must send consent: true.
unknown_contactservice.completed for someone we don’t know, without consent: true.
bad_phoneNot a valid international number (or no phone or email was sent).
bad_emailThat email address isn’t valid.
opted_outThat person replied STOP, so they can’t be added.
cooldownThey were asked for a review recently.
bad_typetype must be customer.created or service.completed.
HTTP codeMeaning
401Missing or invalid key (or the key was revoked).
400The body isn’t valid JSON, or has no events or more than 100.
413The request is too large.
429Too many requests. The limit is 600 a minute per key. Wait and retry.
503Temporarily unavailable. Retry with the same reference.

More examples

// Node 18+ or any modern runtime
const res = await fetch("https://YOUR_NURDGE_ADDRESS/api/v1/events", {
  method: "POST",
  headers: { Authorization: "Bearer ndg_YOUR_KEY", "Content-Type": "application/json" },
  body: JSON.stringify({
    type: "service.completed",
    phone: "+2348012345678",
    reference: "folio-88231",
    consent: true,
  }),
});
console.log(res.status, await res.json()); // 200 { results: [{ reference: "folio-88231", status: "served" }] }
import requests

r = requests.post(
    "https://YOUR_NURDGE_ADDRESS/api/v1/events",
    headers={"Authorization": "Bearer ndg_YOUR_KEY"},
    json={"type": "service.completed", "phone": "+2348012345678", "reference": "folio-88231", "consent": True},
    timeout=15,
)
print(r.status_code, r.json())

Zapier or Make, no code

  1. Trigger: your system’s “guest checked out”, “invoice paid” or “appointment completed” event (or a new row in a spreadsheet).
  2. Action: Webhooks → POST (Zapier) or HTTP → Make a request (Make). URL: your events address. Header Authorization: Bearer ndg_…. Body type JSON.
  3. Map the phone number and a unique id (as reference) from the trigger, and set type to service.completed and consent to true only if that guest opted in.
  4. Send a test, then check Recent activity in the dashboard.

Hotels and restaurants

Typical set-up: your property system (or its integration partner) calls this endpoint when a reservation is checked out or a table’s bill is closed, with the folio or check number as reference. We don’t have direct connectors to Opera, Simphony or similar systems yet, so today this needs your IT team or an integration partner. Tell us which system you use in the dashboard (Collect → API and webhooks → Which system do you use?) and we’ll build the most-requested ones first.

Good to know

  • Keep the key secret and server-side. Never put it in a web page or mobile app. Revoke a key in the dashboard if it leaks.
  • Make one key per system so you can switch one off on its own.
  • This page is a first version. Message sending itself starts once your WhatsApp number is connected.

Questions? Contact us