How to get GitHub following
GET request to /v1/github/following with your input. You get clean JSON back in seconds for ~3 credits (0.1/result) per call — no OAuth, scraping or platform SDKs. Accounts a user follows — same card and ~0.1/row pricing as followers.How to get GitHub following (step by step)
- 1
Get a free API key
Create a free Captapi account (100 credits, no card) and generate an API key from the dashboard.
- 2
Call the GitHub Following API
Send an authenticated GET request to /v1/github/following with your input. No OAuth, no scraping setup.
- 3
Read the JSON response
Parse the clean JSON response. Pass cache=true for a free 24h cache hit; default is always fresh.
Code example
curl "https://api.captapi.com/v1/github/following?username=getify" \
-H "Authorization: Bearer capt_live_..."
# or: -H "x-api-key: capt_live_..."What the response looks like
{
"success": true,
"data": {
"username": "getify",
"totalReturned": 2,
"nextCursor": "eyJ2IjoxLCJrIjoiZm9sbG93aW5nIiwicCI6Mn0",
"hasMore": true,
"following": [
{
"id": 579,
"login": "mikeal",
"type": "User",
"url": "https://github.com/mikeal",
"avatar": "https://avatars.githubusercontent.com/u/579?v=4"
},
{
"id": 9950313,
"login": "nodejs",
"type": "Organization",
"url": "https://github.com/nodejs",
"avatar": "https://avatars.githubusercontent.com/u/9950313?v=4"
}
]
}
}Billing metadata (credits charged, cache hit/miss) is returned in the X-Captapi-Credits and X-Captapi-Cache response headers.
Request parameters
| Name | Type | Required | Description |
|---|---|---|---|
| username | string | Yes | GitHub username or profile URL, e.g. getify. |
| limit | integer | No | Max items to return (default 30, max 100). Billed per result. |
| cursor | string | No | Opaque cursor from a previous nextCursor (GitHub Link page=). Not a bare page number. |
| cache | boolean | No | Set true to serve from the 24h response cache (0 credits on hit). Default false — always fetch fresh. Envelope includes cached + cachedAt on hits. |
Frequently asked questions
What does the GitHub Following API do?
The GitHub Following API lets you list items in bulk with metadata from a public GitHub following using one GET request to /v1/github/following. It returns clean JSON — no OAuth or infrastructure setup required.
How many credits does the GitHub Following API cost?
At the default limit this endpoint costs 3 credits (0.1 per result). Billing scales with how many results you request. Pass cache=true to serve from the 24h cache (0 credits on hit); default is always fresh. Hits include cached + cachedAt. Selected profile endpoints also accept cacheMaxAge=1d|3d|7d|14d|30d. Failed or empty results are never charged.
Do I need a GitHub API key or OAuth?
No. A single Captapi key works across every platform Captapi supports — YouTube, TikTok, Instagram, Facebook, Twitter/X, Reddit, Threads, Bluesky, Pinterest, LinkedIn, Rumble, Spotify, Kwai, and more. We handle proxies, rate limits, retries, and authentication for you.
Why is paging a large account expensive?
There is no sampling/since parameter — every page costs ~0.1 credits/row. ~250k followers ≈ 25k credits. For full archives call api.github.com (free, rate-limited) directly.
What is id / type for?
id is GitHub's numeric account id (stable for joins/dedup). type is User or Organization — both come from the upstream followers/following payload.
Is the GitHub Following API suitable for production use?
Yes. It is a stable REST endpoint with predictable JSON and automatic retries. Pass cache=true to serve from the 24h cache (0 credits on hit); default is always fresh. Hits include cached + cachedAt. Selected profile endpoints also accept cacheMaxAge=1d|3d|7d|14d|30d. Use it for analytics, monitoring, and content automation.
Ready to get GitHub following?
Start free with 100 credits — no credit card required.
Get your free API key