How fxcircus/frontegg-hosted-login-customization-server works
Project type and purpose
• It is typically deployed as a microservice on a hosting platform (Heroku, AWS Lambda, etc.) and sits between the Frontegg login widget and your custom styling configuration.
File structure
• Top-level files only:
– server.js – the Express (or plain HTTP) server implementation
– package.json & package-lock.json – npm dependencies (likely express)
– README.md – project description & usage
– .gitignore
• No subdirectories: this is a single Node.js service with a single endpoint.
README for additional insights
• No database or complex internal components—just a JSON payload provider.
a. Main components:
2. CI/CD or Manual Deployment – pushes code from Git to hosting (Heroku, Lambda).
3. Node.js service (server.js) – exposes GET /overrides endpoint.
5. Optional: Monitoring/Logging service (e.g., Papertrail, CloudWatch).
b. Relationships and interactions:
• Developer → (Git push) → CI/CD system → (deploy) → Hosting Platform
• Browser → (GET https://your-server/overrides) → Node.js service → (200 OK JSON) → Browser
c. Architectural pattern:
• Simple microservice / API endpoint pattern
• Stateless HTTP service
• Hosted independently of Frontegg application
d. Technologies/Frameworks:
• Node.js & Express (or built-in HTTP module)
• npm
• Hosting platform (Heroku, AWS Lambda, Azure Functions, etc.)
• Frontegg SDK running in the client
Detailed call flow to capture
2. Developer deploys server.js to chosen platform.
3. In Frontegg environment settings, set “metadataOverrides.url” to your endpoint.
4. End user visits the Frontegg login URL → browser loads JS widget.
5. Widget calls GET /overrides → Node.js returns override JSON → browser renders customized UI.