Cancel resource operation¶
Mark the resource operation record as canceled. Currently executing tasks will not be stopped.
POST $CLOUDSIGMA_API_BASE/workspaces/{workspace_id}/operations/{operation_id}/cancel
Before you call¶
Configure the CloudSigma regional endpoint and authentication before calling. The endpoint, credentials, workspace, and resource IDs must belong to the same region. Prepare a personal access token and target workspace ID that can access the target workspace.
Request parameters¶
curl -X POST "$CLOUDSIGMA_API_BASE/workspaces/$WORKSPACE_ID/operations/$OPERATION_ID/cancel" -H "X-API-Key: $CLOUDSIGMA_API_KEY" -H "X-Workspace-ID: $WORKSPACE_ID"
Field |
Type |
Required |
Description |
|---|---|---|---|
|
string |
Yes |
Target workspace ID. |
|
string |
Yes |
The resource operation ID to cancel. |
Successful response¶
{
"code": 0,
"data": {
"operation_id": "operation_example",
"type": "agent_package_load",
"status": "canceled",
"progress": 0,
"created_at": "2026-10-14T00:00:00Z",
"updated_at": "2026-10-14T00:00:00Z"
}
}
Field |
Type |
Description |
|---|---|---|
|
integer |
|
|
object |
response data. |
|
string |
Operation record ID. |
|
string |
Operation type. |
|
string |
Resource type. Can be omitted if not set. |
|
string |
Associated resource ID. Can be omitted if not set. |
|
string |
Operating Instructions. Can be omitted if not set. |
|
string |
status after cancellation. Values: |
|
integer |
Current progress. |
|
object |
Operation results. Can be omitted if not set. |
|
object |
Error details. Can be omitted if not set. |
|
string |
Creation time, in RFC 3339 format. |
|
string |
Last updated in RFC 3339 format. |
|
string |
Completion time, may be omitted if not completed. Can be omitted if not set. |
Error response¶
{
"code": 3,
"message": "operation not found"
}
Field |
Type |
Description |
|---|---|---|
|
integer |
error code. |
|
string |
Error message for the caller. |