# GitHub

Monitor your GitHub repositories, commits, issues, and pull requests directly in Weavestream with AI-powered analysis.


# Features

  • 📊 Repository Overview - See all your repos with creation dates
  • 💬 Commit History - Track commits across repositories
  • 🐛 Issues & Pull Requests - Monitor open/closed issues and PRs
  • 🔔 Notifications - Stay updated on mentions and reviews
  • Workflow Runs - Track GitHub Actions success/failure
  • 📈 Repository Activity - Monitor stars, forks, and activity

Estimated Setup Time: 15 minutes


# Setup Guide

# Step 1: Create a GitHub Personal Access Token

  1. Go to https://github.com/settings/tokens
  2. Click "Generate new token""Generate new token (classic)"
  3. Fill in the form:
    • Note: Weavestream Access
    • Expiration: 90 days (or your preference)
    • Select scopes:
      • repo (Full control of private repositories)
      • read:user (Read user profile data)
      • read:org (Read organization membership)
      • notifications (Access notifications)
      • workflow (Update GitHub Action workflows)
  4. Scroll down and click "Generate token"
  5. ⚠️ IMPORTANT: Copy the token immediately (starts with ghp_)
    • You won't be able to see it again!
    • Example: ghp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

# Step 2: Add GitHub to Weavestream

  1. Open Weavestream
  2. Click "+" in the sidebar
  3. Select "Add Source"
  4. Fill in:
    • Name: GitHub
    • Base URL: https://api.github.com
    • Auth Type: Bearer Token
    • Token: Paste your personal access token
    • Icon: github (automatically uses GitHub logo)
    • Refresh Interval: 15 minutes
  5. Click "Add"

# Step 3: Add Endpoints

GitHub has several useful endpoints. Add the ones you need:


# Endpoint 1: Your Repositories

See all repositories you have access to.

Configuration:

  • Name: My Repositories
  • Path: /user/repos
  • Method: GET
  • Query Parameters:
    • sort: updated (shows recently active repos first)
    • per_page: 100 (optional - get more results)

Field Mapping:

  • ID Field: id
  • Title Field: full_name (shows owner/repo-name)
  • Date Field: updated_at
  • Summary Fields: description, language
  • Status Mappings:
    • private field → if true: info, if false: ok

Improved Config:

{
  "mapping": {
    "idField": "id",
    "titleField": "full_name",
    "dateField": "updated_at",
    "summaryFields": ["description", "language", "stargazers_count"],
    "statusField": "archived",
    "statusMappings": {
      "true": "warning",
      "false": "ok"
    },
    "_invertStatusBoolean": false
  }
}

# Endpoint 2: Repository Commits

Track commits across a specific repository.

Configuration:

  • Name: [RepoName] Commits (e.g., "Weavestream Commits")
  • Path: /repos/{owner}/{repo}/commits
    • Replace {owner} with your GitHub username
    • Replace {repo} with repository name
    • Example: /repos/username/weavestream/commits
  • Method: GET
  • Query Parameters:
    • per_page: 50 (optional - get more results)
    • since: 2024-01-01T00:00:00Z (optional - only commits after this date)

Field Mapping:

  • ID Field: sha (more reliable than node_id)
  • Title Field: commit.message
  • Date Field: commit.committer.date
  • Summary Fields: commit.committer.name, author.login

Improved Config:

{
  "mapping": {
    "idField": "sha",
    "titleField": "commit.message",
    "dateField": "commit.committer.date",
    "summaryFields": ["commit.committer.name", "author.login", "stats.total"]
  }
}

# Endpoint 3: Issues & Pull Requests

Monitor open issues and PRs for a repository.

Configuration:

  • Name: [RepoName] Issues (e.g., "Weavestream Issues")
  • Path: /repos/{owner}/{repo}/issues
    • Example: /repos/username/weavestream/issues
  • Method: GET
  • Query Parameters:
    • state: open (or closed or all)
    • sort: updated
    • per_page: 50

Field Mapping:

  • ID Field: id
  • Title Field: title
  • Date Field: updated_at
  • Summary Fields: user.login, labels, comments
  • Status Field: state
    • Map openwarning
    • Map closedok

