Codecov CLI
$ codecovcli Official Low RiskCodecov CLI (codecovcli) replaces legacy uploaders with an official Python CLI supporting create-commit, create-report, do-upload, and pr-base-picking. Built for CI pipelines and local coverage verification with --dry-run and --fail-on-error flags.
brew install codecov-cli codecovcli discovers local coverage.xml/lcov.info files via plugins (gcov, pycoverage, xcode) and uploads them from build runners; MCP servers cannot access local build artifacts directly.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
Runs non-interactively with Click --help and --dry-run, though it lacks a --json output mode for API responses.
- Non-interactive execution via
CODECOV_TOKENand CI env detection - No
--jsonstructured output flag across subcommands
Includes --dry-run and --fail-on-error (-Z), and does not modify local source files or store persistent user credentials.
- Supports
do-upload --dry-runand-Z/--fail-on-error
Available via Homebrew, PyPI (pip install codecov-cli), and standalone PyInstaller binaries, though PyPI requires Python 3.10+.
- Distributed via
brew install codecov-cli, PyPI, andcli.codecov.io
Handles coverage discovery, commit registration, Test Analytics, and PR base-picking in one tool.
- Supports
create-commit,do-upload, andpr-base-picking
Official Codecov repository (codecov/codecov-cli) licensed under Apache-2.0.
- Maintained directly by Codecov
Documented on docs.codecov.com and README, though CLI reference pages are thinner on JSON/schema contracts.
- Official docs and Click CLI
--helpoutput
Security, Auth & Guardrails
Reads CODECOV_TOKEN from environment variables or --token CLI flag, and honors repository settings in codecov.yml without storing persistent local login state.
Apache-2.0 open-source CLI; Codecov is free for public repositories and paid for private org seats.
# Codecov CLI (codecovcli) Agent Rules - Always test discovery first with `codecovcli do-upload --dry-run` before live uploads. - Supply `CODECOV_TOKEN` via environment variable instead of passing `--token` in shell history. - Add `--fail-on-error` in CI steps so silent upload errors do not pass checks.
Agent-Ready Command Recipes
Safe Read-Only Queries
codecovcli do-upload --help
Displays supported coverage file discovery, plugin, and dry-run options without contacting Codecov.
Controlled Writes & Previews
codecovcli do-upload --dry-run --fail-on-error
Runs local coverage file detection and report assembly without uploading anything to Codecov.
Strengths for Agents
- +
do-upload --dry-runvalidates local coverage file detection before sending data to Codecov. - + Automatic CI provider detection (
github,gitlab,bitbucket) simplifies pipeline invocation.
Caveats & Pitfalls
- ! Does not expose a
--jsonoutput flag, requiring log text parsing if agents inspect upload summaries. - ! Focused on coverage/test upload workflows rather than querying historical Codecov dashboard metrics.