{"id":16506065,"url":"https://github.com/borderless/worker-sentry","last_synced_at":"2025-03-28T18:32:25.547Z","repository":{"id":52967559,"uuid":"264697095","full_name":"borderless/worker-sentry","owner":"borderless","description":"Sentry client for Cloudflare Workers using `fetch` and native V8 stack traces","archived":false,"fork":false,"pushed_at":"2023-12-12T06:42:16.000Z","size":1149,"stargazers_count":14,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-22T18:03:55.501Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/borderless.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":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-05-17T15:23:57.000Z","updated_at":"2022-09-01T04:09:29.000Z","dependencies_parsed_at":"2024-10-30T05:26:57.275Z","dependency_job_id":null,"html_url":"https://github.com/borderless/worker-sentry","commit_stats":{"total_commits":33,"total_committers":3,"mean_commits":11.0,"dds":0.06060606060606055,"last_synced_commit":"e9aeb25cf9b3a5c3496d5ddc0536f2cc9c34ddd2"},"previous_names":["borderlesslabs/worker-sentry"],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/borderless%2Fworker-sentry","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/borderless%2Fworker-sentry/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/borderless%2Fworker-sentry/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/borderless%2Fworker-sentry/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/borderless","download_url":"https://codeload.github.com/borderless/worker-sentry/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246080952,"owners_count":20720620,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-10-11T15:16:53.978Z","updated_at":"2025-03-28T18:32:24.624Z","avatar_url":"https://github.com/borderless.png","language":"TypeScript","readme":"# Worker Sentry\n\n[![NPM version][npm-image]][npm-url]\n[![NPM downloads][downloads-image]][downloads-url]\n[![Build status][build-image]][build-url]\n[![Build coverage][coverage-image]][coverage-url]\n\n\u003e Sentry client for Cloudflare Workers using `fetch` and native [V8 stack traces](https://v8.dev/docs/stack-trace-api).\n\n## Installation\n\n```\nnpm install @borderless/worker-sentry --save\n```\n\n## Usage\n\n```ts\nimport { Sentry } from \"@borderless/worker-sentry\";\n\nconst sentry = new Sentry({ dsn: \"https://123@456.ingest.sentry.io/789\" });\n\naddEventListener(\"fetch\", (event) =\u003e {\n  event.respondWith(\n    handler(event.request).catch((err) =\u003e {\n      // Extend the event lifetime until the response from Sentry has resolved.\n      // Docs: https://developers.cloudflare.com/workers/runtime-apis/fetch-event#methods\n      event.waitUntil(\n        // Sends a request to Sentry and returns the response promise.\n        sentry.captureException(err, {\n          tags: {},\n          user: {\n            ip_address: event.request.headers.get(\"cf-connecting-ip\"),\n          },\n        })\n      );\n\n      // Respond to the original request while the error is being logged (above).\n      return new Response(err.message || \"Internal Error\", { status: 500 });\n    })\n  );\n});\n```\n\n## License\n\nMIT\n\n[npm-image]: https://img.shields.io/npm/v/@borderless/worker-sentry\n[npm-url]: https://npmjs.org/package/@borderless/worker-sentry\n[downloads-image]: https://img.shields.io/npm/dm/@borderless/worker-sentry\n[downloads-url]: https://npmjs.org/package/@borderless/worker-sentry\n[build-image]: https://img.shields.io/github/workflow/status/borderless/worker-sentry/CI/main\n[build-url]: https://github.com/borderless/worker-sentry/actions/workflows/ci.yml?query=branch%3Amain\n[coverage-image]: https://img.shields.io/codecov/c/gh/borderless/worker-sentry\n[coverage-url]: https://codecov.io/gh/borderless/worker-sentry\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fborderless%2Fworker-sentry","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fborderless%2Fworker-sentry","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fborderless%2Fworker-sentry/lists"}