v1

latestOpenAPI 3.1.02026-07-24111290748.0 KB
Jobs

List jobs

List jobs, paginated and ordered by their creation date, with the most recent ones first.

get/api/jobs

Query parameters

cursorstring
Example:WyJuZXh0IiwgIjIwMjEtMDEtMDFUMDE6MDA6MDAiLCA1MV0=

Value indicating your position in the list of all jobs. If omitted, the first jobs of the list will be returned.

limitinteger

Maximum number of jobs to return.

order_by'created_datetime:asc' | 'created_datetime:desc'

Attribute used to order jobs.

status'cancel_requested' | 'canceled' | 'done' | 'errored' | 'fatal_errored' | 'pending' | 'running' | 'scheduled' nullable
Example:cancel_requested

Filter jobs by status.

type'applyMacro' | 'deleteTicket' | 'exportTicket' | 'importMacro' | 'exportMacro' | 'updateTicket' | 'exportTicketDrilldown' | 'exportConvertCampaignSalesDrilldown' nullable
Example:applyMacro

Filter jobs by job type.

Response

A list of jobs.

Example response

{
  "data": [
    {
      "id": 1234,
      "cancel_requested_datetime": "2019-11-23T16:31:00.966927",
      "cancelled_datetime": "2019-11-23T16:32:00.966927",
      "created_datetime": "2019-11-23T16:00:00.966927",
      "ended_datetime": "2019-11-23T16:32:00.966927",
      "failed_datetime": "2019-11-23T15:59:41.966927",
      "info": {
        "progress_count": 123
      },
      "locked_datetime": "2019-11-23T16:30:01.966927",
      "meta": {
        "description": "This job closes all tickets created in 2018"
      },
      "params": {
        "ticket_ids": [
          1,
          2,
          3
        ],
        "updates": {
          "status": "open"
        }
      },
      "scheduled_datetime": "2019-11-23T16:30:00.966927",
      "started_datetime": "2019-11-23T16:30:01.966927",
      "status": "canceled",
      "type": "updateTicket",
      "user_id": 42
    }
  ],
  "meta": {
    "next_cursor": "WyJuZXh0IiwgIjIwMjEtMDEtMDFUMDE6MDA6MDAiLCA1MV0=",
    "prev_cursor": "WyJuZXh0IiwgIjIwMjEtMDEtMDFUMDE6MDA6MDAiLCA1MV0="
  }
}