jobs

Cancel a job if it hasn't been completed yet.

Returns the updated job on success, 404 if job not found or already terminal.

post/jobs/{job_id}/cancel

Request

  • Base URL
    https://api.ionworks.com
  • URL
    https://api.ionworks.com/jobs/{job_id}/cancel
  • Auth
    none declared

Path parameters

job_idstring uuid required

The ID of the job to cancel

Response

Successful Response

job_idstring required
job_type'dummy' | 'datafit' | 'array_datafit' | 'validation' | 'simulate' | 'evaluate_variables' | 'optimize' | 'ecm_fit' | 'simple_pipeline' | 'linear_confidence_interval' | 'sobol_sensitivity' | 'surrogate_train' required

Possible types for a job

status'pending' | 'processing' | 'waiting' | 'completed' | 'failed' | 'canceled' required

Possible statuses for a job

priorityinteger required
created_atstring date-time required
updated_atstring date-time required
started_atstring date-time nullable
completed_atstring date-time nullable
compute_timenumber nullable
errorstring nullable
error_code'CONFIGURATION_ERROR' | 'MODEL_ERROR' | 'SOLVER_ERROR' | 'MAX_BACKWARD_JUMPS_EXCEEDED' | 'EXECUTION_TIMEOUT' | 'SUBMISSION_FAILED' | 'INTERNAL_ERROR'

Machine-readable error codes for jobs.

error_detailobject nullable
resultobject nullable
callback_urlstring uri nullable
parent_job_idstring nullable
user_idstring required
organization_idstring required
project_idstring nullable
access_level'project' | 'organization'

Possible access levels for a job

params_pathstring nullable
metadata_pathstring nullable
anyscale_job_idstring nullable
submission_infoobject nullable
child_keyobject nullable
is_terminalboolean required

Whether the job has reached a terminal state and will not transition further.

Derived from :attr:JobStatus.TERMINAL_STATUSES, so adding a new terminal status to the enum automatically updates the wire field — clients that read is_terminal never need to know the status taxonomy or be re-released when it changes.

is_failedboolean required

Whether the job terminated unsuccessfully (failed or canceled, not completed).

Derived from :attr:is_terminal minus the success case, so any new non-success terminal status added to :class:JobStatus is automatically classified as a failure without touching this method.

anyscale_urlstring nullable required

Deep-link to this job's Anyscale console dashboard, or None.

Built server-side (mirroring the Sentry log_url pattern) from the captured anyscale_job_id and the environment's console cloud/project ids. Returns None when the job never ran on Anyscale (local/serve) or the environment has no console ids configured, so the UI simply omits the link in those cases.

Changes

    • warning

      added the new surrogate_train enum value to the response property for the response status

    • breaking

      for the path request parameter job_id, the format changed from no format to uuid

    • warning

      added the new MAX_BACKWARD_JUMPS_EXCEEDED enum value to the / response property for the response status