caput.dev configure your bot →

Deploy on Railway

Railway is the recommended host. Persistent process, simple billing, around $5/month.

Why Railway

Prerequisites

Steps

1. Create a new Railway project

Sign in to Railway. From your dashboard, click New ProjectEmpty Project.

Name the project something like caput-bot.

2. Upload your bundle

Two options:

Option A — Railway CLI (recommended).

Install the Railway CLI:

npm install -g @railway/cli

Log in:

railway login

In the directory where you extracted the bundle:

railway link
railway up

Railway uploads your project and starts deploying.

Option B — Push to GitHub, link to Railway.

Initialize a git repo in your bundle directory, push to a private GitHub repo, then in Railway click + NewGitHub Repo and select it.

3. Set environment variables

In the Railway project's Variables tab, add the contents of your config.env file as individual variables. The bundle's config.env is the source of truth — every line in there should become a Railway variable.

Important variables to verify or update:

4. Configure networking

In SettingsNetworking:

The bot's internal admin UI runs on a separate port (default 7777) which is not exposed publicly. Only the public-facing invitation URLs are reachable from the internet.

5. Set up uptime monitoring

The bot must stay live for the full lifecycle of every active contract. Railway auto-restarts on crash, but a network partition or platform outage could still leave the bot unreachable.

Add an uptime monitor (UptimeRobot, BetterStack, or similar) hitting your bot's /health endpoint every 1–5 minutes. Configure it to alert you via email or push when the bot becomes unreachable.

6. First-run setup

Once deployed, find your Railway domain and reach the bot's admin UI:

7. Test on testnet

Before writing any real contract, generate a test invitation on testnet, deploy a small position, and watch it go through the full lifecycle. Some things to verify:

Only after successful testnet runs, set XRPL_NETWORK=mainnet and restart.

Costs

Updating

When a new caput release comes out, you re-deploy:

  1. Download the new bundle from caput.dev (with whatever uses you have left).
  2. Replace the bundle's contents in your Railway project.
  3. Run railway up again or trigger a redeploy from the dashboard.

The bot's state (open positions, uses consumed) lives in SQLite at the project's persistent volume. Railway preserves this across deploys.

Support

Railway-specific support: Railway's docs at docs.railway.app, or their Discord.

Caput-specific issues: read the source on GitHub. We do not provide support tickets.