Jobs

Start a job execution

Open a job execution for a script running outside the platform.

Pass the returned job_execution_id to the write and upload-file tools so everything one script run produces is attributed to a single execution and can be inspected or reverted as a unit. Pass job_id to run under an existing job, job_name to run under a job of that name (created if missing), or neither to run under the default off-platform job.

The execution is marked running immediately. Close it as completed or failed when the script finishes. Pass timeout_minutes to have the platform fail it after that long if the script has not closed it, so a crashed script does not leave it running forever.

Requires an API key with the write scope.

post/api/v1/job-executions

Request

  • Base URL: https://platform.labric.co
  • URL: https://platform.labric.co/api/v1/job-executions
  • Auth: HTTP bearer

Request body

job_idstring uuid nullable

ID of an existing job to run under. Omit to use job_name instead.

job_namestring nullable

Name of the job to run under, created if it does not exist yet. Ignored when job_id is given. Defaults to 'Off-Platform Manual Job'.

timeout_minutesinteger nullable

Fail the execution if the script has not closed it within this many minutes (at most 43200, i.e. 30 days), so a crashed script does not leave it running forever. Omit to let it run until closed.

Response

OK

job_execution_idstring uuid required

Pass this as job_execution_id to the write and upload-file tools.

job_idstring uuid required

ID of the job the execution belongs to.

job_namestring required

Name of the job the execution belongs to.

statusstring nullable required

The execution's current status.

started_atstring date-time nullable required

When the execution started.

completed_atstring date-time nullable required

When the execution ended, or null while it is still running.

Changes

No recorded changes to this operation across all 1 revision of this API.