Api Only Deploy
API-Only Deployment
Deploy your Dex app as an API backend without serving the frontend.
Build
bun run buildRun API-Only
cd build
DEX_API_ONLY=1 ./serverWhat Changes
- No static assets served
- No SPA fallback
- Only
/api/*routes work - Smaller memory footprint
Use Cases
- API gateway
- Separate frontend deployment
- Backend-only microservice
Example: Deploy to Railway
# Set environment
railway variables set DEX_API_ONLY=1
# Deploy
railway upSee Also
- Production Deployment — Full deployment guide
- Recipes Index — Other recipes