# GitHub Repo Scraper: Trending, Search & Repo Details (`tagadanar/github-repo-scraper`) Actor

Scrape GitHub repositories: Trending lists by language and date range, repository search by keyword, language, topic and stars, or details for repo URLs. Flat rows: stars, forks, stars today, topics, license, dates. $0.50 per 1,000 repos.

- **URL**: https://apify.com/tagadanar/github-repo-scraper.md
- **Developed by:** [Tagada Data](https://apify.com/tagadanar) (community)
- **Categories:** Developer tools, AI, Automation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.35 / 1,000 repositories

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## GitHub Repo Scraper: Trending, Search & Repo Details

Get GitHub repositories as clean, flat rows. Pick a mode: the **GitHub Trending** list for any programming language (today, this week or this month, with the stars gained in that window), a **repository search** by keyword, language, topic and minimum stars, or **details for a list of repository URLs**. Each row holds the repository's name, URL, description, owner, language, stars, forks, open issues, topics, license, homepage, created / updated / last-push dates, default branch and archived / fork flags, ready for a spreadsheet, a dashboard or an AI agent.

**$0.50 per 1,000 repositories on Free ($0.35 on Gold), plus $0.001 per run. Platform usage is included.** No GitHub token, no login, no proxy needed.

### What you get

One flat row per repository. Fields GitHub does not publish for a repository are null.

| Field | What it is |
| --- | --- |
| `fullName` | owner/name, e.g. `apify/crawlee` |
| `url` | Repository URL |
| `description` | The repository's one-line description |
| `owner` / `ownerType` | Owner login and `User` or `Organization` |
| `language` | Primary programming language |
| `stars` / `forks` | Star and fork counts |
| `openIssues` | Open issues plus open pull requests |
| `topics` | GitHub topics, comma-separated |
| `license` | SPDX license ID (`MIT`, `Apache-2.0`...) |
| `homepage` | The project website, when set |
| `createdAt` / `updatedAt` / `pushedAt` | Creation, last update and last push (ISO 8601) |
| `defaultBranch` | `main`, `master`... |
| `isArchived` / `isFork` / `isTemplate` | Repository flags |
| `sizeKb` | Repository size in KB |
| `trendingRank` / `trendingPeriod` / `starsInPeriod` | Trending mode: position on the list, `daily` / `weekly` / `monthly`, and stars gained in that window |
| `latestReleaseTag` | Latest release tag, when you switch on *Add latest release tag* |
| `input` / `mode` | The trending list, search query or URL that produced the row |
| `dataSource` | Which GitHub page or API answered for this row |
| `retrievedAt` | When the row was fetched (ISO 8601) |

Repository facts only: no e-mail addresses, no contributor, follower or stargazer lists of people.

### Who uses it

- **Developer-tool marketers and DevRel teams**: watch what is trending in their language every day or week and spot rising competitors and integration partners.
- **Investors and analysts**: track fast-growing open-source projects (stars gained this week, last push, license) before they show up in the news.
- **Researchers and AI builders**: pull a clean list of repositories for a topic or keyword, with license and activity dates, to build datasets or pick dependencies.
- **Engineering managers**: audit a list of dependencies (archived? last push? license?) from their URLs in one run.

### Examples

Prefill: today's Python trending list, with repository details.

```json
{"mode":"trending","trendingLanguages":["python"],"since":"daily"}
```

This week's trending repositories in several languages, with the latest release tag:

```json
{"mode":"trending","trendingLanguages":["typescript","rust","go"],"since":"weekly","includeLatestRelease":true}
```

Search: the 200 most-starred Python web scrapers with at least 50 stars:

```json
{"mode":"search","searchQueries":["web scraper"],"language":"Python","minStars":50,"sort":"stars","maxResults":200}
```

Search with GitHub qualifiers, one query per line:

```json
{"mode":"search","searchQueries":["llm agent in:readme pushed:>2026-01-01","topic:mcp-server"],"sort":"updated","maxResults":100}
```

Details for a list of repositories:

```json
{"mode":"repos","repoUrls":["https://github.com/apify/crawlee","https://github.com/microsoft/vscode","torvalds/linux"]}
```

### Results, zeros and errors

- A Trending list GitHub shows as empty, a search GitHub answers with 0 matches, or a repository URL GitHub answers with "not found" is named as such in the run status and costs nothing.
- A list, query or repository GitHub did not answer, or that the run clock stopped, is named in the status and is never reported as "no match".
- Each repository is delivered once per run. When a later Trending list or search query contains a repository an earlier one already delivered, it is not repeated (nor charged again), and the status says how many were already delivered.
- GitHub limits anonymous API traffic. When that limit is reached the actor waits for it to reset or continues on GitHub's public web pages; rows read from a web page can have fewer fields (for example no `pushedAt`), and the `dataSource` column says which source was used.
- GitHub search shows at most 1,000 results per query; narrow the query (language, stars, topic, dates) to reach more.
- Invalid input ends the run right away with an "Input error: ..." message and only the $0.001 start charge.

### Pricing

- $0.001 per run (start).
- $0.50 per 1,000 repositories on Free, with lower prices on higher Apify plans ($0.35 per 1,000 on Gold). Platform usage is included.

Set a maximum charge per run in Apify if you want a hard ceiling; the actor stops at it and says so in the status.

### FAQ

**Do I need a GitHub token?** No. The actor reads public repository information without any login or key.

**Which language names work for Trending?** The slug GitHub uses in its Trending URL: `python`, `typescript`, `c++`, `c#`, `jupyter-notebook`, `shell`. Leave the list empty for the all-languages list. An unknown slug gives an empty list, named in the status.

**How many repositories does a Trending list have?** Whatever GitHub shows, usually 10 to 25 per language and period.

**Can I schedule it?** Yes. Schedule a Trending run daily or weekly in Apify and compare the datasets to see what is rising.

**Can I get developer e-mails or followers?** No. This actor returns repository information only.

### Data use

Data comes from GitHub's public Trending, search and repository pages and its public REST API, without a login. It returns repository metadata only and no personal information about GitHub users. GitHub's Terms of Service and Acceptable Use Policies apply to how you use the data; in particular they forbid using it for spam or for selling users' personal information.

# Changelog

This Actor's version history is a separate document: https://apify.com/tagadanar/github-repo-scraper/changelog.md

# Actor input Schema

## `mode` (type: `string`):

trending = GitHub Trending lists; search = repository search by keyword and filters; repos = details for a list of repository URLs.

## `trendingLanguages` (type: `array`):

GitHub language slugs as they appear in the Trending URL (python, typescript, rust, c++, jupyter-notebook). One Trending list per language. Leave empty for all languages. Max 20.

## `since` (type: `string`):

Trending window: today, this week or this month. Sets the stars-in-period column.

## `spokenLanguage` (type: `string`):

Optional two-letter code of the README language (en, zh, es, ja...). Empty = any.

## `includeDetails` (type: `boolean`):

Add license, topics, open issues, homepage, dates and flags to each Trending row. Off = the Trending page fields only (faster).

## `searchQueries` (type: `array`):

One repository search per line, in GitHub search syntax: keywords plus optional qualifiers ("web scraper", "llm agent in:readme", "user:apify", "pushed:>2026-01-01"). Max 50.

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

Optional filter added to every query (Python, TypeScript, Go...).

## `topic` (type: `string`):

Optional GitHub topic filter added to every query (machine-learning, web-scraping...).

## `minStars` (type: `integer`):

Optional: only repositories with at least this many stars.

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

Order of the results (descending).

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

Cap per query. Default 100, max 1,000 (GitHub shows at most 1,000 results per search).

## `repoUrls` (type: `array`):

GitHub repository URLs or owner/name pairs (https://github.com/apify/crawlee, apify/crawlee). Max 1,000 per run.

## `includeLatestRelease` (type: `boolean`):

Look up each repository's latest release tag (one extra page per repository, all modes).

## Actor input object example

```json
{
  "mode": "trending",
  "trendingLanguages": [
    "python"
  ],
  "since": "daily",
  "includeDetails": true,
  "sort": "stars",
  "maxResults": 100,
  "includeLatestRelease": false
}
```

# Actor output Schema

## `dataset` (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 = {
    "mode": "trending",
    "trendingLanguages": [
        "python"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("tagadanar/github-repo-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 = {
    "mode": "trending",
    "trendingLanguages": ["python"],
}

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

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

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

```

## CLI example

```bash
echo '{
  "mode": "trending",
  "trendingLanguages": [
    "python"
  ]
}' |
apify call tagadanar/github-repo-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,tagadanar/github-repo-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/9de2udVGRag3svfN5/builds/ZMCwbdGRgcETT3lIW/openapi.json
