{"id":13430202,"url":"https://github.com/prom-client-net/prom-client-metricpusher","last_synced_at":"2026-01-12T10:51:59.145Z","repository":{"id":40384441,"uuid":"103938024","full_name":"prom-client-net/prom-client-metricpusher","owner":"prom-client-net","description":"Push metrics to Pushgateway","archived":false,"fork":false,"pushed_at":"2026-01-02T01:32:40.000Z","size":347,"stargazers_count":19,"open_issues_count":1,"forks_count":5,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-01-07T16:03:56.534Z","etag":null,"topics":["metrics","prometheus","prometheus-client"],"latest_commit_sha":null,"homepage":"","language":"C#","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/prom-client-net.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":"phnx47","ko_fi":"phnx47","buy_me_a_coffee":"phnx47"}},"created_at":"2017-09-18T12:46:49.000Z","updated_at":"2026-01-02T01:32:43.000Z","dependencies_parsed_at":"2023-10-17T05:04:38.646Z","dependency_job_id":"8bf61837-615c-4586-ad80-367b1648f5b4","html_url":"https://github.com/prom-client-net/prom-client-metricpusher","commit_stats":null,"previous_names":["prometheusclientnet/prometheus.client.metricpusher"],"tags_count":19,"template":false,"template_full_name":null,"purl":"pkg:github/prom-client-net/prom-client-metricpusher","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prom-client-net%2Fprom-client-metricpusher","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prom-client-net%2Fprom-client-metricpusher/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prom-client-net%2Fprom-client-metricpusher/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prom-client-net%2Fprom-client-metricpusher/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/prom-client-net","download_url":"https://codeload.github.com/prom-client-net/prom-client-metricpusher/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prom-client-net%2Fprom-client-metricpusher/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28338846,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-12T10:40:25.642Z","status":"ssl_error","status_checked_at":"2026-01-12T10:39:27.820Z","response_time":98,"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":["metrics","prometheus","prometheus-client"],"created_at":"2024-07-31T02:00:51.010Z","updated_at":"2026-01-12T10:51:59.137Z","avatar_url":"https://github.com/prom-client-net.png","language":"C#","funding_links":["https://github.com/sponsors/phnx47","https://ko-fi.com/phnx47","https://buymeacoffee.com/phnx47"],"categories":["Frameworks, Libraries and Tools"],"sub_categories":["Code Analysis and Metrics"],"readme":"# Prometheus.Client.MetricPusher\n\n[![ci](https://img.shields.io/github/actions/workflow/status/prom-client-net/prom-client-metricpusher/ci.yml?branch=main\u0026label=ci\u0026logo=github\u0026style=flat-square)](https://github.com/prom-client-net/prom-client-metricpusher/actions/workflows/ci.yml)\n[![nuget](https://img.shields.io/nuget/v/Prometheus.Client.MetricPusher?logo=nuget\u0026style=flat-square)](https://www.nuget.org/packages/Prometheus.Client.MetricPusher)\n[![nuget](https://img.shields.io/nuget/dt/Prometheus.Client.MetricPusher?logo=nuget\u0026style=flat-square)](https://www.nuget.org/packages/Prometheus.Client.MetricPusher)\n[![codecov](https://img.shields.io/codecov/c/github/prom-client-net/prom-client-metricpusher?logo=codecov\u0026style=flat-square)](https://app.codecov.io/gh/prom-client-net/prom-client-metricpusher)\n[![license](https://img.shields.io/github/license/prom-client-net/prom-client-metricpusher?style=flat-square)](https://github.com/prom-client-net/prom-client-metricpusher/blob/main/LICENSE)\n\n## Pushgateway\n\nSometimes when it is not possible to pull e.g. - nodes behind LB or there is a worker like daemon or windows service that does not have HTTP endpoint still there is way to push your metrics to Pushgateway server that you can install from [here](https://github.com/prometheus/pushgateway/releases).\n\n## Install\n\n```sh\ndotnet add package Prometheus.Client.MetricPusher\n```\n\n## Use\n\n[Examples](https://github.com/prom-client-net/prom-examples)\n\nOne push. You can use Timer for regularly push to Pushgateway:\n\n```c#\nvar pusher = new MetricPusher(new MetricPusherOptions\n{\n    Endpoint = \"http://localhost:9091\",\n    Job = \"pushgateway\",\n    Instance = \"instance\"\n});\n\nawait pusher.PushAsync();\n```\n\nPush with Auth:\n\n```c#\nvar pusher = new MetricPusher(new MetricPusherOptions\n{\n    Endpoint = \"http://localhost:9091\",\n    Job = \"pushgateway\",\n    Instance = \"instance\",\n    AdditionalHeaders = new Dictionary\u003cstring, string\u003e { { \"Authorization\", \"Bearer \" + accessToken } }\n});\n```\n\nBackground server:\n\n```c#\nvar pusher = new MetricPusher(new MetricPusherOptions\n{\n    Endpoint = \"http://localhost:9091\",\n    Job = \"pushgateway\"\n});\n\nvar worker = new MetricPushServer(pusher);\nworker.Start();\n// code\nworker.Stop();\n```\n\n## Contribute\n\nContributions to the package are always welcome!\n\n* Report any bugs or issues you find on the [issue tracker](https://github.com/prom-client-net/prom-client-metricpusher/issues).\n* You can grab the source code at the package's [git repository](https://github.com/prom-client-net/prom-client-metricpusher).\n\n## License\n\nAll contents of this package are licensed under the [MIT license](https://opensource.org/licenses/MIT).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprom-client-net%2Fprom-client-metricpusher","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fprom-client-net%2Fprom-client-metricpusher","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprom-client-net%2Fprom-client-metricpusher/lists"}