DocsHTTP APICreate a workflow

Create a workflow

Create a workflow. Use POST /workflows in Chronoverse, with authentication, parameters, and response details.

POST
/workflows

Authentication

cookieSession
apiKey
required

Encrypted session cookie issued after registration or login.

cookie: session
csrfToken
apiKey
required

CSRF cookie issued with the session and required for state-changing requests.

cookie: csrf

All credentials in this group are required.

Parameters

Idempotency-Key
header
required

Valid UTF-8 containing 1-255 bytes after trimming only outer ASCII spaces (U+0020), with no Unicode control characters. Reuse a key only for retries of the exact same logical request.

stringmin length: 1

Request body

required
application/json
{
  "type": "object",
  "required": [
    "name",
    "payload",
    "kind",
    "interval",
    "max_consecutive_job_failures_allowed"
  ],
  "properties": {
    "name": {
      "type": "string"
    },
    "payload": {
      "type": "string",
      "description": "Workflow-kind-specific JSON encoded as a string"
    },
    "kind": {
      "type": "string",
      "enum": [
        "HEARTBEAT",
        "CONTAINER"
      ]
    },
    "interval": {
      "type": "integer",
      "minimum": 1,
      "maximum": 10080,
      "description": "Schedule interval in minutes"
    },
    "max_consecutive_job_failures_allowed": {
      "type": "integer",
      "minimum": 3,
      "maximum": 100
    },
    "log_retention": {
      "type": "boolean",
      "description": "Supported for CONTAINER workflows; forced off for HEARTBEAT"
    }
  }
}

Responses

201

Workflow created

application/json
{
  "type": "object",
  "required": [
    "id"
  ],
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    }
  }
}
400

Invalid input or missing required idempotency key

401

Missing or invalid session

409

Idempotency key was already used with a different logical request

413

Request body exceeds the 4 MiB ingress limit

429

Ingress rate or connection limit exceeded for the client address