@pattern-stack/codegen 0.15.2 → 0.15.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. package/CHANGELOG.md +32 -0
  2. package/dist/{chunk-COGHTKXY.js → chunk-27ETSJ2X.js} +2 -2
  3. package/dist/{chunk-WPXNN6QS.js → chunk-4H3PETLM.js} +6 -6
  4. package/dist/{chunk-24CWKBK5.js → chunk-4MF3HKJA.js} +3 -3
  5. package/dist/chunk-4MF3HKJA.js.map +1 -0
  6. package/dist/{chunk-T6C4LFLC.js → chunk-7YGORYZD.js} +4 -4
  7. package/dist/{chunk-I6MG4M3F.js → chunk-FBGHYQIZ.js} +4 -4
  8. package/dist/{chunk-WEVWJKOW.js → chunk-GCYKMF22.js} +7 -7
  9. package/dist/{chunk-OZZJDRGW.js → chunk-IYNSRIGR.js} +8 -8
  10. package/dist/{chunk-DKKFTHHI.js → chunk-J7JMVS2B.js} +4 -4
  11. package/dist/{chunk-KMZCQASO.js → chunk-O37C3YE6.js} +8 -8
  12. package/dist/{chunk-JRVNVKN6.js → chunk-RDVTWIYY.js} +7 -7
  13. package/dist/{chunk-7LKAMLV4.js → chunk-T6SCOJF4.js} +4 -4
  14. package/dist/{chunk-WRUUSZDJ.js → chunk-WWGYCIJX.js} +3 -3
  15. package/dist/{chunk-4OMHBMZJ.js → chunk-YLPAPPLW.js} +3 -3
  16. package/dist/chunk-YLPAPPLW.js.map +1 -0
  17. package/dist/runtime/base-classes/index.js +21 -21
  18. package/dist/runtime/subsystems/analytics/analytics.module.js +2 -2
  19. package/dist/runtime/subsystems/analytics/index.js +4 -4
  20. package/dist/runtime/subsystems/auth/auth.module.js +3 -3
  21. package/dist/runtime/subsystems/auth/index.js +6 -6
  22. package/dist/runtime/subsystems/bridge/bridge.module.js +11 -11
  23. package/dist/runtime/subsystems/bridge/index.js +17 -17
  24. package/dist/runtime/subsystems/cache/cache.drizzle-backend.js +2 -2
  25. package/dist/runtime/subsystems/cache/cache.module.js +3 -3
  26. package/dist/runtime/subsystems/cache/index.js +5 -5
  27. package/dist/runtime/subsystems/events/events.module.js +1 -1
  28. package/dist/runtime/subsystems/events/index.js +3 -3
  29. package/dist/runtime/subsystems/index.d.ts +5 -1
  30. package/dist/runtime/subsystems/index.js +70 -59
  31. package/dist/runtime/subsystems/integration/build-change-source.js +3 -3
  32. package/dist/runtime/subsystems/integration/index.js +24 -24
  33. package/dist/runtime/subsystems/integration/integration.module.js +3 -3
  34. package/dist/runtime/subsystems/integration/poll-change-source.d.ts +1 -1
  35. package/dist/runtime/subsystems/integration/poll-change-source.js +1 -1
  36. package/dist/runtime/subsystems/integration/webhook-change-source.d.ts +4 -3
  37. package/dist/runtime/subsystems/integration/webhook-change-source.js +1 -1
  38. package/dist/runtime/subsystems/jobs/index.js +18 -18
  39. package/dist/runtime/subsystems/jobs/job-orchestrator.bullmq-backend.js +4 -4
  40. package/dist/runtime/subsystems/jobs/job-run-service.drizzle-backend.js +2 -2
  41. package/dist/runtime/subsystems/jobs/job-run-service.memory-backend.js +2 -2
  42. package/dist/runtime/subsystems/jobs/job-worker.module.js +7 -7
  43. package/dist/runtime/subsystems/jobs/jobs-domain.module.js +6 -6
  44. package/dist/runtime/subsystems/observability/index.js +3 -3
  45. package/dist/src/cli/index.js +10 -10
  46. package/dist/src/index.js +8 -8
  47. package/package.json +1 -1
  48. package/runtime/subsystems/index.ts +27 -0
  49. package/runtime/subsystems/integration/poll-change-source.ts +10 -7
  50. package/runtime/subsystems/integration/webhook-change-source.ts +12 -8
  51. package/dist/chunk-24CWKBK5.js.map +0 -1
  52. package/dist/chunk-4OMHBMZJ.js.map +0 -1
  53. /package/dist/{chunk-COGHTKXY.js.map → chunk-27ETSJ2X.js.map} +0 -0
  54. /package/dist/{chunk-WPXNN6QS.js.map → chunk-4H3PETLM.js.map} +0 -0
  55. /package/dist/{chunk-T6C4LFLC.js.map → chunk-7YGORYZD.js.map} +0 -0
  56. /package/dist/{chunk-I6MG4M3F.js.map → chunk-FBGHYQIZ.js.map} +0 -0
  57. /package/dist/{chunk-WEVWJKOW.js.map → chunk-GCYKMF22.js.map} +0 -0
  58. /package/dist/{chunk-OZZJDRGW.js.map → chunk-IYNSRIGR.js.map} +0 -0
  59. /package/dist/{chunk-DKKFTHHI.js.map → chunk-J7JMVS2B.js.map} +0 -0
  60. /package/dist/{chunk-KMZCQASO.js.map → chunk-O37C3YE6.js.map} +0 -0
  61. /package/dist/{chunk-JRVNVKN6.js.map → chunk-RDVTWIYY.js.map} +0 -0
  62. /package/dist/{chunk-7LKAMLV4.js.map → chunk-T6SCOJF4.js.map} +0 -0
  63. /package/dist/{chunk-WRUUSZDJ.js.map → chunk-WWGYCIJX.js.map} +0 -0
package/CHANGELOG.md CHANGED
@@ -4,6 +4,38 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [0.15.3] — 2026-06-03
8
+
9
+ Package-mode **inbound webhook drain** — the first real exercise of
10
+ `WebhookChangeSource` by a `runtime: package` consumer (swe-brain's Slack
11
+ inbound pipeline-parity drain, ADR-0009 §6). One latent transposition this path
12
+ exercises; the fix is framework-only.
13
+
14
+ ### Fixed
15
+
16
+ - **`WebhookChangeSource` (and the identically-shaped `PollChangeSource`) now
17
+ derive `Change<T>.externalId` from the mapping `source`, not `target`.** Both
18
+ primitives located the `DetectionConfig` mapping entry with `target ===
19
+ 'external_id'` correctly, then read the emitted record off
20
+ `mapping.target` — a transposition. Mapping semantics are `{ source: <field on
21
+ the emitted record>, target: <canonical column> }`, and `fetch()` reads
22
+ `record[externalIdSourceField]` off the emitted record, so it must use
23
+ `.source`. The two diverge only when the canonical record is vendor-neutral
24
+ camelCase (`source: 'externalId'` → `target: 'external_id'`): such a consumer
25
+ hit `record missing string 'external_id'` and the primitive was unusable. The
26
+ original unit fixtures masked it by keying records `external_id` (== the
27
+ target). Regression tests now cover the camelCase consumer shape directly.
28
+
29
+ ### Added
30
+
31
+ - **Webhook/poll/detection symbols re-exported from
32
+ `@pattern-stack/codegen/subsystems`.** `WebhookChangeSource`,
33
+ `WebhookChangeSourceOptions`, `WebhookFetchCallback`, `WebhookFetchContext`,
34
+ `WebhookCursor`, `buildChangeSource`, `DetectionConfigSchema`,
35
+ `DetectionConfig` (+ poll equivalents) were previously reachable only via the
36
+ deep `.../integration/index` path; they now ride the public barrel alongside
37
+ the curated `IncrementalReadBase` / `ExecuteIntegrationUseCase` forwards.
38
+
7
39
  ## [0.15.2] — 2026-06-03