Improved Config:

{
  "mapping": {
    "idField": "id",
    "titleField": "title",
    "dateField": "updated_at",
    "summaryFields": ["user.login", "body", "comments"],
    "statusField": "state",
    "statusMappings": {
      "open": "warning",
      "closed": "ok"
    }
  }
}

Note: GitHub's Issues API returns both issues AND pull requests. To filter:

  • Issues only: Add query param is: issue
  • PRs only: The response includes pull_request field - you can filter in Weavestream

# Endpoint 4: Pull Requests (Separate)

If you want PRs separate from issues:

Configuration:

  • Name: [RepoName] Pull Requests
  • Path: /repos/{owner}/{repo}/pulls
  • Method: GET
  • Query Parameters:
    • state: open (or closed or all)
    • sort: updated
    • per_page: 50

Field Mapping:

{
  "mapping": {
    "idField": "id",
    "titleField": "title",
    "dateField": "updated_at",
    "summaryFields": ["user.login", "head.ref", "base.ref", "mergeable_state"],
    "statusField": "state",
    "statusMappings": {
      "open": "warning",
      "closed": "ok"
    }
  }
}

# Endpoint 5: GitHub Actions Workflows

Monitor workflow runs (CI/CD status).

Configuration:

  • Name: [RepoName] Workflow Runs
  • Path: /repos/{owner}/{repo}/actions/runs
  • Method: GET
  • Query Parameters:
    • per_page: 50
    • status: completed (or leave empty for all)

Field Mapping:

{
  "mapping": {
    "idField": "id",
    "titleField": "name",
    "dateField": "updated_at",
    "summaryFields": ["head_branch", "event", "actor.login"],
    "statusField": "conclusion",
    "statusMappings": {
      "success": "ok",
      "failure": "critical",
      "cancelled": "warning",
      "skipped": "info"
    }
  }
}

# Endpoint 6: Notifications

See your GitHub notifications (mentions, reviews, etc.).

Configuration:

  • Name: My Notifications
  • Path: /notifications
  • Method: GET
  • Query Parameters:
    • all: false (only unread, or true for all)
    • per_page: 50

Field Mapping:

{
  "mapping": {
    "idField": "id",
    "titleField": "subject.title",
    "dateField": "updated_at",
    "summaryFields": ["repository.full_name", "reason", "subject.type"],
    "statusField": "unread",
    "statusMappings": {
      "true": "warning",
      "false": "ok"
    },
    "_invertStatusBoolean": false
  }
}

# Endpoint 7: Organization Repositories

If you're part of an organization:

Configuration:

  • Name: [OrgName] Repositories
  • Path: /orgs/{org}/repos
    • Replace {org} with organization name
    • Example: /orgs/anthropic/repos
  • Method: GET

Field Mapping: Same as "My Repositories" above


# Endpoint 8: Repository Activity/Events

See recent activity on a repository:

Configuration:

  • Name: [RepoName] Activity
  • Path: /repos/{owner}/{repo}/events
  • Method: GET

Field Mapping:

{
  "mapping": {
    "idField": "id",
    "titleField": "type",
    "dateField": "created_at",
    "summaryFields": ["actor.login", "payload.action", "repo.name"]
  }
}

# Smart Filters

Create these filters for quick access:

# Filter 1: Open Issues Assigned to Me

  • Endpoint: Issues
  • Conditions:
    • state equals open
    • assignee.login equals [your_username]
  • Logic: AND

# Filter 2: Failed Workflow Runs

  • Endpoint: Workflow Runs
  • Conditions:
    • conclusion equals failure
    • updated_at in last 7 days
  • Logic: AND

# Filter 3: Recently Updated Repos

  • Endpoint: Repositories
  • Conditions:
    • updated_at in last 30 days
    • archived equals false
  • Logic: AND

# Filter 4: My Open PRs

  • Endpoint: Pull Requests
  • Conditions:
    • user.login equals [your_username]
    • state equals open
  • Logic: AND

# AI Analysis Examples

