Deploy Paperclip - AI Agent Company

Open-source control plane for AI agents. Includes managed Postgres

Deploy Paperclip - AI Agent Company

/var/lib/postgresql/data

Just deployed

/paperclip

Deploy and Host Paperclip on Railway

Paperclip is an open-source AI agent orchestration platform for building and running autonomous agent companies. Define roles, assign tasks, set budgets and heartbeats, and let AI agents handle the execution. Connect Claude, Gemini, or OpenAI-compatible agents to a structured org chart, task queue, and governance layer.

About Hosting Paperclip

Paperclip needs a persistent server, a PostgreSQL database, and a public HTTPS URL for agent heartbeats and the web UI. This template wires all three automatically: a managed Railway Postgres database is pre-connected via DATABASE_URL, a volume is mounted at /paperclip for persistent config and storage, and the public Railway domain is injected at deploy time. There's no setup page or config file to edit. The bootstrap admin invite URL appears in the service logs, and sign-up closes automatically once your admin account is created.

Common Use Cases

  • Running a fully autonomous AI agent company with org charts, task assignments, and per-agent budgets
  • Orchestrating multiple LLM-backed agents (Claude, Gemini, OpenAI) from a single dashboard
  • Importing pre-built agent company definitions from companies.sh with a single command
  • Self-hosting Paperclip with production-grade PostgreSQL and persistent storage

Dependencies for Paperclip Hosting

  • Railway Postgres, pre-wired via DATABASE_URL
  • An API key from at least one LLM provider: Anthropic (ANTHROPIC_API_KEY), OpenAI (OPENAI_API_KEY), or Google Gemini (GEMINI_API_KEY)

Deployment Dependencies

Implementation Details

The template builds on the official ghcr.io/paperclipai/paperclip:latest image and keeps its startup chain intact: tini reaps agent subprocesses, the upstream entrypoint fixes volume ownership and drops to an unprivileged user, and Paperclip runs its production server. A small wrapper script adds three things a headless public deployment needs:

  1. Writes a minimal config.json on first boot (authenticated mode, public URL, database mode). Secrets and DATABASE_URL stay in Railway Variables.
  2. Prints the bootstrap admin invite URL to the logs. Search the deploy logs for invite; the invite expires after 72 hours.
  3. Closes sign-up once the admin account exists. The service restarts once to apply this, and the logs show entrypoint: admin claimed, restarting to disable sign-up. To keep sign-up open (e.g. to invite teammates), set PAPERCLIP_AUTH_DISABLE_SIGN_UP=false in Railway Variables.

The service uses /api/health as its healthcheck and the Always restart policy, which the sign-up lockdown relies on.

LLM adapter reference:

ProviderAdapterEnvironment Variable
Anthropicclaude_localANTHROPIC_API_KEY
OpenAIopencode_localOPENAI_API_KEY
Geminiopencode_localGEMINI_API_KEY

For Gemini, select opencode_local as the adapter in agent settings and choose your model. The gemini_local adapter requires interactive OAuth and won't work in a Railway container.

Why Deploy Paperclip 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 Paperclip 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
Chat Chat
Chat Chat, your own unified chat and search to AI platform.

okisdev
117
View Template
Weaviate
Vector database with hybrid search and an API key-protected API

zer0person
1
View Template
Möbius v0.1 Personal AI OS
Self-hosted AI agent that builds and runs apps for you, with memory.

bento
1