AcademyWorkflowsDevelopment

Automated PR Code Reviews with GitHub and OpenAI

Development teams that want an automated first review pass before a person reads the code.

  • Recommendedour rating
  • 4,545views on n8n
Open on n8n.io ↗

Paste it straight onto an n8n canvas with Ctrl+V or Cmd+V.

automated-pr-code-reviews-with-github-gpt-4-and-google-sheets-best-practices.json

Loading the file...

What it does

An n8n workflow that starts when a pull request is opened, reads the changed files and their diffs, and sends them to an OpenAI model. The model uses coding practices kept in a Google Sheet to write a review, which is posted as a comment and marked with a label.

Use cases

  1. 01Add a first-pass review comment to new pull requests
  2. 02Check diffs against a team's coding guidelines
  3. 03Label pull requests that already have an AI review

Connects

GitHub · HTTP Request · Code · AI Agent · OpenAI Chat Model

Questions about
Automated PR Code Reviews with GitHub and OpenAI.

What is Automated PR Code Reviews with GitHub and OpenAI used for?

Development teams that want an automated first review pass before a person reads the code. An n8n workflow that starts when a pull request is opened, reads the changed files and their diffs, and sends them to an OpenAI model. The model uses coding practices kept in a Google Sheet to write a review, which is posted as a comment and marked with a label.

How do I import Automated PR Code Reviews with GitHub and OpenAI into n8n?

Copy the workflow JSON from this page and paste it onto the n8n canvas with Ctrl+V or Cmd+V. Then connect your credentials in each node.

Is Automated PR Code Reviews with GitHub and OpenAI safe to use?

It passed our automatic scan for credential theft, hidden instructions and risky install commands. Third party open source software. Sabemos AI does not maintain it. Check the code and permissions before you connect it to company data.