🤖Automate PR Reviews with GitHub ActionsNEW

Set up PRISM to automatically review every PR in your repository. When a PR is opened, PRISM will analyze the code and post a comment with:

  • 📋 AI-generated summary of what the PR does
  • 🛡️ Security vulnerability detection
  • 📊 Code quality analysis
  • 💡 Suggested fixes
1

Add the workflow file

Create .github/workflows/prism-review.yml in your repo:

name: PRISM Code Review
on:
  pull_request:
    types: [opened, synchronize, reopened]
permissions:
  contents: read
  pull-requests: write
jobs:
  prism-review:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - name: PRISM Analysis
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
        run: |
          curl -X POST "https://prism-ai-code-review-docs.onrender.com/api/github/webhook" \
            -H "Content-Type: application/json" \
            -d '{
              "owner": "${{ github.repository_owner }}",
              "repo": "${{ github.event.repository.name }}",
              "prNumber": ${{ github.event.pull_request.number }},
              "token": "'"$GITHUB_TOKEN"'",
              "openaiKey": "'"$OPENAI_API_KEY"'"
            }'
2

Add your OpenAI API key (optional)

For AI-powered summaries, go to your repo → SettingsSecretsActions

  • OPENAI_API_KEY — Enables AI summaries & deep analysis

Without an API key, PRISM uses pattern-based analysis (still catches security issues!)

3

Open a PR

That's it! Open a PR and PRISM will automatically post a review comment.

Enter a URL above to analyze