ReferenceConfiguration
Environment variables
Every environment variable the Endform CLI reads or sets, from ENDFORM_API_KEY for CI authentication to overrides for the git branch, commit and HTTP headers.
This page lists the environment variables that change how Endform behaves. To find out which of your own environment variables reach the remote runners, see What is sent to runners.
ENDFORM
Endform sets ENDFORM=true in the Node processes it starts to run your tests. Use it to detect that your code is running on Endform:
const isEndform = process.env.ENDFORM === "true";The CLI also sets it on your machine when it evaluates your Playwright config and endform.config.ts, runs global setup and teardown, and starts your webServer commands, so ENDFORM=true does not mean the code is running on a remote runner.
ENDFORM_API_KEY
An organization API key used to authenticate the Endform CLI and local MCP server without interactive login. When set, it takes precedence over a saved endform login session and over GitHub Actions OIDC.
ENDFORM_API_KEY="ef_..." npx endform@latest testStore ENDFORM_API_KEY as a masked secret in CI rather than committing it to your repository. See CI authentication and API keys.
ENDFORM_EXTRA_HTTP_HEADERS
A JSON object of header names and values. It replaces the extraHttpHeaders option of endform.config.ts.
ENDFORM_EXTRA_HTTP_HEADERS='{"x-custom-auth":"env-token"}' npx endform testENDFORM_GIT_BRANCH
The git branch Endform reports for a suite run, instead of the branch it detects.
ENDFORM_GIT_COMMIT_SHA
The git commit SHA Endform reports for a suite run, instead of the commit it detects.
ENDFORM_GIT_DEFAULT_BRANCH
Your repository's default branch, such as main. Endform reads it from GitHub Actions, GitLab CI, Buildkite, the GitHub app or your git checkout. Set it when none of those know it, for example in a shallow checkout on another CI provider.
ENDFORM_MINIMIZE_OUTPUT
Set it to any value to make endform test leave out per-test progress and keep CI logs short.
ENDFORM_MINIMIZE_OUTPUT=1 npx endform@latest testLast updated