OpenAI Direct
Прямое подключение к OpenAI API для моделей GPT, DALL-E, Whisper и других.
Модели чата
| Модель | Описание | Input | Output |
|---|---|---|---|
gpt-5.2 | Последняя GPT-5 | $1.75 | $14.00 |
gpt-5.2-pro | GPT-5 Pro версия | $3.00 | $24.00 |
gpt-5-mini | Быстрая GPT-5 | $0.50 | $4.00 |
gpt-4.1 | GPT-4.1 | $2.00 | $8.00 |
gpt-4.1-mini | GPT-4.1 Mini | $0.40 | $1.60 |
gpt-4o | GPT-4 Omni | $2.50 | $10.00 |
gpt-4o-mini | GPT-4o Mini | $0.15 | $0.60 |
Цены указаны в USD за 1M токенов
Reasoning модели
| Модель | Описание | Input | Output |
|---|---|---|---|
o1 | OpenAI o1 | $15.00 | $60.00 |
o1-mini | o1 Mini | $3.00 | $12.00 |
o3-mini | o3 Mini | $1.10 | $4.40 |
o4-mini | o4 Mini | $1.10 | $4.40 |
Базовый пример
curl https://api.aipomogator.ru/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $API_KEY" \
-d '{
"model": "gpt-4o",
"messages": [
{"role": "system", "content": "Ты полезный ассистент"},
{"role": "user", "content": "Привет!"}
]
}'
Генерация изображений (DALL-E)
| Модель | Описание | Цена за изображение |
|---|---|---|
dall-e-3 | DALL-E 3 (1024x1024) | $0.04 |
dall-e-2 | DALL-E 2 (1024x1024) | $0.02 |
Пример
curl https://api.aipomogator.ru/v1/images/generations \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $API_KEY" \
-d '{
"model": "dall-e-3",
"prompt": "Космический корабль на орбите Земли, фотореалистичный стиль",
"n": 1,
"size": "1024x1024"
}'
Ответ
{
"created": 1706745600,
"data": [
{
"url": "https://..."
}
]
}
Распознавание речи (Whisper)
| Модель | Описание | Цена |
|---|---|---|
whisper-1 | Whisper v1 | $0.006 / минута |
Пример
curl https://api.aipomogator.ru/v1/audio/transcriptions \
-H "Authorization: Bearer $API_KEY" \
-F file="@audio.mp3" \
-F model="whisper-1"
Ответ
{
"text": "Привет, это тестовая запись для распознавания речи."
}
Синтез речи (TTS)
| Модель | Описание | Цена |
|---|---|---|
tts-1 | TTS стандартный | $0.015 / 1K символов |
tts-1-hd | TTS высокое качество | $0.030 / 1K символов |
Пример
curl https://api.aipomogator.ru/v1/audio/speech \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "tts-1",
"input": "Привет! Это синтезированная речь.",
"voice": "alloy"
}' \
--output speech.mp3
Доступные голоса
| Голос | Описание |
|---|---|
alloy | Нейтральный |
echo | Мужской |
fable | Британский |
onyx | Глубокий мужской |
nova | Женский |
shimmer | Женский мягкий |
Embeddings
| Модель | Размерность | Цена |
|---|---|---|
text-embedding-3-small | 1536 | $0.02 / 1M токенов |
text-embedding-3-large | 3072 | $0.13 / 1M токенов |
text-embedding-ada-002 | 1536 | $0.10 / 1M токенов |
Пример
curl https://api.aipomogator.ru/v1/embeddings \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $API_KEY" \
-d '{
"model": "text-embedding-3-small",
"input": "Текст для векторизации"
}'
Ответ
{
"object": "list",
"data": [
{
"object": "embedding",
"embedding": [0.0023064255, -0.009327292, ...],
"index": 0
}
],
"model": "text-embedding-3-small",
"usage": {
"prompt_tokens": 5,
"total_tokens": 5
}
}
Function Calling
{
"model": "gpt-4o",
"messages": [
{"role": "user", "content": "Какая погода в Москве?"}
],
"tools": [
{
"type": "function",
"function": {
"name": "get_weather",
"description": "Получить текущую погоду",
"parameters": {
"type": "object",
"properties": {
"location": {"type": "string"}
},
"required": ["location"]
}
}
}
]
}