{"id":13581735,"url":"https://github.com/kalgurn/github-rate-limits-prometheus-exporter","last_synced_at":"2026-01-14T18:41:08.509Z","repository":{"id":37945408,"uuid":"437474395","full_name":"kalgurn/github-rate-limits-prometheus-exporter","owner":"kalgurn","description":"GitHub Rate Limits Prometheus exporter. Works with both App and PAT credentials ","archived":false,"fork":false,"pushed_at":"2025-07-17T06:02:45.000Z","size":253,"stargazers_count":14,"open_issues_count":9,"forks_count":9,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-17T15:49:17.816Z","etag":null,"topics":["github-rate-limit","go","prometheus","prometheus-exporter"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kalgurn.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-12-12T06:52:25.000Z","updated_at":"2025-07-16T14:12:11.000Z","dependencies_parsed_at":"2024-06-19T03:51:16.837Z","dependency_job_id":"a357b1ea-0dfe-4296-ab93-34631ff80541","html_url":"https://github.com/kalgurn/github-rate-limits-prometheus-exporter","commit_stats":null,"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/kalgurn/github-rate-limits-prometheus-exporter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kalgurn%2Fgithub-rate-limits-prometheus-exporter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kalgurn%2Fgithub-rate-limits-prometheus-exporter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kalgurn%2Fgithub-rate-limits-prometheus-exporter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kalgurn%2Fgithub-rate-limits-prometheus-exporter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kalgurn","download_url":"https://codeload.github.com/kalgurn/github-rate-limits-prometheus-exporter/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kalgurn%2Fgithub-rate-limits-prometheus-exporter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28430880,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T16:38:47.836Z","status":"ssl_error","status_checked_at":"2026-01-14T16:34:59.695Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["github-rate-limit","go","prometheus","prometheus-exporter"],"created_at":"2024-08-01T15:02:12.871Z","updated_at":"2026-01-14T18:41:08.494Z","avatar_url":"https://github.com/kalgurn.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"[![Vulnerabilities](https://sonarcloud.io/api/project_badges/measure?project=kalgurn_github-rate-limits-prometheus-exporter\u0026metric=vulnerabilities)](https://sonarcloud.io/summary/new_code?id=kalgurn_github-rate-limits-prometheus-exporter)\n[![Technical Debt](https://sonarcloud.io/api/project_badges/measure?project=kalgurn_github-rate-limits-prometheus-exporter\u0026metric=sqale_index)](https://sonarcloud.io/summary/new_code?id=kalgurn_github-rate-limits-prometheus-exporter)\n[![Security Rating](https://sonarcloud.io/api/project_badges/measure?project=kalgurn_github-rate-limits-prometheus-exporter\u0026metric=security_rating)](https://sonarcloud.io/summary/new_code?id=kalgurn_github-rate-limits-prometheus-exporter)\n[![Artifact Hub](https://img.shields.io/endpoint?url=https://artifacthub.io/badge/repository/github-rate-limit-prometheus-exporter)](https://artifacthub.io/packages/search?repo=github-rate-limit-prometheus-exporter)\n# Github Rate Limit Prometheus Exporter\n\nA [prometheus](https://prometheus.io/) exporter which scrapes GitHub API for the rate limits used by PAT/GitHub App.\n\nHelm Chart with values and deployment can be found [here](./helm/github-rate-limits-prometheus-exporter)\n\nFor the exporter to run you need to supply either a GitHub Token or a set of a GitHub App credentials, alongside with a type of authentication to use(pat/app)\n\nYou can use the environment variable `GITHUB_LOG_METRIC_COLLECTION` (boolean) to control if rate limit metrics are also logged to the console when they're collected by Prometheus. As the functionality is backed by [Golang `strconv.ParseBool`](https://pkg.go.dev/strconv#ParseBool), it accepts 1, t, T, TRUE, true, True, 0, f, F, FALSE, false, False. Any other value or lack thereof will default to enabling logs.\n\n### The metrics can then be represented on a [grafana](https://grafana.com) dashboard\n\n\n![Grafana panel example](./images/example_panel.png)\n\n\n\n## Docker\n\nPAT\n```sh\ndocker run -d \\\n    -e GITHUB_AUTH_TYPE=PAT \\\n    -e GITHUB_ACCOUNT_NAME=name_of_my_app\n    -e GITHUB_TOKEN=my_token \\\n    -p 2112:2112 \\\n    ghcr.io/kalgurn/grl-exporter:latest\n```\n\nGitHub APP\n```\ndocker run -d \\\n    -e GITHUB_AUTH_TYPE=APP \\\n    -e GITHUB_APP_ID=my_app_id \\\n    -e GITHUB_INSTALLATION_ID=my_app_installation_id \\\n    -e GITHUB_ACCOUNT_NAME=name_of_my_app\n    -e GITHUB_PRIVATE_KEY_PATH=/tmp\n    -v $PWD/path_to/key.pem:/tmp/key.pem\n    -p 2112:2112 \\\n    ghcr.io/kalgurn/grl-exporter:latest\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkalgurn%2Fgithub-rate-limits-prometheus-exporter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkalgurn%2Fgithub-rate-limits-prometheus-exporter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkalgurn%2Fgithub-rate-limits-prometheus-exporter/lists"}