1. API

Endpoint

POST
https://api.comchat.ai/prompt

Set Header

Header
{
  "Content-Type": "application/json",
  "apiKey": <your-comchat-api-key>
}

You can get your comchat api key at https://app.comchat.ai

Json Body

Payload
{
    "service": <service-name>,
    "model": <model-name>,
    "prompt": <prompt-message>
}

Example

Example
{
    "service": "openai",
    "model": "gpt-4-turbo",
    "prompt": "What model do you use?"
}

Tested models

Comchat subnet provides all kind of models supported by OpenAI, Anthropic, OpenRouter, MistralAI, Perplexity, TogetherAI, Gemini and Groq.

Service Model
openai gpt-3.5-turbo
gpt-3.5-turbo-0125
gpt-3.5-turbo-0301
gpt-3.5-turbo-0613
gpt-3.5-turbo-1106
gpt-3.5-turbo-16k
gpt-3.5-turbo-16k-0613
gpt-3.5-turbo-instruct
gpt-3.5-turbo-instruct-0914
gpt-4
gpt-4-0613
gpt-4-1106-vision-preview
gpt-4-turbo
gpt-4-turbo
gpt-4-turbo-2024-04-09
gpt-4-turbo-preview
gpt-4-0125-preview
gpt-4-1106-preview
gpt-4-vision-preview
gpt-4o
gpt-4o-2024-05-13
anthropic claude-3-opus-20240229
claude-3-sonnet-20240229
claude-3-haiku-20240307
openrouter https://openrouter.ai/docs/models
groq llama3-8b-8192
llama3-70b-8192
mixtral-8x7b-32768
gemma-7b-it
gemini gemini-1.5-pro
gemini-1.5-flash
gemini-1.0-pro
gemini-pro-vision
perplexity llama-3-sonar-small-32k-chat
llama-3-sonar-small-32k-online
llama-3-sonar-large-32k-chat
llama-3-sonar-large-32k-online
llama-3-8b-instruct
llama-3-70b-instruct
mixtral-8x7b-instruct
mistralai mistral-tiny-2312
mistral-small-2312
open-mixtral-8x22b-2404
mistral-small-2402
mistral-medium-2312
mistral-large-2402
codestral-2405
togetherai https://docs.together.ai/docs/inference-models

You can find the model names directly by visiting above services but 8 service names are fixed.