Niko reads all runtime configuration from aDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/developer51709/Niko/llms.txt
Use this file to discover all available pages before exploring further.
.env file located at src/.env. To get started, copy src/.env.example to src/.env and fill in the required values. Variables that are left blank or omitted entirely will fall back to their documented defaults.
Template
src/.env
All values in the
.env file must be strings. Wrap values in double quotes as shown in the template above — this is especially important for values that contain spaces, special characters, or the | pipe symbol.Discord
Your bot’s token from the Discord Developer Portal. Navigate to your application → Bot → Token to copy it. This is the only truly required variable — the bot will refuse to start without it.
General Bot Behaviour
Set to
"True", "1", or "yes" to enable verbose logging output. Useful during development; leave as "False" in production to keep your logs clean.The text displayed in the bot’s Discord status. You can use any string here — for example
"your next favourite bot".The activity type shown alongside
STATUS_MESSAGE. Accepted values:| Value | Displays as |
|---|---|
playing | Playing <message> |
watching | Watching <message> |
listening | Listening to <message> |
competing | Competing in <message> |
streaming | Streaming <message> (uses STATUS_LINK) |
A URL used when
STATUS_TYPE is set to "streaming". For the purple streaming badge, this must be a Twitch (https://twitch.tv/...) or YouTube (https://youtube.com/...) URL. Has no effect for other status types.Controls which presence device identity the bot reports to Discord. Accepted values:
| Value | Effect |
|---|---|
normal | Standard bot presence |
embedded | Embedded/console device |
desktop | Desktop client presence |
vr | VR device presence |
mobile_android | Shows mobile indicator (Android) |
mobile_ios | Shows mobile indicator (iOS) |
Casino Cooldowns
These control how many seconds a user must wait between uses of each casino command. All three default to 60 seconds.Seconds between slot machine uses per user. Set to
"0" to disable the cooldown entirely.Seconds between blackjack games per user. Set to
"0" to disable the cooldown entirely.Seconds between roulette spins per user. Set to
"0" to disable the cooldown entirely.NSFW Image APIs
These variables unlock the NSFW image commands. Both the API key and the user ID must be set together for each service.Your Gelbooru API key. Obtain it from your Gelbooru account settings. Leave blank to disable Gelbooru image commands.
Your Gelbooru numeric user ID. Found on the same account settings page as your API key.
Your Rule34 API key. Leave blank to disable Rule34 image commands.
Your Rule34 numeric user ID, paired with
RULE34_API_KEY.AI Integration
The API key for your chosen AI provider. Required for all AI chat features (
/chat, mention triggers, prefix AI commands). Works with any OpenAI-compatible provider — see the AI Providers page for the full list.The base URL of an OpenAI-compatible API endpoint. Omit this variable (or leave it blank) to route requests to the official OpenAI API at
https://api.openai.com. Set it to a third-party provider’s URL (e.g. https://openrouter.ai/api/v1) to use that provider instead. See AI Providers for a full list of compatible services and their base URLs.A Hugging Face API token, required for the
/imagine (image generation) and /edit (image editing) commands. Create a token at huggingface.co/settings/tokens. Without this key those two commands will not function, but all other features remain unaffected.Logging
A Discord webhook URL. When set, Niko will forward internal log messages to that webhook channel. This is optional and not recommended for most deployments — the console output is generally sufficient.
Payments
Your OxaPay Merchant Key (not the General Key or Payout Key). Required for the donation commands to create and verify payment sessions. Obtain it from your OxaPay merchant dashboard. Without this key, donation-related commands will be disabled.