Documentation Index
Fetch the complete documentation index at: https://docs.chamelio.ai/llms.txt
Use this file to discover all available pages before exploring further.
Endpoint
POST /tasks/{task_id}/initiate_sign
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
Path Parameters
| Parameter | Type | Required | Description |
|---|
task_id | integer | Yes | Unique identifier for the task |
Request Body
The request body must be a JSON object with the following fields:
Required Fields
| Field | Type | Description |
|---|
signers | array | List of signer email addresses (must have at least one signer) |
Optional Fields
| Field | Type | Description |
|---|
message | string | Optional message to include for signers |
variables | array | Additional variable values collected before signing |
user_email | string | Email of the user initiating signature (defaults to API key owner) |
step_run_id | string | Specific step run ID for the signature step |
Request Example
curl -X POST "https://platform.chamelio.ai/tasks/12345/initiate_sign" \
-H "X-API-Key: ca_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"signers": [
"john.doe@example.com",
"jane.smith@vendor.com"
],
"message": "Please review and sign the vendor contract. All terms have been approved.",
"variables": [
{
"variable_id": "signing_deadline",
"type": "date",
"value": "2025-02-15"
}
],
"user_email": "legal@example.com"
}'
Response
Success Response
Status Code: 200 OK
{
"task_id": 12345,
"sign_url": "https://platform.chamelio.ai/sign/abc123xyz",
"message": "Signature process initiated successfully"
}
Response Fields
| Field | Type | Description |
|---|
task_id | integer | ID of the task |
sign_url | string | Signing URL for the user (may be null in some configurations) |
message | string | Success confirmation message |
Error Responses
401 Unauthorized
Returned when authentication fails. See the authentication errors section for details.
{
"detail": "Invalid API key"
}
404 Not Found
Returned when the task doesn’t exist or you don’t have access to it.
{
"detail": "Task not found"
}
409 Conflict
Returned when the task is not at a signature step or signature has already been initiated.
{
"detail": "Task is not at a signature step"
}
422 Validation Error
Returned when the request body is invalid (e.g., no signers provided or invalid email format).
{
"detail": [
{
"loc": ["body", "signers"],
"msg": "ensure this value has at least 1 item",
"type": "value_error.list.min_items"
}
]
}
500 Internal Server Error
Returned when signature initiation fails due to a server error.
{
"detail": "Failed to initiate signature"
}
Notes
After initiating the signature process, signers will receive email notifications with links to review and sign the document.
Ensure the task has a document ready for signing before calling this endpoint. The document is typically generated in a previous workflow step.
Use the message field to provide context and instructions to signers about what they’re signing and any important considerations.
Use Cases
This endpoint is useful for:
- Contract execution - Trigger signature collection after contract review and approval
- Custom signing workflows - Integrate Chamelio’s signature capability with external systems
- Automated document routing - Route documents to appropriate signers based on business logic
- Multi-party agreements - Collect signatures from multiple parties in a structured workflow