# GitHub Profile Scraper (`knotless_cadence/github-profile-scraper`) Actor

Scrape GitHub user profiles — repos, stars, contributions, languages. Developer research and talent sourcing. Bulk supported. JSON/CSV. Custom tool in 48h, $100 pilot. Email: spinov001@gmail.com • Tips: t.me/scraping\_ai

- **URL**: https://apify.com/knotless\_cadence/github-profile-scraper.md
- **Developed by:** [Alex](https://apify.com/knotless_cadence) (community)
- **Categories:** Developer tools, Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

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

## 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 Profile Scraper — Users, Repos, Stars & Language Stats

Extract detailed GitHub user profiles and their repositories. Get bio, follower counts, top repos sorted by stars, programming language distribution, and activity timestamps. Uses the official GitHub REST API — no token needed for public data.

### Features

- **Profile Data** — name, bio, company, location, email, blog, Twitter handle, and hire status
- **Follower Metrics** — followers, following, public repos, and public gists counts
- **Repository Extraction** — top repos sorted by stars with forks, watchers, topics, and license info
- **Language Statistics** — aggregated programming language distribution across all repos
- **Total Stars & Forks** — calculated totals across all extracted repositories
- **Rate Limit Handling** — automatic detection and wait for GitHub API rate limits
- **Configurable Depth** — control max repos per user (up to 100)

### Output Example

```json
{
  "username": "torvalds",
  "name": "Linus Torvalds",
  "bio": null,
  "company": "Linux Foundation",
  "location": "Portland, OR",
  "followers": 220000,
  "following": 0,
  "publicRepos": 7,
  "totalStars": 185000,
  "totalForks": 55000,
  "repos": [
    {
      "name": "linux",
      "description": "Linux kernel source tree",
      "stars": 175000,
      "forks": 53000,
      "language": "C",
      "topics": ["linux", "kernel"],
      "license": "GPL-2.0"
    }
  ],
  "languages": [
    { "language": "C", "repoCount": 4 },
    { "language": "Shell", "repoCount": 1 }
  ],
  "createdAt": "2011-09-03T15:26:22Z",
  "scrapedAt": "2026-03-18T10:00:00.000Z"
}
````

### Use Cases

- **Developer Recruiting** — evaluate candidates by analyzing their GitHub contributions, languages, and project quality
- **Competitor Analysis** — study open-source strategies of companies and key developers
- **Community Research** — map contributor networks and identify influential developers in a technology
- **Portfolio Benchmarking** — compare star counts, repo activity, and language usage across developers
- **Lead Generation** — find developers with specific technology expertise for outreach

### Input Parameters

| Parameter | Type | Default | Description |
|-----------|------|---------|-------------|
| `usernames` | array | `[]` | GitHub usernames to scrape (e.g., "torvalds", "gaearon") |
| `includeRepos` | boolean | `true` | Extract repositories with stars, forks, and languages |
| `maxReposPerUser` | integer | `30` | Max repos per user, sorted by stars (1-100) |
| `includeLanguageStats` | boolean | `true` | Calculate language distribution across repos |

### How It Works

The scraper fetches each user's profile from the GitHub REST API, then retrieves their public repositories sorted by star count. It aggregates language usage across all repos to produce a language distribution breakdown. Automatic rate limit detection pauses and retries when the GitHub API limit is reached.

# Actor input Schema

## `usernames` (type: `array`):

GitHub usernames to scrape (e.g., 'torvalds', 'gaearon', 'sindresorhus')

## `includeRepos` (type: `boolean`):

Extract user's public repositories with stars, forks, and languages

## `maxReposPerUser` (type: `integer`):

Maximum repositories to extract per user (sorted by stars)

## `includeLanguageStats` (type: `boolean`):

Calculate programming language distribution across repos

## Actor input object example

```json
{
  "usernames": [
    "torvalds"
  ],
  "includeRepos": true,
  "maxReposPerUser": 30,
  "includeLanguageStats": true
}
```

# 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 = {
    "usernames": [
        "torvalds"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("knotless_cadence/github-profile-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 = { "usernames": ["torvalds"] }

# Run the Actor and wait for it to finish
run = client.actor("knotless_cadence/github-profile-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 '{
  "usernames": [
    "torvalds"
  ]
}' |
apify call knotless_cadence/github-profile-scraper --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "GitHub Profile Scraper",
        "description": "Scrape GitHub user profiles — repos, stars, contributions, languages. Developer research and talent sourcing. Bulk supported. JSON/CSV. Custom tool in 48h, $100 pilot. Email: spinov001@gmail.com • Tips: t.me/scraping_ai",
        "version": "1.0",
        "x-build-id": "Dd4FR3IXzJLVrI7wb"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/knotless_cadence~github-profile-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-knotless_cadence-github-profile-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/knotless_cadence~github-profile-scraper/runs": {
            "post": {
                "operationId": "runs-sync-knotless_cadence-github-profile-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/knotless_cadence~github-profile-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-knotless_cadence-github-profile-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",
                "required": [
                    "usernames"
                ],
                "properties": {
                    "usernames": {
                        "title": "GitHub Usernames",
                        "type": "array",
                        "description": "GitHub usernames to scrape (e.g., 'torvalds', 'gaearon', 'sindresorhus')",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "includeRepos": {
                        "title": "Include Repositories",
                        "type": "boolean",
                        "description": "Extract user's public repositories with stars, forks, and languages",
                        "default": true
                    },
                    "maxReposPerUser": {
                        "title": "Max Repos Per User",
                        "minimum": 1,
                        "maximum": 100,
                        "type": "integer",
                        "description": "Maximum repositories to extract per user (sorted by stars)",
                        "default": 30
                    },
                    "includeLanguageStats": {
                        "title": "Include Language Stats",
                        "type": "boolean",
                        "description": "Calculate programming language distribution across repos",
                        "default": true
                    }
                }
            },
            "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
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
