Skip to main content

Endpoint

GET /workflows

Authentication

This endpoint requires authentication via API key. Include your API key in the X-API-Key header:
X-API-Key: ca_your_api_key_here

Query Parameters

ParameterTypeRequiredDescription
active_onlybooleanNoOnly return active workflows. Defaults to false

Request Example

curl -X GET "https://platform.chamelio.ai/workflows?active_only=true" \
  -H "X-API-Key: ca_your_api_key_here"
import requests

url = "https://platform.chamelio.ai/workflows"
headers = {
    "X-API-Key": "ca_your_api_key_here"
}
params = {
    "active_only": True
}

response = requests.get(url, headers=headers, params=params)
print(response.json())
const response = await fetch('https://platform.chamelio.ai/workflows?active_only=true', {
  method: 'GET',
  headers: {
    'X-API-Key': 'ca_your_api_key_here'
  }
});

const data = await response.json();
console.log(data);

Response

Success Response

Status Code: 200 OK
{
  "workflows": [
    {
      "workflow_id": "vendor_contract_review",
      "workflow_name": "Vendor Contract Review",
      "version": 1,
      "description": "Review and approve vendor contracts",
      "is_active": true,
      "variables": [
        {
          "variable_id": "contract_file",
          "variable_name": "Contract Document",
          "type": "file",
          "required": true,
          "description": "The vendor contract to review"
        },
        {
          "variable_id": "vendor_name",
          "variable_name": "Vendor Name",
          "type": "text",
          "required": true,
          "description": "Name of the vendor"
        }
      ]
    }
  ],
  "total": 1
}

Response Fields

FieldTypeDescription
workflowsarrayList of available workflow schemas
totalintegerTotal number of workflows returned

Workflow Schema Fields

FieldTypeDescription
workflow_idstringUnique identifier for the workflow
workflow_namestringHuman-readable workflow name
versionintegerWorkflow version number
descriptionstringDescription of what the workflow does
is_activebooleanWhether the workflow is currently active
variablesarrayList of input variables for the workflow

Error Responses

401 Unauthorized

Returned when authentication fails. See the authentication errors section for details.
{
  "detail": "Invalid API key"
}

500 Internal Server Error

Returned when the request fails due to a server error.
{
  "detail": "Failed to list workflows"
}

Notes

Use the workflow_id and version from this response to get the full workflow schema or initiate a workflow instance.
Set active_only=true to filter out deprecated or inactive workflows and only see workflows you can currently use.

Use Cases

This endpoint is useful for:
  • Workflow discovery - Explore available workflows in your organization
  • Dynamic integrations - Build applications that adapt to available workflows
  • Workflow management - Monitor which workflows are active
  • User interfaces - Populate workflow selection dropdowns