Pipeline Command
Triggers & Webhooks

HTTP endpoints for automating workflows, agents, skills, and functions. Use these from any HTTP client.

Trigger Workflow

Start a new workflow run by workflow ID. The request body is passed as input data to the workflow.

POSThttps://octra.ai/v1/triggers/workflows/:id

Request Body

{
  "input_data": {
    "key": "value"
  }
}

Response

{
  "workflow_id": "...",
  "run_id": "...",
  "status": "running"
}

Trigger Agent

Send a chat message to an AI agent by agent ID. The agent generates a response using its configured model and prompt.

POSThttps://octra.ai/v1/triggers/agents/:id

Request Body

{
  "messages": [
    {
      "role": "user",
      "content": "Hello!"
    }
  ]
}

Response

{
  "id": "trg_agent_...",
  "object": "trigger.agent.response",
  "agent_id": "...",
  "output_text": "..."
}

Trigger Skill

Execute a skill by skill ID. The request body is passed as input to the skill.

POSThttps://octra.ai/v1/triggers/skills/:id

Request Body

{
  "input": {
    "param1": "value"
  }
}

Response

{
  "id": "trg_skill_...",
  "object": "trigger.skill.response",
  "status": "ok"
}

Trigger Function

Call a registered function by function ID. The input is passed directly to the function handler.

POSThttps://octra.ai/v1/triggers/functions/:id

Request Body

{
  "input": {
    "arg1": "value"
  }
}

Response

{
  "id": "trg_fn_...",
  "object": "trigger.function.response",
  "output": {
    "result": "..."
  }
}

Using Triggers

All trigger endpoints require authentication via the octra-api-token header. Replace :id with the actual workflow, agent, skill, or function ID.

Example using curl:

curl -X POST https://octra.ai/v1/triggers/workflows/YOUR_WORKFLOW_ID \
  -H "octra-api-token: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"input_data": {"message": "hello"}}'