OptiBotinho is a GitHub bot. It reviews every pull request with a panel of AI reviewers, merges the safe ones through its own queue, and keeps issues, releases and the team chat in step with the code.
acme/web#5932: “@alex nice. Can the retry count show up on the dashboard later?”Listens to webhooks, works through the tools the team already uses
A small team ships across dozens of repositories. Dependency bumps wait days for an approval nobody has to think about. Issues sit in the wrong column because no one moved them. Mentions go to an inbox nobody reads during the day. OptiBotinho takes the repetitive part of that loop and leaves the decisions to people.
Every pull request is routed to a review tier. The tier's reviewers run in parallel through the Claude Code and Codex CLIs on a real checkout. A manager then checks their findings against the head commit and publishes one consolidated review.
The retry middleware is sound, but the signature check can leak timing and the empty-payload path has no test.
VerifySignature.php:41WebhookTest.php== stops at the first different byte. Use hash_equals($expected, $signature).
Ordered rules on paths, sizes, labels and repositories pick how hard to look. Sensitive code gets the full panel; a docs typo gets a light one. The last tier always matches.
Reviewers are Claude Code and Codex sessions with their own prompts and accounts, run by a separate review runtime. Profiles can add a code graph over MCP.
The manager drops what it cannot confirm at the head commit, rates the rest from critical to low, and posts inline comments plus a check run. Drafts and empty diffs are skipped.
Every push starts a new round at the current head. Findings are fingerprinted against earlier rounds, so the bot does not say the same thing twice, and the thread stays readable after ten pushes.
Configured rules put every pull request in one of three lanes. lane:auto merges after a clean AI review. lane:assist also needs enough human approval and a delay. lane:human is left to people. The queue automates; it does not enforce, so anyone can still merge by hand.
acme/web#5941evaluatingacme/chat#140evaluatingacme/web#5926waitingacme/mobile#87reviewingacme/api#219blockedApprovals are weighed by a score per GitHub user, with boosts per repository. The author's own approval never counts toward the threshold.
Head and base SHAs, mergeability, labels and kill switches are read again right before the merge call. Every attempt is recorded: merged, conflict, stale, blocked or merged by a person.
lane:human is never removed, a WIP label holds the queue, and audited overrides can merge now, hold, force a lane or change the delay.
Write @OptiBotinho and a command in any issue or pull request. The bot reacts with 👀 so you know it heard, does the work, and replies in the thread. Anything that is not a command gets an AI answer.
write drafts the title and body, review queues a review at the current head, approve approves.clone an issue everywhere it applies; create, delete or copy labels and milestones in one comment.Opening a pull request puts its issue in In review. Merging into dev moves it to To deploy; merging into main moves it to Testing and tells the assignee. Marks in the pull request body label the issue and end up in the release notes.
#5910ALWEBHOOK_RETRY_MAX=5A Fix: #5910 line in the pull request body is all it takes. Nobody drags the card, and nobody forgets to.
ENV:, FF: and MI: lines add has:env, has:feature-flag and has:migration. When a release is published, the envs and flags from its commits are added to the release body.
On working days the bot posts how many items sit in each column, at a minimum interval, and warns when In review piles up. Nothing is posted at night or on weekends.
A GitHub @mention becomes one more notification that is easy to miss. OptiBotinho also sends it as a direct message in the team chat, using a map from GitHub logins to chat users.
Laravel Nightwatch reports exceptions per application, so a Redis restart seen by ten apps is ten reports. OptiBotinho classifies each one before filing anything, fingerprints the cause, and links repeats to the issue that already tracks it.
Application errors go to the repository that saw them. Infrastructure and external dependency failures go to the platform repository. The monitoring agent's own noise is dropped.
Messages are normalised before matching, so the same failure with a different id, path or timestamp joins the open issue as a comment.
A triage dashboard tracks reports by category and cause. Resolving or ignoring an error in Nightwatch closes the GitHub issue, and a backfill command sorts out the issues filed before triage existed.
A web app behind GitHub sign-in, with page-level permissions, for the parts of the job that are not a pull request.
Team secrets, each with a clearance level. Revealing one takes a TOTP code and a ten-minute token. Entries above your level look exactly like missing ones.
A device-code flow signs the team CLI in through GitHub. From there it uploads screenshots for PRs, messages teammates, reads the vault and triggers redeploys.
GET /api/bastion/allowlist?env=stage
[
{ "username": "alex",
"keys": ["ssh-ed25519 AAAA…"] },
{ "username": "sam", "keys": [] }
]Bastions pull who may connect, with each person's public keys from GitHub. Production access is a separate grant.
Every review run records its tokens and an API-equivalent cost. Subscription accounts show how much of their usage window is left.
The team's other bots push snapshots and events. One page shows what each agent is doing, its jobs and its token use.
Pull requests, issues, commits, reviews, releases, weekly test coverage and a contributor ranking, across every registered repository.
retry on 429 tooN+1 in report exportskip tz for legacy rows@OptiBotinho scan-todos stores TODO, FIXME and HACK comments as tech debt. Any of them becomes an issue in one click.
feature_csv_export80%feature_new_editor35%feature_dark_mode100%An inventory of the flags found in the code, plus their state per tenant, so you can see who has a feature on before you remove it.
workspacereadycli-auth:codex:defaultcli-auth:claude:reviewerlogged outPreflight checks prove each reviewer CLI is still logged in, and a lost session raises an alert instead of quietly dropping a reviewer. The database is replicated continuously.
OptiBotinho is built with Laravel and PHP for the Optidata engineering team, with the Claude Code and Codex CLIs doing the reviewing.
Fix: #5910- ENV: WEBHOOK_RETRY_MAX=5