API documentation for the interfaces Timill Platform offers to your own integrations.
Authentication#
JWT Authentication#
Include JWT token in Authorization header:
Authorization: Bearer <token>
Base URLs#
| Environment | URL |
|---|---|
| Development | http://localhost:8080 |
| Production | https://your-domain.com |
Common Headers#
| Header | Description |
|---|---|
Content-Type | application/json |
Authorization | JWT bearer token |
X-Group-ID | Group context (optional) |
Response Format#
Success Response#
{
"success": true,
"data": { ... },
"meta": {
"page": 1,
"per_page": 20,
"total": 100
}
}
Error Response#
{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "Invalid input",
"details": [ ... ]
}
}
Rate Limiting#
| Endpoint | Limit |
|---|---|
| Authentication | 10/minute |
| General API | 100/minute |
| SSE Connections | 10/user |
Pagination#
Use query parameters:
GET /api/items?page=1&per_page=20
Filtering#
Use query syntax:
GET /api/items?query=type:task status:open
Versioning#
API version is included in URL:
/v1/items
/v1/groups
SDKs#
JavaScript SDK#
import { TimillClient } from '@timill/sdk';
const client = new TimillClient({
baseUrl: 'https://your-domain.com',
apiKey: process.env.TIMILL_API_KEY
});
Go SDK#
import "github.com/timill/go-sdk"
client := timill.NewClient(timill.Config{
BaseURL: "https://your-domain.com",
APIKey: "your-api-key",
})