Documentation Navigation
Getting Started
API Reference
Resources
Models API
List available models with pricing, capabilities, and quality rankings. Auto-select the best model for your budget.
GET /v1/models
List all available models with pricing and capabilities. Public endpoint -- no authentication required.
Query parameters
| Parameter | Type | Description |
|---|---|---|
modality | string | Filter: "image", "video", "voice", "music", "threeD", "talkingHead". |
type | string | Filter: "t2i", "i2i", "edit", "t2v", "i2v", "tts", etc. |
tier | string | Filter: "budget", "standard", "premium". |
provider | string | Filter by provider (e.g. "openai", "runway", "suno"). |
Model object fields
| Field | Type | Description |
|---|---|---|
key | string | Unique model identifier. Use this in generation requests. |
name | string | Human-readable model name. |
provider | string | Model provider (e.g. "openai", "suno"). |
modality | string | Generation type. |
type | string | Specific generation type (e.g. "t2i" = text-to-image). |
price | object | Cost per generation. Contains micro, display, unit. |
capabilities | object | Model-specific capabilities (max dimensions, supported features). |
quality_rank | integer | Quality ranking within its modality (1 = best). |
tier | string | "budget", "standard", or "premium". |
status | string | "active", "beta", or "deprecated". |
Code examples
curl (all models)
curl https://api.fairstack.ai/v1/models curl (filtered)
curl "https://api.fairstack.ai/v1/models?modality=image&type=t2i" Python
from fairstack import FairStack
client = FairStack(api_key="fs_live_YOUR_KEY")
# List all models
models = client.models.list()
for m in models:
print(f"{m.key}: {m.name} — {m.price.display}")
# Filter by modality
image_models = client.models.list(modality="image")
print(f"{len(image_models)} image models available")
# Get a specific model
model = client.models.get("gpt-image-1.5-t2i")
print(model.name) # "GPT Image 1.5"
print(model.price.display) # "$0.009" Node.js
import { FairStack } from "fairstack";
const client = new FairStack({ apiKey: "fs_live_YOUR_KEY" });
// List all models
const models = await client.models.list();
for (const m of models) {
console.log(`${m.key}: ${m.name} — ${m.price.display}`);
}
// Filter by modality
const imageModels = await client.models.list({ modality: "image" });
console.log(`${imageModels.length} image models available`);
// Get a specific model
const model = await client.models.get("gpt-image-1.5-t2i");
console.log(model.name); // "GPT Image 1.5"
console.log(model.price.display); // "$0.009" Response
{
"models": [
{
"key": "gpt-image-1.5-t2i",
"name": "GPT Image 1.5",
"provider": "openai",
"modality": "image",
"type": "t2i",
"price": {
"micro": 9000,
"display": "$0.009",
"unit": "per image"
},
"capabilities": {
"max_width": 2048,
"max_height": 2048,
"aspect_ratios": ["1:1", "16:9", "9:16", "4:3", "3:4"],
"supports_negative_prompt": true,
"supports_seed": true
},
"quality_rank": 1,
"tier": "premium",
"status": "active"
},
{
"key": "z-image-turbo",
"name": "Z-Image Turbo",
"provider": "zhipu",
"modality": "image",
"type": "t2i",
"price": {
"micro": 4000,
"display": "$0.004",
"unit": "per image"
},
"capabilities": {
"max_width": 1024,
"max_height": 1024,
"aspect_ratios": ["1:1", "16:9", "9:16"],
"supports_negative_prompt": false,
"supports_seed": true
},
"quality_rank": 12,
"tier": "budget",
"status": "active"
}
],
"total": 72
} GET /v1/models/:key
Get details for a specific model by its key.
curl https://api.fairstack.ai/v1/models/gpt-image-1.5-t2i Returns the full model object as shown above.
GET /v1/select-model
Auto-select the best model for a given modality and budget tier. Useful for AI agents that need to choose models programmatically.
Query parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
modality | string | Yes | Desired modality: "image", "video", "voice", "music". |
tier | string | No | Budget tier: "budget", "standard", "premium". Default: "standard". |
type | string | No | Specific type (e.g. "i2v" for image-to-video). |
max_price_micro | integer | No | Maximum price in microdollars. |
curl "https://api.fairstack.ai/v1/select-model?modality=image&tier=standard" Response
{
"model": {
"key": "flux-1-1-pro-ultra",
"name": "FLUX.1.1 Pro Ultra",
"modality": "image",
"price": { "micro": 25000, "display": "$0.025" },
"tier": "standard",
"quality_rank": 3
},
"reason": "Best quality-to-price ratio for standard-tier image generation"
} Model counts by modality
| Modality | Models | Price range |
|---|---|---|
| Image | 26 | $0.003 - $0.06 |
| Video | 18 | $0.04 - $0.50 |
| Voice | 10 | $0.001 - $0.01 |
| Music | 8 | $0.018 - $0.15 |
| Talking Head | 10 | $0.08 - $0.40 |
Next steps
- Model Catalog -- browse all models with examples
- Image API -- generate images
- Video API -- generate videos
- Quickstart -- make your first API call