Workflows

Create workflow

Create a new workflow together with its initial version. This route forwards to workflows-engine, which generates the slug, persists the workflow + version, and provisions the execution state machine.

Only name is required. definition is the workflow DSL as an arbitrary JSON object (steps, input_schema, metadata). Categories, tags, and visibility are not accepted on this route — workflows-engine applies its defaults (categories ["general"], visibility private).

post/v1/workflows

Request

  • Base URL: https://api.eachlabs.ai
  • URL: https://api.eachlabs.ai/v1/workflows
  • Auth: HTTP bearer

Request body

namestring required

Human-readable workflow name. Required.

definitionobject

Workflow DSL (steps, input_schema, metadata) as a JSON object.

Example request

{
  "name": "My Workflow",
  "definition": {
    "version": "1.0",
    "steps": []
  }
}

Response

Workflow created

workflow_idstring
slugstring
namestring
categoriesstring[]
tagsstring[]
statusstring
trigger_countinteger
clone_countinteger
is_publicboolean
productionboolean
created_atstring date-time
updated_atstring date-time

Example response

{
  "workflow_id": "wf_abc123",
  "slug": "my-workflow",
  "name": "My Workflow",
  "categories": [
    "general"
  ],
  "tags": [],
  "status": "active",
  "versions": [
    {
      "version_id": "v1",
      "slug": "my-workflow",
      "status": "active"
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.