Models
List models available through the TokenFlux API
Use the web app's Models & pricing page to browse models and prices. Applications can retrieve the API model list with:
GET /v1/models
Authorization: Bearer YOUR_TOKENFLUX_KEYcurl https://tokenflux.ai/v1/models \
-H "Authorization: Bearer YOUR_TOKENFLUX_KEY"Use the returned model ID as the model value in inference requests. The list depends on the key's access, so call it with the key you use. When you are signed in, Models & pricing also shows models that only your account can use. Availability and pricing can change, so avoid hard-coding a catalog from this documentation.
Response
The response follows the OpenAI model-list shape. object is list, and data contains model objects. Each model's id is the value to send in an inference request. object, created and owned_by are compatibility metadata, not a price or capability contract. For example:
{
"object": "list",
"data": [
{
"id": "YOUR_MODEL_ID",
"object": "model",
"created": 1626777600,
"owned_by": "MODEL_OWNER"
}
]
}OpenAI SDK
import OpenAI from "openai";
const client = new OpenAI({
apiKey: process.env.TOKENFLUX_API_KEY,
baseURL: "https://tokenflux.ai/v1",
});
const models = await client.models.list();
for (const model of models.data) {
console.log(model.id);
}Choose a model
Use Models & pricing to inspect prices and supported protocols. The API list identifies available models. Read prices and capabilities on the web page, rather than deriving them from a model ID. /models is a web page; API clients must use /v1/models.
List models again if a stored model ID becomes unavailable. Test the selected model with the endpoint you plan to use, such as Chat Completions or Embeddings.