API Reference
Complete API reference for all Banan0 endpoints.
API Reference
Base URL: https://banan0.com/api/v1
Endpoints Overview
| Method | Endpoint | Description |
|---|---|---|
| GET | /models | List available models |
| GET | /models/:modelId | Get model details |
| POST | /models/:modelId/run | Start a model run |
| GET | /runs/:runId | Get run status |
| POST | /runs/:runId/cancel | Cancel a run |
| GET | /webhooks | List webhooks |
| POST | /webhooks | Create webhook |
| DELETE | /webhooks/:id | Delete webhook |
| GET | /account/balance | Get token balance |
Response Format
All responses follow this format:
json
{
"data": { ... },
"meta": {
"request_id": "req_xxx"
}
}Error Format
json
{
"error": "Error message",
"code": "ERROR_CODE",
"details": { ... }
}Common HTTP Status Codes
| Code | Description |
|---|---|
| 200 | Success |
| 201 | Created |
| 400 | Bad request |
| 401 | Unauthorized |
| 402 | Payment required (insufficient tokens) |
| 403 | Forbidden (missing scope) |
| 404 | Not found |
| 429 | Rate limited |
| 500 | Server error |