Skip to main content
The API answers when you ask. A webhook works the other way round: when something happens in your group, Scoutworks sends a short message to an address you choose, straight away. Use it to post to Teams when a Direct Debit fails, or to update a spreadsheet when an event changes, without checking every few minutes.
Webhooks are in the beta programme. A group admin turns the programme on in Settings → Advanced → Beta programme, then Webhooks appears in Settings → Integrations.

Set up an endpoint

You need an address that can receive a message: a Power Automate flow, a Zapier or n8n hook, or your own server. It must start with https:// and use a public domain name.
1

Add the webhook

A group admin opens Settings → Integrations → Webhooks and chooses Add webhook. Paste the address, add a description so the next admin knows what it is for, and tick the Events to send.
2

Copy the signing secret

Choose Add webhook. Scoutworks shows the Signing secret, which starts whsec_. Copy it now and keep it with the receiver: it is not shown again. The receiver uses it to check each message.
3

Send a test

On the webhook’s menu, choose Deliveries and test…, then Send test event. A webhook.test message arrives within a few seconds, and the list shows whether your receiver answered.
A group can have up to ten webhooks. Each one belongs to the admin who added it. If they stop being a group admin, it stops sending and shows Stopped working: delete it and add it again. Building a tool that many groups connect? It can add its own endpoint with the group’s API key, with webhooks:write: see An integration that sets up its own webhooks.

Look after it later

From the webhook’s menu:
  • Deliveries and test… lists the latest messages, each with the answer your receiver gave. Resend sends one again, with the same webhook-id, so a receiver that handles each event once ignores it if it already has it.
  • New signing secret… makes a new secret. The old one keeps working for 24 hours, so you have time to update the receiver. During that time each message carries both signatures.
  • Switch off stops sending without losing the settings. Delete… removes it.
While tries are failing, a webhook shows Failing. If every try fails for 5 days, Scoutworks switches it off, and it shows Switched off. Fix the receiver, then choose Switch on.

What we send

Each message is a POST with a JSON body and three headers. It follows the Standard Webhooks specification.
  • webhook-id is the same every time this message is sent: on a retry, and on a Resend.
  • webhook-timestamp is when this try was sent, in seconds since 1970.
  • type is the event, and timestamp is when it happened.
  • data holds ids and plain facts only, never a name, an email or free text. To learn more, read the record from the API with a key: the ids match the API’s. So a webhook address that leaks can never leak more than “something happened”.
Answer with any 2xx status within 10 seconds. Anything else, a redirect included, is a failed try, and we try again later.

Events

changedFields uses the API’s own field names and never says what a value was or became. Most events also carry source: where the change came from, as app, api (an API key), import (an OSM or file import), system (a scheduled job or an automatic rule) or directory (your organisation’s Microsoft Entra ID or Google Workspace directory). Amounts are strings in pounds with two decimal places, as in the API. Payment events cover only payments the group collects through Scoutworks.

Bulk changes

One change can touch many records: an OSM or CSV import, a bulk badge award, a bank statement import, a register or a closing RSVP wave. Up to 100 records of a type, the change sends one event for each. Past 100, it sends that type as a bulk summary instead: one message, under the same event type, that names every record it changed.
  • ids name one record each: the member for member.*, the application for waiting-list.*, the badge record for badge.*, the member for event.rsvp.changed, the task, the transaction, the claim, the refund or the transfer.
  • A summary carries at most 1,000 ids. A bigger change sends several, numbered by part out of parts, each with the same count.
  • source says where the change came from, as on a single event.
  • An event.rsvp.changed summary covers one event, named in data.eventId, and its ids are the members whose answers changed.
Badge sign-offs (badge.requirement.completed from an event sign-off or a bulk sign-off) are written one member at a time, so they send one event per requirement however many there are. Check data.bulk first. On a summary, read each record from the API by its id, or re-read the list with updatedSince (see Pagination).

Check the signature

Anyone who learns your address can send it a message. The signature proves a message came from Scoutworks and was not changed on the way. Check it before you act on anything. The signature is an HMAC-SHA256 of webhook-id, webhook-timestamp and the body, joined with full stops, keyed with your secret. Check it against the body exactly as it arrived: if your framework turns the JSON into an object and back, the bytes change and the check fails.
Node 18 or later. Nothing to install.
verify.mjs
With Express, read the body raw on this route only:
You can also use any Standard Webhooks library, which does the same check.
Keep the signing secret out of your code and out of shared documents. Put it in an environment variable or your platform’s secret store. If it leaks, choose New signing secret….

When you cannot check a signature

Power Automate and Zapier cannot work out an HMAC without code. For them, keep the address secret, and read the record back from the API before you act: a forged payment.failed names a payment that the API does not list as failed. Tell the treasurer when a Direct Debit fails does this.

Handle each event once

We send every event at least once. A message can arrive twice: when your receiver was slow to answer and we tried again, or when an admin chose Resend. Messages can also arrive out of order.
  1. Remember each webhook-id you have handled, for a few days. If a message arrives with one you know, answer 2xx and do nothing else.
  2. Answer first, work after. Answer within 10 seconds, then do the slow part, such as sending an email. A receiver that takes too long is counted as failed and gets the message again.
  3. Don’t trust the order. To know where a record stands now, read it from the API rather than replaying the messages in order. For an event, compare timestamp with the last one you handled for the same record, and ignore an older one.
  4. Make the action safe to repeat where you can. “Set the status to failed” is safe twice. “Add a row” is not, unless the row carries the webhook-id and you check for it first.

Next