Managing Actions
List Actions
Get all your action definitions.
Endpoint
/actions/v1curl -X GET https://api.case.dev/actions/v1 \
-H "Authorization: Bearer sk_case_your_api_key_here" \
-H "Content-Type: application/json"Example Request
Example Response
Get Action
Get a specific action definition.
Endpoint
/actions/v1/action_abc123curl -X GET https://api.case.dev/actions/v1/action_abc123 \
-H "Authorization: Bearer sk_case_your_api_key_here" \
-H "Content-Type: application/json"Execute Action
Execute a saved action with your input data.
Endpoint
/actions/v1/action_abc123/executecurl -X POST https://api.case.dev/actions/v1/action_abc123/execute \
-H "Authorization: Bearer sk_case_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"input": {
"transcript": "Full deposition transcript text...",
"case_id": "case_2024_001"
},
"webhook_id": "webhook_xyz"
}'Request Fields
input(required): Input data for the actionwebhook_id(optional): Override default webhook for this execution
Supplying inputs
All action executions accept a single input object. Every key in that object is available to your steps via {{input.<key>}}. If you need file locations, pass URLs or S3 keys (e.g., contract_url, audio_url) and read them inside the relevant steps. When writing results, combine those same inputs with helper variables such as {{timestamp}} to build vault paths like {{input.case_id}}/summaries/{{timestamp}}.json.
Synchronous Execution
If no webhook is configured, the action executes synchronously and returns results immediately:
Response (immediate):
Asynchronous Execution with Webhooks
If a webhook is configured, the action executes asynchronously and sends results to your webhook:
Response (immediate):
Webhook payload (sent when complete):
Get Execution Status
Check the status and results of an action execution.
Endpoint
/actions/v1/executions/exec_xyz789curl -X GET https://api.case.dev/actions/v1/executions/exec_xyz789 \
-H "Authorization: Bearer sk_case_your_api_key_here" \
-H "Content-Type: application/json"Example Response
Status values: pending, running, completed, failed
Delete Action
Delete an action definition.
Endpoint
/actions/v1/action_abc123curl -X DELETE https://api.case.dev/actions/v1/action_abc123 \
-H "Authorization: Bearer sk_case_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{}'Related
- Webhooks - Configure webhook notifications for async execution
- Error Handling - Understand how actions handle errors