Перевірити рівеньКурсиПрограмиДля командТарифи
RUУвійтиРеєстрація
Перевірити рівеньКурсиПрограмиДля командТарифиТест із ClaudeПромптиБлогПитання та відповідіПошукРеєстраціяRU
AcademlКурсиOpenAI API from A to ZSDK install and first call
Повторні запити після помилки 429: пауза щоразу вдвічі довша, потім успіхСхема сценарію: повідомлення в Telegram розходиться на команду, голос і текст і приходить до агентаЗаявка з форми потрапляє в рядок таблиці з міткою «Скарга»
Курс

OpenAI API from A to Z

Модуль 1 · API Basics
01SDK install and first call02Choosing an OpenAI model03Tokens, context, and cost
Модуль 2 · Chat Completions
04Developer messages, reasoning effort and sampling parameters05Structured Outputs and JSON Schema06Multimodality: vision, speech-to-text and voice
Модуль 3 · Assistants API v2
07From Assistants to Responses: conversation memory08File Search and vector store09Code Interpreter10Combining tools and tool_choice
Модуль 4 · Function Calling
11Function calling: the full cycle12Parallel function calls13Patterns: designing reliable functions
Модуль 5 · Production
14Streaming responses15Embeddings and semantic search16Production: limits, retries, monitoring
OpenAI API from A to Z · Урок 1

SDK install and first call

Install the openai SDK, create a client and make your first call with the Responses API on gpt-6-luna, then the same request with Chat Completions. Parse the response, status and finish_reason, usage, length limits and reasoning effort.

ENМатеріали курсів поки англійською. Інтерфейс, ШІ-наставник і перевірка завдань — українською.

25 хв читанняОновлено 09.11.20263 питання у квізіГотовий промпт включено

Install

npm install openai
# or for Python
pip install openai

Create a key at platform.openai.com/api-keys and put it in the OPENAI_API_KEY environment variable. Never hardcode the key in your repo.

Далі урок відкривається після безкоштовної реєстрації

Реєстрація через email або Google відкриває перші два уроки кожного курсу назавжди і 7 днів повного доступу до всього каталогу. Картка не потрібна.

Зареєструватися безкоштовноАбо пробний урок без реєстрації →
У цьому уроці
InstallWhich API to useFirst call with the Responses API (TypeScript)What's in a Responses responseSame call with Chat CompletionsSame in PythonLimiting response length and reasoningПрактикаГотовий промптКвіз
КурсиКурси з LLMДля командТарифиПитання та відповідіБлогПро насКонфіденційність
© 2026 AcademlРозробка та просування сайтів —MMIX — Marketing Mix
Почати безкоштовно