Files
errors.bitreport.pt/api/.env.example
David Santos bc8bd8707f feat(api): expose CRM-shaped GET /api/error-monitoring/recent-errors on Fastify
Register the same handler as /v1/paperclip/recent-errors so NPM and direct
API probes (e.g. :3200) match Paperclip default PAPERCLIP_ERROR_API_QUERY.
Admin UI proxy now calls the Fastify path for a single contract end-to-end.

Paperclip-Agent: David Santos (urlKey david-santos; id 0b1fcf92-5fe3-4ac0-9f29-df4ab72f5376)
Paperclip-Issue: BIT-702
Paperclip-Run: 4ba525c4-3929-475c-a845-400c49eda817
Made-with: Cursor
2026-04-01 16:28:43 +00:00

33 lines
991 B
Bash

# Copy to .env and fill in values. Never commit .env.
# Server
NODE_ENV=development
HOST=0.0.0.0
PORT=3200
LOG_LEVEL=info
# Database
DATABASE_URL=postgresql://errors:password@localhost:5432/errors_bitreport
# JWT — generate with: openssl rand -base64 64
JWT_SECRET=change_me_in_production_64_bytes_minimum
# Cookie signing — generate with: openssl rand -base64 32
COOKIE_SECRET=change_me_in_production_32_bytes_minimum
# Recent-errors for Paperclip (optional — if unset, GET …/recent-errors returns 503 on both CRM paths)
# ERROR_RESOLVE_API_KEY=same_as_CRM_or_shared_hub_secret
# DEBUG_VIEW_ERRORS_KEY=read_only_alternate_query_param_view_errors
# Rate limits (optional — defaults shown)
# RATE_INGEST_MAX=1000
# RATE_INGEST_WINDOW_MS=60000
# RATE_LOGIN_MAX=10
# RATE_LOGIN_WINDOW_MS=300000
# RATE_GLOBAL_MAX=500
# RATE_GLOBAL_WINDOW_MS=60000
# Payload limits (optional — defaults shown)
# INGEST_MAX_BODY_BYTES=524288 # 512 KB
# ADMIN_MAX_BODY_BYTES=65536 # 64 KB