avr sbom
View, generate, and download repository SBOMs.
avr sbom [OPTIONS] COMMAND [ARGS]...Subcommands
Section titled “Subcommands”avr sbom download
Section titled “avr sbom download”Download an SBOM artifact (CycloneDX, SPDX, or dependency inventory).
avr sbom download [OPTIONS] [COMMIT]COMMIT is the commit of a recorded SBOM, as a full SHA or a unique prefix
of at least 7 characters such as the one avr sbom list shows. Defaults to
the latest SBOM.
Examples: avr sbom download --repo acme/api avr sbom download --repo acme/api --format spdx --out api.spdx.json avr sbom download 3f2c9a1b7d04 --repo acme/api --out - | jq .componentsArguments
[COMMIT]
Options
--repo, -R<TEXT>— Repository (org/repo or rep-xxx). Auto-detected from git remote if omitted.--org, -o<TEXT>— Organization ID or slug. Uses default org if not specified (see: avr config set org).--commit<TEXT>— Same as the COMMIT argument.--format<CHOICE>— Artifact to download. (choices:cyclonedx,inventory,spdx· default:cyclonedx)--out<TEXT>— Output file path, or "-" for stdout. Defaults to the artifact filename in the current directory.
avr sbom generate
Section titled “avr sbom generate”Start SBOM generation for a repository.
avr sbom generate [OPTIONS] [REF]REF is the branch, tag, or commit SHA to analyse; an abbreviated SHA such
as the one avr sbom list shows works too. Defaults to the default-branch
tip. Without --wait, commit_sha is the full SHA of the commit the run
analyses when REF is a full SHA or one the API expanded.
One analysis runs per repository at a time. A request for the same ref as the analysis already running joins it; a request for a different ref is rejected (HTTP 409) until that analysis finishes. Once an SBOM has been recorded for the repository, a new run is refused (HTTP 429) for a cooldown period, and the error says how many seconds remain.
With --wait and a REF that names a commit, success means a new SBOM for that commit is downloadable, whatever the analysis task's own outcome (task_status); commit_sha and recorded_at identify it. A failed analysis can still deliver its SBOM later, so such a wait runs to --wait-timeout before reporting failure. For a branch, tag, or the default branch the API does not say which commit the run resolved, so --wait reports the analysis task's outcome only. Transient errors while waiting are retried until --wait-timeout; a wait that times out leaves the analysis running.
Examples: avr sbom generate --repo acme/api avr sbom generate v1.4.0 --repo acme/api avr sbom generate 3f2c9a1b7d04 --repo acme/api --waitJSON FIELDS ai_task_id, commit_sha, error_code, recorded_at, status, task_statusArguments
[REF]
Options
--repo, -R<TEXT>— Repository (org/repo or rep-xxx). Auto-detected from git remote if omitted.--org, -o<TEXT>— Organization ID or slug. Uses default org if not specified (see: avr config set org).--ref<TEXT>— Same as the REF argument.--wait— Wait until generation finishes before returning.--wait-timeout<INTEGER RANGE>— Seconds to wait when --wait is set. (default:900)--json<TEXT>— Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.-q, --jq<TEXT>— Filter --json output through a jq expression.
avr sbom list
Section titled “avr sbom list”List the repository's recorded SBOMs, newest first.
avr sbom list [OPTIONS]Counts shown as "?" were not recorded by the SBOM's schema version.
Examples: avr sbom list --repo acme/api avr sbom list --repo acme/api --json commit_sha,copyleft_countJSON FIELDS artifacts, branch, commit_sha, copyleft_count, generated_at, is_release, recorded_at, schema_version, total_dependencies, unresolvedOptions
--repo, -R<TEXT>— Repository (org/repo or rep-xxx). Auto-detected from git remote if omitted.--org, -o<TEXT>— Organization ID or slug. Uses default org if not specified (see: avr config set org).-L, --limit<INTEGER RANGE>— Max SBOMs to return. (default:50)--cursor<TEXT>— Opaque cursor from a previous response's next_cursor.--json<TEXT>— Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.-q, --jq<TEXT>— Filter --json output through a jq expression.
avr sbom view
Section titled “avr sbom view”Show an SBOM's summary: dependency counts, licenses, and artifacts.
avr sbom view [OPTIONS] [COMMIT]COMMIT is the commit of a recorded SBOM, as a full SHA or a unique prefix
of at least 7 characters such as the one avr sbom list shows. Defaults to
the latest SBOM.
A long license table is cut to the most common licenses and a long copyleft list to its first names; --full lists all of them. Long license names are clipped; the summary in --json carries them whole.
Examples: avr sbom view --repo acme/api avr sbom view 3f2c9a1b7d04 --repo acme/api avr sbom view --repo acme/api --full avr sbom view --repo acme/api --json summary --jq .summary.licensesJSON FIELDS artifacts, branch, commit_sha, generated_at, is_release, recorded_at, schema_version, summaryArguments
[COMMIT]
Options
--repo, -R<TEXT>— Repository (org/repo or rep-xxx). Auto-detected from git remote if omitted.--org, -o<TEXT>— Organization ID or slug. Uses default org if not specified (see: avr config set org).--commit<TEXT>— Same as the COMMIT argument.--full— List every license and copyleft dependency in the summary. Long lists are otherwise cut to the 10 most common licenses and the first 10 copyleft dependencies.--json<TEXT>— Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.-q, --jq<TEXT>— Filter --json output through a jq expression.