Skip to the content

DoRoutes API · version 1

Live updates

GET/v1/admin/events

Stream changes as server-sent events

Any signed-in staff member. Each event has an id, a topic (quote.created, quote.updated, quote.status, quote.needs_pricing, job.created, job.updated, job.status, job.issue, plan.updated, plan.nightly_failed, plan.unapproved, plan.replanned) and JSON data with the record id, or the date for plan.nightly_failed and plan.unapproved; plan.updated and plan.replanned also carry the plan's date. Send Last-Event-ID to first receive the events missed since it. A comment is sent every 15 seconds. Read it with fetch: EventSource cannot send the headers.

Response 200

A stream of server-sent events.

Response 401 · Error

No tenant key, or no valid session.

  • errorobject, required
    • codestring, required

      A short machine-readable name, such as not_found.

    • messagestring, required

      What went wrong, for people.

  • request_idstring, required

    Matches the X-Request-ID response header.

Example response 401
{
  "error": {
    "code": "string",
    "message": "string"
  },
  "request_id": "string"
}

Response 403 · Error

The session may not do this.

Fields as in Stream changes as server-sent events

Response 500 · Error

Something failed on our side.

Fields as in Stream changes as server-sent events