-
Notifications
You must be signed in to change notification settings - Fork 0
RepoRank API
The open source community is an extremely important aspect to RepoRank, so it was important that RepoRank offered a public REST API allowing open access to the RepoRank algorithm and data.
The public endpoint is api.reporank.dev
and access is completely free, there is no need for any API key or user authentication.
The root endpoint is designed to allow clients to verify the status of the API, to check the service is running. It also acts as a nice landing page to anyone who stumbles across the domain.
{
"header": {
"code": 200,
"message": "OK"
},
"body": {
"title": "🔥RepoRank Public API",
"version": "1.0.0",
"github": "https://github.com/jackdevey/reporank",
"docs": "https://github.com/jackdevey/reporank/wiki/RepoRank-API",
"frontend": "https://reporank.dev/"
}
}
The main API endpoint for RepoRank calculates the latest score for the repo specified in the request's parameters. Simplicity is important in the design of the API, so repositories are identified using the same owner/repo
format as GitHub.
-
owner
The username of the user or organization that owns the repository -
repo
The name of the repository
Using
facebook/react
, request made on the26/02/2022
{
"header": {
"code": 200,
"message": "OK"
},
"body": {
"score": 2531194018,
"level": 10,
"status": {
"title": "Legendary",
"color": "orange"
},
"breakdown": {
"stars": 182991,
"forks": 37365,
"openIssues": 969,
"codeChange": 588479,
"community": 85
}
}
}
The badge API endpoint for RepoRank calculates the latest score for the repo specified in the request's parameters and generates a shields.io style badge for inclusion in GitHub readmes.
-
owner
The username of the user or organization that owns the repository -
repo
The name of the repository
Using
facebook/react
, request using live data