# 🐙 GitHub Scraper — Repos, Stars & Code Data (`nexgendata/github-scraper`) Actor

Extract repo data from GitHub — stars, forks, contributors, languages, issues & READMEs. Build developer tools, open source analytics & technology trend trackers. Pay per repo.

- **URL**: https://apify.com/nexgendata/github-scraper.md
- **Developed by:** [NexGenData](https://apify.com/nexgendata) (community)
- **Categories:** Developer tools, AI
- **Stats:** 5 total users, 3 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $20.00 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## 🐙 GitHub Scraper — Repos, Stars, Forks, Contributors & Topic Discovery

Pay-per-result GitHub scraper — extracts full repo metadata, stargazer counts, fork graphs, contributor lists, languages, topics, license, README content, and release cadence. Built for VC scouts, devtool marketers, OSS-funded analytics, and competitive intelligence as a no-rate-limit **alternative to** GitHub's REST API (5000 req/hr authenticated cap), GraphQL v4 (point quota), GitHub Archive on BigQuery (storage cost), Octoverse-style reports, and SaaS aggregators like Sourcegraph Cloud ($299+/mo) and OpenSauced.

### Why GitHub Scraper Beats the GitHub REST API, GraphQL & Sourcegraph

| Feature | NexGenData GitHub Scraper | GitHub REST API | GitHub GraphQL v4 | Sourcegraph Cloud |
|---|---|---|---|---|
| Cost | $0.002 / repo, pay-per-result | Free + rate-limited | Free + node quota | $299-1000+ / month |
| Rate limit | None for end user | 5000 req/hr | 5000 node points/hr | Plan-dependent |
| Auth | Apify token | GitHub PAT (often hits cap) | GitHub PAT | Account + plan |
| Bulk export | Direct dataset → JSON/CSV/Excel | Per-call REST | Per-query GraphQL | UI + limited API |
| Contributor enrichment | Yes | Multi-call required | Multi-query | Yes |
| Topic / trending discovery | Yes | Limited | Limited | Yes |
| Free trial | Free Apify credits on signup | Free for low volume | Free for low volume | 30-day trial |

VC scouts, devtool marketers, and OSS-funded analysts pick this actor **instead of** rolling their own PAT-rotation rig to dodge GitHub's 5000-req/hr limit. It is a **drop-in alternative to** GitHub's API for "I just need to pull 50K repos by topic + their stargazer-history slope" — the kind of query you cannot do in one GitHub API call.

### What You Get Per Repo

Each dataset item is a flat JSON record:

- `owner`, `name`, `full_name`, `html_url`, `description`
- `stars`, `forks`, `watchers`, `open_issues`, `closed_issues`, `open_prs`, `closed_prs`
- `primary_language`, `languages_breakdown` (% by bytes)
- `topics`, `license_spdx`, `default_branch`
- `created_at`, `updated_at`, `pushed_at`, `last_release_at`
- `contributors_count`, `top_contributors` — array of `{login, contributions}`
- `releases` — array of `{tag_name, published_at, prerelease, download_count}`
- `commit_activity_52w` — weekly commit counts
- `star_history` — sampled time series
- `readme_text`, `has_wiki`, `has_pages`, `archived`, `disabled`
- `funding_links` — Open Collective, GitHub Sponsors, Patreon, etc.

### Use Cases

- **VC devtool scouting** — surface fast-growing OSS repos in your thesis (LLM tooling, observability, dev experience) without burning GitHub PAT quota
- **Developer-tool marketers** — find repos using your competitor's library to retarget
- **OSS funding programs** — score grant candidates on commit cadence, contributor diversity, and adoption signals
- **Hiring teams** — discover top contributors in a language / topic
- **Investor due-diligence** — verify a startup's claim of "X stars in Y months" with raw star-history data
- **Competitive intel** — track release cadence + open-issue backlog of a competitor's OSS
- **Newsletters / Substacks** — automate "top 10 LLM repos this month" content

### Quick Start

```python
from apify_client import ApifyClient
client = ApifyClient("YOUR_APIFY_TOKEN")
run = client.actor("nexgendata/github-scraper").call(run_input={
    "queries": ["topic:llm stars:>500", "language:rust stars:>1000"],
    "includeContributors": True,
    "includeReleases": True,
    "maxResults": 5000
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item["full_name"], item["stars"], item["primary_language"])
````

### Pricing

Pay-per-event — no PAT quota, no monthly minimum.

- **Actor Start:** $0.0001
- **Per repo:** $0.002
- **Per contributor enrichment:** $0.0005

A 5000-repo topic sweep with contributors costs about $10-15. The equivalent in GitHub-API terms requires hours of PAT rotation and exponential backoff.

### Related NexGenData Actors

| Use case | Actor |
|----------|-------|
| Daily / weekly trending repos | [GitHub Trending Scraper](https://apify.com/nexgendata/github-trending-scraper?fpr=2ayu9b) |
| Deep stargazer-history + analytics | [GitHub Repo Stats](https://apify.com/nexgendata/github-repo-stats?fpr=2ayu9b) |
| GitLab projects + MRs | [GitLab Scraper](https://apify.com/nexgendata/gitlab-scraper?fpr=2ayu9b) |
| Docker Hub image pull counts | [Docker Hub Scraper](https://apify.com/nexgendata/dockerhub-scraper?fpr=2ayu9b) |
| npm package download stats | [npm Package Stats](https://apify.com/nexgendata/npm-package-stats?fpr=2ayu9b) |
| PyPI package download stats | [PyPI Package Stats](https://apify.com/nexgendata/pypi-package-stats?fpr=2ayu9b) |
| Dev.to articles + dev audience | [Dev.to Scraper](https://apify.com/nexgendata/devto-scraper?fpr=2ayu9b) |
| Developer-tools MCP server | [Developer Tools MCP Server](https://apify.com/nexgendata/developer-tools-mcp-server?fpr=2ayu9b) |

### FAQ

**Q: Why not just use the GitHub API directly?**
Two reasons: (1) the 5000 req/hr cap throttles anything over ~3000 repos with contributor enrichment, and (2) star-history requires sampling the stargazer event stream — a paginated multi-call dance that's painful in any GraphQL implementation.

**Q: Do you respect GitHub's TOS?**
We use unauthenticated public-page extraction plus optional authenticated API calls when the user provides a PAT. All data we extract is publicly available without login.

**Q: Can I scrape private repos?**
No — public data only.

**Q: How fresh are stargazer counts?**
Live per run. Star history is sampled at points along the repo's life.

**Q: What about commit-level data?**
This actor stops at repo-level metadata. For commit-diff content extraction, layer on `github-repo-stats` which deep-dives into individual repos.

**Q: Can I filter by topic or language?**
Yes — `queries` accepts any GitHub search syntax (`topic:`, `language:`, `stars:`, `created:`, `pushed:`, etc.).

### About NexGenData

NexGenData publishes 260+ buyer-intent actors covering SEC filings, YC alumni, lead generation, competitive intelligence, stock fundamentals across 30+ exchanges, and more. All pay-per-result. Browse the full catalog at https://apify.com/nexgendata?fpr=2ayu9b

***

### How NexGenData Pricing Works

Every NexGenData actor uses **pay-per-event** pricing — you only pay for results that actually land in your dataset. No monthly minimum, no seat fees, no surprise overage bills.

- **Actor Start:** a single-event charge each time you spin the actor up (scaled to memory size)
- **Result / item:** charged per item written to the default dataset
- **No charge** for retries, internal proxy rotation, or failed sub-requests — those are absorbed by the platform

### Apify Platform Bonus

New to Apify? Sign up with the NexGenData [referral link](https://www.apify.com/?fpr=2ayu9b) — you get free platform credits on signup (enough for several thousand free results) and you help fund the maintenance of this actor fleet.

### Integration Surface

Every actor in the NexGenData catalog can be triggered from:

- **Apify console** — point-and-click run
- **Apify API** — REST + webhooks
- **Apify Python / JS SDKs** — programmatic batch
- **Zapier, Make.com, n8n** — official integrations
- **MCP** — many actors are exposed as MCP tools for Claude / ChatGPT / Cursor agents
- **Schedules** — built-in cron for daily / weekly / monthly runs
- **Webhooks** — POST results to any HTTPS endpoint on dataset write

### Support

NexGenData maintains 260+ Apify actors and ships updates regularly. Bug reports via the Apify console issues tab get a response within 24 hours. Roadmap requests are welcome — high-demand features ship in the next version.

Home: [thenextgennexus.com](https://thenextgennexus.com)
Full catalog: [apify.com/nexgendata](https://apify.com/nexgendata?fpr=2ayu9b)

# Actor input Schema

## `searchQuery` (type: `string`):

Search term for repositories (e.g., 'machine learning', 'react', 'blockchain'). Leave empty for most starred repos.

## `language` (type: `string`):

Filter by programming language (e.g., Python, JavaScript, Go, Rust)

## `maxResults` (type: `integer`):

Maximum number of repositories to extract (default: 30, max: 100)

## `sort` (type: `string`):

Sort results by

## `order` (type: `string`):

Sort order

## Actor input object example

```json
{
  "maxResults": 30,
  "sort": "stars",
  "order": "desc"
}
```

# Actor output Schema

## `overview` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("nexgendata/github-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("nexgendata/github-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call nexgendata/github-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=nexgendata/github-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "🐙 GitHub Scraper — Repos, Stars & Code Data",
        "description": "Extract repo data from GitHub — stars, forks, contributors, languages, issues & READMEs. Build developer tools, open source analytics & technology trend trackers. Pay per repo.",
        "version": "0.0",
        "x-build-id": "6fwZa5KfDE7dQK9WQ"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/nexgendata~github-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-nexgendata-github-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/nexgendata~github-scraper/runs": {
            "post": {
                "operationId": "runs-sync-nexgendata-github-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/nexgendata~github-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-nexgendata-github-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "properties": {
                    "searchQuery": {
                        "title": "Search Query",
                        "type": "string",
                        "description": "Search term for repositories (e.g., 'machine learning', 'react', 'blockchain'). Leave empty for most starred repos."
                    },
                    "language": {
                        "title": "Programming Language",
                        "type": "string",
                        "description": "Filter by programming language (e.g., Python, JavaScript, Go, Rust)"
                    },
                    "maxResults": {
                        "title": "Maximum Results",
                        "minimum": 1,
                        "maximum": 100,
                        "type": "integer",
                        "description": "Maximum number of repositories to extract (default: 30, max: 100)",
                        "default": 30
                    },
                    "sort": {
                        "title": "Sort By",
                        "enum": [
                            "stars",
                            "forks",
                            "updated",
                            "created"
                        ],
                        "type": "string",
                        "description": "Sort results by",
                        "default": "stars"
                    },
                    "order": {
                        "title": "Order",
                        "enum": [
                            "desc",
                            "asc"
                        ],
                        "type": "string",
                        "description": "Sort order",
                        "default": "desc"
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
