{"name":"@opentelemetry/exporter-prometheus","version":"0.20.0","keywords":["opentelemetry","nodejs","tracing","profiling"],"author":{"name":"OpenTelemetry Authors"},"license":"Apache-2.0","_id":"@opentelemetry/exporter-prometheus@0.20.0","maintainers":[{"name":"mayurkale22","email":"mayurkale22@gmail.com"},{"name":"bogdandrutu","email":"bogdandrutu@gmail.com"},{"name":"dyladan","email":"dyladan@gmail.com"},{"name":"obecny","email":"bobecny@gmail.com"}],"homepage":"https://github.com/open-telemetry/opentelemetry-js#readme","bugs":{"url":"https://github.com/open-telemetry/opentelemetry-js/issues"},"dist":{"shasum":"ab4a1c48d357eb5ee1065a0e515aa470deb6d650","tarball":"http://registry-npm.ywwl.com/@opentelemetry/exporter-prometheus/download/@opentelemetry/exporter-prometheus-0.20.0.tgz","fileCount":24,"integrity":"sha512-ZE0WbpnM7aChXRitgfwNEWRYkwylgWbMtiWRGtHupU9DculZZk7617gpddix0SmOc5PSQXMOhUMxe11gUN25nw==","signatures":[{"sig":"MEQCIEoo0Jra0MDCmvQE+qibhG1W3WJ7KeH/p4KmBR8iFWWQAiBmBzDDbUWnjWJi2Q9LPvxCPs3rKIn7cgX11UESo5iHiw==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":52513,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJguR9dCRA9TVsSAnZWagAAapYP/AyL9j1A85bD3EK4o407\nNrEbFLs0UZZHXu3Uk3zywS6CGtbGUteAgefMlE9Vsb1PM69Gtp9Os4Dkayt9\nmCOETuUtfYv/mYBVOIB0FoqNuxXfDhNDkaPVofid6lRfTMM+T7Uzn7nfEO1v\ngLosvx9znvn0gbIk82+6YVaHIRKE39Pl2ZlhpyM5GKHjFl+Rj7l9HW+YWQVp\nqpnK48XPPiC9sIZmxCHC88YBmcga7/uGqCXNvDeDKfynce8/7bJrGU6yQ0ZW\nfrIZOZ0/i2Mhp9ktcCHk0cDfnow+bKKZHYaj9E/644sfJ8zszZ8kifia5Vpw\nRoCaeGtHRGMp8HdoFTdjFrOlXoPJnXS0Yqfn6E8aSu8TJ20fUCWnQpmb8v+1\nsQ8xQjO1QIrGvBoX71O7mvs6lwG5zC9AnfQMoZwXmHsca6TjOVKaeN8Cu85U\nQitffe0I1E5IblOHFiOJr2HNzCvPmD6ituefAnKW1QbtASvUBE/nfDGeRyRu\nJt19cgVrsginDQXyfOFwnVTGuozC3CVr5yvjSUubm7tW4/RNrMJDj2tIjZK4\nHDO0a8vJMF/6kkW+el0S8xBPRIT0oJxwUHjQSd2ACwbonSE341F2c/Gh54NC\nCV0Xl5mpvoSeL718nZe1n45S/GIqj2lDLzzXuOWwlxVnqgAkr/r4XSeEE0Hx\nEteG\r\n=OcY7\r\n-----END PGP SIGNATURE-----\r\n","size":15215,"noattachment":false,"key":"/@opentelemetry/exporter-prometheus/-/@opentelemetry/exporter-prometheus-0.20.0.tgz"},"main":"build/src/index.js","types":"build/src/index.d.ts","engines":{"node":">=8.0.0"},"gitHead":"f79aef422b53f1314cb0b031651875658fc17008","scripts":{"tdd":"npm run test -- --watch-extensions ts --watch","lint":"eslint . --ext .ts","test":"nyc ts-mocha -p tsconfig.json 'test/**/*.test.ts'","clean":"tsc --build --clean","watch":"tsc --build --watch","codecov":"nyc report --reporter=json && codecov -f coverage/*.json -p ../../","compile":"tsc --build","version":"node ../../scripts/version-update.js","lint:fix":"eslint . --ext .ts --fix"},"_npmUser":{"name":"dyladan","email":"dyladan@gmail.com"},"repository":{"url":"git+https://github.com/open-telemetry/opentelemetry-js.git","type":"git"},"_npmVersion":"lerna/3.22.1/node@v14.8.0+x64 (darwin)","description":"OpenTelemetry Exporter Prometheus provides a metrics endpoint for Prometheus","directories":{},"_nodeVersion":"14.8.0","dependencies":{"@opentelemetry/core":"0.20.0","@opentelemetry/metrics":"0.20.0","@opentelemetry/api-metrics":"0.20.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"nyc":"15.1.0","mocha":"7.2.0","sinon":"10.0.0","rimraf":"3.0.2","codecov":"3.8.1","ts-node":"9.1.1","ts-mocha":"8.0.0","typescript":"4.3.2","@types/node":"14.14.43","@types/mocha":"8.2.2","@types/sinon":"9.0.11","@opentelemetry/api":"^0.20.0"},"peerDependencies":{"@opentelemetry/api":"^0.20.0"},"_npmOperationalInternal":{"tmp":"tmp/exporter-prometheus_0.20.0_1622744925556_0.7198374537072416","host":"s3://npm-registry-packages"},"readme":"# OpenTelemetry Prometheus Metric Exporter\n\n[![NPM Published Version][npm-img]][npm-url]\n[![Apache License][license-image]][license-image]\n\n**Note: This is an experimental package under active development. New releases may include breaking changes.**\n\nThe OpenTelemetry Prometheus Metrics Exporter allows the user to send collected [OpenTelemetry Metrics](https://github.com/open-telemetry/opentelemetry-js/tree/main/packages/sdk-metrics) to Prometheus.\n\n[Prometheus](https://prometheus.io/) is a monitoring system that collects metrics, by scraping exposed endpoints at regular intervals, evaluating rule expressions. It can also trigger alerts if certain conditions are met. For assistance setting up Prometheus, [click here for a guided codelab](https://opencensus.io/codelabs/prometheus/#0).\n\n## Installation\n\n```bash\nnpm install --save @opentelemetry/sdk-metrics\nnpm install --save @opentelemetry/exporter-prometheus\n```\n\n## Usage\n\nCreate & register the exporter on your application.\n\n```js\nconst { PrometheusExporter } = require('@opentelemetry/exporter-prometheus');\nconst { MeterProvider }  = require('@opentelemetry/sdk-metrics');\n\n// Add your port and startServer to the Prometheus options\nconst options = {port: 9464};\nconst exporter = new PrometheusExporter(options);\n\n// Creates MeterProvider and installs the exporter as a MetricReader\nconst meterProvider = new MeterProvider({\n  readers: [exporter],\n});\nconst meter = meterProvider.getMeter('example-prometheus');\n\n// Now, start recording data\nconst counter = meter.createCounter('metric_name', {\n  description: 'Example of a counter'\n});\ncounter.add(10, { pid: process.pid });\n\n// .. some other work\n```\n\n## Viewing your metrics\n\nWith the above you should now be able to navigate to the Prometheus UI at: <http://localhost:9464/metrics>\n\n## Useful links\n\n- For more information on OpenTelemetry, visit: <https://opentelemetry.io/>\n- To learn more about Prometheus, visit: <https://prometheus.io/>\n- For more about OpenTelemetry JavaScript: <https://github.com/open-telemetry/opentelemetry-js>\n- For help or feedback on this project, join us in [GitHub Discussions][discussions-url]\n\n## License\n\nApache 2.0 - See [LICENSE][license-url] for more information.\n\n[discussions-url]: https://github.com/open-telemetry/opentelemetry-js/discussions\n[license-url]: https://github.com/open-telemetry/opentelemetry-js/blob/main/LICENSE\n[license-image]: https://img.shields.io/badge/license-Apache_2.0-green.svg?style=flat\n[npm-url]: https://www.npmjs.com/package/@opentelemetry/exporter-prometheus\n[npm-img]: https://badge.fury.io/js/%40opentelemetry%2Fexporter-prometheus.svg\n","publish_time":1622744925719,"_cnpm_publish_time":1622744925719,"dist-tags":{"canary":"0.300.0-rc.0","latest":"0.301.0","next":"0.34.0"}}