GPTDiscord: Running OpenAI Features Inside Discord
A robust, all-in-one GPT interface for Discord. ChatGPT-style conversations, image generation, AI-moderation, custom indexes/knowledgebase, youtube summarizer, and more!
At a glance
- What is it?
- GPTDiscord is a Python Discord bot for OpenAI chat, vision, image generation, transcription, moderation, web search, and optional knowledge tools. It suits operators who want these capabilities exposed through Discord commands and threads, but it requires multiple external services, deliberate permissions, and ongoing configuration work.
- Who is it for?
- Adopt GPTDiscord when a Discord community needs a configurable OpenAI command interface and you are prepared to manage Discord permissions, API credentials, persistent data, and external service costs. Do not choose it for a self-contained local AI application, an environment that cannot expose OpenAI API access, or a server where broad message and thread permissions are unacceptable.
- Can I use it commercially?
- Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
- Is it still maintained?
- Yes. The repository last received commits 5 days ago.
- What is it written in?
- Mainly Python, according to GitHub's language statistics.
Answers come from the project's GitHub data, last synced on October 23, 2026, and from our analysis. They are not legal advice.
Editorial analysis
GPTDiscord's Discord Command Surface
GPTDiscord places OpenAI-backed functions inside Discord, where users interact through slash commands and conversation threads. Its intended operators are community administrators, Discord server owners, and developers who want a shared chat interface without building a separate Discord application around each AI feature. The documented command surface includes `/gpt ask`, `/gpt converse`, `/web`, and `/dalle draw`, alongside transcription and moderation support.
The project is not simply a thin Discord wrapper around one text endpoint. Long conversations, per-user API keys, server roles, saved conversations, prompt optimization, vision, and reasoning models are documented as available chat capabilities. Image generation returns bytes as Discord attachments rather than as a remote URL. Transcription processes downloaded media through FFmpeg and the configured OpenAI transcription model. The result is a multi-feature bot with local persistence and optional third-party integrations.
That scope also defines who may find it excessive. An operator wanting one dependable chat command may have to reason about Discord gateway intents, role controls, OpenAI model availability, usage charges, filesystem permissions, and multiple optional dependency groups. The `pyproject.toml` identifies the distribution as beta, so adoption decisions should account for an early-stage package rather than treat it as a finished platform service.
Chat, Responses, and Image Request Routing
GPTDiscord uses different OpenAI API shapes for different jobs. `/gpt ask` and `/gpt converse` use current Chat Completions models, including vision and reasoning models. Model defaults and limits are centralized, and incompatible sampling options are omitted for reasoning models. The documented default chat model is `gpt-6.1-sol`, while `gpt-6-luna` is described as the low-cost helper model. Actual availability depends on the OpenAI project.
The `/web` command takes a different route. It uses the Responses API with native web search and provides visible source links, which makes it more suitable than ordinary chat when recent external information matters. This path requires an OpenAI key with access to both the selected model and web search. The README also warns that search tool calls incur additional OpenAI charges. A compatible endpoint can be configured through `OPENAI_BASE_URL`, but `/web` still needs a provider that implements Responses and native web search.
Image generation retains the `/dalle draw` command name but uses the current GPT Image API. Its documented default is `gpt-image-2.5-flare`. The generated bytes are sent to Discord as an attachment, so the bot needs permission to attach files. Model selection is configurable through environment variables rather than hard-coded into each command handler. This separation makes the request routing visible: Chat Completions for chat and vision, Responses with search for `/web`, and an image endpoint for drawing.
Installing GPTDiscord from Source for Python 3.11 to 3.13
The source installation creates an isolated environment, installs the package, prepares configuration, and starts the bot. The documented commands use Python 3.13, while `pyproject.toml` allows Python versions from 3.11 through 3.13. Git and network access to GitHub, PyPI, OpenAI, and Discord are required.
Use the documented source workflow in a terminal that can reach the required services:
git clone https://github.com/Kav-K/GPTDiscord.git
cd GPTDiscord
python3.13 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install .
cp sample.env .envOn Windows, the activation command documented by the README uses `.venv\Scripts\activate` instead of the Unix command shown above. After creating `.env`, populate it with credentials and the Discord server ID, then launch the console entry point:
python gpt3discord.pyThe package also installs a `gpt3discord` console command, and prompt files plus conversation openers are included in the wheel. The first real use is therefore a Discord slash command rather than a local prompt. Create the commands in the configured guild with `/gpt ask`, or use `/gpt converse` for the documented conversation flow. A successful local start should produce a connected Discord bot, while the command itself requires `ALLOWED_GUILDS` to contain the relevant server ID.
FFmpeg is not installed by the Python package. The README says to install it with the operating system's package manager before attempting transcription of downloaded media. The core bot does not require Torch, Transformers, LlamaIndex, or LangChain.
Discord Permissions, Credentials, and Persistence Boundaries
Basic operation requires two independent credentials: `OPENAI_API_KEY` for the OpenAI project and `DISCORD_TOKEN` for the Discord application. `OPENAI_TOKEN` remains a supported alias. A ChatGPT subscription does not include OpenAI API billing, so the operator must separately arrange API credit and access to the selected models. Configuration also requires `ALLOWED_GUILDS`, a comma-separated list of Discord server IDs, and optionally `DATA_DIR`, which defaults to the current directory.
Discord must enable the privileged Server Members and Message Content gateway intents. The bot invitation needs the `bot` and `applications.commands` OAuth scopes. Practical permissions include reading and sending messages, attaching files, embedding links, and creating or using threads. These permissions are consequential because the bot is designed to participate in server conversations. The README specifically tells administrators to review role controls in `sample.env` before inviting it to a public server.
For a minimal model setup, the documented environment keys are:
OPENAI_MODEL=gpt-6.1-sol
OPENAI_IMAGE_MODEL=gpt-image-2.5-flare
OPENAI_EMBEDDING_MODEL=text-embedding-3-small
OPENAI_MODERATION_MODEL=omni-moderation-latest
OPENAI_TRANSCRIPTION_MODEL=gpt-4o-mini-transcribe`DATA_DIR` receives local data and usage estimates. This is an operational boundary worth checking. The documentation does not claim that all conversation content is ephemeral, and saved conversations, local indexes, databases, and vectors can be part of later upgrades or backups. Credentials should remain in an untracked `.env` or a hosting platform's secret store.
Optional GPTDiscord Integrations and Dependency Tensions
Document Q&A, Google and Wolfram chat, Pinecone memory, E2B execution, and Replicate vision are optional rather than part of the basic installation. Each has a dedicated extra and separate credentials. Document indexing requires `ENABLE_INDEXING=true` and OpenAI access. Google and Wolfram chat require their search keys, while Pinecone uses `PINECONE_TOKEN` and `PINECONE_REGION`, with `us-east-1` as the documented default. E2B requires `E2B_API_KEY`, and Replicate requires `REPLICATE_API_KEY`.
Install only the integrations needed by the deployment. The core package remains comparatively direct because it does not pull in Torch, Transformers, LlamaIndex, or LangChain. The `index` extra introduces LlamaIndex and LangChain packages, creating a real dependency constraint: the README says LlamaIndex currently requires OpenAI SDK 2.x, so installing that extra selects a compatible SDK even though the core supports SDK 3.x.
Missing configured dependencies produce an actionable startup error, while disabled services respond with setup guidance. When `USER_INPUT_API_KEYS=true`, optional index, search, and code sessions accept messages only from the session creator. That control limits who can spend another person's API credits. It does not, by itself, settle all cost and data governance questions, so deployments should verify the relevant roles, session behavior, storage location, and external service terms.
A concrete alternative is to build a small Discord integration directly around the OpenAI APIs. That approach has fewer GPTDiscord-specific dependencies and persistence features to understand, but the developer must implement command registration, thread handling, conversation memory, attachments, credentials, optional integrations, and error handling. GPTDiscord offers those parts as an existing Python bot, while the direct approach offers a smaller application surface and greater control.
Docker Deployment and GPTDiscord Upgrade Cost
Docker Compose provides a persistent deployment with the bot running as UID and GID `10001`. The image includes FFmpeg, stores application data under `/data`, and maps that path to a named volume. Existing bind-mounted data must be writable by UID `10001`, which is a common source of startup failures when importing files created by another user.
The documented Compose workflow is:
cp sample.env .env
docker compose up --build -d
docker compose logs -fThe compose file sets `FULL` to `false`, so the image installs the core package. Setting `FULL` to `true` selects the `.[full]` extra. The `restart: unless-stopped` setting gives the container a simple process restart policy, but it is not a substitute for backing up local data or reviewing logs.
Upgrading from v12 requires more than replacing the running process. The README directs operators to back up `.env`, SQLite databases, pickles, local indexes, and stored vectors. It also recommends a fresh Python 3.11 to 3.13 virtual environment rather than reusing the old pinned package set. `ENABLE_INDEXING=true` must be set to enable indexing after the upgrade. Model overrides and role settings should be reviewed because the documented defaults target current APIs rather than retired preview endpoints.
The MIT license permits use and modification under its terms, subject to the license text, but this review does not interpret those terms as legal advice. Users must separately account for OpenAI charges and any optional Google, Wolfram, Pinecone, E2B, or Replicate costs. The repository is not archived, and its last push was on 2026-10-16. That fact does not remove the operational cost of auditing model changes, dependency compatibility, Discord permissions, and stored data during each release.
Editorial conclusion
Adopt GPTDiscord when a Discord community needs a configurable OpenAI command interface and you are prepared to manage Discord permissions, API credentials, persistent data, and external service costs. Do not choose it for a self-contained local AI application, an environment that cannot expose OpenAI API access, or a server where broad message and thread permissions are unacceptable. Before installation, verify OpenAI model access and billing, Discord privileged intents, role restrictions, and whether the required data should remain in `DATA_DIR` or a Docker volume.
Frequently asked questions
What is GPTDiscord used for?
GPTDiscord exposes OpenAI chat, vision, image generation, transcription, moderation, and web search through a Discord bot. Optional integrations add document indexing, external search, Pinecone memory, code execution, and Replicate vision.
How do I install GPTDiscord?
Install it from source in a Python 3.11 to 3.13 environment with `python -m pip install .`, then copy `sample.env` to `.env` and start it with `python gpt3discord.py`. The package also provides the `gpt3discord` console command.
Does GPTDiscord work without a Google account?
The README states that `/web` uses the OpenAI Responses API with native web search and requires no Google account. The separate Google chat integration does require `GOOGLE_SEARCH_API_KEY` and `GOOGLE_SEARCH_ENGINE_ID`.
What Discord permissions does GPTDiscord need?
The Discord application needs the privileged Server Members and Message Content intents. The invitation uses the `bot` and `applications.commands` scopes, and practical permissions include reading and sending messages, attaching files, embedding links, and using threads.
Official sources
Add this badge to your README
If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.
[](https://hysenlabs.com/projects/kav-k-gptdiscord)Was this useful?