Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/aliammari1/readrealm/llms.txt

Use this file to discover all available pages before exploring further.

The ReadRealm backend reads all configuration from environment variables at startup. Set these in apps/api/.env.

Copy the template

cp apps/api/.env.example apps/api/.env
Then edit apps/api/.env and fill in your values.

Database

VariableExampleDescription
MONGO_URLmongodb://localhost:27017/readrealmFull MongoDB connection string. When running with Docker Compose, use mongodb://mongodb:27017/readrealm.

Authentication

VariableExampleDescription
JWT_SECRETyour_jwt_secret_key_min_32_charactersSecret used to sign JWT tokens.
JWT_SECRET must be at least 32 characters long. Shorter values will cause token signing to fail.

Email

ReadRealm sends verification and notification emails via Gmail SMTP.
VariableExampleDescription
MAIL_HOSTsmtp.gmail.comSMTP server hostname.
MAIL_USERyour_email@gmail.comGmail address used as the sender.
MAIL_PASSyour_app_specific_passwordApp-specific password generated from your Google Account (not your regular Gmail password).
Generate an app-specific password at myaccount.google.com/apppasswords after enabling 2-Step Verification on your Google Account.

Azure Text-to-Speech

Powers the audio narration feature using Azure OpenAI TTS.
VariableExampleDescription
AZURE_API_TTS_KEYyour_azure_tts_keyAPI key for the Azure OpenAI TTS deployment.
AZURE_API_TTS_ENDPOINThttps://your-region.openai.azure.com/Endpoint URL for the Azure OpenAI TTS deployment.
AZURE_API_TTS_MODELttsDeployment name for the TTS model (e.g. tts).

Azure Real-time Speech

Powers two-way voice interaction using Azure OpenAI Realtime.
VariableExampleDescription
AZURE_API_REALTIME_KEYyour_azure_realtime_keyAPI key for the Azure OpenAI Realtime deployment.
AZURE_API_REALTIME_ENDPOINThttps://your-region.openai.azure.com/Endpoint URL for the Azure OpenAI Realtime deployment.
AZURE_API_REALTIME_MODELgpt-4o-realtime-previewDeployment name for the realtime voice model.

Google AI (Gemini)

Powers AI-generated summaries and book descriptions.
VariableExampleDescription
GEMINI_API_KEYyour_google_ai_api_keyAPI key for Google Generative AI (Gemini). Obtain from Google AI Studio.
GEMINI_API_MODELgemini-proGemini model variant to use.

Server

VariableDefaultDescription
NODE_ENVdevelopmentRuntime environment. Set to production in deployed environments.
PORT3000Port the NestJS API listens on.

Client apps

The Android client, iOS client, and Flutter admin dashboard do not use .env files. Their API connection is configured at build time in source code. See the individual client setup pages for details:

Build docs developers (and LLMs) love