Список моделей

Получить список доступных моделей и цены на них

Чтобы отправлять авторизованные запросы нужно получить API ключ, как это сделать написано в разделе С чего начать?

Запрос списка моделей

GET https://gptunnel.ru/v1/models

Возвращает список всех доступных LLM моделей

Headers

NameTypeDescription

Authorization*

string

API ключ

{
	"object": "list",
	"data": [
		{
			"id": "gpt-4o",
			"object": "model",
			"created": 1685584800,
			"title": "GPT 4o Vision 128K",
			"max_capacity": 4096,
			"cost_context": "1.3500",
			"cost_completion": "2.7000"
		},
		{
			"id": "gpt-4o-mini",
			"object": "model",
			"created": 1685584800,
			"title": "GPT 4o Mini",
			"max_capacity": 4096,
			"cost_context": "0.1200",
			"cost_completion": "0.4800"
		},
		{
			"id": "text-embedding-ada-002",
			"object": "model",
			"created": 1690848600,
			"title": "Embedding ada V2",
			"max_capacity": 8191,
			"cost_context": "0.0500",
			"cost_completion": "0.0000"
		},
		{
			"id": "text-embedding-3-small",
			"object": "model",
			"created": 1714435800,
			"title": "Embedding ada V3 Small",
			"max_capacity": 8191,
			"cost_context": "0.0200",
			"cost_completion": "0.0000"
		},
		{
			"id": "text-embedding-3-large",
			"object": "model",
			"created": 1714435800,
			"title": "Embedding ada V3 Large",
			"max_capacity": 8191,
			"cost_context": "0.0700",
			"cost_completion": "0.0000"
		},
		{
			"id": "text-moderation-007",
			"object": "model",
			"created": 1690848600,
			"title": "Text moderation model",
			"max_capacity": 8191,
			"cost_context": "0.0100",
			"cost_completion": "0.0000"
		},
		{
			"id": "gpt-4-turbo",
			"object": "model",
			"created": 1685581200,
			"title": "GPT 4",
			"max_capacity": 4096,
			"cost_context": "2.7000",
			"cost_completion": "5.4000"
		},
		{
			"id": "gpt-4",
			"object": "model",
			"created": 1690848600,
			"title": "GPT 4",
			"max_capacity": 4096,
			"cost_context": "2.7000",
			"cost_completion": "5.4000"
		},
		{
			"id": "gpt-3.5-turbo",
			"object": "model",
			"created": 1685584800,
			"title": "GPT 3.5 Turbo",
			"max_capacity": 4096,
			"cost_context": "0.5000",
			"cost_completion": "0.9000"
		}
	]
}

Пример запроса

import axios from 'axios'

const request = axios({
  method: 'GET',
  url: 'https://gptunnel.ru/v1/models',
  headers: {
    // use your API key here
    Authorization: 'YOUR_API_KEY',
  },
})

request.then((result) => {
  console.log(result)
}).catch((error) => {
  console.error(error)
})

Пример ответа

{
	"object": "list",
	"data": [
		{
			"id": "gpt-4o",
			"object": "model",
			"created": 1685584800,
			"title": "GPT 4o Vision 128K",
			"max_capacity": 4096,
			"cost_context": "1.3500",
			"cost_completion": "2.7000"
		},
		{
			"id": "gpt-4o-mini",
			"object": "model",
			"created": 1685584800,
			"title": "GPT 4o Mini",
			"max_capacity": 4096,
			"cost_context": "0.1200",
			"cost_completion": "0.4800"
		},
		{
			"id": "text-embedding-ada-002",
			"object": "model",
			"created": 1690848600,
			"title": "Embedding ada V2",
			"max_capacity": 8191,
			"cost_context": "0.0500",
			"cost_completion": "0.0000"
		},
		{
			"id": "text-embedding-3-small",
			"object": "model",
			"created": 1714435800,
			"title": "Embedding ada V3 Small",
			"max_capacity": 8191,
			"cost_context": "0.0200",
			"cost_completion": "0.0000"
		},
		{
			"id": "text-embedding-3-large",
			"object": "model",
			"created": 1714435800,
			"title": "Embedding ada V3 Large",
			"max_capacity": 8191,
			"cost_context": "0.0700",
			"cost_completion": "0.0000"
		},
		{
			"id": "text-moderation-007",
			"object": "model",
			"created": 1690848600,
			"title": "Text moderation model",
			"max_capacity": 8191,
			"cost_context": "0.0100",
			"cost_completion": "0.0000"
		},
		{
			"id": "gpt-4-turbo",
			"object": "model",
			"created": 1685581200,
			"title": "GPT 4",
			"max_capacity": 4096,
			"cost_context": "2.7000",
			"cost_completion": "5.4000"
		},
		{
			"id": "gpt-4",
			"object": "model",
			"created": 1690848600,
			"title": "GPT 4",
			"max_capacity": 4096,
			"cost_context": "2.7000",
			"cost_completion": "5.4000"
		},
		{
			"id": "gpt-3.5-turbo",
			"object": "model",
			"created": 1685584800,
			"title": "GPT 3.5 Turbo",
			"max_capacity": 4096,
			"cost_context": "0.5000",
			"cost_completion": "0.9000"
		}
	]
}

Last updated