AgentWorkflowProposal
Operations
Every route this entity exposes. Each route links to its own reference on this page.
| Method | Route | SDK operation | Returns |
|---|---|---|---|
POST |
/api/v1/organizations/{organization_id}/agents/{id}/spark/workflow_proposals/{proposal}/revise |
create |
The revised proposal |
POST |
/api/v1/organizations/{organization_id}/agents/{id}/spark/workflow_proposals/{proposal}/save |
create |
The saved proposal |
GET |
/api/v1/organizations/{organization_id}/agents/{id}/spark/workflow_proposals/{proposal} |
load |
The proposal and its steps |
Examples
One example per SDK, generated from the API model. The argument names are the parameters and fields of this entity, and the values are placeholders. The examples are not compiled or executed.
Golang
Construct client as shown in the Golang setup, then call the operations:
agent_workflow_proposal, err := client.AgentWorkflowProposal(nil).Load(map[string]any{"agent_id": "example", "id": "example_id", "organization_id": "example"}, nil)
if err != nil {
panic(err)
}
fmt.Println(agent_workflow_proposal)
Lua
Construct client as shown in the Lua setup, then call the operations:
local agent_workflow_proposal, err = client:AgentWorkflowProposal():load({ agent_id = "example", id = "example_id", organization_id = "example" })
PHP
Construct client as shown in the PHP setup, then call the operations:
$agent_workflow_proposal = $client->AgentWorkflowProposal()->load(["agent_id" => "example", "id" => "example_id", "organization_id" => "example"]);
Python
Construct client as shown in the Python setup, then call the operations:
agent_workflow_proposal = client.AgentWorkflowProposal().load({"agent_id": "example", "id": "example_id", "organization_id": "example"})
Ruby
Construct client as shown in the Ruby setup, then call the operations:
agent_workflow_proposal = client.AgentWorkflowProposal.load({ "agent_id" => "example", "id" => "example_id", "organization_id" => "example" })
TypeScript
Construct client as shown in the TypeScript setup, then call the operations:
const agent_workflow_proposal = await client.AgentWorkflowProposal().load({ agent_id: "example", id: "example_id", organization_id: "example" })
Fields
| Field | Type | Required | Description |
|---|---|---|---|
agent_steps |
object |
No | The model and reasoning the workflow's agent steps share. |
base_digest |
one,string,null |
Yes | The saved workflow this proposal changes; null for a new workflow. |
can_manage |
boolean |
Yes | Can Manage |
can_revise |
boolean |
Yes | The viewer can choose the model and reasoning of the agent steps now, before saving. |
can_save |
boolean |
Yes | The viewer can save this proposal now: they manage the agent, and it is unsaved, current and passes its checks. |
can_set_trigger |
boolean |
Yes | Saved as proposed with nothing starting it, so saving again sets its trigger. |
created_at |
string |
Yes | Created At |
definition |
one,object,null |
Yes | Definition |
digest |
string |
Yes | Names the reviewed version, its source and trigger; send it to save this version. |
error |
one,string,null |
Yes | Why the proposal no longer passes its checks, such as a model this agent no longer has. |
id |
string |
Yes | Id |
model_choices |
array |
No | Models the viewer may choose for the agent steps before saving. |
name |
string |
Yes | Name |
native_rows |
array |
No | Native Rows |
path |
string |
Yes | Path |
pipeline_checkpoints |
object |
Yes | Pipeline Checkpoints |
pipeline_commands |
object |
Yes | Pipeline Commands |
reasoning_choices |
array |
No | Reasoning levels the viewer may choose for the agent steps; none uses the agent's default. |
runs_on_earlier_version |
one,integer,null |
Yes | Runs already going when this save replaced the file, which finish on the version they started with; only in the reply to that save. |
saved |
one,object,null |
Yes | Saved |
stale |
boolean |
Yes | The workflow changed since the proposal, so it cannot be saved. |
starts |
one,object,null |
Yes | What starts the workflow without a chat turn; saving the proposal sets this trigger. |
trigger_error |
one,string,null |
Yes | Why the save could not set the trigger; only in the reply to that save. |
create
POST /api/v1/organizations/{organization_id}/agents/{id}/spark/workflow_proposals/{proposal}/revise
Operation ID: post_api_v1_organizations_organization_id_agents_id_spark_workflow_proposals_proposal_revise.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
organization_id |
path |
string |
Yes | |
id |
path |
string |
Yes | |
proposal |
path |
string |
Yes |
Request body
application/json
| Property | Type | Required | Description |
|---|---|---|---|
digest |
string |
Yes | |
model |
string |
Yes | |
reasoning |
string |
Yes |
Responses
200: The revised proposal
application/json
| Property | Type | Required | Description |
|---|---|---|---|
agent_steps |
object |
No | The model and reasoning the workflow's agent steps share. |
agent_steps.model |
string |
Yes | The model every agent step uses; null when they differ. |
agent_steps.reasoning |
string |
Yes | The reasoning every agent step sets; null for the agent's default or when they differ. |
agent_steps.reasoning_mixed |
boolean |
Yes | The agent steps set different reasoning. |
agent_steps.revisable |
boolean |
Yes | The agent steps' model and reasoning can be changed from the card. |
base_digest |
string |
Yes | The saved workflow this proposal changes; null for a new workflow. |
can_manage |
boolean |
Yes | |
can_revise |
boolean |
Yes | The viewer can choose the model and reasoning of the agent steps now, before saving. |
can_save |
boolean |
Yes | The viewer can save this proposal now: they manage the agent, and it is unsaved, current and passes its checks. |
can_set_trigger |
boolean |
Yes | Saved as proposed with nothing starting it, so saving again sets its trigger. |
created_at |
string (date-time) |
Yes | |
definition |
object |
Yes | |
digest |
string |
Yes | Names the reviewed version, its source and trigger; send it to save this version. |
error |
string |
Yes | Why the proposal no longer passes its checks, such as a model this agent no longer has. |
id |
string |
Yes | |
model_choices |
array of string |
No | Models the viewer may choose for the agent steps before saving. |
name |
string |
Yes | |
native_rows |
array of object |
No | |
native_rows[].actor |
enum: agent, sandbox, you, group |
Yes | |
native_rows[].conditional |
boolean |
Yes | |
native_rows[].depth |
integer |
Yes | |
native_rows[].detail |
string,null |
Yes | |
native_rows[].id |
string |
Yes | |
native_rows[].line |
string,null |
Yes | |
native_rows[].title |
string |
Yes | |
native_rows[].who |
string |
Yes | |
path |
string |
Yes | |
pipeline_checkpoints |
object |
Yes | |
pipeline_commands |
object |
Yes | |
reasoning_choices |
array of string |
No | Reasoning levels the viewer may choose for the agent steps; none uses the agent's default. |
runs_on_earlier_version |
integer |
Yes | Runs already going when this save replaced the file, which finish on the version they started with; only in the reply to that save. |
saved |
object |
Yes | |
saved.at |
string (date-time) |
Yes | |
saved.by |
object |
Yes | |
saved.by.kind |
enum: person, agent |
Yes | |
saved.by.name |
string |
No | |
stale |
boolean |
Yes | The workflow changed since the proposal, so it cannot be saved. |
starts |
object |
Yes | What starts the workflow without a chat turn; saving the proposal sets this trigger. |
starts.daily_limit |
integer |
Yes | How many events a day may start a run. |
starts.event_kinds |
array of string |
Yes | The signal kinds or event types it starts on; empty for any. |
starts.found |
boolean |
Yes | The event subscription it names still exists. |
starts.kind |
enum: event, schedule |
Yes | |
starts.min_severity |
string |
Yes | |
starts.on |
boolean |
Yes | Once saved, whether a trigger for the saved file is on; null before. |
starts.run_budget_usd |
number |
Yes | The most each run may spend. |
starts.schedule |
object |
Yes | A cron expression with its time zone, or an interval. |
starts.source |
string |
Yes | Where events come from: a signal provider such as sentry, signals for several, github, verify, or webhook. |
trigger_error |
string |
Yes | Why the save could not set the trigger; only in the reply to that save. |
401: Unauthorized
403: Current agent management authority required
404: The proposal is no longer available
409: The proposal changed after it was reviewed (workflow_proposal_changed) or is already saved (workflow_proposal_saved)
410: The file-based proposal is retired (workflow_files_retired)
422: The model or reasoning is not available, or this workflow's steps can't be changed this way
502: Bad gateway
POST /api/v1/organizations/{organization_id}/agents/{id}/spark/workflow_proposals/{proposal}/save
Operation ID: post_api_v1_organizations_organization_id_agents_id_spark_workflow_proposals_proposal_save.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
organization_id |
path |
string |
Yes | |
id |
path |
string |
Yes | |
proposal |
path |
string |
Yes |
Request body
application/json
| Property | Type | Required | Description |
|---|---|---|---|
digest |
string |
Yes |
Responses
200: The saved proposal
application/json
| Property | Type | Required | Description |
|---|---|---|---|
agent_steps |
object |
No | The model and reasoning the workflow's agent steps share. |
agent_steps.model |
string |
Yes | The model every agent step uses; null when they differ. |
agent_steps.reasoning |
string |
Yes | The reasoning every agent step sets; null for the agent's default or when they differ. |
agent_steps.reasoning_mixed |
boolean |
Yes | The agent steps set different reasoning. |
agent_steps.revisable |
boolean |
Yes | The agent steps' model and reasoning can be changed from the card. |
base_digest |
string |
Yes | The saved workflow this proposal changes; null for a new workflow. |
can_manage |
boolean |
Yes | |
can_revise |
boolean |
Yes | The viewer can choose the model and reasoning of the agent steps now, before saving. |
can_save |
boolean |
Yes | The viewer can save this proposal now: they manage the agent, and it is unsaved, current and passes its checks. |
can_set_trigger |
boolean |
Yes | Saved as proposed with nothing starting it, so saving again sets its trigger. |
created_at |
string (date-time) |
Yes | |
definition |
object |
Yes | |
digest |
string |
Yes | Names the reviewed version, its source and trigger; send it to save this version. |
error |
string |
Yes | Why the proposal no longer passes its checks, such as a model this agent no longer has. |
id |
string |
Yes | |
model_choices |
array of string |
No | Models the viewer may choose for the agent steps before saving. |
name |
string |
Yes | |
native_rows |
array of object |
No | |
native_rows[].actor |
enum: agent, sandbox, you, group |
Yes | |
native_rows[].conditional |
boolean |
Yes | |
native_rows[].depth |
integer |
Yes | |
native_rows[].detail |
string,null |
Yes | |
native_rows[].id |
string |
Yes | |
native_rows[].line |
string,null |
Yes | |
native_rows[].title |
string |
Yes | |
native_rows[].who |
string |
Yes | |
path |
string |
Yes | |
pipeline_checkpoints |
object |
Yes | |
pipeline_commands |
object |
Yes | |
reasoning_choices |
array of string |
No | Reasoning levels the viewer may choose for the agent steps; none uses the agent's default. |
runs_on_earlier_version |
integer |
Yes | Runs already going when this save replaced the file, which finish on the version they started with; only in the reply to that save. |
saved |
object |
Yes | |
saved.at |
string (date-time) |
Yes | |
saved.by |
object |
Yes | |
saved.by.kind |
enum: person, agent |
Yes | |
saved.by.name |
string |
No | |
stale |
boolean |
Yes | The workflow changed since the proposal, so it cannot be saved. |
starts |
object |
Yes | What starts the workflow without a chat turn; saving the proposal sets this trigger. |
starts.daily_limit |
integer |
Yes | How many events a day may start a run. |
starts.event_kinds |
array of string |
Yes | The signal kinds or event types it starts on; empty for any. |
starts.found |
boolean |
Yes | The event subscription it names still exists. |
starts.kind |
enum: event, schedule |
Yes | |
starts.min_severity |
string |
Yes | |
starts.on |
boolean |
Yes | Once saved, whether a trigger for the saved file is on; null before. |
starts.run_budget_usd |
number |
Yes | The most each run may spend. |
starts.schedule |
object |
Yes | A cron expression with its time zone, or an interval. |
starts.source |
string |
Yes | Where events come from: a signal provider such as sentry, signals for several, github, verify, or webhook. |
trigger_error |
string |
Yes | Why the save could not set the trigger; only in the reply to that save. |
401: Unauthorized
403: Current agent management authority required
404: The proposal is no longer available
409: The proposal changed after it was reviewed (workflow_proposal_changed), the workflow changed since the proposal (workflow_proposal_stale), or the file could not be written (workflow_write_unavailable)
410: The file-based proposal is retired (workflow_files_retired)
422: The proposed workflow no longer passes its checks
502: Bad gateway
load
GET /api/v1/organizations/{organization_id}/agents/{id}/spark/workflow_proposals/{proposal}
Operation ID: get_api_v1_organizations_organization_id_agents_id_spark_workflow_proposals_proposal_.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
organization_id |
path |
string |
Yes | |
id |
path |
string |
Yes | |
proposal |
path |
string |
Yes |
Responses
200: The proposal and its steps
application/json
| Property | Type | Required | Description |
|---|---|---|---|
agent_steps |
object |
No | The model and reasoning the workflow's agent steps share. |
agent_steps.model |
string |
Yes | The model every agent step uses; null when they differ. |
agent_steps.reasoning |
string |
Yes | The reasoning every agent step sets; null for the agent's default or when they differ. |
agent_steps.reasoning_mixed |
boolean |
Yes | The agent steps set different reasoning. |
agent_steps.revisable |
boolean |
Yes | The agent steps' model and reasoning can be changed from the card. |
base_digest |
string |
Yes | The saved workflow this proposal changes; null for a new workflow. |
can_manage |
boolean |
Yes | |
can_revise |
boolean |
Yes | The viewer can choose the model and reasoning of the agent steps now, before saving. |
can_save |
boolean |
Yes | The viewer can save this proposal now: they manage the agent, and it is unsaved, current and passes its checks. |
can_set_trigger |
boolean |
Yes | Saved as proposed with nothing starting it, so saving again sets its trigger. |
created_at |
string (date-time) |
Yes | |
definition |
object |
Yes | |
digest |
string |
Yes | Names the reviewed version, its source and trigger; send it to save this version. |
error |
string |
Yes | Why the proposal no longer passes its checks, such as a model this agent no longer has. |
id |
string |
Yes | |
model_choices |
array of string |
No | Models the viewer may choose for the agent steps before saving. |
name |
string |
Yes | |
native_rows |
array of object |
No | |
native_rows[].actor |
enum: agent, sandbox, you, group |
Yes | |
native_rows[].conditional |
boolean |
Yes | |
native_rows[].depth |
integer |
Yes | |
native_rows[].detail |
string,null |
Yes | |
native_rows[].id |
string |
Yes | |
native_rows[].line |
string,null |
Yes | |
native_rows[].title |
string |
Yes | |
native_rows[].who |
string |
Yes | |
path |
string |
Yes | |
pipeline_checkpoints |
object |
Yes | |
pipeline_commands |
object |
Yes | |
reasoning_choices |
array of string |
No | Reasoning levels the viewer may choose for the agent steps; none uses the agent's default. |
runs_on_earlier_version |
integer |
Yes | Runs already going when this save replaced the file, which finish on the version they started with; only in the reply to that save. |
saved |
object |
Yes | |
saved.at |
string (date-time) |
Yes | |
saved.by |
object |
Yes | |
saved.by.kind |
enum: person, agent |
Yes | |
saved.by.name |
string |
No | |
stale |
boolean |
Yes | The workflow changed since the proposal, so it cannot be saved. |
starts |
object |
Yes | What starts the workflow without a chat turn; saving the proposal sets this trigger. |
starts.daily_limit |
integer |
Yes | How many events a day may start a run. |
starts.event_kinds |
array of string |
Yes | The signal kinds or event types it starts on; empty for any. |
starts.found |
boolean |
Yes | The event subscription it names still exists. |
starts.kind |
enum: event, schedule |
Yes | |
starts.min_severity |
string |
Yes | |
starts.on |
boolean |
Yes | Once saved, whether a trigger for the saved file is on; null before. |
starts.run_budget_usd |
number |
Yes | The most each run may spend. |
starts.schedule |
object |
Yes | A cron expression with its time zone, or an interval. |
starts.source |
string |
Yes | Where events come from: a signal provider such as sentry, signals for several, github, verify, or webhook. |
trigger_error |
string |
Yes | Why the save could not set the trigger; only in the reply to that save. |