Skip to main content
POST
Restore a previous version to draft
This overwrites an existing draft. Retrieve any changes you need to keep before restoring a version.
Requires Editor, Admin, or Owner. Use the version record’s id from List versions as definition_id; it is different from version_number. The restored version becomes a draft. The published agent remains unchanged until you explicitly publish. A missing agent/version returns 404; selecting the current draft returns 409. Changing the agent’s assistant mode is not supported by rollback.

Authorizations

Authorization
string
header
required

Bandwidth Labs OAuth access token. Uses the user's selected workspace; the workspace header is not required. Do not also send an API key. Bearer-only operations may additionally require the Labs super_user role.

Headers

X-VOAI-ORGANIZATION-ID
string | null

Required with X-BW-LABS-AGENTS-API-KEY: the positive local workspace ID to access. The key owner must be a current member. Missing or invalid IDs return 400; non-member workspaces return 403. Not required for bearer authentication, which uses the user's selected workspace.

Path Parameters

workflow_id
integer
required
definition_id
integer
required

Response

Successful Response

created_at
string<date-time>
required
id
integer
required
status
string
required
version_number
integer
required
workflow_json
Workflow Json · object
required
published_at
string<date-time> | null
template_context_variables
Template Context Variables · object | null
workflow_configurations
Workflow Configurations · object | null