Prompt Buddy logoPrompt Buddy

openai · OpenAI Platform Docs

Developer quickstart | OpenAI API

Provides a step-by-step guide to setting up an OpenAI API account, installing the necessary client libraries, and making an initial authenticated request to a language model.

Import to Prompt Buddy

Derived skill

Files assembled from official documentation

Viewing SKILL.md

Developer quickstart | OpenAI API

Provides a step-by-step guide to setting up an OpenAI API account, installing the necessary client libraries, and making an initial authenticated request to a language model.

When To Use

Use when you need to perform the initial setup and authentication required to send your first request to the OpenAI API using a programming language library.

Reference Files

FileContainsUse For
SKILL.mdEntry point: scope, routing table, and workflow.Start here.
docs/developer-quickstart-openai-api-workflow-guide.mdA guide covering API key creation, SDK installation, and executing initial API calls to interact with OpenAI models.Questions about a guide covering API key creation, SDK installation, and executing initial API calls to interact with OpenAI models.
examples/developer-quickstart-openai-api-openai-api-quickstart-environment-variab.textA text file demonstrating how to export the OPENAI_API_KEY environment variable for API authentication.Exact payloads, commands, or snippets shown in A text file demonstrating how to export the OPENAIAPIKEY environment variable for API authentication.
examples/developer-quickstart-openai-api-openai-api-quickstart-environment-variab-2.textA command to set the OPENAI_API_KEY environment variable for the OpenAI API quickstart.Exact payloads, commands, or snippets shown in A command to set the OPENAIAPIKEY environment variable for the OpenAI API quickstart.
examples/developer-quickstart-openai-api-openai-api-npm-install-command.textThe npm install command required to add the openai library to a project.Exact payloads, commands, or snippets shown in The npm install command required to add the openai library to a project.
examples/developer-quickstart-openai-api-openai-api-nodejs-responses-create-quick.textA Node.js code snippet demonstrating how to initialize the OpenAI client and create a response using the responses.create method.Exact payloads, commands, or snippets shown in A Node.js code snippet demonstrating how to initialize the OpenAI client and create a response using the responses.cr...
examples/developer-quickstart-openai-api-openai-api-python-pip-install-command.textThe shell command to install the openai python library using pip.Exact payloads, commands, or snippets shown in The shell command to install the openai python library using pip.
examples/developer-quickstart-openai-api-openai-api-python-quickstart-client-resp.textA Python code snippet demonstrating how to initialize the OpenAI client and create a response using the responses.create method.Exact payloads, commands, or snippets shown in A Python code snippet demonstrating how to initialize the OpenAI client and create a response using the responses.cre...
examples/developer-quickstart-openai-api-openai-api-dotnet-package-installation-c.textThe dotnet CLI command required to add the OpenAI NuGet package to a project.Exact payloads, commands, or snippets shown in The dotnet CLI command required to add the OpenAI NuGet package to a project.
examples/developer-quickstart-openai-api-openai-api-csharp-quickstart-request.textA C# code example demonstrating how to initialize an OpenAIClient and create a response request using the OpenAI library.Exact payloads, commands, or snippets shown in A C# code example demonstrating how to initialize an OpenAIClient and create a response request using the OpenAI libr...
examples/developer-quickstart-openai-api-openai-api-java-dependency-maven-configu.textThe Maven dependency configuration for integrating the OpenAI Java library version 4.0.0.Exact payloads, commands, or snippets shown in The Maven dependency configuration for integrating the OpenAI Java library version 4.0.0.
examples/developer-quickstart-openai-api-openai-api-java-quickstart-response-crea.textA Java code example demonstrating how to initialize an OpenAI client and create a response using the ResponseCreateParams builder.Exact payloads, commands, or snippets shown in A Java code example demonstrating how to initialize an OpenAI client and create a response using the ResponseCreatePa...
examples/developer-quickstart-openai-api-openai-api-go-quickstart-implementation.textA Go language implementation demonstrating the basic setup and initial request for the OpenAI API quickstart.Exact payloads, commands, or snippets shown in A Go language implementation demonstrating the basic setup and initial request for the OpenAI API quickstart.
examples/developer-quickstart-openai-api-openai-api-go-quickstart.textA Go language implementation demonstrating how to initialize an OpenAI client and make a basic API request.Exact payloads, commands, or snippets shown in A Go language implementation demonstrating how to initialize an OpenAI client and make a basic API request.
examples/developer-quickstart-openai-api-openai-api-nodejs-chat-completions-quick.textA Node.js code snippet demonstrating how to initialize the OpenAI client and create a chat completion response using a model and user input.Exact payloads, commands, or snippets shown in A Node.js code snippet demonstrating how to initialize the OpenAI client and create a chat completion response using...
examples/developer-quickstart-openai-api-openai-api-curl-chat-completion-request.textA curl command demonstrating a POST request to the OpenAI API chat completion endpoint using a JSON payload.Exact payloads, commands, or snippets shown in A curl command demonstrating a POST request to the OpenAI API chat completion endpoint using a JSON payload.
examples/developer-quickstart-openai-api-openai-api-cli-chat-completions-request.textA text-based example of an OpenAI API CLI command using a YAML heredoc to send a multimodal chat completion request.Exact payloads, commands, or snippets shown in A text-based example of an OpenAI API CLI command using a YAML heredoc to send a multimodal chat completion request.
examples/developer-quickstart-openai-api-openai-api-python-client-quickstart.textA Python code snippet demonstrating how to initialize the OpenAI client and create a response using a model.Exact payloads, commands, or snippets shown in A Python code snippet demonstrating how to initialize the OpenAI client and create a response using a model.
examples/developer-quickstart-openai-api-openai-api-csharp-quickstart.textA C# code example demonstrating how to initialize an OpenAIResponseClient and create a response using an environment variable for the API key.Exact payloads, commands, or snippets shown in A C# code example demonstrating how to initialize an OpenAIResponseClient and create a response using an environment...
examples/developer-quickstart-openai-api-openai-api-curl-responses-quickstart.textA curl command demonstrating a POST request to the OpenAI API responses endpoint using a JSON payload.Exact payloads, commands, or snippets shown in A curl command demonstrating a POST request to the OpenAI API responses endpoint using a JSON payload.
examples/developer-quickstart-openai-api-openai-api-nodejs-responses-create-quick-2.textA Node.js code snippet demonstrating how to use the OpenAI client to create a response using a specific model and input text.Exact payloads, commands, or snippets shown in A Node.js code snippet demonstrating how to use the OpenAI client to create a response using a specific model and inp...
examples/developer-quickstart-openai-api-openai-api-python-client-quickstart-2.textA Python code snippet demonstrating how to initialize the OpenAI client and create a response using a model with text and file input.Exact payloads, commands, or snippets shown in A Python code snippet demonstrating how to initialize the OpenAI client and create a response using a model with text...
examples/developer-quickstart-openai-api-openai-api-csharp-quickstart-upload.textA C# code example demonstrating how to initialize an OpenAI client and upload a PDF file using the OpenAI API.Exact payloads, commands, or snippets shown in A C# code example demonstrating how to initialize an OpenAI client and upload a PDF file using the OpenAI API.
examples/developer-quickstart-openai-api-openai-api-files-upload-curl-request.textA curl command demonstrating how to upload a file to the OpenAI API using the files endpoint with a specified purpose.Exact payloads, commands, or snippets shown in A curl command demonstrating how to upload a file to the OpenAI API using the files endpoint with a specified purpose.
examples/developer-quickstart-openai-api-openai-api-nodejs-files-create-and-respo.textA Node.js code snippet demonstrating how to upload a file for userdata and create a response using the OpenAI client.Exact payloads, commands, or snippets shown in A Node.js code snippet demonstrating how to upload a file for userdata and create a response using the OpenAI client.
examples/developer-quickstart-openai-api-openai-api-python-upload-and-response-cr.textA Python script demonstrating how to upload a PDF file to the OpenAI API and create a response using the file ID.Exact payloads, commands, or snippets shown in A Python script demonstrating how to upload a PDF file to the OpenAI API and create a response using the file ID.
examples/developer-quickstart-openai-api-openai-api-csharp-quickstart-upload-2.textA C# code example demonstrating how to initialize an OpenAI client and upload a file using the OpenAI API.Exact payloads, commands, or snippets shown in A C# code example demonstrating how to initialize an OpenAI client and upload a file using the OpenAI API.
examples/developer-quickstart-openai-api-openai-api-nodejs-client-initialization-.textA JavaScript code snippet demonstrating how to initialize the OpenAI client and create a response using the responses.create method.Exact payloads, commands, or snippets shown in A JavaScript code snippet demonstrating how to initialize the OpenAI client and create a response using the responses...
examples/developer-quickstart-openai-api-openai-api-python-quickstart-client-init.textA Python code snippet demonstrating how to initialize the OpenAI client and create a response using a model with web search tools.Exact payloads, commands, or snippets shown in A Python code snippet demonstrating how to initialize the OpenAI client and create a response using a model with web...
examples/developer-quickstart-openai-api-openai-api-curl-responses-quickstart-2.textA curl command demonstrating a request to the OpenAI API responses endpoint using a model with web search tools.Exact payloads, commands, or snippets shown in A curl command demonstrating a request to the OpenAI API responses endpoint using a model with web search tools.
examples/developer-quickstart-openai-api-openai-api-quickstart-curl-model-request.textA shell command demonstrating a raw API request to the OpenAI model endpoint using a YAML-formatted input.Exact payloads, commands, or snippets shown in A shell command demonstrating a raw API request to the OpenAI model endpoint using a YAML-formatted input.
examples/developer-quickstart-openai-api-openai-api-csharp-quickstart-response-cr.textA C# code example demonstrating how to initialize an OpenAIResponseClient and configure response creation options with a web search tool.Exact payloads, commands, or snippets shown in A C# code example demonstrating how to initialize an OpenAIResponseClient and configure response creation options wit...
examples/developer-quickstart-openai-api-openai-api-python-quickstart-client-resp-2.textA Python code snippet demonstrating how to initialize the OpenAI client and create a response using a specific model and tool configuration.Exact payloads, commands, or snippets shown in A Python code snippet demonstrating how to initialize the OpenAI client and create a response using a specific model...
examples/developer-quickstart-openai-api-openai-api-nodejs-responses-create-quick-3.textA Node.js code snippet demonstrating how to use the OpenAI client to create a response with a filesearch tool.Exact payloads, commands, or snippets shown in A Node.js code snippet demonstrating how to use the OpenAI client to create a response with a filesearch tool.
examples/developer-quickstart-openai-api-openai-api-csharp-quickstart-response-cr-2.textA C# code example demonstrating how to initialize an OpenAIResponseClient and create a response using response creation options and tools.Exact payloads, commands, or snippets shown in A C# code example demonstrating how to initialize an OpenAIResponseClient and create a response using response creati...
examples/developer-quickstart-openai-api-openai-api-nodejs-function-calling-quick.textA Node.js code example demonstrating how to initialize the OpenAI client and implement function calling with a weather tool.Exact payloads, commands, or snippets shown in A Node.js code example demonstrating how to initialize the OpenAI client and implement function calling with a weathe...
examples/developer-quickstart-openai-api-openai-api-python-quickstart-client-init-2.textA Python code snippet demonstrating how to initialize the OpenAI client and define tool function parameters for a quickstart guide.Exact payloads, commands, or snippets shown in A Python code snippet demonstrating how to initialize the OpenAI client and define tool function parameters for a qui...
examples/developer-quickstart-openai-api-openai-api-csharp-quickstart-client-init.textA C# code snippet demonstrating how to initialize an OpenAIResponseClient using an environment variable for the API key and configuring response creation options.Exact payloads, commands, or snippets shown in A C# code snippet demonstrating how to initialize an OpenAIResponseClient using an environment variable for the API k...
examples/developer-quickstart-openai-api-openai-api-chat-completions-curl-request.textA curl command demonstrating a POST request to the OpenAI API chat completions endpoint using a JSON payload.Exact payloads, commands, or snippets shown in A curl command demonstrating a POST request to the OpenAI API chat completions endpoint using a JSON payload.
examples/developer-quickstart-openai-api-openai-api-curl-chat-completion-request-2.textA curl command demonstrating a POST request to the OpenAI API using a JSON payload with model and tool parameters.Exact payloads, commands, or snippets shown in A curl command demonstrating a POST request to the OpenAI API using a JSON payload with model and tool parameters.
examples/developer-quickstart-openai-api-openai-api-nodejs-mcp-tool-response-quic.textA Node.js code snippet demonstrating how to use the OpenAI client to create a response using an MCP tool.Exact payloads, commands, or snippets shown in A Node.js code snippet demonstrating how to use the OpenAI client to create a response using an MCP tool.
examples/developer-quickstart-openai-api-openai-api-python-client-quickstart-3.textA Python code snippet demonstrating how to initialize the OpenAI client and create a response using a model with tool definitions.Exact payloads, commands, or snippets shown in A Python code snippet demonstrating how to initialize the OpenAI client and create a response using a model with tool...
examples/developer-quickstart-openai-api-openai-api-csharp-quickstart-client-init-2.textA C# code snippet demonstrating how to initialize the OpenAIResponseClient using an environment variable for the API key and configuring response creation options with MCP tools.Exact payloads, commands, or snippets shown in A C# code snippet demonstrating how to initialize the OpenAIResponseClient using an environment variable for the API...
examples/developer-quickstart-openai-api-openai-api-nodejs-responses-create-strea.textA Node.js code example demonstrating how to create a streaming response using the OpenAI client.Exact payloads, commands, or snippets shown in A Node.js code example demonstrating how to create a streaming response using the OpenAI client.
examples/developer-quickstart-openai-api-openai-api-python-client-response-stream.textA Python code example demonstrating how to initialize the OpenAI client and stream responses from a model.Exact payloads, commands, or snippets shown in A Python code example demonstrating how to initialize the OpenAI client and stream responses from a model.
examples/developer-quickstart-openai-api-openai-api-csharp-quickstart-streaming-r.textA C# code example demonstrating how to initialize an OpenAI client and create a streaming response using a user message.Exact payloads, commands, or snippets shown in A C# code example demonstrating how to initialize an OpenAI client and create a streaming response using a user message.
examples/developer-quickstart-openai-api-openai-api-agent-handoff-javascript.textA JavaScript code example demonstrating the implementation of multiple agents with specific instructions for handoff logic.Exact payloads, commands, or snippets shown in A JavaScript code example demonstrating the implementation of multiple agents with specific instructions for handoff...
examples/developer-quickstart-openai-api-openai-agents-python-multi-agent-handoff.textA Python code example demonstrating the implementation of multiple agents with handoff capabilities using the OpenAI Agents framework.Exact payloads, commands, or snippets shown in A Python code example demonstrating the implementation of multiple agents with handoff capabilities using the OpenAI...

What This Skill Covers

  • The OpenAI API provides a simple interface to state-of-the-art AI models for text generation, natural language processing, computer vision, and more. Get sta...
  • Main sections: Create and export an API key, Install the OpenAI SDK and Run an API Call, Add credits to keep building, Analyze images and files, Extend the model with tools.

Workflow

  1. Open the most relevant file under docs/ for the exact documented workflow and wording.
  2. Open schemas/ files for exact structured contracts.
  3. Open examples/ files for concrete requests, commands, snippets, and manifests.
  4. Do not add behavior or configuration that is not present in the attached source files.

Canonical source: https://developers.openai.com/api/docs/quickstart