{"_id":"@absolutejs/dispatch-telnyx","_rev":"3-f110a73b586055f95a03ca1d2510fb32","name":"@absolutejs/dispatch-telnyx","dist-tags":{"latest":"0.3.0"},"versions":{"0.1.0":{"name":"@absolutejs/dispatch-telnyx","version":"0.1.0","keywords":["absolutejs","dispatch","telnyx","sms","mms","rcs","10dlc"],"author":{"name":"Alex Kahn"},"license":"Apache-2.0","_id":"@absolutejs/dispatch-telnyx@0.1.0","maintainers":[{"name":"alexkahndev","email":"alexkahn2019@gmail.com"}],"homepage":"https://github.com/absolutejs/dispatch-adapters/tree/main/telnyx","bugs":{"url":"https://github.com/absolutejs/dispatch-adapters/issues"},"dist":{"shasum":"da39ca9039bd7cfee6ffb5ec8d9699e02dcc3f40","tarball":"https://registry.npmjs.org/@absolutejs/dispatch-telnyx/-/dispatch-telnyx-0.1.0.tgz","fileCount":22,"integrity":"sha512-SViRT8w8CVlDpm+7y9OvhCmpX3ZmBUvyUCFuYF/XYx+3xqcLMKJkSy+4Rpu3VAz83OBHlQt7egalONzsGLC1fA==","signatures":[{"sig":"MEUCIB3NDXGlCTA5Rv7bz2/PPwOZQLou2/57r8vFhoGr3Gv/AiEA4gElaLR0CPzMILHAIA3MsMav6fEfGA6WGlz2w44sEas=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":148834},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./manifest":{"types":"./dist/manifest.d.ts","import":"./dist/manifest.js","default":"./dist/manifest.js"},"./manifest.json":"./dist/manifest.json"},"gitHead":"60f2121776ae1f0d138f9ea77f6ac04889f5f1b0","scripts":{"test":"bun test","build":"rm -rf dist && bun build src/index.ts src/manifest.ts --outdir dist --sourcemap --target=bun --external @absolutejs/compliance --external @absolutejs/dispatch --external '@absolutejs/dispatch/*' --external @absolutejs/reliability --external '@absolutejs/reliability/*' --external @absolutejs/manifest --external @sinclair/typebox --external telnyx --external 'telnyx/*' && tsc --project tsconfig.build.json && absolute-manifest emit","format":"prettier --write \"./**/*.{ts,json,md}\"","release":"bun run check:package && npm publish --access public","typecheck":"tsc --noEmit","check:package":"bun run format && bun run typecheck && bun run test && bun run verify-package && bun run build && bun run verify-package --artifacts","verify-package":"absolute-manifest verify-package"},"_npmUser":{"name":"alexkahndev","email":"alexkahn2019@gmail.com"},"absolutejs":{"runtimePeers":{"telnyx":{"range":">=7.0.0 <8","tested":"7.12.0","optional":false,"buildExternals":["telnyx","telnyx/*"],"artifactImports":[]},"@absolutejs/dispatch":{"range":">=0.5.0 <0.6","tested":"0.5.0","optional":false,"buildExternals":["@absolutejs/dispatch","@absolutejs/dispatch/*"],"artifactImports":[]},"@absolutejs/compliance":{"range":">=0.5.0 <0.6","tested":"0.5.0","optional":true,"buildExternals":["@absolutejs/compliance"],"artifactImports":[]}},"manifestContract":2},"repository":{"url":"git+https://github.com/absolutejs/dispatch-adapters.git","type":"git","directory":"telnyx"},"_npmVersion":"10.9.2","description":"Production Telnyx SMS, MMS, and RCS messaging for @absolutejs/dispatch with signed webhooks, consent-safe scheduling, registration workflows, and readiness checks.","directories":{},"_nodeVersion":"22.14.0","dependencies":{"@sinclair/typebox":"^0.34.0","@absolutejs/manifest":"0.7.2","@absolutejs/reliability":"0.1.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"pg":"8.22.0","telnyx":"7.12.0","prettier":"3.8.1","@types/pg":"8.20.3","@types/bun":"1.3.14","typescript":"5.9.3","@absolutejs/dispatch":"0.5.0","@absolutejs/compliance":"0.5.0"},"peerDependencies":{"telnyx":">=7.0.0 <8","@absolutejs/dispatch":">=0.5.0 <0.6","@absolutejs/compliance":">=0.5.0 <0.6"},"peerDependenciesMeta":{"@absolutejs/compliance":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/dispatch-telnyx_0.1.0_1785607436521_0.5365917045019468","host":"s3://npm-registry-packages-npm-production"}},"0.2.0":{"name":"@absolutejs/dispatch-telnyx","version":"0.2.0","keywords":["absolutejs","dispatch","telnyx","sms","mms","rcs","10dlc"],"author":{"name":"Alex Kahn"},"license":"Apache-2.0","_id":"@absolutejs/dispatch-telnyx@0.2.0","maintainers":[{"name":"alexkahndev","email":"alexkahn2019@gmail.com"}],"homepage":"https://github.com/absolutejs/dispatch-adapters/tree/main/telnyx","bugs":{"url":"https://github.com/absolutejs/dispatch-adapters/issues"},"dist":{"shasum":"b25a4b0a54f7b4b79c450553c71bdac18feab7fd","tarball":"https://registry.npmjs.org/@absolutejs/dispatch-telnyx/-/dispatch-telnyx-0.2.0.tgz","fileCount":22,"integrity":"sha512-kbGZRlX6j/7tH10Y+y02oXYy69zcYROCoFeFZGIvrJyV72gt8q1afgThSX7rfA1JqDVgB5YUcOKEM98c25DZag==","signatures":[{"sig":"MEUCIQD6iDRP+XArmLApAAxqJLQg+tcDfTtF2ix+a0Y1uGlAhQIgEdONdc8Sr0SchpJ/meyfTu6owLbv3UpQDAClvaIWiSs=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":154241},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./manifest":{"types":"./dist/manifest.d.ts","import":"./dist/manifest.js","default":"./dist/manifest.js"},"./manifest.json":"./dist/manifest.json"},"gitHead":"ac4ca39431662b229f1ff78f6eeff465d00c5949","scripts":{"test":"bun test","build":"rm -rf dist && bun build src/index.ts src/manifest.ts --outdir dist --sourcemap --target=bun --external @absolutejs/compliance --external @absolutejs/dispatch --external '@absolutejs/dispatch/*' --external @absolutejs/reliability --external '@absolutejs/reliability/*' --external @absolutejs/manifest --external @sinclair/typebox --external telnyx --external 'telnyx/*' && tsc --project tsconfig.build.json && absolute-manifest emit","format":"prettier --write \"./**/*.{ts,json,md}\"","release":"bun run check:package && npm publish --access public","typecheck":"tsc --noEmit","check:package":"bun run format && bun run typecheck && bun run test && bun run verify-package && bun run build && bun run verify-package --artifacts","verify-package":"absolute-manifest verify-package"},"_npmUser":{"name":"alexkahndev","email":"alexkahn2019@gmail.com"},"absolutejs":{"runtimePeers":{"telnyx":{"range":">=7.0.0 <8","tested":"7.12.0","optional":false,"buildExternals":["telnyx","telnyx/*"],"artifactImports":[]},"@absolutejs/dispatch":{"range":">=0.6.0 <0.7","tested":"0.6.0","optional":false,"buildExternals":["@absolutejs/dispatch","@absolutejs/dispatch/*"],"artifactImports":[]},"@absolutejs/compliance":{"range":">=0.6.0 <0.7","tested":"0.6.0","optional":true,"buildExternals":["@absolutejs/compliance"],"artifactImports":[]}},"manifestContract":2},"repository":{"url":"git+https://github.com/absolutejs/dispatch-adapters.git","type":"git","directory":"telnyx"},"_npmVersion":"10.9.2","description":"Production Telnyx SMS, MMS, and RCS messaging for @absolutejs/dispatch with signed webhooks, consent-safe scheduling, registration workflows, and readiness checks.","directories":{},"_nodeVersion":"22.14.0","dependencies":{"@sinclair/typebox":"^0.34.0","@absolutejs/manifest":"0.7.2","@absolutejs/reliability":"0.1.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"pg":"8.22.0","telnyx":"7.12.0","prettier":"3.8.1","@types/pg":"8.20.3","@types/bun":"1.3.14","typescript":"5.9.3","@absolutejs/dispatch":"0.6.0","@absolutejs/compliance":"0.6.0"},"peerDependencies":{"telnyx":">=7.0.0 <8","@absolutejs/dispatch":">=0.6.0 <0.7","@absolutejs/compliance":">=0.6.0 <0.7"},"peerDependenciesMeta":{"@absolutejs/compliance":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/dispatch-telnyx_0.2.0_1785612566320_0.31223374924861","host":"s3://npm-registry-packages-npm-production"}},"0.3.0":{"name":"@absolutejs/dispatch-telnyx","version":"0.3.0","description":"Production Telnyx SMS, MMS, and RCS messaging for @absolutejs/dispatch with signed webhooks, consent-safe scheduling, registration workflows, and readiness checks.","repository":{"type":"git","url":"git+https://github.com/absolutejs/dispatch-adapters.git","directory":"telnyx"},"homepage":"https://github.com/absolutejs/dispatch-adapters/tree/main/telnyx","bugs":{"url":"https://github.com/absolutejs/dispatch-adapters/issues"},"main":"./dist/index.js","module":"./dist/index.js","types":"./dist/index.d.ts","type":"module","license":"Apache-2.0","author":{"name":"Alex Kahn"},"publishConfig":{"access":"public"},"keywords":["absolutejs","dispatch","telnyx","sms","mms","rcs","10dlc"],"scripts":{"build":"rm -rf dist && bun build src/index.ts src/manifest.ts --outdir dist --sourcemap --target=bun --external @absolutejs/compliance --external @absolutejs/dispatch --external '@absolutejs/dispatch/*' --external @absolutejs/reliability --external '@absolutejs/reliability/*' --external @absolutejs/manifest --external @sinclair/typebox --external telnyx --external 'telnyx/*' && tsc --project tsconfig.build.json && absolute-manifest emit","test":"bun test","typecheck":"tsc --noEmit","format":"prettier --write \"./**/*.{ts,json,md}\"","verify-package":"absolute-manifest verify-package","check:package":"bun run format && bun run typecheck && bun run test && bun run verify-package && bun run build && bun run verify-package --artifacts","release":"bun run check:package && npm publish --access public"},"peerDependencies":{"@absolutejs/compliance":">=0.7.0 <0.8","@absolutejs/dispatch":">=0.7.0 <0.8","telnyx":">=7.0.0 <8"},"peerDependenciesMeta":{"@absolutejs/compliance":{"optional":true}},"dependencies":{"@absolutejs/manifest":"0.7.2","@absolutejs/reliability":"0.1.0","@sinclair/typebox":"^0.34.0"},"devDependencies":{"@absolutejs/compliance":"0.7.0","@absolutejs/dispatch":"0.7.1","@types/bun":"1.3.14","@types/pg":"8.20.3","pg":"8.22.0","prettier":"3.8.1","telnyx":"7.12.0","typescript":"5.9.3"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./manifest":{"types":"./dist/manifest.d.ts","import":"./dist/manifest.js","default":"./dist/manifest.js"},"./manifest.json":"./dist/manifest.json"},"absolutejs":{"manifestContract":2,"runtimePeers":{"@absolutejs/compliance":{"artifactImports":[],"buildExternals":["@absolutejs/compliance"],"optional":true,"range":">=0.7.0 <0.8","tested":"0.7.0"},"@absolutejs/dispatch":{"artifactImports":[],"buildExternals":["@absolutejs/dispatch","@absolutejs/dispatch/*"],"optional":false,"range":">=0.7.0 <0.8","tested":"0.7.1"},"telnyx":{"artifactImports":[],"buildExternals":["telnyx","telnyx/*"],"optional":false,"range":">=7.0.0 <8","tested":"7.12.0"}}},"_id":"@absolutejs/dispatch-telnyx@0.3.0","gitHead":"c7ced4f2c36deff0db92b72ef5bf86ca98aa004d","_nodeVersion":"22.14.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-OEx9GBQ5MVf6BTUjFu85SeP2JZKEsHmeRuqQz+m4SFXXfFwNGdI8Nr2Yyj1KFZcKZctyBRfbkbw8yvXpgPBv7A==","shasum":"249c2a16eadf2fb9accf23237ce10c95385029d4","tarball":"https://registry.npmjs.org/@absolutejs/dispatch-telnyx/-/dispatch-telnyx-0.3.0.tgz","fileCount":22,"unpackedSize":154241,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQDnssEyNk6qMgZPH3FPcaO7Twj2hXX7KwAK2vc4PTugmgIhAP593WHNPgtvQC0LHnOxpnTDPQ8CMjn6dpiUsreLQdw2"}]},"_npmUser":{"name":"alexkahndev","email":"alexkahn2019@gmail.com"},"directories":{},"maintainers":[{"name":"alexkahndev","email":"alexkahn2019@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/dispatch-telnyx_0.3.0_1785618466832_0.40131546552802266"},"_hasShrinkwrap":false}},"time":{"created":"2026-08-01T18:03:56.391Z","modified":"2026-08-01T21:07:47.135Z","0.1.0":"2026-08-01T18:03:56.665Z","0.2.0":"2026-08-01T19:29:26.458Z","0.3.0":"2026-08-01T21:07:46.971Z"},"bugs":{"url":"https://github.com/absolutejs/dispatch-adapters/issues"},"author":{"name":"Alex Kahn"},"license":"Apache-2.0","homepage":"https://github.com/absolutejs/dispatch-adapters/tree/main/telnyx","keywords":["absolutejs","dispatch","telnyx","sms","mms","rcs","10dlc"],"repository":{"type":"git","url":"git+https://github.com/absolutejs/dispatch-adapters.git","directory":"telnyx"},"description":"Production Telnyx SMS, MMS, and RCS messaging for @absolutejs/dispatch with signed webhooks, consent-safe scheduling, registration workflows, and readiness checks.","maintainers":[{"name":"alexkahndev","email":"alexkahn2019@gmail.com"}],"readme":"# @absolutejs/dispatch-telnyx\n\nProduction Telnyx SMS, MMS, and direct rich RCS for\n`@absolutejs/dispatch`. The package includes multi-account routing, atomic\nidempotency, Ed25519-signed webhook processing, durable inbox recovery,\nconsent ingestion, scheduling cancellation, RCS capability checks, carrier\nregistration helpers, and readiness diagnostics.\n\n## Install\n\n```sh\nbun add @absolutejs/dispatch@^0.5 @absolutejs/dispatch-telnyx telnyx\nbun add @absolutejs/compliance@^0.5 # when enforcing program consent\n```\n\nAll dependencies above are normal npm releases. No file overrides or package\nprepare/prepack hooks are required.\n\n## Send SMS, MMS, and RCS\n\n```ts\nimport { createDispatcher } from \"@absolutejs/dispatch\";\nimport {\n  createPostgresIdempotentOperationStore,\n  createPostgresTransactionRunner,\n  createTelnyxAdapter,\n} from \"@absolutejs/dispatch-telnyx\";\nimport { Telnyx } from \"telnyx\";\n\nconst client = new Telnyx({ apiKey: process.env.TELNYX_API_KEY! });\nconst runner = createPostgresTransactionRunner(postgresPool);\n\nconst dispatcher = createDispatcher({\n  messaging: createTelnyxAdapter({\n    accountId: process.env.TELNYX_ORGANIZATION_ID!,\n    client,\n    idempotencyStore: createPostgresIdempotentOperationStore(runner),\n    messagingProfileId: process.env.TELNYX_MESSAGING_PROFILE_ID!,\n    rcsAgentId: process.env.TELNYX_RCS_AGENT_ID,\n    webhookFailoverUrl: \"https://failover.example.com/webhooks/telnyx\",\n    webhookUrl: \"https://app.example.com/webhooks/telnyx\",\n  }),\n});\n\nawait dispatcher.messaging({\n  content: { kind: \"text\", text: \"Production database latency is elevated.\" },\n  consent: { programId: \"pro-alerts\", purpose: \"incident-alerts\" },\n  idempotencyKey: \"incident-42:recipient-7\",\n  tenant: \"tenant-a\",\n  to: { address: \"+12025550100\", transport: \"sms\" },\n});\n```\n\nRCS can use portable rich cards and an explicit fallback route. The compliance\npolicy derives both `rcs` and `sms` consent checks from these routes:\n\n```ts\nawait dispatcher.messaging({\n  content: {\n    actions: [\n      {\n        kind: \"url\",\n        label: \"Open incident\",\n        url: \"https://app.example.com/incidents/42\",\n      },\n    ],\n    kind: \"rich\",\n    mediaUrl: \"https://cdn.example.com/incident.png\",\n    text: \"Production database latency is elevated.\",\n    title: \"Incident 42\",\n  },\n  consent: { programId: \"pro-alerts\", purpose: \"incident-alerts\" },\n  fallbacks: [\n    {\n      content: {\n        kind: \"text\",\n        text: \"Incident 42: https://app.example.com/incidents/42\",\n      },\n      from: { address: \"+12025550199\", transport: \"sms\" },\n      transport: \"sms\",\n    },\n  ],\n  to: { address: \"+12025550100\", transport: \"rcs\" },\n});\n```\n\nUse `checkTelnyxRcsCapabilities()` when product behavior should differ before\nsending. Telnyx still performs delivery fallback when one is declared.\n\n## Reliability and webhooks\n\nApply `IDEMPOTENT_OPERATION_POSTGRES_SCHEMA` and\n`WEBHOOK_INBOX_POSTGRES_SCHEMA`, then use a checked-out transaction runner.\nIdempotency is scoped by provider, organization, tenant, namespace, and key;\npayload reuse conflicts, fencing prevents stale completion, and ambiguous\nprovider calls become indeterminate instead of being retried automatically.\n\n```ts\nimport {\n  createPostgresWebhookInboxStore,\n  createTelnyxWebhookHandler,\n} from \"@absolutejs/dispatch-telnyx\";\n\nconst handler = createTelnyxWebhookHandler({\n  consentLedger,\n  handler: processNormalizedEvent,\n  inbox: createPostgresWebhookInboxStore(runner),\n  resolveAccount: (organizationId) => accountConfiguration(organizationId),\n  resolveConsentScopes: (event) => programsForNumber(event.from!.address),\n});\n```\n\n`resolveAccount()` returns one or two active Ed25519 public keys for safe key\nrotation and an optional Messaging Profile allowlist. Verification covers the\nraw body and timestamp before parsing or processing. Events are normalized with\nprovider event id, occurrence time, typed endpoints and content, normalized\ninteraction, provider status, transport, and delivery errors. Completed inbox rows default to a 24-hour\npurge window when the processor runs; applications should also run a scheduled\npurge and their legal-hold policy.\n\n## Scheduling, registration, and readiness\n\nNative scheduling is opt-in, limited to SMS/MMS from five minutes to five days,\nand prohibited for consent-scoped messages. Prefer an Absolute queue that\nre-evaluates consent immediately before delivery. Use\n`createTelnyxScheduledMessageManager()` to inspect or cancel native schedules.\n\n`createTelnyxComplianceManager()` validates privacy/terms, opt-in evidence,\ncurrent business-registration fields, and exposes explicit `a2p` and\n`toll-free` inspections with rejection diagnostics. It does not certify legal\ncompliance. `inspectTelnyxMessagingReadiness()` checks the live Messaging\nProfile/webhook binding plus operator assertions for consent, durable storage,\nopt-out testing, carrier registration, and RCS approval.\n\n## License\n\nApache-2.0.\n","readmeFilename":"README.md"}