API Overview
The PrompTick API provides programmatic access to execute your deployed agents from any application.
Base URL
https://api.promptick.ai/api/v1
Authentication
All API requests require an API key in the Authorization header:
Authorization: Bearer pk_live_YOUR_API_KEY
Learn more about authentication →
OpenAPI Specification
The machine-readable OpenAPI 3.0 spec for the public API is available at:
https://api.promptick.ai/openapi.yaml
You can import this into Postman, Insomnia, or any OpenAPI-compatible tool.
Quick Example
Execute an agent:
curl -X POST https://api.promptick.ai/api/v1/agents/{agentId}/execute \
-H "Authorization: Bearer pk_live_YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"variables": {"product_name": "Smart Watch"}}'
Response (202 Accepted):
{
"success": true,
"executionId": "550e8400-e29b-41d4-a716-446655440000",
"agentId": "agent_123",
"agentName": "Product Description Generator",
"status": "processing",
"message": "Agent execution started",
"statusUrl": "/api/v1/agents/agent_123/executions/550e8400-e29b-41d4-a716-446655440000"
}
API Endpoints
| Endpoint | Method | Description |
|---|---|---|
/agents/{agentId}/execute | POST | Execute an agent |
/agents/{agentId}/executions/{executionId} | GET | Get execution status |
The public v1 API does not provide a list-executions endpoint. Use the PrompTick dashboard to browse execution history.
Response Format
All responses are JSON.
Success (202 Accepted) — agent execution accepted and started:
{
"success": true,
"executionId": "string",
"agentId": "string",
"agentName": "string",
"status": "processing",
"message": "string",
"statusUrl": "string"
}
Error (4xx/5xx):
{
"error": "string",
"message": "string"
}
Error Codes
| Code | Status | Description |
|---|---|---|
| 400 | Bad Request | Invalid request body or missing required fields |
| 401 | Unauthorized | Invalid or missing API key |
| 403 | Forbidden | Agent not active or API access disabled |
| 404 | Not Found | Agent does not exist |
| 429 | Too Many Requests | Rate limit exceeded |
| 500 | Internal Server Error | Server error |
| 503 | Service Unavailable | Background job system unavailable |
Rate Limiting
Each API key has three configurable counters with these defaults:
| Window | Default | Max configurable |
|---|---|---|
| Per minute | 10 | 100 |
| Per hour | 100 | 1,000 |
| Per day | 1,000 | 10,000 |
When a limit is exceeded, the API returns 429 Too Many Requests with the current rateLimits object in the body.
Learn more about rate limits →
Best Practices
- Handle Errors Gracefully - Implement retry logic with exponential backoff
- Use HTTPS - All requests must use HTTPS
- Secure API Keys - Store in environment variables
- Implement Timeouts - Set reasonable request timeouts
- Poll Status, Don't Block - Execution is asynchronous; poll the status URL
SDKs & Libraries
Official SDKs coming soon. For now, use any standard HTTP client:
- Node.js:
axios,fetch - Python:
requests,httpx - PHP:
guzzle,curl - Ruby:
faraday,httparty - Go:
net/http
Need Help?
- Authentication - API key setup
- Code Examples - Working samples
- Troubleshooting - Common issues
- Support - Get help
Ready to integrate? View authentication guide →