Generate a CI skip plan
Requires the Generate Dynamic CI plans permission.
Returns a per-job verdict for one workflow run: which jobs the change makes it safe to skip, and the evidence behind each decision. Normally called once per run by the trunk-io/dynamic-ci action, which maps the verdicts onto job outputs.
Fail open. A job absent from jobs must be run — that is the contract, not an error. Treat any non-200 the same way.
Send the changed files as changedFiles when you can compute them. Without it, Trunk fetches the diff between baseSha and commitSha through your GitHub App installation, which needs both commits on GitHub.
Authorizations
An API key, sent as Authorization: Bearer <key>. An organization admin creates one in the Trunk app under Settings → Developer → API Keys and chooses the permissions it holds. A key with none can read merge queues but change nothing in them. Permissions cover merge queues and test-result uploads, including the quarantine lookups a CI run makes before it uploads; any key can call the other Flaky Tests and Dynamic CI endpoints, including their writes.
Body
Ignored. Trunk reads the pull request's labels itself when the run asks for a plan. While the repository is in Learning mode, a pull request carrying a label on the repository's managed allow list (matched case-insensitively) is gated as if Dynamic CI were enabled. Accepted so that older clients still validate.
1000256Signals to drop from the tally. An unrecognized identifier is rejected, so a typo surfaces.
64Which independent signal produced a contribution to a job's verdict. These identifiers are also what ignoreSignals accepts.
estimated-cost, previous-result-on-pr, historical-pass-rate, diff-driven-volatility, force-override, merge-failure, mid-pr-stack, required-check, merge-queue-is-required, paths-filter, draft-pull-request, impact-reach The files changed between base and commitSha, diffed from their merge base (base...commitSha). No file contents. Omit it if you cannot compute the diff; never send an empty list in its place. An empty list says nothing changed, which is the strongest evidence to skip. When it is absent, Trunk fetches the diff through your GitHub App installation.
How much of the codebase the change affects, by each measure your own build or dependency tool computes, one entry per source. Jobs with the impact reach signal turned on always run a change that affects everything, lean toward running a broad change and lean slightly toward skipping a narrow one. Omit it when your tool computed nothing; sending nothing leaves every verdict as it is.
8The git blob sha of the workflow file at commitSha (git rev-parse <commitSha>:<workflowPath>). Matrix jobs are pruned only against the parsed version of exactly this file; without it, a matrix job is decided as a whole.
^[0-9a-f]{40}([0-9a-f]{24})?$"51d537a714c0f1c8a4e92b13d5f0e6a7c2b9d8e1"
job.workflow_ref: the workflow file that defines the job this request is sent from. Inside a reusable workflow it names the called file, where workflowPath names the calling one. Omit it when GitHub leaves it empty.
1 - 1024"octo-org/octo-repo/.github/workflows/reusable-tests.yaml@refs/heads/main"
The name GitHub gave the check run checkRunId names (<calling job> / <job> inside a reusable workflow). Inside a reusable workflow called from several jobs it tells them apart. Omit it when the check run could not be read.
1 - 1024"Lint Suite / dynamic-ci"
For matrix jobs whose rows a planner job builds at run time (fromJSON): each job's rows array, by job key, as the exact JSON text the planner emitted. Send the text unchanged; Trunk returns the rows it keeps in the same text. A job is pruned per variation only when its rows are sent and they are its whole matrix. Send at most 64 jobs, 64 KiB and 256 rows per job, and 256 KiB in all; a job over its limits is decided as a whole.
Response
The plan
Why this plan has the shape it does. Absent unless every job runs for a reason jobs cannot express: a not-yet-enabled organization or repository, a CI job experiment branch (trunk-runners/experiments/), an engine outage, or a workflow Trunk has not enumerated — all indistinguishable otherwise, and all arriving as an empty jobs when you request a whole workflow. REPO_IN_SHADOW_MODE is the exception: the plan is fully populated and each summary is the recommendation the job would have received, but nothing is allowed to skip.