openai-sdk
Integrate OpenAI APIs into applications. Use when a user asks to add GPT or ChatGPT to an app, generate text with OpenAI, build a chatbot, use GPT-4 or o1 models, generate embeddings, use function calling, stream chat completions, build AI features, moderate content, generate images with DALL-E, transcribe audio with Whisper API, or integrate any OpenAI model. Covers Chat Completions, Assistants API, function calling, embeddings, streaming, vision, DALL-E, Whisper, and moderation.
npx skills add majiayu000/claude-skill-registry --skill openai-sdk-terminalskills-skills --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# OpenAI SDK ## Overview The OpenAI SDK provides access to GPT-4o, o1, DALL-E 3, Whisper, and embedding models. This skill covers the Chat Completions API (text generation, conversation, function calling), streaming responses, vision (image understanding), embeddings, the Assistants API (stateful agents), DALL-E image generation, Whisper transcription, and content moderation. Examples in both TypeScript/Node.js and Python. ## Instructions ### Step 1: Installation and Setup ```bash # Node.js npm install openai # Python pip install openai ``` ```typescript // lib/openai.ts — Client initialization import OpenAI from 'openai' const openai = new OpenAI({ apiKey: process.env.OPENAI_API_KEY, // or set OPENAI_API_KEY env var }) ``` ### Step 2: Chat Completions ```typescript // chat.ts — Basic chat completion and conversation import OpenAI from 'openai' const openai = new OpenAI() // Single message const response = await openai.chat.completions.create({ model: 'gpt-4o', messages: [ { role: 'system', content: 'You are a helpful coding assistant.' }, { role: 'user', content: 'Write a Python function to merge two sorted lists.' }, ], temperature: 0.7, // 0 = deterministic, 2 = creative max_tok
- Overview
- Instructions
- Step 1: Installation and Setup
- Step 2: Chat Completions
- Step 3: Streaming Responses
- Step 4: Function Calling (Tool Use)
- Step 5: Embeddings
- Step 6: Vision (Image Understanding)
- Step 7: Structured Outputs
- Examples
- Example 1: Build a customer support chatbot with function calling
- Example 2: Build a document analysis pipeline
- Guidelines
Node.js npm install openai Python pip install openai
What does the openai-sdk skill do?
Integrate OpenAI APIs into applications. Use when a user asks to add GPT or ChatGPT to an app, generate text with OpenAI, build a chatbot, use GPT-4 or o1 models, generate embeddings, use function calling, stream chat completions, build AI features, moderate content, generate images with DALL-E, transcribe audio with Whisper API, or integrate any OpenAI model. Covers Chat Completions, Assistants API, function calling, embeddings, streaming, vision, DALL-E, Whisper, and moderation.
How do I install it?
Run `npx skills add majiayu000/claude-skill-registry --skill openai-sdk-terminalskills-skills --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
