ReviewBot
nberdi/ReviewBot
Revisão automática de PRs com IA diretamente no GitHub
Ver no GitHubGitHub App alimentado por IA que executa revisões automáticas de pull requests e posta comentários inline precisos no código. Integra-se com Claude da Anthropic para analisar mudanças e identificar problemas de segurança, qualidade e padrões de código.
Instalação
npx convez-ai nberdi/ReviewBot1 comando no terminal: detecta o formato do repositório (marketplace ou plugin avulso) e instala via Claude Code. Requer Node 18+ e o Claude Code instalado.
Métricas
Casos de uso
- Automatizar revisão de código em equipes de desenvolvimento
- Identificar vulnerabilidades de segurança antes do merge
- Enforçar padrões de qualidade e boas práticas em pull requests
Veredito

Solução prática e bem documentada para automatizar code reviews em GitHub usando Claude. Reduz overhead de revisão manual e captura problemas de segurança cedo, porém exige setup inicial de GitHub App e integração com Anthropic.
README
A tradução para o português deste README ainda está na fila.
ReviewBot
What is ReviewBot
ReviewBot is a GitHub App that automatically performs AI-powered code review on pull requests. It fetches changed lines from each PR, asks Anthropic Claude to identify high-signal issues, and posts precise inline comments on the affected code.
How It Works
When a pull request is opened or updated, GitHub sends a signed webhook event to ReviewBot. ReviewBot verifies the webhook signature, fetches the pull request diff through the GitHub API, parses the diff into changed files and added line numbers, sends those added lines to Claude for review, validates Claude's JSON response, and posts each issue as an inline pull request review comment on the exact file and line.
Tech Stack
- Node.js
- TypeScript
- Express
- Octokit
- Anthropic Claude
- Railway
Prerequisites
- Node.js 18+
- A GitHub account
- An Anthropic API key
Step 1 — Clone and Install
git clone https://github.com/your-username/reviewbot.git
cd reviewbot
npm install
Step 2 — Create the GitHub App
- Go to github.com/settings/apps/new
- GitHub App name: ReviewBot (or any name)
- Homepage URL: your deployed URL (or http://localhost:3000 for now)
- Webhook URL: your deployed URL + /webhook
- Webhook secret: generate a random string, save it as GITHUB_WEBHOOK_SECRET
- Permissions needed — Repository permissions:
- Pull requests: Read & Write
- Contents: Read-only
- Subscribe to events: Pull request
- Where can this be installed: Only on this account
- Click Create GitHub App
- On the app page: note the App ID, save it as GITHUB_APP_ID
- Generate a private key, download the .pem file
- Convert it for the env var:
Save the output as GITHUB_PRIVATE_KEYawk 'NF {sub(/\r/, ""); printf "%s\\n",$0;}' your-key.pem - Install the app on your own repositories
Step 3 — Configure Environment
cp .env.example .env
Fill in all values in .env.
Step 4 — Run Locally with a Tunnel
npm run dev
Use ngrok or smee.io to expose localhost:3000 to the internet for webhook delivery during development:
npx smee-client --url https://smee.io/your-channel --target http://localhost:3000/webhook
Step 5 — Deploy to Railway
- Push to GitHub
- Create new Railway project from repo
- Add environment variables
- Deploy — Railway auto-detects the Procfile
How to Test It
Open a PR on a repo where ReviewBot is installed. ReviewBot will automatically post inline comments within seconds.
Example Review Comment
[Security] eval() executes arbitrary code and is a critical security vulnerability. Replace with a safe alternative such as JSON.parse() for data or a proper expression parser library.
Environment Variables
| Variable | Description | Where to find it |
|---|---|---|
| GITHUB_APP_ID | GitHub App ID used to authenticate as the app. | GitHub App settings page after app creation. |
| GITHUB_PRIVATE_KEY | GitHub App private key with newlines converted to \n. | Download from the GitHub App settings page, then convert with the README command. |
| GITHUB_WEBHOOK_SECRET | Shared secret used to verify webhook signatures. | The random webhook secret you set while creating the GitHub App. |
| ANTHROPIC_API_KEY | API key used to call Claude. | Anthropic Console. |
| PORT | HTTP port for the Express server. | Set by Railway in production or use 3000 locally. |