Inbound webhooks: overview
What an inbound webhook is, why there is one per kind of data, who creates it, and how it works from creation to reading.
An inbound webhook is an address your project sends structured data to. MCID checks every request against a schema, stores what is valid, and lets chosen members read it. Use one for a sign-up form, an application, an event your system wants to record, or any data a club team needs to see.
What it gives you
- A schema as the contract. Each webhook has a schema that says which fields exist, their types and their limits. MCID rejects anything that does not match, and returns every problem at once. See Schemas.
- Proof the data is yours. Requests carry your API key and, by default, a signature computed with a secret only you and MCID know. See Signing and sending.
- Reading controlled by Discord roles. Only members who hold a role the webhook names can read what it received. See Reading submissions.
One webhook per kind of data
Create one webhook for each kind of form or event, not one for everything. A recruitment form, a workshop sign-up and a "member joined" event are three webhooks, each with its own schema, readers and secret. The schema then describes one thing exactly, and the readers of one form never see another.
A webhook belongs to one project. Its slug, a short lowercase name such as recruitment-2026, is unique inside that project. The webhook's ID, a UUID, is what appears in its address.
The lifecycle
-
An admin creates the webhook in the admin panel, for your project. They choose a name and a slug, write or pick a schema, and name the Discord roles that may read the submissions. The panel then shows the signing secret once, and the address to send to.
-
The admin gives you the webhook ID and the signing secret. Your project already has its API key.
-
Your backend sends JSON to
POST /api/inbound-webhooks/{id}/submit. MCID answers 201 with the submission's ID, or an error that says what to fix. -
Members with a reader role read the submissions, in the admin panel or through the API. The panel can also export them as CSV.
-
When a secret may have leaked, an admin rotates it. The old secret stops working at once and a new one is shown once. An admin can also switch a webhook off, which makes it answer 410, or delete it.
Creating and managing webhooks is an admin task, done in the admin panel. Your project does not create webhooks through its API key.
What an admin can set
| Setting | Default | Effect |
|---|---|---|
| Require signature | on | Every request must carry a valid X-MCID-Signature. Switching it off lets any holder of the API key submit. |
| Reject unknown fields | on | A payload with a field the schema does not declare is refused with UNKNOWN_FIELD. |
| Accepted origins | none | When the list is not empty, a request must carry an Origin header from the list. |
| Allow role inheritance | off | Members whose role inherits a reader role may read too. See Roles, permissions and inheritance. |
| Active | on | An inactive webhook answers 410. |
| Reader roles | at least one | The roles that may read. They must belong to a server your project has access to. When the admin names none, the default reader roles of the admin settings apply, and a webhook with no reader at all cannot be created. |
Send your first submission
For a webhook that does not require a signature, this is all it takes:
curl -s -X POST "$MCID_URL/inbound-webhooks/$WEBHOOK_ID/submit" \
-H "X-API-Key: $MCID_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "memberId": "42", "plan": "pro" }'{ "id": "e258e77a-7242-46e8-9ccd-493aa17024d9", "receivedAt": "2026-10-05T18:18:39.839Z" }Most webhooks require a signature. Signing and sending has runnable Node and Python examples.
Good to know
- A webhook that belongs to another project answers 404, the same as one that does not exist, so a key cannot be used to find out which webhooks exist.
- Your project can send, but cannot read back what it sent. Reading needs a member session with a reader role.
- Submissions are not kept forever. An hourly job deletes each one 365 days after it arrived, together with its files and the draft it came from, and an operator can change the period with
INBOUND_WEBHOOK_SUBMISSION_RETENTION_DAYS. A draft that expired without being submitted is deleted by the same job a day after it expires, until then it still answers 410. A webhook's submission count is a lifetime total and does not go down. - To find the webhook for a form, list your project's own webhooks with
GET /api/project/inbound-webhooks?limit=50&offset=0and match onslug. The answer is{ items, total }withid,name,slug,active,schemaandcreatedAtfor each webhook, oldest first. It never contains a signing secret or another project's webhook, and it is limited to 30 requests a minute per project. - Your backend can create a webhook for its own project with
POST /api/project/inbound-webhooks?serverId=...and the body{ name, slug, schema, allowedRoleIds? }. The project needs themanage_inbound_webhooksscope on that server, and it can hold at most 100 webhooks (INBOUND_WEBHOOK_MAX_PER_PROJECT), past which the create answers 409. The project comes from the API key, and aprojectIdin the body is rejected with 400. The schema is checked by the same rules as the admin create, and an invalid one answers 422 with every error. A slug the project already uses answers 409. Reader roles must belong to the project's servers, and when you omitallowedRoleIdsthe default reader roles apply. The answer is201with{ id, slug, secret }. The secret is shown only here and no later read returns it. - To change a form, send
PATCH /api/project/inbound-webhooks/:id?serverId=...withnameand/orschema. The schema goes through the same checks as the admin update, and an invalid one answers 422 with every error. Any other field answers 400. The answer is the updated webhook with the same fields as a list item. - To replace a leaked secret, send
POST /api/project/inbound-webhooks/:id/rotate-secret?serverId=.... The answer is{ "secret": "whsec_..." }, shown once, and the old secret stops verifying at once. Like the create, both calls need themanage_inbound_webhooksscope on the server named inserverId: without the scope they answer 403, and withoutserverIdthey answer 400. Both calls are audited with your project id, and a webhook of another project answers 404. - Files travel in two steps. You upload each file to
POST /api/inbound-webhooks/{id}/files, then reference it byfileIdfrom the JSON you submit. Signing and sending describes the upload.
For the endpoint's exact fields, see Inbound webhooks (Ingest) in the reference.
Source: apps/api/src/modules/inbound-webhooks/inbound-webhook-ingest.controller.ts, apps/api/src/modules/inbound-webhooks/inbound-webhook-project.controller.ts, apps/api/src/modules/inbound-webhooks/inbound-webhooks.service.ts, apps/api/src/modules/inbound-webhooks/dto/create-inbound-webhook.dto.ts, apps/api/src/modules/inbound-webhooks/inbound-webhooks.controller.ts, apps/api/src/modules/inbound-webhooks/retention/inbound-webhook-retention.service.ts.
Roles, permissions and inheritance
How Discord roles become permissions, how inheritance reaches other servers, how to check them, and how fresh an answer is.
Inbound webhooks: schemas
Everything a webhook schema can contain: steps or flat fields, every field type and its limits, conditions, defaults and templates.