{"_id":"@achrononlimited/pulse-nest","name":"@achrononlimited/pulse-nest","dist-tags":{"latest":"0.1.0"},"versions":{"0.1.0":{"name":"@achrononlimited/pulse-nest","version":"0.1.0","description":"pulse heartbeat client + @Pulse decorator for NestJS / TypeScript","license":"MIT","author":{"name":"Achronon"},"homepage":"https://github.com/Achronon/pulse/tree/main/clients/nest#readme","repository":{"type":"git","url":"git+https://github.com/Achronon/pulse.git","directory":"clients/nest"},"bugs":{"url":"https://github.com/Achronon/pulse/issues"},"keywords":["pulse","heartbeat","cron","liveness","monitoring","healthcheck","nestjs","decorator","prometheus"],"type":"commonjs","main":"dist/index.js","types":"dist/index.d.ts","publishConfig":{"access":"public","provenance":true},"engines":{"node":">=18"},"scripts":{"build":"tsc -p tsconfig.json","test":"vitest run","prepublishOnly":"npm run build"},"dependencies":{"cron-parser":"^4.9.0"},"devDependencies":{"@types/node":"^20.11.0","typescript":"^5.4.0","vitest":"^3.2.6"},"gitHead":"266a592ed19fe61af3603839da6bda332ba5f7a7","_id":"@achrononlimited/pulse-nest@0.1.0","_nodeVersion":"24.14.1","_npmVersion":"11.11.0","dist":{"integrity":"sha512-qQ1HJSVLg+YDIOIsa+kaYYNmvOKium5HpDIAOK7bzonrWYqtrw6BjSkXutKBeutwSvHsJoVIL2oe1SxUWWtcng==","shasum":"931ea85914306146628983e457adb9ea1faf4dbe","tarball":"https://registry.npmjs.org/@achrononlimited/pulse-nest/-/pulse-nest-0.1.0.tgz","fileCount":5,"unpackedSize":11606,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQDFOqpg/voFupWUiMrvlF29uJ3qFgjwmQwun4S4c5nmOgIgZStc5Rp13qjGkO3IIRVwQ6ekM3cp0gTt78A8GolQUnc="}]},"_npmUser":{"name":"achronon","email":"v@achronon.com"},"directories":{},"maintainers":[{"name":"achronon","email":"v@achronon.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/pulse-nest_0.1.0_1781788302784_0.5761962837763415"},"_hasShrinkwrap":false}},"time":{"created":"2026-06-18T13:11:42.544Z","0.1.0":"2026-06-18T13:11:42.986Z","modified":"2026-06-18T13:11:43.219Z"},"maintainers":[{"name":"achronon","email":"v@achronon.com"}],"description":"pulse heartbeat client + @Pulse decorator for NestJS / TypeScript","homepage":"https://github.com/Achronon/pulse/tree/main/clients/nest#readme","keywords":["pulse","heartbeat","cron","liveness","monitoring","healthcheck","nestjs","decorator","prometheus"],"repository":{"type":"git","url":"git+https://github.com/Achronon/pulse.git","directory":"clients/nest"},"author":{"name":"Achronon"},"bugs":{"url":"https://github.com/Achronon/pulse/issues"},"license":"MIT","readme":"# @achrononlimited/pulse-nest\n\npulse heartbeat client + `@Pulse` decorator for NestJS / TypeScript. Fail-open: a\nmonitoring error never affects your job.\n\nDrop-in for `@SentryCron` — keep your `@Cron(...)` and swap the decorator:\n\n```ts\nimport { Cron } from '@nestjs/schedule';\nimport { Pulse } from '@achrononlimited/pulse-nest';\n\n@Cron('*/5 * * * *')\n@Pulse('empera-booking-expiry', { schedule: '*/5 * * * *', grace: '2m', maxRuntime: '4m' })\nasync expireStaleBookings() {\n  // ...\n}\n```\n\nConfigure once at bootstrap (or rely on env `PULSE_URL`, `PULSE_TOKEN`, `PULSE_PROJECT`):\n\n```ts\nimport { configurePulse } from '@achrononlimited/pulse-nest';\n\nconfigurePulse({\n  baseUrl: process.env.PULSE_URL,\n  token: process.env.PULSE_TOKEN,\n  project: 'empera',\n});\n```\n\n`@Pulse` pings `start`, runs the method, then `ok` (with duration) or `fail`. The next\nexpected run time is computed locally from `schedule` (or `intervalSeconds`) and pushed to\nthe server — the server does no cron parsing. Durations accept seconds (`240`) or strings\n(`'4m'`).\n\nAnnounce a monitor at startup so a job that never fires is detectable:\n\n```ts\nimport { getPulseClient } from '@achrononlimited/pulse-nest';\nawait getPulseClient().register('empera-booking-expiry', { schedule: '*/5 * * * *', grace: '2m' });\n```\n\nRequires `experimentalDecorators` (NestJS enables it by default).\n","readmeFilename":"README.md","_rev":"1-272aabb219704c1ec92b9b0428bb73b5"}