rsvp) or opts out (opt_out). The event type is in the payload’s type field.
How it works
- Each Laylo account sends its events to your Nango webhook URL with
?nangoConnectionId=<CONNECTION-ID>appended, so Nango knows which connection they belong to. - Nango verifies the HMAC signature (
X-Signature-256, computed overX-Laylo-Timestamp+ the request body) with that connection’s secret, and rejects requests older than 5 minutes. - Nango forwards the event to your app or runs your webhook functions for that connection.
Setup
Repeat these steps for each connection.1. Build the webhook URL
In the Nango dashboard, open your Laylo integration and copy the Webhook URL. Append the URL-encoded connection ID:&, #, + or spaces, which break the query string if pasted as-is. Encode the ID first, for example with encodeURIComponent(connectionId) in JavaScript.
2. Register the webhook in Laylo
- Log in to the connection’s Laylo account and go to Settings → Integrations.
- Paste the URL from step 1 into the Webhooks field and click Submit.
- Laylo generates an HMAC secret and shows it once. Copy it.
3. Store the HMAC secret on the connection
Laylo issues one secret per Laylo account. Store it aswebhookSecret in the connection’s metadata with Update connection metadata:
nangoConnectionId, the connection doesn’t exist or has no webhookSecret, or the signature doesn’t match.
Use Send test payload on Laylo’s Settings → Integrations page to check your setup.
Handle the webhook
- Forward it to your app: Nango forwards the event with connection attribution. See Webhook forwarding.
- Process it in a function: see Webhook functions.
opt_out events have the same shape without productId.