Workflows

Save a successful Code Mode run as a Workflow inside an OpenWork Connect Plugin

Changed on

Saves a successful authoring run as a reusable Workflow. Supply code or receiptId, or both with byte-identical source. Explicit receiptId requires a successful run from this caller in this organization within 15 minutes, retained source (encrypted shared storage when Redis is configured; process-local otherwise), and exactly matching tested input and schema digests; missing retention fails closed (400 workflow_authoring_receipt_required). Live receipts forbid currentInput, validate with their server-generated runtime, and never save runtime day bounds as example input. Without receiptId, the existing byte-exact recent successful code lookup applies (400 workflow_recent_receipt_required). Literal credentials in source are rejected, not sanitized. The run's tool calls become requiredCapabilities and must still be available. Saving creates no artifact snapshot linkage. Omit pluginId for the private My Workflows Plugin; a chosen Plugin requires editor access. Replacing a same-name Workflow requires manager access.

post/v1/workflows

Request

  • Base URL
    https://api.openworklabs.com
  • Auth
    • API key in header x-api-key
    • or HTTP bearer

Request body

object required
pluginId, string

Existing OpenWork Connect Plugin that will contain and share this Workflow. Omit to use the member's private My Workflows Plugin.

name, string required
description, string
code, string

Exact tested source. Required without receiptId; if both are supplied it must byte-match the retained source.

receiptId, string

Successful authoring receipt from this caller within 15 minutes. Encrypted source retention is shared across replicas when Redis is configured, otherwise process-local. If unavailable, retest or omit receiptId and supply the exact source.

currentInput, unknown
inputSchema, unknown
outputSchema, unknown

Response

Workflow saved.

object required
pluginId, string required
configObjectId, string required
configObjectVersionId, string required
graph, object required
mermaid, string required
name, string required

The name the Workflow was saved under; tell the person "Saved as <name>".

libraryUrl, string required

The Workflow's page in the member's Library, where they run, schedule and share it. Give the person this link.

Changes

    • info

      added the required property libraryUrl to the response with the status

    • info

      added the required property name to the response with the status

    • breaking

      the response property graph/edges/items/label became nullable for the status

    8 more changes in this revision