Skip to main content
POST
/
hub
/
workflows
/
{collection_topic}
/
{flow_topic}
/
run
curl --request POST \
  --url https://api.quiva.ai/hub/workflows/{collection_topic}/{flow_topic}/run \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "trigger": {
    "user_id": "user_123",
    "action": "process_order",
    "data": {
      "order_id": "ORD-456",
      "items": [
        {
          "sku": "PROD-001",
          "quantity": 2
        },
        {
          "sku": "PROD-002",
          "quantity": 1
        }
      ],
      "total": 149.99
    }
  },
  "enable_log": true,
  "await": true
}
'
{
"trackingId": "ms.hub.run.abcdef-1234-5678-90ab-cdef12345678.ms.hub.config.workflow.1234567890.98765432",
"result": {
"status": "completed",
"order_id": "ORD-456",
"processed_at": "2024-01-15T10:30:00Z",
"confirmation_number": "CONF-789012"
}
}

Authorizations

Authorization
string
header
required

JWT Authorization header using the Bearer scheme

Path Parameters

collection_topic
string
required

The topic is a hash of the name that was used when a collection was created

flow_topic
string
required

Flow topic - hash of the names the node was created with

Query Parameters

draft
boolean

Draft flag

Body

application/json
trigger
object

Trigger data for workflow execution (use either trigger or triggers)

triggers
object[]

Multiple trigger data sets for parallel workflow execution

enable_log
boolean
default:false

Whether to enable logging of workflow execution

await
boolean
default:false

Whether to wait for workflow completion

Response

Workflow executed successfully

trackingId
string

ID for tracking the workflow execution

result
object

Result of the workflow execution