Cancel a job
cancel_jobCancel a job: stops its machine and billing, and the status becomes cancelled. Cancelling a cancelled job changes nothing; a job that already ended another way cannot be cancelled. Returns the job. cost_usd covers the machine's whole time, not only the command's: from when its machine came up until it stopped, so setup before the command (pulling the image, waiting for the GPU driver, unpacking code) is included, at each machine's hourly rate (cost_per_hour is the current one's) and with every attempt added up. It is in USD to six decimal places, so a short run is not shown as $0, and while the job runs it is the cost so far. The charge on the billing page can differ slightly: machines billed by the minute are charged whole minutes, including about 30 seconds of teardown, and time some hosts report offline is not charged.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"id": "<id>"
},
"name": "cancel_job"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Job ID | |
| workspace | No | Workspace ID (optional: defaults to the authenticated workspace) | |
| environment | No | Environment name (optional: defaults to the environment this session acts in) |