Amend.sh

Self-Hosting

Run Amend with your own deployment, provider keys, and docs URL.

Self-hosting keeps the same product loop while moving ownership of runtime, secrets, model policy, and DNS to your infrastructure.

Deployment pieces

PieceResponsibility
Web appDashboard, portal routes, embed demo, auth surfaces
Fumadocs appDocumentation, launch guidance, integration reference
Convex backendData model, HTTP actions, auth integration, automation state
ProvidersGitHub, email, billing, AI model, custom domains

You can deploy docs as a subpath, a subdomain, or a separate instance. Keep the app link portable with VITE_DOCS_URL.

Local shape

Local development uses portless names:

http://amend.localhost:1355
http://docs.amend.localhost:1355/docs

The web app should point at the docs app through:

VITE_DOCS_URL=http://docs.amend.localhost:1355/docs

Production shape

Choose one docs route before shipping public links:

PatternVITE_DOCS_URL
Same app proxy/docs
Main-site proxyhttps://amend.sh/docs
Docs subdomainhttps://docs.amend.sh/docs
Separate docs hosthttps://amend-docs.example.com/docs

If the route changes later, update the environment variable and redeploy the web app. Product code should not need edits.

API Base URL

Customer-owned products should point SDK and server calls at the Convex HTTP action origin:

AMEND_API_BASE_URL=https://your-production-convex.convex.site/api/v1

Use AMEND_API_TOKEN only in trusted server code, CLI automation, or owner tools.

Provider keys

Production should configure these outside the client bundle:

  • BETTER_AUTH_SECRET
  • GITHUB_WEBHOOK_SECRET
  • GitHub App ID, slug, client ID, client secret, and private key
  • AMEND_API_TOKEN
  • POSTHOG_API_KEY and POSTHOG_HOST
  • VITE_POSTHOG_TOKEN, VITE_POSTHOG_HOST, and VITE_POSTHOG_PROJECT_ID
  • OPENAI_API_KEY and OPENAI_MODEL
  • RESEND_API_KEY and EMAIL_FROM
  • STRIPE_SECRET_KEY and STRIPE_WEBHOOK_SECRET

Readiness

Run local readiness during setup:

bun run readiness

Run strict readiness only with production secrets available:

bun run readiness:strict

Local green checks mean the repo wiring works. They do not prove DNS, webhook delivery, auth callbacks, billing webhooks, or email sending in production.

On this page