GoRunner docs
Search or askSearch⌘K

Deliver to a webhook

POST/api/webhooks/{token}

A published workflow’s public address: any request to it starts a production run, and the answer can be the run’s result.

Needs no API token: the token in the address is the key. See Call a workflow’s webhook.

Parameters

Path

tokenRequired · string

The workflow’s webhookToken, from Publish a workflow.

Query

asyncOptional · string

true answers 202 as soon as the run is queued. Anything else waits, up to 30 seconds.

Headers

Idempotency-KeyOptional · string

Up to 255 characters. A retry with the same key and the same method, query and body starts no second run: it gets the first run’s answer, with Idempotency-Replayed: true. Kept 24 hours.

Body

Any body, any Content-Type, up to 5 MiB. It becomes {{trigger.body}}.

A Return Response step

A Return Response step decides the answer instead: its status, headers and body. The run headers come with it.

Responses

  • 200OK

    The run finished within 30 seconds. The body is the last step’s output, or {}. X-Run-Id and X-Run-Status are set.

  • 202Accepted

    Still going after 30 seconds, paused, or waiting for a free slot; or ?async=true. The body has runId.

  • A NUL in the address, or a body that couldn’t be read.

  • The trigger’s Authentication, or an app’s signature check, failed. Nothing runs.

  • “Webhook not found.” The address is wrong or was replaced, the workflow isn’t published, or its trigger isn’t one this address is for.

  • The trigger’s methods leaves this method out. Allow lists the ones it takes.

  • The run was cancelled, while it waited for a slot or while it ran. Or the Idempotency-Key’s first delivery is still being recorded (Retry-After: 1), or its run has since been deleted.

  • The body is over 5 MiB. Nothing runs.

  • This Idempotency-Key was already used with a different request.

  • This address sent more than WEBHOOK_RATE_LIMIT requests this minute. Retry-After says when to try again.

  • The workflow is at its runs-at-once limit and is set to Refuse.

  • Too many runs are already waiting, for the organization or this workflow.

  • 500

    The run failed. Read the run for the reason.

  • The address couldn’t be looked up just now, or nothing can run the workflow. Retry after Retry-After.

  • The account is suspended. Retry-After: 3600.

  • A self-hosted installation has no license. Retry-After: 3600.

  • Nothing can run the workflow just now, and nothing was recorded. Retry-After: 10. With ?async=true, the run is queued instead.

  • GoRunner couldn’t check which apps this workspace may use. Nothing changed. Try again.

  • The run finished, but its answer couldn’t be read back. Read it with the ID in X-Run-Id.

  • 504

    The run failed on a time limit.

Any call can also answer: 401 TOKEN_ENDED · 403 TOKEN_SURFACE_OFF · 415 INVALID_CONTENT_TYPE · 503 BUSY. See Errors.

Request

GORUNNER="https://api.gorunner.io"
WEBHOOK_TOKEN="your-webhook-token"

curl -i -X POST "$GORUNNER/api/webhooks/$WEBHOOK_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"orderId": "A-1001"}'

Response · 200 OK, the last step’s output, with no data envelope

json
{
  "orderId": "A-1001",
  "accepted": true
}
Every field

The delivery, any content type: it becomes the run’s trigger data ({{trigger.body}}).

200 OK: a body.

Response · 202 Accepted

dataobject
runIdUUID
statusstring

running, paused, waiting or pending (pending when not waited for: queued). Absent with ?async=true.

messagestring

A sentence for a person: what to do next.

waitstring

overloaded: not waited for, because the server held as many waiting callers as it may.

One of overloaded.

pollstring

With wait: overloaded: where to read the run.