{"_id":"@dcsv-io/d2-headers-amqp","_rev":"2-3fed3f83a9d428ce91275c0130009ba1","name":"@dcsv-io/d2-headers-amqp","dist-tags":{"latest":"0.1.2"},"versions":{"0.1.1":{"name":"@dcsv-io/d2-headers-amqp","version":"0.1.1","_id":"@dcsv-io/d2-headers-amqp@0.1.1","maintainers":[{"name":"dcsv-tristan","email":"tristan@dcsv.io"}],"dist":{"shasum":"182d29307cff4691125ed6554352af123cd4b94f","tarball":"https://registry.npmjs.org/@dcsv-io/d2-headers-amqp/-/d2-headers-amqp-0.1.1.tgz","fileCount":11,"integrity":"sha512-fgft+BFfkSWaTlwbquh2kPNLc9CexeT1+aRtC0VpANOaT6VBiEm1i3dfydoL8buTZvS9XdOfD0bEoQOQFPBVow==","signatures":[{"sig":"MEUCIQC74Bhxm16UR1xU9pQit8wTurT1W7Opgq4kCAyzh0I/iwIgaRZcKt8jJ5exoUbwD3vysd79KcFBX/Csj7Y90MOc1q4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":22948},"main":"./dist/index.js","type":"module","_from":"file:bundle/npm/dcsv-io-d2-headers-amqp-0.1.1.tgz","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"test":"vitest run","build":"tsc -b","prebuild":"node ../../scripts/run-ts-codegen.mjs src/headers-emit.ts --target=amqp","test:coverage":"vitest run --coverage","type-check:test":"tsc -p tsconfig.test.json"},"_npmUser":{"name":"dcsv-tristan","email":"tristan@dcsv.io"},"_resolved":"/home/runner/work/D2-Public/D2-Public/bundle/npm/dcsv-io-d2-headers-amqp-0.1.1.tgz","_integrity":"sha512-fgft+BFfkSWaTlwbquh2kPNLc9CexeT1+aRtC0VpANOaT6VBiEm1i3dfydoL8buTZvS9XdOfD0bEoQOQFPBVow==","_npmVersion":"11.16.0","description":"<!-- Copyright (c) DCSV. Licensed under the Apache License, Version 2.0. -->","directories":{},"_nodeVersion":"24.18.0","_hasShrinkwrap":false,"devDependencies":{"vitest":"4.0.18","typescript":"5.9.3","@vitest/coverage-v8":"4.0.18"},"_npmOperationalInternal":{"tmp":"tmp/d2-headers-amqp_0.1.1_1784262826298_0.5377784778104495","host":"s3://npm-registry-packages-npm-production"}},"0.1.2":{"name":"@dcsv-io/d2-headers-amqp","version":"0.1.2","type":"module","main":"./dist/index.js","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"devDependencies":{"@vitest/coverage-v8":"4.0.18","typescript":"5.9.3","vitest":"4.0.18"},"scripts":{"prebuild":"node ../../scripts/run-ts-codegen.mjs src/headers-emit.ts --target=amqp","build":"tsc -b","test":"vitest run","test:coverage":"vitest run --coverage","type-check:test":"tsc -p tsconfig.test.json"},"_id":"@dcsv-io/d2-headers-amqp@0.1.2","description":"<!-- Copyright (c) DCSV. Licensed under the Apache License, Version 2.0. -->","_integrity":"sha512-dlJiqmTUbl1OsCfWm9KRZrKlO++0uFmfN6BgJs8t9qRn0hVbeGT0bpxkOoBZ9s/4+EbPoaR6zoE0zrhua7h6ow==","_resolved":"/home/runner/work/D2-Public/D2-Public/bundle/npm/dcsv-io-d2-headers-amqp-0.1.2.tgz","_from":"file:bundle/npm/dcsv-io-d2-headers-amqp-0.1.2.tgz","_nodeVersion":"24.18.0","_npmVersion":"11.16.0","dist":{"integrity":"sha512-dlJiqmTUbl1OsCfWm9KRZrKlO++0uFmfN6BgJs8t9qRn0hVbeGT0bpxkOoBZ9s/4+EbPoaR6zoE0zrhua7h6ow==","shasum":"8138438710ccaec3e3f5bd3d395071834b8f3e83","tarball":"https://registry.npmjs.org/@dcsv-io/d2-headers-amqp/-/d2-headers-amqp-0.1.2.tgz","fileCount":11,"unpackedSize":22745,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIDN5X0G1L7dyjwr7C3GWlKPhClKFA97dRpz5ukTgRkgDAiEAzE1XSepRHXBmsFi0tx0bw04nQrVIK/QpsHzAkbjbnlc="}]},"_npmUser":{"name":"dcsv-tristan","email":"tristan@dcsv.io"},"directories":{},"maintainers":[{"name":"dcsv-tristan","email":"tristan@dcsv.io"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/d2-headers-amqp_0.1.2_1784286925411_0.7944823287938596"},"_hasShrinkwrap":false}},"time":{"created":"2026-07-17T04:33:46.166Z","modified":"2026-07-17T11:15:25.698Z","0.1.1":"2026-07-17T04:33:46.435Z","0.1.2":"2026-07-17T11:15:25.553Z"},"description":"<!-- Copyright (c) DCSV. Licensed under the Apache License, Version 2.0. -->","maintainers":[{"name":"dcsv-tristan","email":"tristan@dcsv.io"}],"readme":"<!--\nCopyright (c) DCSV. Licensed under the Apache License, Version 2.0.\n-->\n\n# @dcsv-io/d2-headers-amqp\n\n> **Duplicated from `contracts/headers/headers.spec.json` — update both in lockstep.** This catalog mirrors its .NET sibling `DcsvIo.D2.Headers.Amqp` at byte-equal wire values. Both sides emit from the same spec; physical dedup across TS ↔ .NET is not feasible. Parity is asserted by `contract-tests/headers.parity.test.ts` (TS) and `HeaderCatalogConsistencyTests` (.NET).\n\nD2 wire-protocol headers applicable to the AMQP transport. Includes the AMQP-specific entries (`content-type`, `x-proto-type`, `message-id`, `timestamp`, `x-d2-encryption-kid`, `x-d2-failure-reason`) AND the cross-transport entries that ride alongside AMQP messages (`x-d2-context`, `traceparent`, `tracestate`) at identical wire values per `headers.spec.json`. Mirrors .NET `DcsvIo.D2.Headers.Amqp.AmqpHeaders`.\n\n## Install\n\n```bash\npnpm add @dcsv-io/d2-headers-amqp\n```\n\n## Public API\n\n| Export             | Source              | Mirror                                  |\n| ------------------ | ------------------- | --------------------------------------- |\n| `AmqpHeaders`      | `amqp-headers.g.ts` | `DcsvIo.D2.Headers.Amqp.AmqpHeaders`    |\n| `AmqpHeaderName`   | `amqp-headers.g.ts` | n/a (TS-only union type)                |\n| `ALL_AMQP_HEADERS` | `amqp-headers.g.ts` | `DcsvIo.D2.Headers.Amqp.AllAmqpHeaders` |\n\n## Codegen workflow\n\n`prebuild` regenerates the catalog from `contracts/headers/headers.spec.json` when a generator is available. Generated files (`*.g.ts`) are committed to git.\n\n## When to reach for this catalog\n\nUse `@dcsv-io/d2-headers-amqp` from any AMQP-context consumer — RabbitMQ publishers, subscribers, DLQ inspection tools. The catalog includes BOTH the AMQP-only entries (e.g. `MESSAGE_ID`) AND the cross-transport entries (e.g. `TRACEPARENT`) that an AMQP pipeline can encounter; one `import` covers everything that transport's pipeline can encounter.\n\n## Spec contract\n\n`contracts/headers/headers.spec.json` is the single source of truth. Every entry whose `applicability` array contains `\"amqp\"` lives in this catalog (cross-transport entries also live in `@dcsv-io/d2-headers-common` AND every other transport catalog they apply to, all at identical wire values; codegen-guaranteed and verified by `HeaderCatalogConsistencyTests` on the .NET side).\n\n## Header categories\n\n- **Routing + observability**: `MESSAGE_ID`, `TIMESTAMP`, `CONTENT_TYPE`, `PROTO_TYPE`\n- **Cross-hop tracing**: `TRACEPARENT`, `TRACESTATE`, `PROPAGATED_CONTEXT`\n- **Encryption + DLQ ops**: `ENCRYPTION_KID`, `FAILURE_REASON`\n\nHeaders MUST NOT carry user identity, scopes, fingerprints, or any other sensitive context — the broker stores headers as plaintext at rest.\n\n## Dependencies\n\nNone at runtime — pure constants. DevDeps: `vitest` + `@vitest/coverage-v8` + `typescript`.\n\n## Reference\n\n- `contracts/headers/headers.spec.json` — source spec\n- `@dcsv-io/d2-headers-common` — cross-transport subset\n- `@dcsv-io/d2-headers-http` — HTTP-applicable subset\n- `@dcsv-io/d2-headers-grpc` — gRPC-applicable subset\n","readmeFilename":"README.md"}