gerrit-api

Automate Gerrit Code Review change queries, diff retrieval, and review posting via REST API.

1|Updated Apr 20, 2026
One-click install
npx skills add https://github.com/vancebs/skills --skill gerrit-api
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gerrit-api
Source: https://github.com/vancebs/skills/tree/main/gerrit-api
Command: npx skills add https://github.com/vancebs/skills --skill gerrit-api

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires curl, jq, python3, base64, and includes scripts (resource) components.

What problem does it solve?

Interact with Gerrit Code Review REST API to automate change querying, read diffs, post reviews, and manage lifecycle.

Core Features & Use Cases

  • Interact with Gerrit REST API to query open changes, read diffs, post code reviews, and manage change lifecycle (submit, abandon, restore).
  • Added config file support so multiple agents can each maintain credentials without conflicting environment variables.
  • Suitable for automation in CI/CD pipelines and developer workflows.

Quick Start

Run the gerrit_api.sh script with a sample query to list open changes.

Frequently Asked Questions about gerrit-api

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate Gerrit code reviews via REST API?

Automating Gerrit code reviews through the REST API involves using a script-based CLI to query changes, read diffs, post reviews, and manage lifecycles. It relies on curl, jq, and base64 for execution, with authentication handled via config file or environment variables.

Can I query open Gerrit changes and retrieve diffs from a CI/CD pipeline?

Yes, querying open Gerrit changes and retrieving diffs from a CI/CD pipeline is supported. The script-based CLI interfaces directly with the Gerrit REST API to fetch change data and diffs, fitting seamlessly into automated developer workflows.

Does the Gerrit REST API automation support submitting and abandoning changes?

Yes, Gerrit REST API automation supports managing the full change lifecycle, including submitting, abandoning, and restoring changes. You can execute these actions programmatically via shell scripts to update change statuses within your CI/CD pipelines.

Do I need curl and jq to run the Gerrit API automation scripts?

Yes, curl and jq are required dependencies, alongside python3 and base64, to run the Gerrit API automation scripts. These tools manage the HTTP requests, JSON parsing, and data encoding necessary for interacting with the Gerrit REST API.

What is the best way to manage Gerrit credentials for multiple agents?

Using a config file is the best way to manage Gerrit credentials for multiple agents. This approach allows each agent to maintain its own credentials independently, avoiding conflicts with system environment variables during REST API authentication.