import_workflow
Import a complete workflow graph as a new private workflow, optionally into a project.
Saves a definition only: importing runs none of the graph's steps and spends no Creative
Units. The graph may only use the node kinds get_blueprint_system_config lists, all of them
Layer operations; running the workflow later is a separate execute_workflow call.
Use this to bring in a workflow authored outside the Blueprint editor, such as one
converted from another workflow tool, in one call. Call get_blueprint_system_config
first for the node kinds, ports and value schemas the graph must use, then call with
`validate_only=true` and fix the reported problems until `is_valid` is true.
The workflow is always created private and unfeatured; making it public or featured is
a separate curation step in the app. By default the version is published so the
workflow can run right away with execute_workflow; an invalid graph is then rejected and
nothing is created. With `publish=false` a draft is created even when the graph has
problems.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
workspace_idrequired | string (uuid) | — | The workspace that will own the imported workflow. |
project_id | string (uuid) | — | Optional project to add the workflow to, e.g. a curation project. Use list_projects to find project ids. |
namerequired | string1–∞ chars | — | Display name for the workflow. |
description | string | — | Optional description shown with the workflow. |
graphrequired | object | — | The complete blueprint graph: `inputs` (parameter key to input parameter), `outputs` (parameter key to output parameter), and `nodes` (node id to node). Nodes use kinds and ports from get_blueprint_system_config. Edges are not listed separately: a node input or output parameter names what feeds it in its `refs` (`{"_default": [...]}`), either a node output (`nodes::<node id>[<kind key>]::<port key>`) or a workflow input (`blueprint::<input key>`). |
publish | boolean | true | Publish the imported version so the workflow can run (it stays private). Requires a valid graph. Set false to keep it as a draft, which is created even when the graph has problems so it can be fixed in the editor. |
validate_only | boolean | false | Only check the graph and report problems; create nothing. Use it to iterate on a converted graph before importing it. |