• AI Engineering
  • Posts
  • [Hands-On] Build a PR Review Agent With OpenClaw and MiniMax M2.7

[Hands-On] Build a PR Review Agent With OpenClaw and MiniMax M2.7

... PLUS: Connect Claude Code to any data source

In today’s newsletter:

  • Apify Actors: Connect Claude Code to any data source

  • PR Review Agent: Telegram-Triggered and Built on OpenClaw

Reading time: 5 minutes.

Make Claude Code 10x more useful by connecting it to any data source.

Apify Actors are pre-built data scrapers that connect to Claude Code as agent skills.

Most agents can't access external data beyond web search. They can't scrape. They can't extract structured information. You ask them to monitor repos, track competitors, or analyze market data, and they're stuck.

Apify Actors fix this. They're specialized scrapers for:

  • LinkedIn

  • Job boards

  • News sites

  • Documentation pages

  • E-commerce sites

  • GitHub repositories

They scrape the data and return it structured.

You build a skill in Claude Code that connects to an Actor. The Actor handles scraping. Your skill handles the logic.

Example: GitHub repo monitoring

Say you want to monitor GitHub repos. Track activity, analyze contributors, watch competitor projects. You connect to Apify's GitHub Repository Data Scraper Actor. Send it a repo URL. It returns stars, forks, topics, license info, language, timestamps. Your agent analyzes it, generates reports, tracks changes.

The workflow:

Apify has a community collection of pre-built skills for lead generation, brand monitoring, competitor intelligence, market research, and trend analysis. You can also build your own skills that connect to any Actor on the platform.

  • Search the Apify Store for the Actor you need

  • Build a skill that connects to it

  • Let Claude Code handle the rest

Most PR reviews are inconsistent. One reviewer catches security vulnerabilities, another misses them entirely. Logic errors slip through depending on who's reviewing and how tired they are. The quality of your codebase ultimately depends on who reviews that PR.

We built it as a PR review agent on OpenClaw called Eagle Eye. It fetches a GitHub pull request, analyses the diff, and sends structured feedback directly to your Telegram chat. Reviews cover security vulnerabilities, bugs, code quality, and best practices, grouped by severity and rated overall.

Nothing gets posted to GitHub without your explicit approval.

Here is the stack:

  • OpenClaw as the agent runtime

  • MiniMax M2.7 as the reasoning model

  • GitHub MCP server for fetching PR diffs and posting reviews

  • Telegram as the trigger and delivery channel

Setup instructions

Before you start, make sure you have OpenClaw installed and available in your PATH, a Telegram bot token from @BotFather, and a GitHub Personal Access Token with repo, pull_requests: write, and issues: write permissions.

Step 1. Onboard and select your model

Run the command below. It launches an interactive wizard that configures your AI provider, sets up the gateway, and connects your Telegram channel. When prompted for a model, select MiniMax M2.7. This is also where OpenClaw stores your API key securely in its auth profiles.

openclaw onboard

Step 2. Configure openclaw.json

Create your openclaw.json using the template below and fill in your credentials. This file tells OpenClaw how to run the gateway, which channel to listen on, and which MCP servers to spin up. The GitHub MCP server is declared here and starts automatically when the agent starts.

Step 3. Create your SOUL.md file

This is the most important file in the project. Traditional software hardcodes review logic in scripts. Eagle Eye defines its entire behaviour in SOUL.md, covering how the agent speaks, what it looks for in a diff, how it formats findings, and how it handles the approval workflow with the developer.

Start with the agent identity:

Step 4. Copy the skill to your workspace

Once your files are ready, copy the entire project into your OpenClaw skills directory. This is where OpenClaw looks for agent skills at runtime. Run the command for your operating system:

On macOS or Linux:

cp -r . ~/.openclaw/workspace/skills/eagle-eye/

On Windows:

xcopy . %USERPROFILE%\.openclaw\workspace\skills\eagle-eye\ /E /I

Step 5. Start the gateway

With everything in place, start the gateway. OpenClaw will boot up, load the Eagle Eye skill, connect to Telegram, and begin listening for messages.

openclaw gateway

Send any GitHub PR URL to your bot, and Eagle Eye fetches the diff, analyses it, and returns a structured review.

Reply post to publish it as a GitHub comment, no to discard it, or give further instructions and it will revise and ask again.

That is the entire workflow. From Telegram message to GitHub comment, without leaving your chat

Find the full workflow on GitHub → (Feel free to star the repo if you find it useful)

Curious how you’d use this: would you plug it into your workflow or keep reviews fully manual?

That’s all for today. Thank you for reading today’s edition. See you in the next issue with more AI Engineering insights.

PS: We curate this AI Engineering content for free, and your support means everything. If you find value in what you read, consider sharing it with a friend or two.

Your feedback is valuable: If there’s a topic you’re stuck on or curious about, reply to this email. We’re building this for you, and your feedback helps shape what we send

WORK WITH US

Looking to promote your company, product, or service to 200K+ AI developers? Get in touch today by replying to this email.