Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Daniel-Stojanovski/finkiopendesk/llms.txt

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

The FinkiOpenDesk backend reads its runtime configuration entirely from environment variables. None of these values are hard-coded; every sensitive setting is injected at startup via the OS environment, a Docker --env-file, or a Render service configuration. The sections below document each variable and how it is used by Spring Boot.
Never commit secrets — database passwords, JWT signing keys, or API keys — to source control. Use a secrets manager, a CI/CD environment variable store, or a local .env file that is listed in .gitignore.

Loading variables from a .env file

application.properties includes the following line:
application.properties
spring.config.import=optional:file:./.env
When a .env file is present in the working directory at startup, Spring Boot loads it automatically. The optional: prefix means the application starts normally even if the file is absent (as is the case in production containers where variables are injected by the runtime).

Database

DB_URL
string
required
Full JDBC connection string for the PostgreSQL database. Flyway uses this same connection to apply migrations on startup.
jdbc:postgresql://localhost:5432/finkiopendesk
DB_USER
string
required
PostgreSQL username. Mapped to spring.datasource.username in application.properties.
DB_PASSWORD
string
required
Password for the PostgreSQL user. Mapped to spring.datasource.password.

Email (SendGrid)

SENDGRID_SMTP_API_KEY
string
required
A SendGrid API key used as the SMTP password when sending account activation emails. The SMTP username is always the literal string apikey (set in application.properties); only the password — this variable — changes between environments.Generate a key in the SendGrid dashboard under Settings → API Keys. The key must have at least Mail Send permissions.
SG.xxxxxxxxxxxxxxxxxxxx
The backend connects to SendGrid via SMTP on port 587 with STARTTLS. Make sure your hosting environment allows outbound connections on port 587.

Authentication (JWT)

JWT_ACTIVATION_SECRET
string
required
Secret used to sign and verify account activation tokens. Choose a long, randomly generated string (at least 256 bits of entropy). This value must remain constant across restarts; rotating it invalidates all pending activation links.
JWT_LOGIN_SECRET
string
required
Secret used to sign and verify login (session) tokens. Use a different value from JWT_ACTIVATION_SECRET. Rotating this secret invalidates all active user sessions.
Generate secure secrets with: openssl rand -base64 64

Server

PORT
number
default:"8080"
The port the embedded Tomcat server listens on. Defaults to 8080 if not set, as expressed in application.properties:
server.port=${PORT:8080}
On Render, the platform injects PORT automatically. You do not need to set it manually for Render deployments.

Complete example

The following .env file shows all variables together. Use it as a starting point for local development — fill in your own values and make sure this file is in .gitignore.
.env
DB_URL=jdbc:postgresql://localhost:5432/finkiopendesk
DB_USER=postgres
DB_PASSWORD=change_me

SENDGRID_SMTP_API_KEY=SG.xxxxxxxxxxxxxxxxxxxx

JWT_ACTIVATION_SECRET=replace_with_a_long_random_string
JWT_LOGIN_SECRET=replace_with_a_different_long_random_string

PORT=8080

Build docs developers (and LLMs) love