跳到主要内容

GitHub 集成

Create GitHub App

提示

You’ll need to create a GitHub App (not a GitHub OAuth App). These are different types of applications with different capabilities. Consider creating separate GitHub apps for development and production environments.

Create the GitHub App

  1. Go to GitHub App creation page
  2. Fill in the basic information:
    • GitHub App name: Your preferred name
    • Description: Development instance of Open SWE coding agent
    • Homepage URL: Your repository URL
    • Callback URL: http://localhost:3000/api/github/<your-integration-id>/callback

Configure OAuth Settings

  • Request user authorization (OAuth) during installation - Allows users to log in to the web app
  • Redirect on update - Redirects users back to your app after permission updates
  • Expire user authorization tokens - Keep tokens from expiring

Set Up Webhook

  1. ✅ Enable webhook

  2. Webhook URL: You’ll need to use a tool like ngrok to expose your local server:

    # Install ngrok if you haven't already
    # Then expose your local LangGraph server
    ngrok http 2024

    Use the ngrok URL + /api/github/<your-integration-id>/webhook/ (e.g., https://abc123.ngrok.io/api/github/<your-integration-id>/webhook/)

  3. Webhook secret: Generate and save this value:

    openssl rand -hex 32

Configure Permissions