GroundsocialDocs

API · GitHub

GET /github/users/{handle}/contributions

A GitHub user’s contribution calendar for a year: daily counts and the total.

RequestGET /v1/github/users/{handle}/contributions
Operation idgithub.user.contributions
Cost1 credit, refunded if the call fails
AuthAPI key: Authorization: Bearer <key> or x-api-key.

A GitHub user’s contribution calendar for a year: daily counts and the total.

Path parameters

NameTypeRequiredDescription
handlestringyesGitHub username, with or without the @, or a profile URL. Example: torvalds.

Query parameters

NameTypeRequiredDescription
yearintegernoCalendar year (default: the last 12 months).

Responses

StatusMeaningSchema
200The calendar.GitHubContributionsResponse
400Invalid input. Nothing was charged.Error
401Missing or invalid API key.Error
402Not enough credits, a spend cap was reached, or payment is required.Error
403The target is private, or the account is suspended.Error
404No public GitHub user, repository or issue by that name.Error
429Too many requests. Wait for Retry-After seconds.Error
503GitHub is temporarily unavailable. Retryable; nothing was charged.Error

GitHubContributionsResponse fields

FieldTypeDescription
loginstring
yearinteger | nullThe calendar year, or null for the last 12 months.
totalintegerContributions in the period, as the profile states it.
fromstring | null
tostring | null
daysGitHubContributionDay[]

Errors use one shape everywhere; see Errors for every code and what to do.