Railway

Deploy Agent Artifact Engine

Self-hostable HTML and safe MDX artifact publishing for AI agents.

Deploy Agent Artifact Engine

Just deployed

/data

Deploy and Host Agent Artifact Engine on Railway

Agent Artifact Engine is a self-hostable service for publishing immutable HTML and safe MDX artifacts from AI agents. It provides a simple publish API, public and unlisted viewer pages, private share links, sandboxed raw artifact rendering, and persistent file-backed storage without requiring a hosted SaaS platform.

About Hosting Agent Artifact Engine

Hosting Agent Artifact Engine on Railway runs the Node/Fastify server with a persistent Railway Volume mounted at /data. Published artifacts, metadata, source files, and rendered HTML are stored on that volume so data survives deploys and restarts. Railway provides the public HTTP endpoint, health checks, restart handling, and environment variables. The template only requires a generated PUBLISH_TOKEN; optional settings can tune file size limits, script sandboxing, custom domains, and storage paths.

Common Use Cases

  • Publish and share AI-generated HTML reports, dashboards, demos, or documents.
  • Host a private artifact vault for agent workflows, prototypes, and review links.
  • Provide a lightweight self-hosted alternative to pastebins, markdown docs, or ad hoc static files.

Dependencies for Agent Artifact Engine Hosting

  • Node.js 22 runtime
  • Railway Volume mounted at /data

Deployment Dependencies

Implementation Details

Required variable:

PUBLISH_TOKEN=${{ secret(64) }}

Optional variables:

DATA_DIR=/data
MAX_SOURCE_BYTES=1048576
ARTIFACT_ALLOW_SCRIPTS=false
PUBLIC_BASE_URL=https://custom-domain.example
ARTIFACT_BASE_URL=https://custom-domain.example

Recommended service settings:

HTTP networking enabled
Healthcheck path: /health
Volume mount path: /data
Restart policy: ON_FAILURE
Max retries: 3

Agent Artifact Engine automatically detects Railway’s public domain and mounted volume path. DATA_DIR=/data can be set explicitly, but is not required when the Railway Volume mount path is available.

Why Deploy Agent Artifact Engine 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 Agent Artifact Engine 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
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
View Template
(v1) Simple Medusa Backend
Deploy an ecommerce backend and admin using Medusa

Shahed Nasser