Prompt Buddy logoPrompt Buddy

openai · OpenAI Platform Docs

ChatKit

A guide to implementing agentic chat experiences using ChatKit, covering both recommended frontend embedding and advanced self-hosted infrastructure via the Python SDK.

Import to Prompt Buddy

Derived skill

Files assembled from official documentation

Viewing SKILL.md

ChatKit

A guide to implementing agentic chat experiences using ChatKit, covering both recommended frontend embedding and advanced self-hosted infrastructure via the Python SDK.

When To Use

Use when you need to integrate a customizable, agentic chat UI into a frontend application or build a custom backend using the ChatKit Python SDK.

Reference Files

FileContainsUse For
SKILL.mdEntry point: scope, routing table, and workflow.Start here.
docs/chatkit-workflow-guide.mdA guide providing an overview of ChatKit for building agentic chat experiences and embedding them into frontends.Questions about a guide providing an overview of ChatKit for building agentic chat experiences and embedding them into frontends.
examples/chatkit-openai-chatkit-fastapi-session-creation.pythonA Python implementation using FastAPI and the OpenAI SDK to create a ChatKit session via a POST endpoint.Exact payloads, commands, or snippets shown in A Python implementation using FastAPI and the OpenAI SDK to create a ChatKit session via a POST endpoint.
examples/chatkit-openai-chatkit-get-session-token.typescriptA TypeScript function that fetches a ChatKit session token from the OpenAI API using a device ID and beta headers.Exact payloads, commands, or snippets shown in A TypeScript function that fetches a ChatKit session token from the OpenAI API using a device ID and beta headers.
examples/chatkit-react-npm-install-command.bashThe bash command to install the @openai/chatkit-react package via npm.Exact payloads, commands, or snippets shown in The bash command to install the @openai/chatkit-react package via npm.
examples/chatkit-openai-chatkit.htmlAn HTML implementation example demonstrating the integration of the ChatKit interface.Exact payloads, commands, or snippets shown in An HTML implementation example demonstrating the integration of the ChatKit interface.
examples/chatkit-openai-chatkit-react-usechatkit-hook-implementation.reactA React component demonstrating the use of the useChatKit hook to manage client secret retrieval and session refreshing.Exact payloads, commands, or snippets shown in A React component demonstrating the use of the useChatKit hook to manage client secret retrieval and session refreshing.
examples/chatkit-javascript-setoptions-client-secret-implementation.javascriptA JavaScript code example demonstrating how to use the ChatKit setOptions method to implement client secret retrieval and refreshing via fetch requests.Exact payloads, commands, or snippets shown in A JavaScript code example demonstrating how to use the ChatKit setOptions method to implement client secret retrieval...

What This Skill Covers

  • ChatKit is the best way to build agentic chat experiences. Whether you’re building an internal knowledge base assistant, HR onboarding helper, research compa...
  • Main sections: Overview, Get started with ChatKit, Embed ChatKit in your frontend, 1. Create an agent workflow, 2. Set up ChatKit in your product.

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/guides/chatkit.md