Model Management
Model configuration management.
Endpoints
GET https://ai-tokenhub.com/v1/admin/models
POST https://ai-tokenhub.com/v1/admin/models
PUT https://ai-tokenhub.com/v1/admin/models/{id}
DELETE https://ai-tokenhub.com/v1/admin/models/{id}Model Object
json
{
"id": "gpt-4o",
"name": "GPT-4o",
"provider": "openai",
"context_length": 128000,
"input_price": 0.005,
"output_price": 0.015,
"capabilities": ["chat", "function_calling", "vision"],
"status": "active"
}Create Model
bash
curl -X POST https://ai-tokenhub.com/v1/admin/models \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"id": "custom-model",
"name": "Custom Model",
"provider": "custom",
"context_length": 4096
}'Fields
| Field | Type | Description |
|---|---|---|
| id | string | Model ID |
| name | string | Display name |
| provider | string | Provider |
| context_length | integer | Context window size |
| input_price | number | Input price |
| output_price | number | Output price |
| capabilities | array | Supported capabilities |
| status | string | Status |