8
40
 
9
41
  Package-mode **bridge *delivery*** — the first time a `runtime: package` consumer
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  DrizzleCacheService
3
- } from "./chunk-T6C4LFLC.js";
3
+ } from "./chunk-7YGORYZD.js";
4
4
  import {
5
5
  MemoryCacheService
6
6
  } from "./chunk-IF5I3DAA.js";
@@ -81,4 +81,4 @@ CacheModule = __decorateClass([
81
81
  export {
82
82
  CacheModule
83
83
  };
84
- //# sourceMappingURL=chunk-COGHTKXY.js.map
84
+ //# sourceMappingURL=chunk-27ETSJ2X.js.map
@@ -3,11 +3,7 @@ import {
3
3
  } from "./chunk-RC23QROE.js";
4
4
  import {
5
5
  JobsDomainModule
6
- } from "./chunk-KMZCQASO.js";
7
- import {
8
- BootValidationError,
9
- ReservedPoolViolationError
10
- } from "./chunk-T4BIIU5E.js";
6
+ } from "./chunk-O37C3YE6.js";
11
7
  import {
12
8
  BULLMQ_CONNECTION,
13
9
  BULLMQ_RESOLVED_CONFIG,
@@ -18,6 +14,10 @@ import {
18
14
  allPoolNames,
19
15
  loadPoolConfig
20
16
  } from "./chunk-RHVN6NA7.js";
17
+ import {
18
+ BootValidationError,
19
+ ReservedPoolViolationError
20
+ } from "./chunk-T4BIIU5E.js";
21
21
  import {
22
22
  HandlerRegistry
23
23
  } from "./chunk-CO6LUM72.js";
@@ -287,4 +287,4 @@ export {
287
287
  JobWorkerOrchestrator,
288
288
  JobWorkerModule
289
289
  };
290
- //# sourceMappingURL=chunk-WPXNN6QS.js.map
290
+ //# sourceMappingURL=chunk-4H3PETLM.js.map
@@ -29,7 +29,7 @@ var PollChangeSource = class {
29
29
  "PollChangeSource: DetectionConfig.mapping must include an entry with target 'external_id' so emitted Change<T>.externalId can be populated"
30
30
  );
31
31
  }
32
- this.externalIdSourceField = externalIdMapping.target;
32
+ this.externalIdSourceField = externalIdMapping.source;
33
33
  this.adapter = opts.adapter;
34
34
  this.filters = config.filters;
35
35
  const isCdc = config.poll.provenance === "cdc";
@@ -56,7 +56,7 @@ var PollChangeSource = class {
56
56
  const externalIdRaw = record[this.externalIdSourceField];
57
57
  if (typeof externalIdRaw !== "string" || externalIdRaw.length === 0) {
58
58
  throw new Error(
59
- `PollChangeSource: record missing string '${this.externalIdSourceField}' \u2014 emitted records MUST carry the canonical external id keyed by the mapping target`
59
+ `PollChangeSource: record missing string '${this.externalIdSourceField}' \u2014 emitted records MUST carry the canonical external id keyed by the mapping source`
60
60
  );
61
61
  }
62
62
  let dedupKey;
@@ -91,4 +91,4 @@ var PollChangeSource = class {
91
91
  export {
92
92
  PollChangeSource
93
93
  };
94
- //# sourceMappingURL=chunk-24CWKBK5.js.map
94
+ //# sourceMappingURL=chunk-4MF3HKJA.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../runtime/subsystems/integration/poll-change-source.ts"],"sourcesContent":["/**\n * Integration subsystem — `PollChangeSource<T>` primitive (#226-3, ADR-033).\n *\n * Generic poll-mode `IChangeSource<T>` implementation parameterized by a\n * parsed `DetectionConfig` (poll mode) and a consumer-supplied\n * `PollFetchCallback<T>`. The primitive owns:\n *\n * - filter resolution (flat-AND vocabulary per epic decision Q3 — richer\n * boolean expressions deferred);\n * - field mapping → `Change.externalId` derivation;\n * - cursor strategy passthrough (the orchestrator passes the prior cursor\n * by-value per ADR-033 / #226-2; the callback yields the next cursor\n * per record; the primitive simply stamps it onto `Change<T>`);\n * - `Change<T>.source` provenance (`'poll'` by default);\n * - middleware-chain composition (the `ChangeMiddleware<T>` shape\n * locked in #226-1).\n *\n * Shape locks (decision memo Q5):\n * - `PollFetchContext = { subscription, cursor, filters }` — explicitly\n * NO `userId` / `tenantId`. Run-scope identity is closed over by the\n * consumer at adapter construction (or resolved inside the callback\n * via consumer services). Threading it through the seam would force\n * port expansion every time run-context grows.\n *\n * The adapter callback returns `{ record: T; cursor: PollCursor }` — the\n * primitive does not reach into the record to extract a cursor itself.\n * `cursor.field` from `DetectionConfig.poll.cursor` is metadata for codegen\n * + adapters; the primitive trusts what the callback yielded.\n */\n\nimport type {\n DetectionConfig,\n ResolvedFilter,\n} from './detection-config.schema';\nimport type {\n Change,\n ChangeSource,\n IChangeSource,\n IntegrationSubscriptionView,\n} from './integration-change-source.protocol';\nimport type {\n ChangeIterator,\n ChangeMiddleware,\n} from './integration-middleware.protocol';\n\n// ============================================================================\n// Cursor + adapter callback shapes\n// ============================================================================\n\n/**\n * Opaque poll-cursor shape. Each provider/entity pair binds it concretely\n * via the cursor strategy (`{ systemModstamp }`, `{ replayId }`, etc.); the\n * primitive treats it as an opaque value to pass through.\n */\nexport type PollCursor = unknown;\n\n/**\n * The context the primitive forwards to the adapter callback. Locked to\n * exactly three fields per decision memo Q5 — `userId` / `tenantId` are\n * NOT here on purpose.\n */\nexport interface PollFetchContext {\n readonly subscription: IntegrationSubscriptionView;\n readonly cursor: PollCursor | null;\n readonly filters: readonly ResolvedFilter[];\n}\n\n/**\n * Consumer-supplied fetch callback. Returns an async iterable of\n * `{ record, cursor }` pairs — `record` is already the canonical `T`\n * (the adapter does provider-side translation), `cursor` is the post-record\n * cursor the orchestrator should persist if the run completes successfully.\n */\nexport type PollFetchCallback<T> = (\n ctx: PollFetchContext,\n) => AsyncIterable<{ record: T; cursor: PollCursor }>;\n\n// ============================================================================\n// Constructor options\n// ============================================================================\n\nexport interface PollChangeSourceOptions<T> {\n /** Consumer-supplied fetch callback. */\n readonly adapter: PollFetchCallback<T>;\n /**\n * Parsed detection config. MUST be `mode: 'poll'`; the constructor\n * throws if a webhook config is supplied. Codegen-emitted factories\n * call `DetectionConfigSchema.parse(...)` upstream so this is a safety\n * net, not the primary validation point.\n */\n readonly config: DetectionConfig;\n /**\n * Optional middleware chain. First element is the outermost layer:\n * sees `(subscription, cursor)` first and yielded `Change<T>` last.\n * Locked shape (#226-1) — the primitive composes them with its own\n * `listChanges` implementation as the innermost iterator.\n */\n readonly middlewares?: ReadonlyArray<ChangeMiddleware<T>>;\n /**\n * Optional human label for run logs (e.g. `'salesforce-poll-opportunity'`).\n * Defaults to a derived label based on the subscription domain at\n * construction time fallback — adapters are encouraged to provide one.\n */\n readonly label?: string;\n}\n\n// ============================================================================\n// PollChangeSource<T>\n// ============================================================================\n\nexport class PollChangeSource<T> implements IChangeSource<T> {\n public readonly label: string;\n\n private readonly adapter: PollFetchCallback<T>;\n private readonly filters: readonly ResolvedFilter[];\n private readonly externalIdSourceField: string;\n private readonly source: ChangeSource;\n /**\n * When `poll.provenance === 'cdc'`, the field on the emitted record from\n * which `Change<T>.dedupKey` is read — sourced from `poll.cursor.field`\n * (Stripe-style event endpoints carry the event id on the record itself\n * and the cursor advances over the same id). `null` for default poll\n * provenance, which does NOT populate `dedupKey`.\n */\n private readonly dedupKeySourceField: string | null;\n private readonly composed: ChangeIterator<T>;\n\n constructor(opts: PollChangeSourceOptions<T>) {\n if (opts.config.mode !== 'poll') {\n throw new Error(\n `PollChangeSource requires DetectionConfig.mode === 'poll'; got '${(opts.config as { mode: string }).mode}'`,\n );\n }\n const config = opts.config;\n\n // Field mapping: locate the entry whose canonical `target` is `external_id`.\n // Adapters emit T already-mapped, but the primitive needs to know which key\n // on T carries the external id so it can stamp `Change.externalId`. That key\n // is the mapping's `source` (the field on the emitted record), NOT its\n // `target` (the canonical column) — they differ whenever the canonical\n // record is vendor-neutral camelCase (e.g. `source: 'externalId'` →\n // `target: 'external_id'`). Source of truth is the mapping table — codegen\n // emits it from YAML, the primitive reads it here.\n const externalIdMapping = config.mapping.find(\n (m) => m.target === 'external_id',\n );\n if (!externalIdMapping) {\n throw new Error(\n \"PollChangeSource: DetectionConfig.mapping must include an entry with target 'external_id' so emitted Change<T>.externalId can be populated\",\n );\n }\n this.externalIdSourceField = externalIdMapping.source;\n\n this.adapter = opts.adapter;\n this.filters = config.filters;\n // Provenance: `mode: 'poll'` defaults to `'poll'`; opt into `'cdc'` via\n // `poll.provenance` (Stripe-style event endpoints — wired in #226-4).\n // CDC provenance also stamps `dedupKey` from the cursor's `field`, since\n // those endpoints surface a per-event id on each record (the same id the\n // cursor advances over).\n const isCdc = config.poll.provenance === 'cdc';\n this.source = isCdc ? 'cdc' : 'poll';\n this.dedupKeySourceField = isCdc ? config.poll.cursor.field : null;\n\n this.label =\n opts.label ?? `poll-change-source:${externalIdMapping.source}`;\n\n // Compose middleware chain. The terminal iterator is `this.fetch`\n // bound to `this`. First middleware in the array is the outermost\n // layer (sees subscription/cursor first, yielded changes last).\n const inner: ChangeIterator<T> = (sub, cur) => this.fetch(sub, cur);\n const middlewares = opts.middlewares ?? [];\n this.composed = middlewares.reduceRight<ChangeIterator<T>>(\n (next, mw) => mw(next),\n inner,\n );\n }\n\n listChanges(\n subscription: IntegrationSubscriptionView,\n cursor: unknown | null,\n ): AsyncIterable<Change<T>> {\n return this.composed(subscription, cursor);\n }\n\n private async *fetch(\n subscription: IntegrationSubscriptionView,\n cursor: unknown | null,\n ): AsyncIterable<Change<T>> {\n const ctx: PollFetchContext = {\n subscription,\n cursor: cursor as PollCursor | null,\n filters: this.filters,\n };\n\n for await (const { record, cursor: nextCursor } of this.adapter(ctx)) {\n const externalIdRaw = (record as Record<string, unknown>)[\n this.externalIdSourceField\n ];\n if (typeof externalIdRaw !== 'string' || externalIdRaw.length === 0) {\n throw new Error(\n `PollChangeSource: record missing string '${this.externalIdSourceField}' — emitted records MUST carry the canonical external id keyed by the mapping source`,\n );\n }\n let dedupKey: string | undefined;\n if (this.dedupKeySourceField !== null) {\n const dedupRaw = (record as Record<string, unknown>)[\n this.dedupKeySourceField\n ];\n if (typeof dedupRaw !== 'string' || dedupRaw.length === 0) {\n throw new Error(\n `PollChangeSource: cdc-provenance record missing string '${this.dedupKeySourceField}' — when poll.provenance === 'cdc' the cursor.field must be present on each record so dedupKey can be populated`,\n );\n }\n dedupKey = dedupRaw;\n }\n\n const change: Change<T> = {\n externalId: externalIdRaw,\n // Polling cannot distinguish create vs. update vs. delete on its\n // own — all yielded records are surfaced as 'updated'. The\n // orchestrator's diff stage classifies create-vs-update against\n // local state; soft-delete detection is out of scope for the\n // primitive (consumer drives via tombstone records or a separate\n // sweep — see ADR-033).\n operation: 'updated',\n record,\n cursor: nextCursor,\n source: this.source,\n ...(dedupKey !== undefined ? { dedupKey } : {}),\n };\n yield change;\n }\n }\n}\n"],"mappings":";AA8GO,IAAM,mBAAN,MAAsD;AAAA,EAC3C;AAAA,EAEC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQA;AAAA,EACA;AAAA,EAEjB,YAAY,MAAkC;AAC5C,QAAI,KAAK,OAAO,SAAS,QAAQ;AAC/B,YAAM,IAAI;AAAA,QACR,mEAAoE,KAAK,OAA4B,IAAI;AAAA,MAC3G;AAAA,IACF;AACA,UAAM,SAAS,KAAK;AAUpB,UAAM,oBAAoB,OAAO,QAAQ;AAAA,MACvC,CAAC,MAAM,EAAE,WAAW;AAAA,IACtB;AACA,QAAI,CAAC,mBAAmB;AACtB,YAAM,IAAI;AAAA,QACR;AAAA,MACF;AAAA,IACF;AACA,SAAK,wBAAwB,kBAAkB;AAE/C,SAAK,UAAU,KAAK;AACpB,SAAK,UAAU,OAAO;AAMtB,UAAM,QAAQ,OAAO,KAAK,eAAe;AACzC,SAAK,SAAS,QAAQ,QAAQ;AAC9B,SAAK,sBAAsB,QAAQ,OAAO,KAAK,OAAO,QAAQ;AAE9D,SAAK,QACH,KAAK,SAAS,sBAAsB,kBAAkB,MAAM;AAK9D,UAAM,QAA2B,CAAC,KAAK,QAAQ,KAAK,MAAM,KAAK,GAAG;AAClE,UAAM,cAAc,KAAK,eAAe,CAAC;AACzC,SAAK,WAAW,YAAY;AAAA,MAC1B,CAAC,MAAM,OAAO,GAAG,IAAI;AAAA,MACrB;AAAA,IACF;AAAA,EACF;AAAA,EAEA,YACE,cACA,QAC0B;AAC1B,WAAO,KAAK,SAAS,cAAc,MAAM;AAAA,EAC3C;AAAA,EAEA,OAAe,MACb,cACA,QAC0B;AAC1B,UAAM,MAAwB;AAAA,MAC5B;AAAA,MACA;AAAA,MACA,SAAS,KAAK;AAAA,IAChB;AAEA,qBAAiB,EAAE,QAAQ,QAAQ,WAAW,KAAK,KAAK,QAAQ,GAAG,GAAG;AACpE,YAAM,gBAAiB,OACrB,KAAK,qBACP;AACA,UAAI,OAAO,kBAAkB,YAAY,cAAc,WAAW,GAAG;AACnE,cAAM,IAAI;AAAA,UACR,4CAA4C,KAAK,qBAAqB;AAAA,QACxE;AAAA,MACF;AACA,UAAI;AACJ,UAAI,KAAK,wBAAwB,MAAM;AACrC,cAAM,WAAY,OAChB,KAAK,mBACP;AACA,YAAI,OAAO,aAAa,YAAY,SAAS,WAAW,GAAG;AACzD,gBAAM,IAAI;AAAA,YACR,2DAA2D,KAAK,mBAAmB;AAAA,UACrF;AAAA,QACF;AACA,mBAAW;AAAA,MACb;AAEA,YAAM,SAAoB;AAAA,QACxB,YAAY;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,QAOZ,WAAW;AAAA,QACX;AAAA,QACA,QAAQ;AAAA,QACR,QAAQ,KAAK;AAAA,QACb,GAAI,aAAa,SAAY,EAAE,SAAS,IAAI,CAAC;AAAA,MAC/C;AACA,YAAM;AAAA,IACR;AAAA,EACF;AACF;","names":[]}
@@ -1,9 +1,9 @@
1
- import {
2
- cacheEntries
3
- } from "./chunk-FASRXRX5.js";
4
1
  import {
5
2
  CACHE_DEFAULT_TTL
6
3
  } from "./chunk-L6FTY45T.js";
4
+ import {
5
+ cacheEntries
6
+ } from "./chunk-FASRXRX5.js";
7
7
  import {
8
8
  DRIZZLE
9
9
  } from "./chunk-U64T4YZE.js";
@@ -109,4 +109,4 @@ DrizzleCacheService = __decorateClass([
109
109
  export {
110
110
  DrizzleCacheService
111
111
  };
112
- //# sourceMappingURL=chunk-T6C4LFLC.js.map
112
+ //# sourceMappingURL=chunk-7YGORYZD.js.map
@@ -1,12 +1,12 @@
1
- import {
2
- MissingTenantIdError
3
- } from "./chunk-T4BIIU5E.js";
4
1
  import {
5
2
  clampLimit,
6
3
  decodeKeysetCursor,
7
4
  encodeKeysetCursor,
8
5
  toJobRunSummary
9
6
  } from "./chunk-L3LZWWSX.js";
7
+ import {
8
+ MissingTenantIdError
9
+ } from "./chunk-T4BIIU5E.js";
10
10
  import {
11
11
  JOBS_MULTI_TENANT,
12
12
  JOB_ORCHESTRATOR
@@ -198,4 +198,4 @@ DrizzleJobRunService = __decorateClass([
198
198
  export {
199
199
  DrizzleJobRunService
200
200
  };
201
- //# sourceMappingURL=chunk-I6MG4M3F.js.map
201
+ //# sourceMappingURL=chunk-FBGHYQIZ.js.map
@@ -1,15 +1,15 @@
1
- import {
2
- MemoryCursorStore
3
- } from "./chunk-AHV4GDYM.js";
4
- import {
5
- DrizzleIntegrationRunRecorder
6
- } from "./chunk-SR7F3TJY.js";
7
1
  import {
8
2
  MemoryRunRecorder
9
3
  } from "./chunk-EO2QPOKH.js";
10
4
  import {
11
5
  PostgresCursorStore
12
6
  } from "./chunk-DCCZB4UC.js";
7
+ import {
8
+ MemoryCursorStore
9
+ } from "./chunk-AHV4GDYM.js";
10
+ import {
11
+ DrizzleIntegrationRunRecorder
12
+ } from "./chunk-SR7F3TJY.js";
13
13
  import {
14
14
  DeepEqualDiffer
15
15
  } from "./chunk-36U5UGIO.js";
@@ -78,4 +78,4 @@ IntegrationModule = __decorateClass([
78
78
  export {
79
79
  IntegrationModule
80
80
  };
81
- //# sourceMappingURL=chunk-WEVWJKOW.js.map
81
+ //# sourceMappingURL=chunk-GCYKMF22.js.map
@@ -1,30 +1,30 @@
1
1
  import {
2
2
  bridgeRegistry
3
3
  } from "./chunk-5A432NZJ.js";
4
- import {
5
- BridgeOutboxDrainHook
6
- } from "./chunk-L7BNNRGI.js";
7
4
  import {
8
5
  EventFlowService
9
6
  } from "./chunk-32BMMV4H.js";
10
7
  import {
11
8
  BRIDGE_RESERVED_POOLS
12
9
  } from "./chunk-EDKJU5BO.js";
13
- import {
14
- BridgeDeliveryHandler
15
- } from "./chunk-YTN6BKWA.js";
16
10
  import {
17
11
  DrizzleBridgeDeliveryRepo
18
12
  } from "./chunk-K2I6XIK5.js";
19
13
  import {
20
14
  MemoryBridgeDeliveryRepo
21
15
  } from "./chunk-4DOJBQTP.js";
16
+ import {
17
+ BridgeOutboxDrainHook
18
+ } from "./chunk-L7BNNRGI.js";
19
+ import {
20
+ BridgeDeliveryHandler
21
+ } from "./chunk-YTN6BKWA.js";
22
22
  import {
23
23
  BridgeReservedPoolsNotPolledError
24
24
  } from "./chunk-NXXDZ6ZF.js";
25
25
  import {
26
26
  JOB_WORKER_MODULE_OPTIONS
27
- } from "./chunk-WPXNN6QS.js";
27
+ } from "./chunk-4H3PETLM.js";
28
28
  import {
29
29
  BRIDGE_DELIVERY_REPO,
30
30
  BRIDGE_MODULE_OPTIONS,
@@ -119,4 +119,4 @@ BridgeModule = __decorateClass([
119
119
  export {
120
120
  BridgeModule
121
121
  };
122
- //# sourceMappingURL=chunk-OZZJDRGW.js.map
122
+ //# sourceMappingURL=chunk-IYNSRIGR.js.map
@@ -1,9 +1,9 @@
1
- import {
2
- NoopAnalyticsBackend
3
- } from "./chunk-J37YWU7Y.js";
4
1
  import {
5
2
  CubeAnalyticsBackend
6
3
  } from "./chunk-7B3RYX45.js";
4
+ import {
5
+ NoopAnalyticsBackend
6
+ } from "./chunk-J37YWU7Y.js";
7
7
  import {
8
8
  ANALYTICS_QUERY,
9
9
  CUBE_API_SECRET,
@@ -50,4 +50,4 @@ AnalyticsModule = __decorateClass([
50
50
  export {
51
51
  AnalyticsModule
52
52
  };
53
- //# sourceMappingURL=chunk-DKKFTHHI.js.map
53
+ //# sourceMappingURL=chunk-J7JMVS2B.js.map
@@ -1,12 +1,17 @@
1
1
  import {
2
2
  DrizzleJobRunService
3
- } from "./chunk-I6MG4M3F.js";
3
+ } from "./chunk-FBGHYQIZ.js";
4
4
  import {
5
5
  MemoryJobRunService
6
- } from "./chunk-JRVNVKN6.js";
6
+ } from "./chunk-RDVTWIYY.js";
7
7
  import {
8
8
  DrizzleJobStepService
9
9
  } from "./chunk-DV4RV2DC.js";
10
+ import {
11
+ BULLMQ_CONNECTION,
12
+ BULLMQ_RESOLVED_CONFIG,
13
+ resolveBullMqConfig
14
+ } from "./chunk-I6MVCB5A.js";
10
15
  import {
11
16
  DrizzleJobOrchestrator
12
17
  } from "./chunk-5Y7W3XR6.js";
@@ -19,11 +24,6 @@ import {
19
24
  import {
20
25
  MemoryJobStore
21
26
  } from "./chunk-SNQ3TOWP.js";
22
- import {
23
- BULLMQ_CONNECTION,
24
- BULLMQ_RESOLVED_CONFIG,
25
- resolveBullMqConfig
26
- } from "./chunk-I6MVCB5A.js";
27
27
  import {
28
28
  JOBS_MULTI_TENANT,
29
29
  JOB_ORCHESTRATOR,
@@ -108,4 +108,4 @@ JobsDomainModule = __decorateClass([
108
108
  export {
109
109
  JobsDomainModule
110
110
  };
111
- //# sourceMappingURL=chunk-KMZCQASO.js.map
111
+ //# sourceMappingURL=chunk-O37C3YE6.js.map
@@ -1,15 +1,15 @@
1
- import {
2
- MemoryJobStore
3
- } from "./chunk-SNQ3TOWP.js";
4
- import {
5
- MissingTenantIdError
6
- } from "./chunk-T4BIIU5E.js";
7
1
  import {
8
2
  clampLimit,
9
3
  decodeKeysetCursor,
10
4
  encodeKeysetCursor,
11
5
  toJobRunSummary
12
6
  } from "./chunk-L3LZWWSX.js";
7
+ import {
8
+ MemoryJobStore
9
+ } from "./chunk-SNQ3TOWP.js";
10
+ import {
11
+ MissingTenantIdError
12
+ } from "./chunk-T4BIIU5E.js";
13
13
  import {
14
14
  JOBS_MULTI_TENANT,
15
15
  JOB_ORCHESTRATOR
@@ -209,4 +209,4 @@ function compareBy(a, b, order) {
209
209
  export {
210
210
  MemoryJobRunService
211
211
  };
212
- //# sourceMappingURL=chunk-JRVNVKN6.js.map
212
+ //# sourceMappingURL=chunk-RDVTWIYY.js.map
@@ -1,15 +1,15 @@
1
1
  import {
2
2
  EnvEncryptionKey
3
3
  } from "./chunk-IP4OO26U.js";
4
+ import {
5
+ AuthController
6
+ } from "./chunk-SZVPIHWE.js";
4
7
  import {
5
8
  DrizzleOAuthStateStore
6
9
  } from "./chunk-N5OTOWTP.js";
7
10
  import {
8
11
  MemoryOAuthStateStore
9
12
  } from "./chunk-QLTJSCE6.js";
10
- import {
11
- AuthController
12
- } from "./chunk-SZVPIHWE.js";
13
13
  import {
14
14
  AUTH_OPTIONS,
15
15
  ENCRYPTION_KEY,
@@ -89,4 +89,4 @@ AuthModule = __decorateClass([
89
89
  export {
90
90
  AuthModule
91
91
  };
92
- //# sourceMappingURL=chunk-7LKAMLV4.js.map
92
+ //# sourceMappingURL=chunk-T6SCOJF4.js.map
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  PollChangeSource
3
- } from "./chunk-24CWKBK5.js";
3
+ } from "./chunk-4MF3HKJA.js";
4
4
  import {
5
5
  WebhookChangeSource
6
- } from "./chunk-4OMHBMZJ.js";
6
+ } from "./chunk-YLPAPPLW.js";
7
7
 
8
8
  // runtime/subsystems/integration/build-change-source.ts
9
9
  function buildChangeSource(cfg, fetch, middlewares = []) {
@@ -26,4 +26,4 @@ function buildChangeSource(cfg, fetch, middlewares = []) {
26
26
  export {
27
27
  buildChangeSource
28
28
  };
29
- //# sourceMappingURL=chunk-WRUUSZDJ.js.map
29
+ //# sourceMappingURL=chunk-WWGYCIJX.js.map
@@ -20,7 +20,7 @@ var WebhookChangeSource = class {
20
20
  "WebhookChangeSource: DetectionConfig.mapping must include an entry with target 'external_id' so emitted Change<T>.externalId can be populated"
21
21
  );
22
22
  }
23
- this.externalIdSourceField = externalIdMapping.target;
23
+ this.externalIdSourceField = externalIdMapping.source;
24
24
  this.eventIdSourceField = config.webhook.eventIdField;
25
25
  this.queue = opts.queue;
26
26
  this.label = opts.label ?? `webhook-change-source:${externalIdMapping.source}`;
@@ -43,7 +43,7 @@ var WebhookChangeSource = class {
43
43
  const externalIdRaw = record[this.externalIdSourceField];
44
44
  if (typeof externalIdRaw !== "string" || externalIdRaw.length === 0) {
45
45
  throw new Error(
46
- `WebhookChangeSource: record missing string '${this.externalIdSourceField}' \u2014 emitted records MUST carry the canonical external id keyed by the mapping target`
46
+ `WebhookChangeSource: record missing string '${this.externalIdSourceField}' \u2014 emitted records MUST carry the canonical external id keyed by the mapping source`
47
47
  );
48
48
  }
49
49
  const eventIdRaw = record[this.eventIdSourceField];
@@ -72,4 +72,4 @@ var WebhookChangeSource = class {
72
72
  export {
73
73
  WebhookChangeSource
74
74
  };
75
- //# sourceMappingURL=chunk-4OMHBMZJ.js.map
75
+ //# sourceMappingURL=chunk-YLPAPPLW.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../runtime/subsystems/integration/webhook-change-source.ts"],"sourcesContent":["/**\n * Integration subsystem — `WebhookChangeSource<T>` primitive (#226-4, ADR-033).\n *\n * Generic webhook-mode `IChangeSource<T>` implementation parameterized by a\n * parsed `DetectionConfig` (webhook mode) and a consumer-supplied\n * `WebhookFetchCallback<T>` that iterates a consumer-owned inbound staging\n * queue. The primitive owns:\n *\n * - canonical `Change<T>.source = 'webhook'` stamping;\n * - `dedupKey` derivation from the configured `webhook.eventIdField` on\n * the emitted record;\n * - `externalId` derivation: the mapping entry whose `target === 'external_id'`\n * names — via its `source` — the field on the emitted record that carries\n * the canonical external id (mirrors `PollChangeSource`);\n * - middleware-chain composition via the locked `ChangeMiddleware<T>` shape\n * (#226-1) — same composition seam as the poll primitive.\n *\n * The primitive is **passive**: it iterates whatever the consumer-owned\n * queue yields. It does NOT synchronously drive the orchestrator, does NOT\n * own a transport, and does NOT manage acks. The inbound staging table\n * schema is consumer-owned and deferred per ADR-0002 §Phase 4 — the\n * `WebhookFetchCallback<T>` is the queue contract the consumer injects.\n *\n * Shape locks (decision memo Q5, mirrored from poll primitive):\n * - `WebhookFetchContext = { subscription, cursor }` — explicitly NO\n * `userId` / `tenantId`. Run-scope identity is closed over by the\n * consumer at queue construction or resolved inside the callback via\n * consumer services. There are no `filters` on the webhook context —\n * filtering is done at registration / on the staging row, not at the\n * port seam (the queue is already filtered by the time the primitive\n * iterates).\n *\n * Long-lived streaming CDC primitives (SFDC Pub-Sub gRPC, Debezium/Kafka,\n * Postgres logical replication) are deferred to `#226-8` — they need a\n * fundamentally different lifecycle (`subscribe(onChange, onError)`,\n * server-paced backpressure, ack-on-yield) and shouldn't be retrofitted\n * into either this primitive or the poll primitive.\n */\n\nimport type { DetectionConfig } from './detection-config.schema';\nimport type {\n Change,\n IChangeSource,\n IntegrationSubscriptionView,\n} from './integration-change-source.protocol';\nimport type {\n ChangeIterator,\n ChangeMiddleware,\n} from './integration-middleware.protocol';\n\n// ============================================================================\n// Cursor + queue callback shapes\n// ============================================================================\n\n/**\n * Opaque webhook cursor shape. Webhook mode typically has a cursor of\n * `{ ts: ISO-string }` (last drained staging-row timestamp) but the\n * primitive treats it as opaque. Consumer-owned queue iterators interpret\n * it however the staging schema needs.\n */\nexport type WebhookCursor = unknown;\n\n/**\n * Context the primitive forwards to the queue iterator. Locked to exactly\n * two fields per the same Q5 reasoning that locks `PollFetchContext` — no\n * `userId` / `tenantId`.\n */\nexport interface WebhookFetchContext {\n readonly subscription: IntegrationSubscriptionView;\n readonly cursor: WebhookCursor | null;\n}\n\n/**\n * Consumer-supplied queue iterator. Returns an async iterable of\n * `{ record }` pairs — the consumer drains the inbound staging queue and\n * emits already-mapped canonical records `T`. The primitive stamps\n * `source: 'webhook'` and `dedupKey` from the record's configured\n * `webhook.eventIdField`; the consumer is the one who decided when a\n * staging row is \"ready\" to drain.\n *\n * Webhook mode has no per-record cursor advance — the staging-row drain\n * order is consumer policy (FIFO by ingestion timestamp, by event id, etc.)\n * and is opaque to the primitive. The orchestrator's last-yielded cursor\n * is whatever the consumer chooses to surface, if anything.\n */\nexport type WebhookFetchCallback<T> = (\n ctx: WebhookFetchContext,\n) => AsyncIterable<{ record: T; cursor?: WebhookCursor }>;\n\n// ============================================================================\n// Constructor options\n// ============================================================================\n\nexport interface WebhookChangeSourceOptions<T> {\n /** Consumer-supplied inbound queue iterator. */\n readonly queue: WebhookFetchCallback<T>;\n /**\n * Parsed detection config. MUST be `mode: 'webhook'`; the constructor\n * throws if a poll config is supplied. Codegen-emitted factories call\n * `DetectionConfigSchema.parse(...)` upstream so this is a safety net,\n * not the primary validation point.\n */\n readonly config: DetectionConfig;\n /**\n * Optional middleware chain. Same shape and composition rules as\n * `PollChangeSource` — first element is the outermost layer.\n */\n readonly middlewares?: ReadonlyArray<ChangeMiddleware<T>>;\n /**\n * Optional human label for run logs (e.g. `'stripe-webhook-charge'`).\n * Defaults to a derived label based on the mapping at construction.\n */\n readonly label?: string;\n}\n\n// ============================================================================\n// WebhookChangeSource<T>\n// ============================================================================\n\nexport class WebhookChangeSource<T> implements IChangeSource<T> {\n public readonly label: string;\n\n private readonly queue: WebhookFetchCallback<T>;\n private readonly externalIdSourceField: string;\n private readonly eventIdSourceField: string;\n private readonly composed: ChangeIterator<T>;\n\n constructor(opts: WebhookChangeSourceOptions<T>) {\n if (opts.config.mode !== 'webhook') {\n throw new Error(\n `WebhookChangeSource requires DetectionConfig.mode === 'webhook'; got '${(opts.config as { mode: string }).mode}'`,\n );\n }\n const config = opts.config;\n\n // Field mapping: locate the entry whose canonical `target` is `external_id`\n // — mirrors the poll primitive's contract. Adapters emit records\n // already-mapped; the primitive needs to know which key on T carries the\n // external id so it can stamp `Change.externalId`. That key is the\n // mapping's `source` (the field on the emitted record), NOT its `target`\n // (the canonical column) — they differ whenever the canonical record is\n // vendor-neutral camelCase (e.g. `source: 'externalId'` → `target: 'external_id'`).\n const externalIdMapping = config.mapping.find(\n (m) => m.target === 'external_id',\n );\n if (!externalIdMapping) {\n throw new Error(\n \"WebhookChangeSource: DetectionConfig.mapping must include an entry with target 'external_id' so emitted Change<T>.externalId can be populated\",\n );\n }\n this.externalIdSourceField = externalIdMapping.source;\n this.eventIdSourceField = config.webhook.eventIdField;\n\n this.queue = opts.queue;\n\n this.label =\n opts.label ?? `webhook-change-source:${externalIdMapping.source}`;\n\n // Compose middleware chain — same shape as PollChangeSource.\n const inner: ChangeIterator<T> = (sub, cur) => this.fetch(sub, cur);\n const middlewares = opts.middlewares ?? [];\n this.composed = middlewares.reduceRight<ChangeIterator<T>>(\n (next, mw) => mw(next),\n inner,\n );\n }\n\n listChanges(\n subscription: IntegrationSubscriptionView,\n cursor: unknown | null,\n ): AsyncIterable<Change<T>> {\n return this.composed(subscription, cursor);\n }\n\n private async *fetch(\n subscription: IntegrationSubscriptionView,\n cursor: unknown | null,\n ): AsyncIterable<Change<T>> {\n const ctx: WebhookFetchContext = {\n subscription,\n cursor: cursor as WebhookCursor | null,\n };\n\n for await (const { record, cursor: nextCursor } of this.queue(ctx)) {\n const externalIdRaw = (record as Record<string, unknown>)[\n this.externalIdSourceField\n ];\n if (typeof externalIdRaw !== 'string' || externalIdRaw.length === 0) {\n throw new Error(\n `WebhookChangeSource: record missing string '${this.externalIdSourceField}' — emitted records MUST carry the canonical external id keyed by the mapping source`,\n );\n }\n const eventIdRaw = (record as Record<string, unknown>)[\n this.eventIdSourceField\n ];\n if (typeof eventIdRaw !== 'string' || eventIdRaw.length === 0) {\n throw new Error(\n `WebhookChangeSource: record missing string '${this.eventIdSourceField}' — webhook records MUST carry the event id (DetectionConfig.webhook.eventIdField) so Change<T>.dedupKey can be populated`,\n );\n }\n\n const change: Change<T> = {\n externalId: externalIdRaw,\n // Webhook mode cannot distinguish create vs. update vs. delete on\n // its own — the orchestrator's diff stage handles classification.\n // Tombstone / soft-delete detection is consumer-driven (same as\n // poll mode — see ADR-033).\n operation: 'updated',\n record,\n cursor: nextCursor ?? null,\n source: 'webhook',\n dedupKey: eventIdRaw,\n };\n yield change;\n }\n }\n}\n"],"mappings":";AAuHO,IAAM,sBAAN,MAAyD;AAAA,EAC9C;AAAA,EAEC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAEjB,YAAY,MAAqC;AAC/C,QAAI,KAAK,OAAO,SAAS,WAAW;AAClC,YAAM,IAAI;AAAA,QACR,yEAA0E,KAAK,OAA4B,IAAI;AAAA,MACjH;AAAA,IACF;AACA,UAAM,SAAS,KAAK;AASpB,UAAM,oBAAoB,OAAO,QAAQ;AAAA,MACvC,CAAC,MAAM,EAAE,WAAW;AAAA,IACtB;AACA,QAAI,CAAC,mBAAmB;AACtB,YAAM,IAAI;AAAA,QACR;AAAA,MACF;AAAA,IACF;AACA,SAAK,wBAAwB,kBAAkB;AAC/C,SAAK,qBAAqB,OAAO,QAAQ;AAEzC,SAAK,QAAQ,KAAK;AAElB,SAAK,QACH,KAAK,SAAS,yBAAyB,kBAAkB,MAAM;AAGjE,UAAM,QAA2B,CAAC,KAAK,QAAQ,KAAK,MAAM,KAAK,GAAG;AAClE,UAAM,cAAc,KAAK,eAAe,CAAC;AACzC,SAAK,WAAW,YAAY;AAAA,MAC1B,CAAC,MAAM,OAAO,GAAG,IAAI;AAAA,MACrB;AAAA,IACF;AAAA,EACF;AAAA,EAEA,YACE,cACA,QAC0B;AAC1B,WAAO,KAAK,SAAS,cAAc,MAAM;AAAA,EAC3C;AAAA,EAEA,OAAe,MACb,cACA,QAC0B;AAC1B,UAAM,MAA2B;AAAA,MAC/B;AAAA,MACA;AAAA,IACF;AAEA,qBAAiB,EAAE,QAAQ,QAAQ,WAAW,KAAK,KAAK,MAAM,GAAG,GAAG;AAClE,YAAM,gBAAiB,OACrB,KAAK,qBACP;AACA,UAAI,OAAO,kBAAkB,YAAY,cAAc,WAAW,GAAG;AACnE,cAAM,IAAI;AAAA,UACR,+CAA+C,KAAK,qBAAqB;AAAA,QAC3E;AAAA,MACF;AACA,YAAM,aAAc,OAClB,KAAK,kBACP;AACA,UAAI,OAAO,eAAe,YAAY,WAAW,WAAW,GAAG;AAC7D,cAAM,IAAI;AAAA,UACR,+CAA+C,KAAK,kBAAkB;AAAA,QACxE;AAAA,MACF;AAEA,YAAM,SAAoB;AAAA,QACxB,YAAY;AAAA;AAAA;AAAA;AAAA;AAAA,QAKZ,WAAW;AAAA,QACX;AAAA,QACA,QAAQ,cAAc;AAAA,QACtB,QAAQ;AAAA,QACR,UAAU;AAAA,MACZ;AACA,YAAM;AAAA,IACR;AAAA,EACF;AACF;","names":[]}
@@ -1,6 +1,18 @@
1
+ import {
2
+ MetadataEntityRepository
3
+ } from "../../chunk-7KOW6PU6.js";
4
+ import {
5
+ MetadataEntityService
6
+ } from "../../chunk-RFH7N6EP.js";
1
7
  import {
2
8
  WithAnalytics
3
9
  } from "../../chunk-IBGER4YK.js";
10
+ import {
11
+ IntegratedEntityRepository
12
+ } from "../../chunk-OTDN3OUQ.js";
13
+ import {
14
+ IntegratedEntityService
15
+ } from "../../chunk-2VHZ7EKC.js";
4
16
  import {
5
17
  JunctionIntegrationRepository,
6
18
  buildCompositeExternalId,
@@ -12,12 +24,6 @@ import {
12
24
  import {
13
25
  KnowledgeEntityService
14
26
  } from "../../chunk-AS3NAZB6.js";
15
- import {
16
- MetadataEntityRepository
17
- } from "../../chunk-7KOW6PU6.js";
18
- import {
19
- MetadataEntityService
20
- } from "../../chunk-RFH7N6EP.js";
21
27
  import {
22
28
  ActivityEntityRepository
23
29
  } from "../../chunk-XCEI7NUH.js";
@@ -28,24 +34,9 @@ import {
28
34
  BaseFindByIdUseCase,
29
35
  BaseListUseCase
30
36
  } from "../../chunk-EXVDJMIY.js";
31
- import {
32
- IntegratedEntityRepository
33
- } from "../../chunk-OTDN3OUQ.js";
34
37
  import {
35
38
  BaseRepository
36
39
  } from "../../chunk-J6KZS54B.js";
37
- import {
38
- requireRequester,
39
- requireRequesterScope,
40
- tryGetRequester,
41
- withOrgScope,
42
- withRequester,
43
- withSuperuserScope,
44
- withUserScope
45
- } from "../../chunk-ZUKFQL6E.js";
46
- import {
47
- IntegratedEntityService
48
- } from "../../chunk-2VHZ7EKC.js";
49
40
  import {
50
41
  BaseService
51
42
  } from "../../chunk-W72PRNJY.js";
@@ -56,6 +47,15 @@ import {
56
47
  emitSafely,
57
48
  entitySnapshot
58
49
  } from "../../chunk-KYR3B3OW.js";
50
+ import {
51
+ requireRequester,
52
+ requireRequesterScope,
53
+ tryGetRequester,
54
+ withOrgScope,
55
+ withRequester,
56
+ withSuperuserScope,
57
+ withUserScope
58
+ } from "../../chunk-ZUKFQL6E.js";
59
59
  import "../../chunk-2E224ZSN.js";
60
60
  export {
61
61
  ActivityEntityRepository,
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  AnalyticsModule
3
- } from "../../../chunk-DKKFTHHI.js";
4
- import "../../../chunk-J37YWU7Y.js";
3
+ } from "../../../chunk-J7JMVS2B.js";
5
4
  import "../../../chunk-7B3RYX45.js";
5
+ import "../../../chunk-J37YWU7Y.js";
6
6
  import "../../../chunk-6I7ULIN6.js";
7
7
  import "../../../chunk-GYGNEQSC.js";
8
8
  import "../../../chunk-2E224ZSN.js";
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  AnalyticsModule
3
- } from "../../../chunk-DKKFTHHI.js";
4
- import {
5
- NoopAnalyticsBackend
6
- } from "../../../chunk-J37YWU7Y.js";
3
+ } from "../../../chunk-J7JMVS2B.js";
7
4
  import {
8
5
  CubeAnalyticsBackend
9
6
  } from "../../../chunk-7B3RYX45.js";
7
+ import {
8
+ NoopAnalyticsBackend
9
+ } from "../../../chunk-J37YWU7Y.js";
10
10
  import {
11
11
  ANALYTICS_QUERY,
12
12
  CUBE_API_SECRET,
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  AuthModule
3
- } from "../../../chunk-7LKAMLV4.js";
3
+ } from "../../../chunk-T6SCOJF4.js";
4
4
  import "../../../chunk-IP4OO26U.js";
5
+ import "../../../chunk-SZVPIHWE.js";
5
6
  import "../../../chunk-N5OTOWTP.js";
6
7
  import "../../../chunk-QLTJSCE6.js";
7
8
  import "../../../chunk-BPARRK6F.js";
8
- import "../../../chunk-SZVPIHWE.js";
9
- import "../../../chunk-6XY6ZMMD.js";
10
9
  import "../../../chunk-NPFPZ2HO.js";
10
+ import "../../../chunk-6XY6ZMMD.js";
11
11
  import "../../../chunk-GYGNEQSC.js";
12
12
  import "../../../chunk-U64T4YZE.js";
13
13
  import "../../../chunk-2E224ZSN.js";
@@ -19,10 +19,13 @@ import {
19
19
  } from "../../../chunk-OSQRXVG2.js";
20
20
  import {
21
21
  AuthModule
22
- } from "../../../chunk-7LKAMLV4.js";
22
+ } from "../../../chunk-T6SCOJF4.js";
23
23
  import {
24
24
  EnvEncryptionKey
25
25
  } from "../../../chunk-IP4OO26U.js";
26
+ import {
27
+ AuthController
28
+ } from "../../../chunk-SZVPIHWE.js";
26
29
  import {
27
30
  DrizzleOAuthStateStore
28
31
  } from "../../../chunk-N5OTOWTP.js";
@@ -33,8 +36,8 @@ import {
33
36
  OAuthStateError
34
37
  } from "../../../chunk-BPARRK6F.js";
35
38
  import {
36
- AuthController
37
- } from "../../../chunk-SZVPIHWE.js";
39
+ authOAuthState
40
+ } from "../../../chunk-NPFPZ2HO.js";
38
41
  import {
39
42
  AUTH_CONNECTION_GRANT_SINK,
40
43
  AUTH_CONNECTION_READER,
@@ -45,9 +48,6 @@ import {
45
48
  OAUTH_STATE_STORE,
46
49
  STRATEGY_REGISTRY
47
50
  } from "../../../chunk-6XY6ZMMD.js";
48
- import {
49
- authOAuthState
50
- } from "../../../chunk-NPFPZ2HO.js";
51
51
  import "../../../chunk-GYGNEQSC.js";
52
52
  import "../../../chunk-ZUKFQL6E.js";
53
53
  import "../../../chunk-U64T4YZE.js";
@@ -1,30 +1,30 @@
1
1
  import {
2
2
  BridgeModule
3
- } from "../../../chunk-OZZJDRGW.js";
3
+ } from "../../../chunk-IYNSRIGR.js";
4
4
  import "../../../chunk-5A432NZJ.js";
5
- import "../../../chunk-L7BNNRGI.js";
6
5
  import "../../../chunk-32BMMV4H.js";
7
6
  import "../../../chunk-EDKJU5BO.js";
8
- import "../../../chunk-YTN6BKWA.js";
9
7
  import "../../../chunk-K2I6XIK5.js";
10
- import "../../../chunk-6DWFJNIK.js";
11
8
  import "../../../chunk-4DOJBQTP.js";
9
+ import "../../../chunk-L7BNNRGI.js";
10
+ import "../../../chunk-YTN6BKWA.js";
11
+ import "../../../chunk-6DWFJNIK.js";
12
12
  import "../../../chunk-2TVVBC53.js";
13
13
  import "../../../chunk-NXXDZ6ZF.js";
14
- import "../../../chunk-WPXNN6QS.js";
14
+ import "../../../chunk-4H3PETLM.js";
15
15
  import "../../../chunk-RC23QROE.js";
16
- import "../../../chunk-KMZCQASO.js";
17
- import "../../../chunk-I6MG4M3F.js";
18
- import "../../../chunk-JRVNVKN6.js";
16
+ import "../../../chunk-O37C3YE6.js";
17
+ import "../../../chunk-FBGHYQIZ.js";
18
+ import "../../../chunk-RDVTWIYY.js";
19
+ import "../../../chunk-L3LZWWSX.js";
19
20
  import "../../../chunk-DV4RV2DC.js";
21
+ import "../../../chunk-I6MVCB5A.js";
22
+ import "../../../chunk-RHVN6NA7.js";
20
23
  import "../../../chunk-5Y7W3XR6.js";
21
24
  import "../../../chunk-4RFHUZXU.js";
22
25
  import "../../../chunk-PNZSGAB2.js";
23
26
  import "../../../chunk-SNQ3TOWP.js";
24
27
  import "../../../chunk-T4BIIU5E.js";
25
- import "../../../chunk-L3LZWWSX.js";
26
- import "../../../chunk-I6MVCB5A.js";
27
- import "../../../chunk-RHVN6NA7.js";
28
28
  import "../../../chunk-CO6LUM72.js";
29
29
  import "../../../chunk-BIO6F7YI.js";
30
30
  import "../../../chunk-H5NH7KPE.js";