{"_id":"@auriclabs/events","_rev":"8-c47a5f6b9f84b281a8b7c44e7f65666c","name":"@auriclabs/events","dist-tags":{"latest":"0.4.4"},"versions":{"0.1.0":{"name":"@auriclabs/events","version":"0.1.0","keywords":[],"author":"","license":"ISC","_id":"@auriclabs/events@0.1.0","maintainers":[{"name":"kevupton","email":"kevin@upton.tech"}],"homepage":"https://github.com/auriclabs/packages#readme","bugs":{"url":"https://github.com/auriclabs/packages/issues"},"dist":{"shasum":"0dc40319bdc0b6572a73e70c01fa7baf9a6193cd","tarball":"https://registry.npmjs.org/@auriclabs/events/-/events-0.1.0.tgz","fileCount":30,"integrity":"sha512-V1jKs8itkiHE2FhNFSG7rOX4KcJ/CczkLAsbRGMLxz+9zZF9AFGw0BYvwIQaXX3mXePTChEBtDPO1s46AgW22g==","signatures":[{"sig":"MEUCIBgcPxqR7kiySBoRCz59BGoQZOxyxtu80JOox2AqFDwvAiEA0qDZJ/G6lshzSzi3UZXQgE+xeWsEDa9gqF3eIg+wXmY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":169793},"main":"dist/index.cjs","type":"module","_from":"file:auriclabs-events-0.1.0.tgz","types":"dist/index.d.mts","module":"dist/index.mjs","exports":{".":{"types":"./dist/index.d.mts","import":"./dist/index.mjs","require":"./dist/index.cjs"}},"scripts":{"dev":"concurrently \"pnpm build --watch\" \"pnpm:y:watch\"","lint":"eslint .","test":"vitest run --passWithNoTests","build":"tsdown src/index.ts --format cjs,esm --dts --no-hash","y:watch":"chokidar dist --initial --silent -c \"yalc publish --push\"","lint:fix":"eslint . --fix","typecheck":"ts-config-typecheck","test:watch":"vitest"},"_npmUser":{"name":"kevupton","email":"kevin@upton.tech"},"prettier":"@auriclabs/prettier-config","_resolved":"/tmp/ca099172ebc6e156af41f6799b377cdc/auriclabs-events-0.1.0.tgz","_integrity":"sha512-V1jKs8itkiHE2FhNFSG7rOX4KcJ/CczkLAsbRGMLxz+9zZF9AFGw0BYvwIQaXX3mXePTChEBtDPO1s46AgW22g==","repository":{"url":"git+https://github.com/auriclabs/packages.git","type":"git","directory":"packages/events"},"_npmVersion":"10.8.2","description":"Event sourcing runtime utilities for DynamoDB-backed event stores","directories":{},"_nodeVersion":"20.20.1","dependencies":{"ulid":"^2.3.0","lodash-es":"4.17.21"},"publishConfig":{"registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"devDependencies":{"@types/lodash-es":"4.17.12","@auriclabs/logger":"0.1.0","@types/aws-lambda":"^8.10.148","@auriclabs/api-core":"0.1.0","@auriclabs/pagination":"1.0.0"},"peerDependencies":{"@auriclabs/logger":"^0.1.0","@auriclabs/api-core":"^0.1.0","@aws-sdk/client-sqs":"^3.0.0","@auriclabs/pagination":"^0.1.0","@aws-sdk/lib-dynamodb":"^3.0.0","@aws-sdk/util-dynamodb":"^3.0.0","@aws-sdk/client-dynamodb":"^3.0.0","@aws-sdk/client-eventbridge":"^3.0.0"},"_npmOperationalInternal":{"tmp":"tmp/events_0.1.0_1774134513816_0.2690749023705803","host":"s3://npm-registry-packages-npm-production"}},"0.2.0":{"name":"@auriclabs/events","version":"0.2.0","keywords":[],"author":"","license":"ISC","_id":"@auriclabs/events@0.2.0","maintainers":[{"name":"kevupton","email":"kevin@upton.tech"}],"homepage":"https://github.com/auriclabs/packages#readme","bugs":{"url":"https://github.com/auriclabs/packages/issues"},"dist":{"shasum":"f31297dd4061328bd8572e488cfc971094a2bf6d","tarball":"https://registry.npmjs.org/@auriclabs/events/-/events-0.2.0.tgz","fileCount":33,"integrity":"sha512-qG279sA2y34a+3jNBCZqGlmgiXStFized5gVqEp9cpUjZIWdhPTxmOiIy/QqcpCJ42/W8WCn00mKLzSXZltkcw==","signatures":[{"sig":"MEYCIQCVqki+HpxFENfSvackLt5egVNw1oJ0n/rRx2bJlBKA3QIhAO3xFxUtbBy0FMw/OfR19r6DXzonJK+cqFYmYQw25p61","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":170321},"main":"dist/index.cjs","type":"module","_from":"file:auriclabs-events-0.2.0.tgz","types":"dist/index.d.mts","module":"dist/index.mjs","exports":{".":{"types":"./dist/index.d.mts","import":"./dist/index.mjs","require":"./dist/index.cjs"}},"scripts":{"dev":"concurrently \"pnpm build --watch\" \"pnpm:y:watch\"","lint":"eslint .","test":"vitest run --passWithNoTests","build":"tsdown src/index.ts --format cjs,esm --dts --no-hash","y:watch":"chokidar dist --initial --silent -c \"yalc publish --push\"","lint:fix":"eslint . --fix","typecheck":"ts-config-typecheck","test:watch":"vitest"},"_npmUser":{"name":"kevupton","email":"kevin@upton.tech"},"prettier":"@auriclabs/prettier-config","_resolved":"/tmp/4b5fdb27d34ab222f08c7aa99ccaf623/auriclabs-events-0.2.0.tgz","_integrity":"sha512-qG279sA2y34a+3jNBCZqGlmgiXStFized5gVqEp9cpUjZIWdhPTxmOiIy/QqcpCJ42/W8WCn00mKLzSXZltkcw==","repository":{"url":"git+https://github.com/auriclabs/packages.git","type":"git","directory":"packages/events"},"_npmVersion":"10.8.2","description":"Event sourcing runtime utilities for DynamoDB-backed event stores","directories":{},"_nodeVersion":"20.20.1","dependencies":{"ulid":"^2.3.0","lodash-es":"4.17.21"},"publishConfig":{"registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"devDependencies":{"@types/lodash-es":"4.17.12","@auriclabs/logger":"0.1.1","@types/aws-lambda":"^8.10.148","@auriclabs/api-core":"0.1.1","@auriclabs/pagination":"1.0.1"},"peerDependencies":{"@auriclabs/logger":"^0.1.1","@auriclabs/api-core":"^0.1.1","@aws-sdk/client-sqs":"^3.0.0","@auriclabs/pagination":"^1.0.1","@aws-sdk/lib-dynamodb":"^3.0.0","@aws-sdk/util-dynamodb":"^3.0.0","@aws-sdk/client-dynamodb":"^3.0.0","@aws-sdk/client-eventbridge":"^3.0.0"},"_npmOperationalInternal":{"tmp":"tmp/events_0.2.0_1774290597957_0.12569807648258546","host":"s3://npm-registry-packages-npm-production"}},"0.3.0":{"name":"@auriclabs/events","version":"0.3.0","keywords":[],"author":"","license":"ISC","_id":"@auriclabs/events@0.3.0","maintainers":[{"name":"kevupton","email":"kevin@upton.tech"}],"homepage":"https://github.com/auriclabs/packages#readme","bugs":{"url":"https://github.com/auriclabs/packages/issues"},"dist":{"shasum":"76794de56c2185fa64dbbdbd855ab45204886893","tarball":"https://registry.npmjs.org/@auriclabs/events/-/events-0.3.0.tgz","fileCount":33,"integrity":"sha512-ocvfmtm0wtqqPjh6mXFYBF8A8gVfaryAtDk3SE6/nauQPrGFWrji/4rrYxfgkUCv1O/j6n5DM9gJRghAaQ/8Lw==","signatures":[{"sig":"MEUCIQCgjl8N+ns/pBsh/dMN4NQ4A8AjV1e1C2RqzxzIlm2xSwIgSE6l1IyjyplNbg8RtgEeEDBjwUupOPmAaZuLS9MkM30=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":173055},"main":"dist/index.cjs","type":"module","_from":"file:auriclabs-events-0.3.0.tgz","types":"dist/index.d.mts","module":"dist/index.mjs","exports":{".":{"types":"./dist/index.d.mts","import":"./dist/index.mjs","require":"./dist/index.cjs"}},"scripts":{"dev":"concurrently \"pnpm build --watch\" \"pnpm:y:watch\"","lint":"eslint .","test":"vitest run --passWithNoTests","build":"tsdown src/index.ts --format cjs,esm --dts --no-hash","y:watch":"chokidar dist --initial --silent -c \"yalc publish --push\"","lint:fix":"eslint . --fix","typecheck":"ts-config-typecheck","test:watch":"vitest"},"_npmUser":{"name":"kevupton","email":"kevin@upton.tech"},"prettier":"@auriclabs/prettier-config","_resolved":"/tmp/8fafc0f48029074da49b534cb1c726f9/auriclabs-events-0.3.0.tgz","_integrity":"sha512-ocvfmtm0wtqqPjh6mXFYBF8A8gVfaryAtDk3SE6/nauQPrGFWrji/4rrYxfgkUCv1O/j6n5DM9gJRghAaQ/8Lw==","repository":{"url":"git+https://github.com/auriclabs/packages.git","type":"git","directory":"packages/events"},"_npmVersion":"10.8.2","description":"Event sourcing runtime utilities for DynamoDB-backed event stores","directories":{},"_nodeVersion":"20.20.1","dependencies":{"ulid":"^2.3.0","lodash-es":"4.17.21"},"publishConfig":{"registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"devDependencies":{"@types/lodash-es":"4.17.12","@auriclabs/logger":"0.1.1","@types/aws-lambda":"^8.10.148","@auriclabs/api-core":"0.1.1","@auriclabs/pagination":"1.0.1"},"peerDependencies":{"@auriclabs/logger":"^0.1.1","@auriclabs/api-core":"^0.1.1","@aws-sdk/client-sqs":"^3.0.0","@auriclabs/pagination":"^1.0.1","@aws-sdk/lib-dynamodb":"^3.0.0","@aws-sdk/util-dynamodb":"^3.0.0","@aws-sdk/client-dynamodb":"^3.0.0","@aws-sdk/client-eventbridge":"^3.0.0"},"_npmOperationalInternal":{"tmp":"tmp/events_0.3.0_1774384475396_0.7755376997961245","host":"s3://npm-registry-packages-npm-production"}},"0.4.0":{"name":"@auriclabs/events","version":"0.4.0","keywords":[],"author":"","license":"ISC","_id":"@auriclabs/events@0.4.0","maintainers":[{"name":"kevupton","email":"kevin@upton.tech"}],"homepage":"https://github.com/auriclabs/packages#readme","bugs":{"url":"https://github.com/auriclabs/packages/issues"},"dist":{"shasum":"370e4bcc9c445cc4643a0ae471f6aca5fd85cc9b","tarball":"https://registry.npmjs.org/@auriclabs/events/-/events-0.4.0.tgz","fileCount":48,"integrity":"sha512-cUqNcPW9YnbJC0rPPkIa/oxWdcUMlzjIkKyMGI0aIWT/ERVM/Z9YImTJL82UnLZZoSyWp2FrS5eUUJGMgVqspA==","signatures":[{"sig":"MEUCIQDrUGsSzEbX4LIM2roHZQCJhxwyO1osoEBeFBsbhxqrtgIgQxizfvjD2sZbxf+UXtjmZ95VmxlUHSG5fmLbzdFTuvg=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":180140},"main":"dist/index.cjs","type":"module","_from":"file:auriclabs-events-0.4.0.tgz","types":"dist/index.d.mts","module":"dist/index.mjs","exports":{".":{"types":"./dist/index.d.mts","import":"./dist/index.mjs","require":"./dist/index.cjs"},"./stream-handler":{"types":"./dist/stream-handler.entry.d.mts","import":"./dist/stream-handler.entry.mjs","require":"./dist/stream-handler.entry.cjs"}},"scripts":{"dev":"concurrently \"pnpm build --watch\" \"pnpm:y:watch\"","lint":"eslint .","test":"vitest run --passWithNoTests","build":"tsdown src/index.ts src/stream-handler.entry.ts --format cjs,esm --dts --no-hash","y:watch":"chokidar dist --initial --silent -c \"yalc publish --push\"","lint:fix":"eslint . --fix","typecheck":"ts-config-typecheck","test:watch":"vitest"},"_npmUser":{"name":"kevupton","email":"kevin@upton.tech"},"prettier":"@auriclabs/prettier-config","_resolved":"/tmp/20804d8a6da6f1a20c3d595ef28cf9c9/auriclabs-events-0.4.0.tgz","_integrity":"sha512-cUqNcPW9YnbJC0rPPkIa/oxWdcUMlzjIkKyMGI0aIWT/ERVM/Z9YImTJL82UnLZZoSyWp2FrS5eUUJGMgVqspA==","repository":{"url":"git+https://github.com/auriclabs/packages.git","type":"git","directory":"packages/events"},"_npmVersion":"10.8.2","description":"Event sourcing runtime utilities for DynamoDB-backed event stores","directories":{},"_nodeVersion":"20.20.1","dependencies":{"ulid":"^2.3.0","lodash-es":"4.17.21"},"publishConfig":{"registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"devDependencies":{"@types/lodash-es":"4.17.12","@auriclabs/logger":"0.1.1","@types/aws-lambda":"^8.10.148","@auriclabs/api-core":"0.1.1","@auriclabs/pagination":"1.0.1"},"peerDependencies":{"@auriclabs/logger":"^0.1.1","@auriclabs/api-core":"^0.1.1","@aws-sdk/client-sqs":"^3.0.0","@auriclabs/pagination":"^1.0.1","@aws-sdk/lib-dynamodb":"^3.0.0","@aws-sdk/util-dynamodb":"^3.0.0","@aws-sdk/client-dynamodb":"^3.0.0","@aws-sdk/client-eventbridge":"^3.0.0"},"_npmOperationalInternal":{"tmp":"tmp/events_0.4.0_1774388669172_0.4803517567213904","host":"s3://npm-registry-packages-npm-production"}},"0.4.1":{"name":"@auriclabs/events","version":"0.4.1","keywords":[],"author":"","license":"ISC","_id":"@auriclabs/events@0.4.1","maintainers":[{"name":"kevupton","email":"kevin@upton.tech"}],"homepage":"https://github.com/auriclabs/packages#readme","bugs":{"url":"https://github.com/auriclabs/packages/issues"},"dist":{"shasum":"a555b79da170936be70db168b335c720e7790f20","tarball":"https://registry.npmjs.org/@auriclabs/events/-/events-0.4.1.tgz","fileCount":41,"integrity":"sha512-lFql7JEz9Jb9whptahVEW6vmsTBkxV7pDCFh7hT/1YVdZBsw2u+2EI6L+dLa3JGjJWMQXxA2mPSSt6cR1GElrg==","signatures":[{"sig":"MEUCIQCvOEG2CyZ0uNwV8tw22LFSOaRs/0fHPRapoBIjpNaPzwIgIxWKNsthQ7qJQx+T70x9dMz9t/3q1P0WDonFiJjw+eU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":213979},"main":"dist/index.cjs","type":"module","_from":"file:auriclabs-events-0.4.1.tgz","types":"dist/index.d.mts","module":"dist/index.mjs","exports":{".":{"types":"./dist/index.d.mts","import":"./dist/index.mjs","require":"./dist/index.cjs"},"./stream-handler":{"types":"./dist/stream-handler.entry.d.mts","import":"./dist/stream-handler.entry.mjs","require":"./dist/stream-handler.entry.cjs"}},"scripts":{"dev":"concurrently \"pnpm build --watch\" \"pnpm:y:watch\"","lint":"eslint .","test":"vitest run --passWithNoTests","build":"tsdown src/index.ts --format cjs,esm --dts --no-hash && tsdown src/stream-handler.entry.ts --format cjs,esm --dts --no-hash --no-clean","y:watch":"chokidar dist --initial --silent -c \"yalc publish --push\"","lint:fix":"eslint . --fix","typecheck":"ts-config-typecheck","test:watch":"vitest"},"_npmUser":{"name":"kevupton","email":"kevin@upton.tech"},"prettier":"@auriclabs/prettier-config","_resolved":"/tmp/be2d68498919dfebc300c8d4a3658c40/auriclabs-events-0.4.1.tgz","_integrity":"sha512-lFql7JEz9Jb9whptahVEW6vmsTBkxV7pDCFh7hT/1YVdZBsw2u+2EI6L+dLa3JGjJWMQXxA2mPSSt6cR1GElrg==","repository":{"url":"git+https://github.com/auriclabs/packages.git","type":"git","directory":"packages/events"},"_npmVersion":"10.8.2","description":"Event sourcing runtime utilities for DynamoDB-backed event stores","directories":{},"_nodeVersion":"20.20.1","dependencies":{"ulid":"^2.3.0","lodash-es":"4.17.21"},"publishConfig":{"registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"devDependencies":{"@types/lodash-es":"4.17.12","@auriclabs/logger":"0.1.1","@types/aws-lambda":"^8.10.148","@auriclabs/api-core":"0.1.1","@auriclabs/pagination":"1.0.1"},"peerDependencies":{"@auriclabs/logger":"^0.1.1","@auriclabs/api-core":"^0.1.1","@aws-sdk/client-sqs":"^3.0.0","@auriclabs/pagination":"^1.0.1","@aws-sdk/lib-dynamodb":"^3.0.0","@aws-sdk/util-dynamodb":"^3.0.0","@aws-sdk/client-dynamodb":"^3.0.0","@aws-sdk/client-eventbridge":"^3.0.0"},"_npmOperationalInternal":{"tmp":"tmp/events_0.4.1_1774396093678_0.062289358478101686","host":"s3://npm-registry-packages-npm-production"}},"0.4.2":{"name":"@auriclabs/events","version":"0.4.2","keywords":[],"author":"","license":"ISC","_id":"@auriclabs/events@0.4.2","maintainers":[{"name":"kevupton","email":"kevin@upton.tech"}],"homepage":"https://github.com/auriclabs/packages#readme","bugs":{"url":"https://github.com/auriclabs/packages/issues"},"dist":{"shasum":"f2fdac35edb3b9febf5043b084f5094891438bf2","tarball":"https://registry.npmjs.org/@auriclabs/events/-/events-0.4.2.tgz","fileCount":41,"integrity":"sha512-U3pVy0iwvu2l3YvhZhGqvmdBPg0Eh09M+0us37panIGkVjFbhuYNthHipwagh4rE8hXqyoWj7dBMvXVF4Q0l9w==","signatures":[{"sig":"MEUCIBROezLioFKetIH5Pabk8AFD3tmFqbjfnlLgHr82bswjAiEA0EBtR6P6sKQHx5ke1yVQ1U1MIL3eD2YkkDwF3WYy9zw=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":216914},"main":"dist/index.cjs","type":"module","_from":"file:auriclabs-events-0.4.2.tgz","types":"dist/index.d.mts","module":"dist/index.mjs","exports":{".":{"types":"./dist/index.d.mts","import":"./dist/index.mjs","require":"./dist/index.cjs"},"./stream-handler":{"types":"./dist/stream-handler.entry.d.mts","import":"./dist/stream-handler.entry.mjs","require":"./dist/stream-handler.entry.cjs"}},"scripts":{"dev":"concurrently \"pnpm build --watch\" \"pnpm:y:watch\"","lint":"eslint .","test":"vitest run --passWithNoTests","build":"tsdown src/index.ts --format cjs,esm --dts --no-hash && tsdown src/stream-handler.entry.ts --format cjs,esm --dts --no-hash --no-clean","y:watch":"chokidar dist --initial --silent -c \"yalc publish --push\"","lint:fix":"eslint . --fix","typecheck":"ts-config-typecheck","test:watch":"vitest"},"_npmUser":{"name":"kevupton","email":"kevin@upton.tech"},"prettier":"@auriclabs/prettier-config","_resolved":"/tmp/f4c16e30605cb63ce0e782b225ddaa12/auriclabs-events-0.4.2.tgz","_integrity":"sha512-U3pVy0iwvu2l3YvhZhGqvmdBPg0Eh09M+0us37panIGkVjFbhuYNthHipwagh4rE8hXqyoWj7dBMvXVF4Q0l9w==","repository":{"url":"git+https://github.com/auriclabs/packages.git","type":"git","directory":"packages/events"},"_npmVersion":"10.8.2","description":"Event sourcing runtime utilities for DynamoDB-backed event stores","directories":{},"_nodeVersion":"20.20.2","dependencies":{"ulid":"^2.3.0","lodash-es":"4.18.1"},"publishConfig":{"registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"devDependencies":{"@types/lodash-es":"4.17.12","@auriclabs/logger":"0.1.1","@types/aws-lambda":"^8.10.148","@auriclabs/api-core":"0.1.2","@auriclabs/pagination":"1.0.1"},"peerDependencies":{"@auriclabs/logger":"^0.1.1","@auriclabs/api-core":"^0.1.2","@aws-sdk/client-sqs":"^3.0.0","@auriclabs/pagination":"^1.0.1","@aws-sdk/lib-dynamodb":"^3.0.0","@aws-sdk/util-dynamodb":"^3.0.0","@aws-sdk/client-dynamodb":"^3.0.0","@aws-sdk/client-eventbridge":"^3.0.0"},"_npmOperationalInternal":{"tmp":"tmp/events_0.4.2_1775857288127_0.9305133376812278","host":"s3://npm-registry-packages-npm-production"}},"0.4.3":{"name":"@auriclabs/events","version":"0.4.3","keywords":[],"author":"","license":"ISC","_id":"@auriclabs/events@0.4.3","maintainers":[{"name":"kevupton","email":"kevin@upton.tech"}],"homepage":"https://github.com/auriclabs/packages#readme","bugs":{"url":"https://github.com/auriclabs/packages/issues"},"dist":{"shasum":"0bfae47fc48c76175b23ea052d3a525f742f7758","tarball":"https://registry.npmjs.org/@auriclabs/events/-/events-0.4.3.tgz","fileCount":41,"integrity":"sha512-e62bbDXyBb1yUvENKNxQVRyfGTqMF/3D42EYhjOeOBzJW2Tx9CxUSZHZ+4cvdUDT5OVv6kQdEpjirEDTw/d8iA==","signatures":[{"sig":"MEUCIQC5o4aFmC6WCKMUtCjyxv+XZICfiXFagV8nScGIBkCGwAIgHtCvzB5lUi9x7LuY8gW2aEUhLMyj+z4P5tYgmTJnXdY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":236592},"main":"dist/index.cjs","type":"module","_from":"file:auriclabs-events-0.4.3.tgz","types":"dist/index.d.mts","module":"dist/index.mjs","exports":{".":{"types":"./dist/index.d.mts","import":"./dist/index.mjs","require":"./dist/index.cjs"},"./stream-handler":{"types":"./dist/stream-handler.entry.d.mts","import":"./dist/stream-handler.entry.mjs","require":"./dist/stream-handler.entry.cjs"}},"scripts":{"dev":"concurrently \"pnpm build --watch\" \"pnpm:y:watch\"","lint":"eslint .","test":"vitest run --passWithNoTests","build":"tsdown src/index.ts --format cjs,esm --dts --no-hash && tsdown src/stream-handler.entry.ts --format cjs,esm --dts --no-hash --no-clean","y:watch":"chokidar dist --initial --silent -c \"yalc publish --push\"","lint:fix":"eslint . --fix","typecheck":"ts-config-typecheck","test:watch":"vitest"},"_npmUser":{"name":"kevupton","email":"kevin@upton.tech"},"prettier":"@auriclabs/prettier-config","_resolved":"/tmp/15f035210a4862ce7399e5495b4b1bbb/auriclabs-events-0.4.3.tgz","_integrity":"sha512-e62bbDXyBb1yUvENKNxQVRyfGTqMF/3D42EYhjOeOBzJW2Tx9CxUSZHZ+4cvdUDT5OVv6kQdEpjirEDTw/d8iA==","repository":{"url":"git+https://github.com/auriclabs/packages.git","type":"git","directory":"packages/events"},"_npmVersion":"10.8.2","description":"Event sourcing runtime utilities for DynamoDB-backed event stores","directories":{},"_nodeVersion":"20.20.2","dependencies":{"ulid":"^2.3.0","lodash-es":"4.18.1"},"publishConfig":{"registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"devDependencies":{"@types/lodash-es":"4.17.12","@auriclabs/logger":"0.1.1","@types/aws-lambda":"^8.10.148","@auriclabs/api-core":"0.1.2","@auriclabs/pagination":"1.0.1"},"peerDependencies":{"@auriclabs/logger":"^0.1.1","@auriclabs/api-core":"^0.1.2","@aws-sdk/client-sqs":"^3.0.0","@auriclabs/pagination":"^1.0.1","@aws-sdk/lib-dynamodb":"^3.0.0","@aws-sdk/util-dynamodb":"^3.0.0","@aws-sdk/client-dynamodb":"^3.0.0","@aws-sdk/client-eventbridge":"^3.0.0"},"_npmOperationalInternal":{"tmp":"tmp/events_0.4.3_1779026441261_0.03450172275118035","host":"s3://npm-registry-packages-npm-production"}},"0.4.4":{"name":"@auriclabs/events","version":"0.4.4","description":"Event sourcing runtime utilities for DynamoDB-backed event stores","prettier":"@auriclabs/prettier-config","main":"dist/index.cjs","module":"dist/index.mjs","types":"dist/index.d.mts","exports":{".":{"types":"./dist/index.d.mts","import":"./dist/index.mjs","require":"./dist/index.cjs"},"./stream-handler":{"types":"./dist/stream-handler.entry.d.mts","import":"./dist/stream-handler.entry.mjs","require":"./dist/stream-handler.entry.cjs"}},"keywords":[],"author":"","type":"module","license":"ISC","dependencies":{"lodash-es":"4.18.1","ulid":"^2.3.0"},"devDependencies":{"@types/aws-lambda":"^8.10.148","@types/lodash-es":"4.17.12","@auriclabs/api-core":"0.1.2","@auriclabs/logger":"0.1.1","@auriclabs/pagination":"1.0.1"},"peerDependencies":{"@auriclabs/api-core":"^0.1.2","@auriclabs/logger":"^0.1.1","@auriclabs/pagination":"^1.0.1","@aws-sdk/client-dynamodb":"^3.0.0","@aws-sdk/client-eventbridge":"^3.0.0","@aws-sdk/client-sqs":"^3.0.0","@aws-sdk/lib-dynamodb":"^3.0.0","@aws-sdk/util-dynamodb":"^3.0.0"},"publishConfig":{"registry":"https://registry.npmjs.org/"},"repository":{"type":"git","url":"git+https://github.com/auriclabs/packages.git","directory":"packages/events"},"scripts":{"build":"tsdown src/index.ts --format cjs,esm --dts --no-hash && tsdown src/stream-handler.entry.ts --format cjs,esm --dts --no-hash --no-clean","dev":"concurrently \"pnpm build --watch\" \"pnpm:y:watch\"","y:watch":"chokidar dist --initial --silent -c \"yalc publish --push\"","lint":"eslint .","lint:fix":"eslint . --fix","typecheck":"ts-config-typecheck","test":"vitest run --passWithNoTests","test:watch":"vitest"},"_id":"@auriclabs/events@0.4.4","bugs":{"url":"https://github.com/auriclabs/packages/issues"},"homepage":"https://github.com/auriclabs/packages#readme","_integrity":"sha512-9rfH5ru/FKjupbREWAVusDrMlvTSAVp7FEKV+n6G2iskAWGANjzbY3pksXSPqZM37tfb41cDNoPpOQ3gB3p/Tg==","_resolved":"/tmp/147385f765ef196d4dab02bff478e737/auriclabs-events-0.4.4.tgz","_from":"file:auriclabs-events-0.4.4.tgz","_nodeVersion":"20.20.2","_npmVersion":"10.8.2","dist":{"integrity":"sha512-9rfH5ru/FKjupbREWAVusDrMlvTSAVp7FEKV+n6G2iskAWGANjzbY3pksXSPqZM37tfb41cDNoPpOQ3gB3p/Tg==","shasum":"b95c81e16d63af7ae2c254a38ec6c0509782cd2f","tarball":"https://registry.npmjs.org/@auriclabs/events/-/events-0.4.4.tgz","fileCount":44,"unpackedSize":270862,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIGkLiSolAJU6XXz+fDCe38GuzLD6E2zmsONiQ8RSiuEuAiEAsaCdrKsQVKrqjkf9XC+b+QIj+dhkugTBbUu1P4/KFzE="}]},"_npmUser":{"name":"kevupton","email":"kevin@upton.tech"},"directories":{},"maintainers":[{"name":"kevupton","email":"kevin@upton.tech"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/events_0.4.4_1779217057281_0.7802045129270503"},"_hasShrinkwrap":false}},"time":{"created":"2026-03-21T23:08:33.747Z","modified":"2026-05-19T18:57:37.555Z","0.1.0":"2026-03-21T23:08:33.980Z","0.2.0":"2026-03-23T18:29:58.129Z","0.3.0":"2026-03-24T20:34:35.547Z","0.4.0":"2026-03-24T21:44:29.385Z","0.4.1":"2026-03-24T23:48:13.882Z","0.4.2":"2026-04-10T21:41:28.305Z","0.4.3":"2026-05-17T14:00:41.401Z","0.4.4":"2026-05-19T18:57:37.443Z"},"bugs":{"url":"https://github.com/auriclabs/packages/issues"},"license":"ISC","homepage":"https://github.com/auriclabs/packages#readme","keywords":[],"repository":{"type":"git","url":"git+https://github.com/auriclabs/packages.git","directory":"packages/events"},"description":"Event sourcing runtime utilities for DynamoDB-backed event stores","maintainers":[{"name":"kevupton","email":"kevin@upton.tech"}],"readme":"# @auriclabs/events\n\nEvent sourcing runtime utilities for DynamoDB-backed event stores. Provides event dispatching, listeners, context management, and DynamoDB stream handling.\n\n## Setup\n\n```bash\npnpm add @auriclabs/events\n```\n\n### Peer dependencies\n\n```bash\npnpm add @auriclabs/api-core @auriclabs/logger @auriclabs/pagination\npnpm add @aws-sdk/client-dynamodb @aws-sdk/lib-dynamodb @aws-sdk/client-eventbridge @aws-sdk/client-sqs @aws-sdk/util-dynamodb\n```\n\n## Initialization\n\nCall `initEvents()` once per Lambda cold start before using any event functions:\n\n```typescript\nimport { initEvents } from '@auriclabs/events';\nimport { Resource } from 'sst';\n\ninitEvents({ tableName: Resource.EventStoreTable.name });\n```\n\n## API Reference\n\n### `initEvents(config: { tableName: string })`\n\nInitializes the module-level event service with the DynamoDB table name. Must be called before any other function.\n\n### `getEventService(): EventService`\n\nReturns the initialized `EventService` instance. Throws if `initEvents()` hasn't been called.\n\n### `EventService` interface\n\n```typescript\ninterface EventService {\n  appendEvent<P>(args: AppendArgs<P>): Promise<AppendEventResult>;\n  getHead(aggregateType: string, aggregateId: string): Promise<AggregateHead | undefined>;\n  getEvent(aggregateType: string, aggregateId: string, version: number): Promise<EventRecord | undefined>;\n  listEvents(params: {\n    aggregateType: string;\n    aggregateId: string;\n    fromVersionExclusive?: number;\n    toVersionInclusive?: number;\n    limit?: number;\n  }): Promise<PaginationResponse<EventRecord>>;\n}\n```\n\nLow-level DynamoDB operations with optimistic concurrency control and idempotent writes. Most consumers should use `createDispatch()` instead.\n\n### `createDispatch(record, options?)`\n\nType-safe factory for creating domain-specific dispatch functions. This is the primary way to dispatch events.\n\n```typescript\nimport { createDispatch } from '@auriclabs/events';\n\nconst dispatch = createDispatch(\n  {\n    funded: (walletId: string, amount: number) => ({\n      aggregateId: walletId,\n      eventType: 'Wallet.Funded',\n      payload: { amount },\n    }),\n    withdrawn: (walletId: string, amount: number) => ({\n      aggregateId: walletId,\n      eventType: 'Wallet.Withdrawn',\n      payload: { amount },\n    }),\n  },\n  { aggregateType: 'wallet', source: 'billing' },\n);\n\n// Usage:\nawait dispatch.funded('wal_123', 5000);\nawait dispatch.withdrawn('wal_123', 1000);\n```\n\nEach dispatch function automatically:\n- Generates a ULID-based `eventId`\n- Reads the current aggregate HEAD for version tracking\n- Retries on OCC conflicts\n- Merges event context (correlation/causation/actor IDs)\n\n### `dispatchEvent(event: DispatchEventArgs)`\n\nLow-level single event dispatch. Auto-generates `eventId`, reads HEAD version, retries on OCC.\n\n```typescript\nimport { dispatchEvent } from '@auriclabs/events';\n\nawait dispatchEvent({\n  aggregateType: 'wallet',\n  aggregateId: 'wal_123',\n  source: 'billing',\n  eventType: 'Wallet.Funded',\n  payload: { amount: 5000 },\n});\n```\n\n### `dispatchEvents(events, options?)`\n\nDispatches multiple events. By default dispatches in parallel. Set `{ inOrder: true }` for sequential dispatch (required when events target the same aggregate).\n\n```typescript\nimport { dispatchEvents } from '@auriclabs/events';\n\nawait dispatchEvents([event1, event2, event3], { inOrder: true });\n```\n\n### `createEventListener(handlers, options?)`\n\nCreates an SQS batch handler for processing events. Returns a Lambda handler function.\n\n```typescript\nimport { createEventListener } from '@auriclabs/events';\n\nexport const handler = createEventListener({\n  'Wallet.Funded': async (event) => {\n    // Process the event\n    console.log(event.payload, event.aggregateId);\n  },\n  // String values create aliases:\n  'Wallet.Credited': 'Wallet.Funded',\n}, { debug: true });\n```\n\nThe listener:\n- Parses `EventRecord` from SQS message body\n- Resolves string aliases to handler functions\n- Sets event context (causation/correlation/actor IDs) before calling the handler\n- Returns `SQSBatchResponse` with failures for partial batch retry\n\n### `createStreamHandler(config)`\n\nCreates a DynamoDB Streams handler that fans out events to SQS queues and EventBridge.\n\n```typescript\nimport { createStreamHandler } from '@auriclabs/events';\nimport { Resource } from 'sst';\n\nexport const handler = createStreamHandler({\n  busName: Resource.EventBus.name,\n  queueUrls: JSON.parse(process.env.QUEUE_URL_LIST ?? '[]'),\n});\n```\n\n### Context Management\n\n```typescript\nimport { setEventContext, getEventContext, resetEventContext, appendEventContext } from '@auriclabs/events';\n\n// Set context for current request\nsetEventContext({ correlationId: 'corr-123', actorId: 'user-456' });\n\n// Read current context\nconst ctx = getEventContext();\n\n// Append to existing context\nappendEventContext({ causationId: 'evt-789' });\n\n// Reset between requests\nresetEventContext();\n```\n\nContext is automatically merged into dispatched events. `createEventListener` sets causation/correlation context from the incoming event.\n\n## Types\n\n### `EventRecord<P>`\n\n```typescript\ninterface EventRecord<P = unknown> {\n  pk: AggregatePK;           // \"AGG#{type}#{id}\"\n  sk: EventSK;               // \"EVT#000000042\"\n  itemType: 'event';\n  source: Source;\n  aggregateId: AggregateId;\n  aggregateType: AggregateType;\n  version: number;\n  eventId: EventId;\n  eventType: string;\n  schemaVersion?: number;\n  occurredAt: string;        // ISO timestamp\n  correlationId?: string;\n  causationId?: string;\n  actorId?: string;\n  payload: Readonly<P>;\n}\n```\n\n### `AggregateHead`\n\n```typescript\ninterface AggregateHead {\n  pk: AggregatePK;\n  sk: 'HEAD';\n  itemType: 'head';\n  aggregateId: AggregateId;\n  aggregateType: AggregateType;\n  currentVersion: number;\n  lastEventId?: EventId;\n  lastIdemKey?: string;\n  updatedAt: string;\n}\n```\n\n### Branded types\n\n`Source`, `AggregateId`, `AggregateType`, `EventId` — branded string types for type safety. Cast with `as Source`, etc.\n\n## DynamoDB Table Schema\n\nThe event store uses a single-table design:\n\n| Key | Format | Description |\n|-----|--------|-------------|\n| `pk` | `AGG#{aggregateType}#{aggregateId}` | Partition key |\n| `sk` | `EVT#{version}` or `HEAD` | Sort key |\n\nEvents are immutable INSERT records. HEAD is updated atomically with each event via DynamoDB transactions.\n","readmeFilename":"README.md"}