Skip to content

GitHub

Learn how to securely authenticate Mindflow with your GitHub repositories using a fine-grained Personal Access Token (PAT). This guide walks you through generating the required token in GitHub and configuring the API credential within your Mindflow environment.

To allow Mindflow to interact with your GitHub data securely, you must first create a repository-scoped access token.

  1. Access Developer Settings Log in to GitHub, click your profile picture in the top-right corner, and select Settings. Scroll down the left sidebar and click Developer settings.

    Access developer settings

    Access developer settings

  2. Navigate to Fine-Grained Tokens In the left menu, expand Personal access tokens and select Fine-grained tokens. Click the Generate new token button.

    Navigate fine grained tokens

  3. Configure Token Details

    • Token name: Enter a recognizable name (e.g., Mindflow Integration).
    • Expiration: Select an appropriate lifespan for your token (e.g., 30 days).

    Expiration

  4. Set Repository Access

    Under the Repository access section, select Only select repositories and choose the specific repositories you want Mindflow to access.

    Set repository access

  5. Assign Permissions

    Expand the Repository permissions section. Assign the minimal access required for your workflow. For standard read operations, configure the following:

    • Contents: Read-only
    • Metadata: Read-only
  6. Generate and Save

    Scroll to the bottom and click Generate token.

    Generate save

Once your GitHub PAT is generated, you can set up the authentication credential in your Mindflow dashboard.

  1. Navigate to Environments

    Open Mindflow and go to the Environments page.

  2. Create a Credential

    Locate the target environment or within the Global Environment section and click the + Create credential button on the right side.

    Create credential

  3. Select the Integration Service

    In the Service search bar, type GitHub and select either the GitHub option labeled with the Native badge or Vendor.

    Select integration service

  4. Configure Credential Details

    Fill out the form with the following parameters:

    Configure credential details

    - **Credential name:** Enter a clear identifier (e.g., `GitHub credential`). - **URL:** Ensure this is set to `https://api.github.com`. - **Credential type:** Select **HTTP API Key** from the dropdown menu.
  5. Set the Authorization Header

    • Click the Advanced button to reveal additional settings.
    • Expand the Headers menu and click + Add item.
    • In the Key field, enter: Authorization
    • In the Value field, enter: Bearer<your_pat_token>“
  6. Save the Credential

    Click Update (or Create) to save your configuration. Your GitHub integration is now ready to use in your Mindflow workflows.