Skip to main content
POST
/
v1
/
compute
/
{goalId}
/
pause
curl -X POST https://win.oneshotagent.com/v1/compute/goal_01HX8K3YZ/pause \
  -H "Content-Type: application/json" \
  -H "X-Agent-ID: 0xYourWalletAddress" \
  -d '{ "reason": "Pausing over the weekend" }'
{
  "success": true,
  "data": {
    "goal_id": "goal_01HX8K3YZ...",
    "status": "paused",
    "run_count": 4
  }
}

Overview

Pauses an active recurring compute goal (one created with a schedule_cron). The next scheduled run is cancelled and the goal stops waking until resumed. One-off (non-recurring) goals cannot be paused.

Authentication

Send your agent wallet address in the X-Agent-ID header. Only the wallet that created the goal can pause it; other callers get a 404.

Path Parameters

goalId
string
required
The goal ID to pause

Request Body

reason
string
Optional reason for pausing (logged for audit)

Response

data.goal_id
string
The paused goal ID
data.status
string
paused
data.run_count
number
Number of times the recurring goal has run so far
curl -X POST https://win.oneshotagent.com/v1/compute/goal_01HX8K3YZ/pause \
  -H "Content-Type: application/json" \
  -H "X-Agent-ID: 0xYourWalletAddress" \
  -d '{ "reason": "Pausing over the weekend" }'
{
  "success": true,
  "data": {
    "goal_id": "goal_01HX8K3YZ...",
    "status": "paused",
    "run_count": 4
  }
}
Only recurring goals (not_recurring error otherwise) that are currently active (invalid_state error otherwise) can be paused.