Railway

Deploy OfferKit

Self-hosted engine for coupons, loyalty, referrals, and gift cards.

Deploy OfferKit

/var/lib/postgresql/data

Just deployed

Just deployed

Just deployed

/data

Deploy and Host OfferKit on Railway

OfferKit is an open-source promotion engine for coupons, gift cards, loyalty, referrals, customer segments, validation rules, and stackable redemptions. It includes a dashboard, REST API, TypeScript SDK, CLI, and MCP server, giving developers a self-hosted way to manage promotion logic across products and checkout flows.

About Hosting OfferKit

Hosting OfferKit on Railway provisions the core services needed to run the promotion engine in production: a public web service, a private background worker, PostgreSQL for durable application data, and Redis for job processing. The web service serves the dashboard, API, and docs, while the worker handles async jobs such as webhook delivery, bulk code generation, and loyalty expiration. OfferKit runs from a published Docker image, so Railway can deploy it without building the source monorepo. On first boot, the web service runs database migrations and creates the initial admin user from environment variables.

Common Use Cases

  • Run a self-hosted coupon, voucher, gift card, and loyalty engine.
  • Add promotion APIs to an app, commerce platform, or checkout flow.
  • Manage customer segments, validation rules, referrals, and stackable redemptions.

Dependencies for OfferKit Hosting

  • Railway account with Postgres and Redis services.
  • OfferKit Docker image from GitHub Container Registry.
  • Admin email, admin password, and Better Auth secret for first boot.

Deployment Dependencies

Implementation Details

This template runs two services from the same OfferKit image:

  • web: public Next.js dashboard, REST API, and docs on port 3000.
  • worker: private background worker using node apps/worker/dist/index.js.

The web service health check is /api/v1/ready. The worker health check is /health. Set DATABASE_URL and REDIS_URL on both services. Set BETTER_AUTH_SECRET, OFFERKIT_PUBLIC_URL, ADMIN_EMAIL, and ADMIN_PASSWORD on the web service.

Why Deploy OfferKit on Railway?

Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.

By deploying OfferKit on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.


Template Content

More templates in this category

View Template
Rocky Linux
[Jun'26] Hosted Rocky Linux 9 workspace with SSH and persistent storage. 🚀

codestorm
View Template
Foundry Virtual Tabletop
A Self-Hosted & Modern Roleplaying Platform

Lucas
View Template
Letta Code Remote
Run a Letta Code agent 24/7. No inbound ports, just deploy.

Letta