E-FACTS — E-receipt management companyE-FACTS — E-receipt management company
Engineering

Local development setup

Run the docs site and sibling E-FACTS projects locally

Local development setup

Internal docs (efacts-dev)

cp .env.example .env.local   # set DOCS_AUTH_*
npm install
npm run dev

Open http://localhost:3000. Docs live at /docs. Unauthenticated requests redirect to /login.

VariablePurpose
DOCS_AUTH_EMAILAllowed email (case-insensitive)
DOCS_AUTH_PASSWORDPassword (exact match)
DOCS_AUTH_SECRETOptional HMAC secret for session cookie

Session cookie: efacts_docs_sessionhttpOnly, SameSite=Lax, Secure in production, 7-day expiry.

Do not commit secrets

.env.local stays local. .env.example is the contract only.

Sibling repos (high level)

RepoTypical local entry
efacts-backendFollow that repo’s README (Fastify + DB + Redis)
efacts-iosappXcode · iOS 17+ simulator / device
efacts-websitenpm install · npm run dev (Next.js)

Point clients at local or staging API bases via each repo’s env docs — never hardcode production secrets.

Useful checks (docs site)

npm run build    # must pass before merge
npm run lint     # if configured in package scripts

On this page