feat(api-gateway): add Swagger, admin endpoints, and scheduler

- Add Swagger/OpenAPI documentation at /docs endpoint
- Add admin module for system-wide API key management
- Add scheduler for monthly credit reset and usage cleanup
- Add Docker Compose entry for Mac Mini deployment
- Document all endpoints with descriptions and examples
This commit is contained in:
Till-JS 2026-01-29 18:03:16 +01:00
parent 4b322f59b1
commit fc0ed636fc
21 changed files with 1059 additions and 1 deletions

View file

@ -103,6 +103,42 @@ services:
retries: 3
start_period: 40s
# ============================================
# API Gateway (Monetization)
# ============================================
api-gateway:
image: ghcr.io/memo-2023/api-gateway:latest
container_name: mana-api-gateway
restart: always
depends_on:
mana-core-auth:
condition: service_healthy
postgres:
condition: service_healthy
redis:
condition: service_healthy
environment:
NODE_ENV: production
PORT: 3030
DATABASE_URL: postgresql://postgres:${POSTGRES_PASSWORD:-manacore123}@postgres:5432/manacore
REDIS_HOST: redis
REDIS_PORT: 6379
REDIS_PASSWORD: ${REDIS_PASSWORD:-redis123}
MANA_CORE_AUTH_URL: http://mana-core-auth:3001
SEARCH_SERVICE_URL: http://mana-search:3021
STT_SERVICE_URL: http://mana-stt:3020
TTS_SERVICE_URL: http://mana-tts:3022
CORS_ORIGINS: https://api.mana.how,https://mana.how
ports:
- "3030:3030"
healthcheck:
test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://127.0.0.1:3030/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
# ============================================
# ManaCore Dashboard
# ============================================