# SocialCrawl API: github endpoints # Base URL: https://www.socialcrawl.dev # Auth: x-api-key header # Full docs: https://www.socialcrawl.dev/docs/github ## GET /v1/github/profile Get a GitHub user profile Credit cost: 1 (standard) Parameters: - handle (required): GitHub username: 1-39 chars, alphanumeric + non-consecutive hyphens, no leading/trailing hyphen. curl -G "https://www.socialcrawl.dev/v1/github/profile" \ --data-urlencode "handle=octocat" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/repo Get a GitHub repository Credit cost: 1 (standard) Parameters: - url (required): GitHub repo URL: `https://github.com/{owner}/{repo}`. curl -G "https://www.socialcrawl.dev/v1/github/repo" \ --data-urlencode "url=https://github.com/octocat/Hello-World" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/profile/repos List a GitHub user's repositories Credit cost: 1 (standard) Parameters: - handle (required): GitHub username. - type (optional, enum: all | owner | member): Filter: `all`, `owner`, or `member`. Defaults to `owner`. - sort (optional, enum: created | updated | pushed | full_name): Sort field: `created`, `updated`, `pushed`, or `full_name`. Defaults to `full_name`. - direction (optional, enum: asc | desc): `asc` or `desc`. Defaults to `asc` for full_name, `desc` otherwise. - per_page (optional, integer): Repos per page (1-100). Defaults to 30. - page (optional, integer): 1-indexed page number for pagination. - since (optional, string): Only rows published on or after this date: YYYY-MM-DD (midnight UTC) or an ISO 8601 timestamp. Rows older than it are left off each page. This list is not in date order, so the walk does not stop at the date: keep following `next_cursor`, and each page costs what a page costs even when every row on it is filtered out. A row with no date is kept. `published_after`, `start_date`, `from_date`, `publish_time` (`yesterday`, `this-week`, `this-month`, `last-3-months`, `last-6-months`) and `max_age_days` are accepted and applied as `since`. - until (optional, string): Only rows published on or before this date: YYYY-MM-DD (that whole UTC day is included) or an ISO 8601 timestamp. Newer rows are left off each page and the walk does not stop, so older pages follow. A row with no date is kept. `published_before`, `end_date` and `to_date` are accepted and applied as `until`. - max_pages (optional, integer): 1 to 50 (default 1, or 50 when `max_items` or `max_credits` is sent). Walk up to this many pages in one call and return the rows from all of them. Each page walked is billed exactly as one call to this endpoint (a cached page is free) and counts against your rate limit; its charge and any refund are recorded under the page's own request id, listed in `data.walk.request_ids`. The walk stops early at the last page, or when the request's time budget runs low; `data.walk.stopped` says why (`end`, `max_pages`, `max_items`, `max_credits`, `time_budget`, `page_error`) and `pagination.next_cursor` continues from where it stopped. - max_items (optional, integer): 1 to 5000. Get more in one call: keep walking pages until the response holds at least this many rows, then stop with `data.walk.stopped: "max_items"`. The last page is returned whole (it was billed), so `data.items` can hold up to one page more than this, and `pagination.next_cursor` resumes right after it without skipping a row. Walks up to 50 pages unless `max_pages` says fewer; each page is billed as one call (a cached page is free). Add `max_credits` to cap the spend. A long walk can stop on the time budget first (`"time_budget"`): send the returned cursor with the same params to continue. - max_credits (optional, integer): 1 to 100000. The most this call may spend, across every page it walks. A page starts only while the credits already spent plus that page's price (or, when higher, the most any page of this walk has cost) still fit, so the call never goes past it; the walk then stops with `data.walk.stopped: "max_credits"` and the cursor to resume. Sent alone, it walks as far as the budget goes (up to 50 pages). A value below the price of one page is a free 400 whose `error.details.page_credits` names that price. Credits a row join (`include=`) adds are known only once a page has run, so page 1 is checked against its own price. curl -G "https://www.socialcrawl.dev/v1/github/profile/repos" \ --data-urlencode "handle=octocat" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/repo/readme Get a repository's README Credit cost: 1 (standard) Parameters: - url (required): GitHub repo URL: `https://github.com/{owner}/{repo}`. curl -G "https://www.socialcrawl.dev/v1/github/repo/readme" \ --data-urlencode "url=https://github.com/octocat/Hello-World" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/repo/releases List a repository's releases Credit cost: 1 (standard) Parameters: - url (required): GitHub repo URL: `https://github.com/{owner}/{repo}`. - per_page (optional, integer): Releases per page (1-100). Defaults to 30. - page (optional, integer): 1-indexed page number. - since (optional, string): Only rows published on or after this date: YYYY-MM-DD (midnight UTC) or an ISO 8601 timestamp. Rows older than it are left off each page. This list is not in date order, so the walk does not stop at the date: keep following `next_cursor`, and each page costs what a page costs even when every row on it is filtered out. A row with no date is kept. `published_after`, `start_date`, `from_date`, `publish_time` (`yesterday`, `this-week`, `this-month`, `last-3-months`, `last-6-months`) and `max_age_days` are accepted and applied as `since`. - until (optional, string): Only rows published on or before this date: YYYY-MM-DD (that whole UTC day is included) or an ISO 8601 timestamp. Newer rows are left off each page and the walk does not stop, so older pages follow. A row with no date is kept. `published_before`, `end_date` and `to_date` are accepted and applied as `until`. - max_pages (optional, integer): 1 to 50 (default 1, or 50 when `max_items` or `max_credits` is sent). Walk up to this many pages in one call and return the rows from all of them. Each page walked is billed exactly as one call to this endpoint (a cached page is free) and counts against your rate limit; its charge and any refund are recorded under the page's own request id, listed in `data.walk.request_ids`. The walk stops early at the last page, or when the request's time budget runs low; `data.walk.stopped` says why (`end`, `max_pages`, `max_items`, `max_credits`, `time_budget`, `page_error`) and `pagination.next_cursor` continues from where it stopped. - max_items (optional, integer): 1 to 5000. Get more in one call: keep walking pages until the response holds at least this many rows, then stop with `data.walk.stopped: "max_items"`. The last page is returned whole (it was billed), so `data.items` can hold up to one page more than this, and `pagination.next_cursor` resumes right after it without skipping a row. Walks up to 50 pages unless `max_pages` says fewer; each page is billed as one call (a cached page is free). Add `max_credits` to cap the spend. A long walk can stop on the time budget first (`"time_budget"`): send the returned cursor with the same params to continue. - max_credits (optional, integer): 1 to 100000. The most this call may spend, across every page it walks. A page starts only while the credits already spent plus that page's price (or, when higher, the most any page of this walk has cost) still fit, so the call never goes past it; the walk then stops with `data.walk.stopped: "max_credits"` and the cursor to resume. Sent alone, it walks as far as the budget goes (up to 50 pages). A value below the price of one page is a free 400 whose `error.details.page_credits` names that price. Credits a row join (`include=`) adds are known only once a page has run, so page 1 is checked against its own price. curl -G "https://www.socialcrawl.dev/v1/github/repo/releases" \ --data-urlencode "url=https://github.com/facebook/react" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/repo/issues List a repository's issues (and PRs) Credit cost: 1 (standard) Parameters: - url (required): GitHub repo URL: `https://github.com/{owner}/{repo}`. - type (optional, enum: issue | pr | all): Filter the unified issues+PRs list: `issue` returns only issues, `pr` returns only pull requests, `all` (default) returns both. Each item also carries `post.ext.type` (`issue`/`pull_request`). - state (optional, enum: open | closed | all): `open`, `closed`, or `all`. Defaults to `open`. - labels (optional, string): Comma-separated label names (e.g. `bug,help wanted`). - sort (optional, enum: created | updated | comments): `created`, `updated`, or `comments`. Defaults to `created`. - direction (optional, enum: asc | desc): `asc` or `desc`. Defaults to `desc`. - since (optional, string): Only issues updated at or after this ISO 8601 timestamp. - per_page (optional, integer): Issues per page (1-100). Defaults to 30. - page (optional, integer): 1-indexed page number. - max_pages (optional, integer): 1 to 50 (default 1, or 50 when `max_items` or `max_credits` is sent). Walk up to this many pages in one call and return the rows from all of them. Each page walked is billed exactly as one call to this endpoint (a cached page is free) and counts against your rate limit; its charge and any refund are recorded under the page's own request id, listed in `data.walk.request_ids`. The walk stops early at the last page, or when the request's time budget runs low; `data.walk.stopped` says why (`end`, `max_pages`, `max_items`, `max_credits`, `time_budget`, `page_error`) and `pagination.next_cursor` continues from where it stopped. - max_items (optional, integer): 1 to 5000. Get more in one call: keep walking pages until the response holds at least this many rows, then stop with `data.walk.stopped: "max_items"`. The last page is returned whole (it was billed), so `data.items` can hold up to one page more than this, and `pagination.next_cursor` resumes right after it without skipping a row. Walks up to 50 pages unless `max_pages` says fewer; each page is billed as one call (a cached page is free). Add `max_credits` to cap the spend. A long walk can stop on the time budget first (`"time_budget"`): send the returned cursor with the same params to continue. - max_credits (optional, integer): 1 to 100000. The most this call may spend, across every page it walks. A page starts only while the credits already spent plus that page's price (or, when higher, the most any page of this walk has cost) still fit, so the call never goes past it; the walk then stops with `data.walk.stopped: "max_credits"` and the cursor to resume. Sent alone, it walks as far as the budget goes (up to 50 pages). A value below the price of one page is a free 400 whose `error.details.page_credits` names that price. Credits a row join (`include=`) adds are known only once a page has run, so page 1 is checked against its own price. curl -G "https://www.socialcrawl.dev/v1/github/repo/issues" \ --data-urlencode "url=https://github.com/facebook/react" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/issue Get a single issue or pull request Credit cost: 1 (standard) Parameters: - url (required): GitHub HTML URL: `https://github.com/{owner}/{repo}/issues/{n}` or `/pull/{n}`. curl -G "https://www.socialcrawl.dev/v1/github/issue" \ --data-urlencode "url=https://github.com/facebook/react/issues/27522" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/issue/comments Get comments on an issue or pull request Credit cost: 1 (standard) Parameters: - url (required): GitHub HTML URL of the issue or PR. - since (optional, string): Only comments updated at or after this ISO 8601 timestamp. - per_page (optional, integer): Comments per page (1-100). Defaults to 30. - page (optional, integer): 1-indexed page number. - max_pages (optional, integer): 1 to 50 (default 1, or 50 when `max_items` or `max_credits` is sent). Walk up to this many pages in one call and return the rows from all of them. Each page walked is billed exactly as one call to this endpoint (a cached page is free) and counts against your rate limit; its charge and any refund are recorded under the page's own request id, listed in `data.walk.request_ids`. The walk stops early at the last page, or when the request's time budget runs low; `data.walk.stopped` says why (`end`, `max_pages`, `max_items`, `max_credits`, `time_budget`, `page_error`) and `pagination.next_cursor` continues from where it stopped. - max_items (optional, integer): 1 to 5000. Get more in one call: keep walking pages until the response holds at least this many rows, then stop with `data.walk.stopped: "max_items"`. The last page is returned whole (it was billed), so `data.items` can hold up to one page more than this, and `pagination.next_cursor` resumes right after it without skipping a row. Walks up to 50 pages unless `max_pages` says fewer; each page is billed as one call (a cached page is free). Add `max_credits` to cap the spend. A long walk can stop on the time budget first (`"time_budget"`): send the returned cursor with the same params to continue. - max_credits (optional, integer): 1 to 100000. The most this call may spend, across every page it walks. A page starts only while the credits already spent plus that page's price (or, when higher, the most any page of this walk has cost) still fit, so the call never goes past it; the walk then stops with `data.walk.stopped: "max_credits"` and the cursor to resume. Sent alone, it walks as far as the budget goes (up to 50 pages). A value below the price of one page is a free 400 whose `error.details.page_credits` names that price. Credits a row join (`include=`) adds are known only once a page has run, so page 1 is checked against its own price. curl -G "https://www.socialcrawl.dev/v1/github/issue/comments" \ --data-urlencode "url=https://github.com/facebook/react/issues/27522" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/search Search GitHub issues and pull requests Credit cost: 1 (standard) Parameters: - query (required): GitHub search query (uses GitHub's qualifier syntax: see https://docs.github.com/en/search-github/searching-on-github/searching-issues-and-pull-requests). - sort (optional, enum: reactions | comments | created | updated): Sort field: `reactions`, `comments`, `created`, `updated`. Defaults to best-match relevance. - order (optional, enum: asc | desc): `asc` or `desc`. Defaults to `desc`. - per_page (optional, integer): Results per page (1-100). Defaults to 30. - page (optional, integer): 1-indexed page number. - since (optional, string): Only rows published on or after this date: YYYY-MM-DD (midnight UTC) or an ISO 8601 timestamp. Rows older than it are left off each page. This list is not in date order, so the walk does not stop at the date: keep following `next_cursor`, and each page costs what a page costs even when every row on it is filtered out. A row with no date is kept. `published_after`, `start_date`, `from_date`, `publish_time` (`yesterday`, `this-week`, `this-month`, `last-3-months`, `last-6-months`) and `max_age_days` are accepted and applied as `since`. - until (optional, string): Only rows published on or before this date: YYYY-MM-DD (that whole UTC day is included) or an ISO 8601 timestamp. Newer rows are left off each page and the walk does not stop, so older pages follow. A row with no date is kept. `published_before`, `end_date` and `to_date` are accepted and applied as `until`. - max_pages (optional, integer): 1 to 50 (default 1, or 50 when `max_items` or `max_credits` is sent). Walk up to this many pages in one call and return the rows from all of them. Each page walked is billed exactly as one call to this endpoint (a cached page is free) and counts against your rate limit; its charge and any refund are recorded under the page's own request id, listed in `data.walk.request_ids`. The walk stops early at the last page, or when the request's time budget runs low; `data.walk.stopped` says why (`end`, `max_pages`, `max_items`, `max_credits`, `time_budget`, `page_error`) and `pagination.next_cursor` continues from where it stopped. - max_items (optional, integer): 1 to 5000. Get more in one call: keep walking pages until the response holds at least this many rows, then stop with `data.walk.stopped: "max_items"`. The last page is returned whole (it was billed), so `data.items` can hold up to one page more than this, and `pagination.next_cursor` resumes right after it without skipping a row. Walks up to 50 pages unless `max_pages` says fewer; each page is billed as one call (a cached page is free). Add `max_credits` to cap the spend. A long walk can stop on the time budget first (`"time_budget"`): send the returned cursor with the same params to continue. - max_credits (optional, integer): 1 to 100000. The most this call may spend, across every page it walks. A page starts only while the credits already spent plus that page's price (or, when higher, the most any page of this walk has cost) still fit, so the call never goes past it; the walk then stops with `data.walk.stopped: "max_credits"` and the cursor to resume. Sent alone, it walks as far as the budget goes (up to 50 pages). A value below the price of one page is a free 400 whose `error.details.page_credits` names that price. Credits a row join (`include=`) adds are known only once a page has run, so page 1 is checked against its own price. curl -G "https://www.socialcrawl.dev/v1/github/search" \ --data-urlencode "query=repo:vercel/next.js is:issue is:open" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/repo/top-issues Top feature request and top complaint for a repository Credit cost: 5 (advanced) Parameters: - url (required): GitHub repo URL: `https://github.com/{owner}/{repo}`. curl -G "https://www.socialcrawl.dev/v1/github/repo/top-issues" \ --data-urlencode "url=https://github.com/facebook/react" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/repo/dossier Full project dossier for a repository Credit cost: 5 (advanced) Parameters: - url (required): GitHub repo URL: `https://github.com/{owner}/{repo}`. curl -G "https://www.socialcrawl.dev/v1/github/repo/dossier" \ --data-urlencode "url=https://github.com/facebook/react" \ -H "x-api-key: YOUR_API_KEY" ## GET /v1/github/user/profile-velocity User contribution velocity dossier Credit cost: 10 (premium) Parameters: - handle (required): GitHub username. - depth (optional, enum: quick | default | deep): `quick`, `default`, or `deep`. Defaults to `default`. Trades off upstream calls vs. dossier richness. curl -G "https://www.socialcrawl.dev/v1/github/user/profile-velocity" \ --data-urlencode "handle=octocat" \ -H "x-api-key: YOUR_API_KEY"