Skip to main content
POST
/
v1
/
public
/
workflows
Create or Update Workflow
curl --request POST \
  --url https://api.sanka.com/v1/public/workflows \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "external_id": "<string>",
  "title": "<string>",
  "description": "<string>",
  "status": "<string>",
  "trigger_type": "<string>",
  "trigger_every": 123,
  "is_trigger_active": true,
  "nodes": [
    {
      "id": "<string>",
      "action_uid": "<string>",
      "action_slug": "<string>",
      "action_id": "<string>",
      "is_base": true,
      "input_data": {},
      "predefined_input": {},
      "previous_output_data": {},
      "user_display_name": "<string>",
      "integration_slug": "<string>",
      "integration_id": "<string>",
      "cost_minutes": 123,
      "valid_to_run": true,
      "condition_groups": [
        {
          "id": "<string>",
          "operator": "and",
          "parent_group_id": "<string>",
          "conditions": [
            {
              "id": "<string>",
              "object_type": "<string>",
              "record_source": "<string>",
              "record_ids": "<string>",
              "field_name": "<string>",
              "operator": "<string>",
              "value_type": "<string>",
              "value_text": "<string>",
              "value_number": 123,
              "value_date": "<string>",
              "value_datetime": "<string>",
              "extra_condition": {}
            }
          ]
        }
      ]
    }
  ],
  "config": {},
  "type": "<string>"
}
'
{
  "ok": true,
  "status": "<string>",
  "external_id": "<string>",
  "workflow_id": "<string>",
  "valid_to_run": true,
  "node_count": 123,
  "ctx_id": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
external_id
string | null
title
string | null
description
string | null
status
string | null
trigger_type
string | null
trigger_every
integer | null
is_trigger_active
boolean | null
nodes
WorkflowNodeInput · object[]
config
Config · object
type
string | null

Response

OK

ok
boolean
required
status
string
required
external_id
string
required
workflow_id
string
required
valid_to_run
boolean
required
node_count
integer
required
ctx_id
string | null