Endpoint
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
| Parameter | Type | Required | Description |
|---|
active_only | boolean | No | Only 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
| Field | Type | Description |
|---|
workflows | array | List of available workflow schemas |
total | integer | Total number of workflows returned |
Workflow Schema Fields
| Field | Type | Description |
|---|
workflow_id | string | Unique identifier for the workflow |
workflow_name | string | Human-readable workflow name |
version | integer | Workflow version number |
description | string | Description of what the workflow does |
is_active | boolean | Whether the workflow is currently active |
variables | array | List 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