Models

JoyToken supports two model selection modes: model: "auto" for routing, or a concrete model_key from the model catalog.

ScenarioRequest
New integrationmodel: "auto"
Cost-firstmodel: "auto" + tier: "economy"
Balanced defaultmodel: "auto" + tier: "standard"
Quality-firstmodel: "auto" + tier: "premium"
Evaluated production workflowConcrete model_key

Auto Routing

1{
2 "model": "auto",
3 "tier": "standard",
4 "messages": [
5 { "role": "user", "content": "Write a short onboarding message." }
6 ]
7}

auto lets JoyToken choose a model within API key policy, tier, wallet balance, and model-pool availability.

Pinned Model

1{
2 "model": "GLM-5",
3 "messages": [
4 { "role": "user", "content": "Write a concise release note." }
5 ]
6}

Pinned models are best for evaluated production workflows. They still pass through API key policy, blacklist, tier, and wallet checks.

List Models

Set JOY_TOKEN_API_BASE_URL from Environments before calling the model catalog.

$curl "$JOY_TOKEN_API_BASE_URL/api/v1/models"

Common filter:

$curl "$JOY_TOKEN_API_BASE_URL/api/v1/models?tier=standard&feature_tag=code"

Model Fields

FieldMeaning
model_keyModel name used in requests
display_nameDisplay name
tierBilling and routing tier
providerModel provider
feature_tagsCapability tags
customer_input_mtokInput price in Cr / MTok
customer_output_mtokOutput price in Cr / MTok

Model Is Listed But Request Fails

The model catalog shows platform models. It does not mean every API key can call every model. Check:

CheckDescription
API key policytier, blacklist, fixed model
Source IPwhether the key policy allows it
Wallet and budgetbalance for the target tier
Request modelrun auto first, then switch to a concrete model