Skip to navigation

Poll the session

View as Markdown

Whether the session is finished, as an HTTP code with no body — the cheapest way to poll.

  • 200 — finished. Nothing about the session will change any more; read the results.
  • 202 — still open. Nothing is wrong: your customer has not finished, or a source is still answering.
  • 404 — no session with that id for your application, or it was deleted. A deleted session answers exactly like one that never existed.
Prefer a webhook to a poll

This endpoint exists for the cases where you cannot receive a callback. When you can, subscribe to On Flow Ended instead: it arrives the moment the session closes, and costs you nothing while it is open.

Every answer is a status code and nothing else, which is the point — there is no body to parse and no session document to build. The same contract as the Direct Executions poll, so both products are polled the same way.

This endpoint needs to be executed with an app secret, so should always be used in server side without exposing the secret to customers.

Authentication

X-APP-SECRETstring
Application Secret

Path parameters

session_idstringRequiredformat: "object-id"
Session ID to poll

Response

200 OK
Finished. Read the results.

Errors

404
Not Found Error
422
Unprocessable Entity Error
429
Too Many Requests Error