Once configured, ask Weavestream questions like:

# About Commits:

  • "Summarize commits from the last week"
  • "Who has been committing the most?"
  • "Show me commits by [username]"

# About Issues:

  • "What are my critical open issues?"
  • "Summarize issues that need attention"
  • "How many bugs vs features are open?"

# About Repositories:

  • "Which repos have I updated recently?"
  • "What's my most active repository?"
  • "Show me archived repos"

# About Workflows:

  • "Are there any failed CI builds?"
  • "Show me workflow runs that failed today"
  • "Which workflows are taking the longest?"

# Cross-Analysis:

  • "Show me repos with open issues and failed builds"
  • "What needs my attention in GitHub today?"

# Rate Limits

GitHub API has rate limits:

  • Authenticated requests: 5,000 requests/hour
  • Unauthenticated: 60 requests/hour (don't use this)

With 15-minute refresh and 5-10 endpoints, you'll use ~40-80 requests/hour - well within limits.

Check your rate limit:

curl -H "Authorization: Bearer YOUR_TOKEN" https://api.github.com/rate_limit

# Advanced Configuration

# Custom Headers

GitHub API accepts these useful headers:

In Weavestream source configuration, add Custom Headers:

{
  "Accept": "application/vnd.github.v3+json",
  "X-GitHub-Api-Version": "2022-11-28"
}

These ensure you get the latest API version.


# Pagination

GitHub returns 30 items by default. To get more:

Add query parameter:

  • per_page: 100 (max allowed)

For multiple pages: GitHub uses Link headers for pagination. Weavestream should auto-detect this. If not, you can:

  • Make multiple endpoint configs with page parameter
  • Or fetch only recent items using since parameter

# Filtering Results

Many GitHub endpoints support filtering:

Commits:

  • since: 2024-01-01T00:00:00Z (ISO 8601 date)
  • until: 2024-12-31T23:59:59Z
  • author: [username]
  • path: src/main.js (commits touching specific file)

Issues:

  • state: open, closed, all
  • labels: bug,enhancement (comma-separated)
  • assignee: [username]
  • creator: [username]
  • mentioned: [username]
  • since: 2024-01-01T00:00:00Z

Pull Requests:

  • state: open, closed, all
  • head: username:branch
  • base: main
  • sort: created, updated, popularity
  • direction: asc, desc

# Troubleshooting

# Issue: "Bad credentials" or 401 error

Solution:

  1. Verify your personal access token is correct
  2. Check that the token hasn't expired
  3. Ensure you selected the right scopes when creating the token
  4. Try generating a new token

# Issue: "Not Found" or 404 error

Solution:

  1. Verify the repository path is correct (case-sensitive)
  2. Check that you have access to the repository
  3. For organization repos, ensure your token has read:org scope

# Issue: Rate limit exceeded

Solution:

  1. Check your rate limit: curl -H "Authorization: Bearer TOKEN" https://api.github.com/rate_limit
  2. Increase refresh interval to 30 or 60 minutes
  3. Reduce number of endpoints
  4. Use pagination more efficiently

# Issue: No data appearing

Solution:

  1. Check that the repository/path exists
  2. Verify field mappings match the actual JSON structure
  3. View "Raw JSON" in Weavestream to see the actual response
  4. Some endpoints return nested data in a value or data array

# Security Best Practices

# Do:

  • Use fine-grained tokens when possible (beta feature)
  • Set token expiration (90 days recommended)
  • Only grant necessary scopes
  • Rotate tokens regularly
  • Store tokens securely (Weavestream uses macOS Keychain)

# Don't:

  • Share your personal access token
  • Grant more scopes than needed
  • Use tokens in public repositories
  • Set tokens to never expire
  • Commit tokens to code

# Additional Resources


# Summary

This GitHub integration gives you:

  • Repository monitoring across all your projects
  • Commit history and author tracking
  • Issue and PR management
  • CI/CD workflow monitoring
  • Real-time notifications
  • AI-powered analysis of all GitHub activity

Import this config into Weavestream or build it manually using the instructions above!


Last updated: February 2026
Weavestream Version: 1.0