Skip to main content
POST
Cancel a background job
The job ends as cancelled, and its run is stopped too. Rows the run already found are kept. Cancelling a batch stops every job in it that is still open. The answer is the job as it is now: while it stops, status is still queued or running with cancel_requested: true. A job that already ended is left as it is, and status says how it ended. Only your own; anyone else gets 404. Needs jobs:write. MCP tool: cancel_job.

Authorizations

Authorization
string
header
required

API key with the vd_sk_ prefix, as Authorization: Bearer vd_sk_.... Create keys in Settings → API Keys.

Headers

Idempotency-Key
string

Any unique string (such as your order id). Resending the same request with the same key within 24 hours returns the first answer (with Idempotent-Replayed: true) and does nothing twice; the same key with a different request is a 422 idempotency_key_reused.

Required string length: 1 - 255

Path Parameters

job_id
string
required

Response

The job as it is now: stopping, or left as it was because it had already ended.

id
string
required
origin_kind
enum<string>
required

Who started it: session (a chat session's agent), igris (the assistant), brain (a workflow's Brain, which may report results) or api.

Available options:
session,
igris,
brain,
api
kind
enum<string>
required

What it runs: a skill, a workflow, a research helper, or a batch grouping jobs started together.

Available options:
skill,
workflow,
research,
batch
status
enum<string>
required

queued, running, then one of completed, failed, cancelled.

Available options:
queued,
running,
completed,
failed,
cancelled
origin_id
string
default:""

The session or workflow that started it; empty for the assistant and the API.

group_id
string | null

The batch job it belongs to, when several were started together.

label
string
default:""

What it is, in the words it was started with, e.g. 'eBay search'.

target_id
string
default:""

The skill or workflow it runs.

run_ref
string | null

The run it drives (GET /v1/runs/{run_id} for a skill or workflow); null until it has started.

summary
string | null

One plain line of what came back, once it ended.

result
Result · object | null

A small result: count and a preview of the first rows. The run has the rest.

error
string | null

Why it failed.

cancel_requested
boolean
default:false

A stop was asked for; it ends cancelled soon.

attempts
integer
default:0

How many times its run was started.

created_at
string<date-time> | null
started_at
string<date-time> | null
ended_at
string<date-time> | null

The path of the page in the Valendata app that shows its run (e.g. /skills/runs/run_…); empty until it has started.