Skip to Content
ReferenceAPI referenceSystem

Run a scheduler job now

POST
/api/v1/system/scheduler/jobs/{job_id}/run

Moves the job's next run to now and answers 202 right away, before the job finishes. A job that is already running does not start a second time, and an interval job counts its next run from this one. An unknown job id gets a 404, and so does every id while this process has no scheduler. Needs a Read/write API key or a browser session.

Authorization

cookiesession<token>

Session cookie authentication.

Path Parameters

job_id*string

The job's id from the job list, such as geoip-refresh.

Response Body

Request accepted, processing continues off-line

application/json
  1. response

One scheduled job. The last-run fields cover runs since this process started.

id*string

The job id that the run endpoint takes, such as geoip-refresh.

lastDurationSeconds*|

How long the last run took, in seconds.

lastError*|

The error of the last run when it failed.

lastRunTime*|

When the last run started.

lastStatus*|

missed means a run came due but could not start in time, so the scheduler skipped it.

Value in"success""error""missed"null
name*string
nextRunTime*|

Null when no next run is scheduled.

running*boolean

Whether a run is in progress.

trigger*string

When the job runs, as APScheduler describes its trigger.

Example Request
curl -X POST 'https://geometrikks.example.com/api/v1/system/scheduler/jobs/string/run'
Example Response
{  "id": "string",  "lastDurationSeconds": 0,  "lastError": "string",  "lastRunTime": "2019-08-24T14:15:22Z",  "lastStatus": "success",  "name": "string",  "nextRunTime": "2019-08-24T14:15:22Z",  "running": true,  "trigger": "string"}