Guide

How to call any catalog model through the API

Use the OpenAI-compatible AshnaAI API to call any catalog model: get a key, list ids from GET /v1/api/models, then POST /v1/api/chat/completions with that id in the model field. The same route works for GLM-5.3-Flash, GPT-5.6 Terra, Claude rows, Kimi K3, or a custom agent id.

AshnaAI

How to call any catalog model through the API

Key Takeaways

  • One route covers every catalog model: set model to the catalog id from GET /v1/api/models or the in-app picker.
  • The API is OpenAI-compatible. Point an OpenAI or Vercel AI SDK at https://api.ashna.ai/v1/api and send a Bearer key.
  • Custom agents use the same chat-completions path: pass the agent’s customAgentId as model, or agent_id when model is omitted.

One API, any catalog id

Developers calling models through AshnaAI use an OpenAI-compatible HTTP API. Base URL: https://api.ashna.ai/v1/api Auth is Authorization: Bearer YOUR_API_KEY. The model field is either a foundation catalog id or a custom agent id. That is how GLM-5.3-Flash, GPT-5.6 Terra, a Claude row, Kimi K3, or Ashna-X1 are called from code—one route, not a URL per vendor.

Official reference: AshnaAI API docs, including model and agent ids. If you do not have a key, create one in Account → API.

Step 1: Get a key

Open Account → API and choose Create key. Send it as a Bearer token. Do not put the key in a public blog, client bundle, or screenshot.

Step 2: List models, then pick an id

GET https://api.ashna.ai/v1/api/models returns the OpenAI list shape. Copy the id string exactly as listed—for Flash that is glm-5.3-flash. The same id is visible in the in-app model picker. Custom agents use the agent id on the same chat-completions path. Endpoint notes: list models.

Step 3: POST chat completions

POST https://api.ashna.ai/v1/api/chat/completions with model, messages, and optional stream, temperature, or max_tokens. To switch from Flash to GPT-5.6 Terra, change model to gpt-5.6-terra. To run a saved agent, pass that agent’s customAgentId as model. Endpoint notes: chat completions.

To try Flash in the product UI instead of curl, open GLM-5.3-Flash in chat. For when to pin Flash versus other rows, start at Pin GLM-5.3-Flash for cost-effective coding.

Try the API now

Create a key in Account → API, then open AshnaAI API docs and run the chat-completions examples with the model id you listed. To use the same key from the editor, follow How to use the AshnaAI API in VS Code.

Sourcing & Methodology

Mapped to the public AshnaAI HTTP API: base URL https://api.ashna.ai/v1/api, GET /models, POST /chat/completions, model or agent_id, and Account → API keys.

Topics

#API#models#developers#GLM-5.3-Flash

Found this article insightful?

Share it with fellow builders, founders, and AI practitioners.

Frequently asked questions

Everything You Need to Know

Create a Bearer key, then POST https://api.ashna.ai/v1/api/chat/completions with model set to glm-5.3-flash and a messages array. To try it in the product first, open the pinned chat link.

Yes. List ids with GET /v1/api/models, then POST /v1/api/chat/completions. Only the model field changes. Custom agents use the same POST path with the agent id.

Yes. Use the same clients and auth style. Set base URL to https://api.ashna.ai/v1/api Full reference is on the AshnaAI API docs.

GET /v1/api/models returns foundation models. A custom agent uses the same chat-completions path: pass the agent’s customAgentId as model, or send agent_id when model is omitted.

Continue ReadingView all

Related Articles & Guides