Skip to content

Environments

These pages use production hosts. Paths, headers, and request bodies are the same on every environment. Only the hostname changes.

WhatProductionStaging
Site, browse UI, Git HTTPShttps://amendable.iohttps://stage.amendable.io
Sign upamendable.io/sign-uphttps://stage.amendable.io/sign-up
REST APIhttps://api.amendable.iohttps://stage.api.amendable.io
OpenAPI UIapi.amendable.io/docshttps://stage.api.amendable.io/docs
Clone URLhttps://amendable.io/r/<user>/<repo>.githttps://stage.amendable.io/r/<user>/<repo>.git
BYO S3 OIDC issuerhttps://oidc.amendable.iohttps://stage.oidc.amendable.io

OIDC trust policies are hostname-specific. Copy issuer, audience, and subject from GET /v1/storage-buckets/oidc-setup on the environment you are calling.

Defaults are production. Override with env vars or --staging:

Terminal window
export AMENDABLE_API_URL=https://stage.api.amendable.io
export AMENDABLE_APP_URL=https://stage.amendable.io
amendable repo list
Terminal window
amendable login --staging
amendable --staging repo list

login --staging writes those hosts into ~/.config/amendable/config.toml.

api_url = "https://stage.api.amendable.io"
app_url = "https://stage.amendable.io"

Git credential helper for staging:

Terminal window
git config --global credential.https://stage.amendable.io.helper '!amendable git-credential'
Terminal window
export AMENDABLE_API_URL=https://stage.api.amendable.io
curl -sS "$AMENDABLE_API_URL/v1/account/usage" \
-H "access-token: $AMENDABLE_TOKEN"

The CLI reads AMENDABLE_API_URL and AMENDABLE_APP_URL. Those override the config file.

Terminal window
PUBLIC_DOCS_ENV=staging npm run build

That rewrites production hostnames in the built site. The Markdown in git stays on production. Default PUBLIC_DOCS_ENV is production.