Skip to main content
Skip to content

Webhooks

Yes, with webhooks. Coassemble can send a server-to-server message to your app the moment a course is created, started or completed, so your own systems react automatically without you polling for changes. Webhooks are available on Embed Core and above.

A webhook is a message Coassemble sends to your app when something happens, rather than you having to check for it. When a learner finishes a course, Coassemble posts the details to a URL you control, so you can update a record, trigger an email, issue a certificate, or sync the result into another system straight away.

Events you can subscribe to

You choose which events you want to hear about:

  • course.created, when a new course is created.
  • course.commenced, when a learner first starts a course.
  • course.completed, when a learner first completes a course.

What Coassemble sends

Each webhook is an HTTPS POST with a JSON body. The payload includes the event type and time, the workspace, details of the course (id, title, key), and the tracking record for the learner, including their identifier, email, when they started and completed, and total time spent. That's enough for your system to know exactly who did what, and when.

Each request also carries headers identifying the event, a unique delivery ID, a timestamp, and a signature you can use to verify the message genuinely came from Coassemble.

Set up a webhook

  1. Build an HTTPS endpoint in your app that accepts POST JSON and returns a 2xx response quickly. The URL must use https.
  2. In Coassemble, go to Settings → Webhooks.
  3. Create a webhook endpoint URL and select the events you want.
  4. Send a test delivery to confirm your receiver works. Test payloads are flagged so you can tell them apart from real ones.
  5. Verify the signature on incoming requests, deduplicate using the delivery ID, then process the event.

Webhook endpoints are managed in the Coassemble app under Settings → Webhooks, where you can create, edit, test, enable, disable or delete them.

Making delivery reliable

A delivery counts as successful only when your endpoint returns a 2xx status. Coassemble waits up to 10 seconds for a response, and retries a failed delivery up to four attempts total, with backoff of roughly 1 minute, then 5 minutes, then 30 minutes. Every attempt carries the same delivery ID, so you can safely ignore duplicates. Because of retries, it's best to acknowledge quickly and do the real work afterwards.

Webhooks vs in-page events

Webhooks are server-to-server, which suits updating your back-end systems. If instead you want to react to things happening live in the learner's browser while a course is embedded, the embedded course player emits events in the page for that. Webhooks are the right choice when another system needs to know a result, even when no one's looking at the screen.

Frequently asked questions

What can I do when a course is completed?

Anything your systems support: mark a record complete, issue a certificate, send a notification, or sync the result into a CRM or LMS. Coassemble sends the learner's identifier, email and completion details so you have what you need.

How do I know a webhook really came from Coassemble?

Each request is signed. Coassemble includes a signature header, and your endpoint has its own signing secret, so you can verify the request before trusting it.

What happens if my endpoint is down?

Coassemble retries failed deliveries up to four times with increasing delays. Each retry uses the same delivery ID so you can avoid processing the same event twice.

Do I need Embed for webhooks?

Yes. Webhooks are part of Embed and available on Embed Core and above.

This article is maintained in our help centre. View the original ↗