Chapter 14 of 211 min

14. Multiple Models and Protocols#

YiTuoToken exposes a single OpenAI-compatible format to callers. Whether the underlying model is GPT, Claude, Gemini, or DeepSeek, everything is called through the same /v1/chat/completions endpoint — you only switch the model field:

JSON
{ "model": "gpt-4o", "messages": [] }
{ "model": "claude-3-5-sonnet-20241022", "messages": [] }
{ "model": "gemini-2.0-flash", "messages": [] }
{ "model": "deepseek-chat", "messages": [] }

The platform routes to the corresponding upstream vendor based on model and performs the protocol conversion, so you never need to switch endpoints or rewrite request bodies for different vendors.

  • When calling Claude, Gemini, and other models, we still recommend the OpenAI request-body format (/v1/chat/completions), switching only model.
  • If your application is deeply tied to the native Anthropic protocol, you can use /v1/messages instead (see Section 12), but that endpoint does not support function calling or multimodal content.
  • The exact supported model names are whatever GET /v1/models returns.