GITHUB ACTION · API
See deployment risks before you merge.
The same static analysis as the website, on a pull request before Vercel builds it. Findings land as annotations on the changed files and one updated PR comment links the full report. The job summary remains available, and the check goes red on a definite problem. Static analysis through the GitHub API: nothing is cloned, installed or executed, and no build step is needed.
1. Add the workflow. Free on public repositories.
Save this as .github/workflows/deploydoctor.yml. No account, no token, no secret: the id-token: write permission lets GitHub sign a short-lived proof of which repository is asking, and DeployDoctor only scans that repository. Each public repository gets 1 free scan a day; when it is used, the job warns and passes instead of blocking the pull request.
name: DeployDoctor
on:
pull_request:
concurrency:
group: deploydoctor-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
deploydoctor:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write # maintains one PR conversation comment
id-token: write # lets GitHub prove which public repo is asking; no account, no secret
steps:
- uses: jonjys/deploydoctor-action@ef4c69e41868bf712b6dab3ccc1ea123eb4037c0The workflow pins the PR Change Review release to an immutable commit. Existing workflows using an older version must update the Action reference and add pull-requests: write to get comments.
Also listed on the GitHub Marketplace.
Maintaining a template or starter? Every public report also offers a Scan with DeployDoctor button for its README. Forks keep the README text, so a fork changes the owner/repo in the link to scan its own copy before the first deploy.
2. Private repository or more than 1 scan a day
Open My scans in the browser you paid in and click Create API token. Tokens work while a pass is active, which is any pass: $2 for 24 hours, $5 for 7 days or $9 a month, and are never subject to the daily limit. Store it as a repository secret named DEPLOYDOCTOR_TOKEN under Settings, Secrets and variables, Actions.
- uses: jonjys/deploydoctor-action@ef4c69e41868bf712b6dab3ccc1ea123eb4037c0
with:
token: ${{ secrets.DEPLOYDOCTOR_TOKEN }}
# Private repository? Let the scan read it:
github-token: ${{ github.token }}For a private repository, pass github-token so the scan can read it. The job's own token has read access to the repository, is forwarded for that one scan and is never stored. Private reports open only in the browser you paid in, or through your API token.
What the check does
- Fails the job when a check is red: an import that only resolves on macOS, a package that is used but not declared, a
process.envread without a fallback that no.env.exampledocuments, a Node-only module on the Edge runtime, Prisma withoutprisma generate, a live secret in source. - Annotates each finding on the file and line in the pull request, with the fix.
- Maintains one PR conversation comment with up to three ranked findings, the analyzed commit, file/line links and the full report. Partial scans say so. An exhausted allowance replaces stale results with Not scanned.
- Writes a status table to the job summary and links the saved report.
- Sets outputs
overall,report-url,redandyellowfor later steps.
Inputs: fail-on (red by default, yellow to also fail on items that need review, never to only report),checks (comma-separated next, vercel, env, supabase, prisma; the detected stack decides when empty),ref and repository to scan something other than the pull request.
What changed in this PR?
For a matching same-repository PR head, the Action compares static findings at the PR merge base and head. Newly detected findings appear first; already-present findings and observations no longer detected stay separate. Moving lines are matched, known file renames are accounted for, and incomplete coverage requires review. Both commits are pinned.
The comparison uses one existing scan allowance. It does not build the merged app or certify a fix. The job still applies fail-on to the full head scan, including existing problems.
Deploy Handoff: Compare a PR to get a manual release checklist for newly referenced environment names, migration files, deployment configuration, build commands and endpoint source changes. Each task links to its pinned commit. Copy it to your release issue or coding assistant; actual production setup and runtime still need verification.
Comments are supported for same-repository pull requests on the scanned head commit. Forks, Dependabot, closed PRs, other events and ref overrides are not commented. Do not use pull_request_target to bypass these restrictions.
The built-in GitHub token stays in the runner and is used only for GitHub comments. A missing write permission produces a warning; scan results remain in the job summary. Private reports retain their existing authentication.
Set comment: false to disable conversation comments, or audit-link: false to remove the discreet link to the existing optional €149 human audit. No new price or subscription is introduced.
Workflow concurrency prevents competing runs. The Action rechecks the live PR head before writing, but GitHub does not provide an atomic head condition for comment updates. Each comment always identifies its exact analyzed commit.
The API behind it
The action is a thin client. Any script can do the same with the token: POST a repository URL and an optional ref and get the whole report as JSON, including every finding with file and line.
curl -s -X POST https://deploydoctor.nyttolabs.com/api/reports \
-H "Authorization: Bearer $DEPLOYDOCTOR_TOKEN" \
-H "Content-Type: application/json" \
-d '{"repoUrl":"https://github.com/vercel/commerce","ref":"main"}'Responses: 201 with the report, 401 for a token that does not verify, 402 when no pass is active, 404 for a missing repository or ref, 429 when GitHub's own rate limit is hit. A saved report is also readable as JSON at /api/reports/<id>, public ones with no token at all. Token requests never count against the free daily limit, so a shared runner IP does not matter.
What it does not do
It does not run your build, so it cannot catch type errors or failing tests; your existing jobs do that. It reads the repository through GitHub's API with a file and time budget, and marks a scan partial when it hits one. A green check means the applicable static checks passed, not that the deploy will succeed.
Updated 2026-11-03 · GitHub Marketplace · Action source