Skip to main content
Arcade can send your server a signed request when a job finishes, so you don’t have to poll. Polling with jobs/get keeps working.

Events

A job from patterns/create, a refine, products/create or products/generate sends one event when it finishes. A download job sends none. A product job’s event can arrive about a minute after jobs/get reports the job finished. Each request body is one event:
An event carries IDs only. Call jobs/get with the jobId to read the job’s result or error.

Add a destination

  1. In Arcade Studio, open Settings → API keys and select Manage webhooks. This opens the webhooks portal.
  2. Add a destination with your HTTPS URL and the events you want.
  3. Copy the destination’s signing secret. It starts with whsec_.
Destinations belong to your account, not to one API key. The portal also shows each delivery and your server’s response, and lets you retry a failed delivery.
Open the portal before you start the jobs you want events for. A job started before you first opened it may not send an event.

Test locally

Run the receiver below, then give it a public URL with a quick tunnel:
Add the printed URL as a destination, with /webhooks on the end, then start a job with patterns/create.

Verify the signature

Check the signature on every request, so you know it came from Arcade. Each request has an x-outpost-signature header of the form v0=<signature>. To check it:
  1. Compute the HMAC-SHA256 of the raw request body, using the whole signing secret as the key.
  2. Encode the result as hex.
  3. Compare it with the signature in the header.
Use the raw bytes of the body, before you parse the JSON. Parsing and serializing the body again can change it. While you rotate a secret, the header holds two signatures separated by a comma. Accept the request if either one matches.

Handle delivery

  • Respond quickly. Return a 2xx as soon as you have verified the request, and do your work afterwards. Any other response, or a timeout, counts as a failed delivery.
  • Expect retries. A failed delivery is retried automatically, with a longer wait each time. Once the retries run out, you can retry it from the portal.
  • Ignore duplicates. The same event can arrive more than once. Keep the id of each event you handle, and skip an id you have seen.
  • Don’t rely on order. Events can arrive in any order. Read the current state from the API.