API Reference
The CODITECT API provides programmatic access to all platform features, enabling integration with your existing tools and workflows.
Base URL
https://api.coditect.ai/v1
All API requests must use HTTPS. HTTP requests will be rejected.
API Versions
| Version | Status | Notes |
|---|---|---|
v1 | Current | Stable, production-ready |
Authentication
All API requests require authentication using a Bearer token.
curl -H "Authorization: Bearer YOUR_API_TOKEN" \
https://api.coditect.ai/v1/me
See Authentication for details on obtaining tokens.
Response Format
All responses are JSON with consistent structure:
Successful Response
{
"data": {
// Response payload
},
"meta": {
"request_id": "req_abc123",
"timestamp": "2026-01-09T10:30:00Z"
}
}
Error Response
{
"error": {
"code": "invalid_request",
"message": "The request body is missing required field 'name'",
"details": {
"field": "name",
"reason": "required"
}
},
"meta": {
"request_id": "req_xyz789",
"timestamp": "2026-01-09T10:30:00Z"
}
}
HTTP Status Codes
| Code | Meaning |
|---|---|
200 | Success |
201 | Created (POST requests) |
204 | No Content (DELETE requests) |
400 | Bad Request - Invalid parameters |
401 | Unauthorized - Invalid or missing token |
403 | Forbidden - Insufficient permissions |
404 | Not Found - Resource doesn't exist |
409 | Conflict - Resource already exists |
422 | Unprocessable Entity - Validation failed |
429 | Too Many Requests - Rate limit exceeded |
500 | Internal Server Error |
Pagination
List endpoints support cursor-based pagination:
# First page
GET /v1/projects?limit=20
# Response includes cursor
{
"data": [...],
"pagination": {
"has_more": true,
"next_cursor": "eyJpZCI6MTIzfQ=="
}
}
# Next page
GET /v1/projects?limit=20&cursor=eyJpZCI6MTIzfQ==
Pagination Parameters
| Parameter | Type | Default | Max | Description |
|---|---|---|---|---|
limit | integer | 20 | 100 | Items per page |
cursor | string | - | - | Cursor from previous response |
Filtering
Many endpoints support filtering via query parameters:
# Filter projects by status
GET /v1/projects?status=active
# Multiple filters
GET /v1/projects?status=active&created_after=2026-01-01
Sorting
Use sort parameter to order results:
# Sort by creation date (newest first)
GET /v1/projects?sort=-created_at
# Sort by name (ascending)
GET /v1/projects?sort=name
Prefix with - for descending order.
API Endpoints
Core Resources
| Endpoint | Description |
|---|---|
| Authentication | OAuth2, tokens, sessions |
| Licenses | License management |
| Commerce | Subscriptions, billing |
| Webhooks | Event notifications |
Quick Reference
# Authentication
POST /v1/auth/login
POST /v1/auth/register
POST /v1/auth/refresh
POST /v1/auth/logout
GET /v1/auth/me
# Organizations
GET /v1/orgs
POST /v1/orgs
GET /v1/orgs/{id}
PATCH /v1/orgs/{id}
DELETE /v1/orgs/{id}
# Licenses
GET /v1/licenses
POST /v1/licenses/acquire
POST /v1/licenses/heartbeat
POST /v1/licenses/release
GET /v1/licenses/{id}
# Subscriptions
GET /v1/subscriptions
POST /v1/subscriptions
GET /v1/subscriptions/{id}
POST /v1/subscriptions/{id}/cancel
# Webhooks
GET /v1/webhooks
POST /v1/webhooks
GET /v1/webhooks/{id}
DELETE /v1/webhooks/{id}
SDKs and Libraries
Official SDKs are available for popular languages:
| Language | Package | Install |
|---|---|---|
| Python | coditect | pip install coditect |
| JavaScript | @coditect/sdk | npm install @coditect/sdk |
| Go | coditect-go | go get github.com/coditect-ai/coditect-go |
Testing
Use our sandbox environment for testing:
https://api.sandbox.coditect.ai/v1
Sandbox features:
- Isolated from production data
- Test credit card numbers accepted
- Webhooks sent to your test endpoints
- Rate limits are more lenient
Support
- API Status: status.coditect.ai
- Changelog: changelog.coditect.ai
- Support: 1@az1.ai