@wildo-ai/external-connectors-models 1.1.3 → 1.1.4

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 (81) hide show
  1. package/dist/esm/companion-exports.d.ts.map +1 -1
  2. package/dist/esm/core/commons.external-connectors-models.schemas.d.ts.map +1 -1
  3. package/dist/esm/core/commons.external-connectors-models.schemas.js.map +1 -1
  4. package/dist/esm/core/operation-classification.external-connectors-models.schemas.d.ts.map +1 -1
  5. package/dist/esm/core/operation-classification.external-connectors-models.schemas.js.map +1 -1
  6. package/dist/esm/core/protocols.external-connectors-models.schemas.d.ts.map +1 -1
  7. package/dist/esm/core/protocols.external-connectors-models.schemas.js.map +1 -1
  8. package/dist/esm/core/security.external-connectors-models.schemas.d.ts.map +1 -1
  9. package/dist/esm/core/security.external-connectors-models.schemas.js.map +1 -1
  10. package/dist/esm/index.d.ts.map +1 -1
  11. package/dist/esm/index.js.map +1 -1
  12. package/dist/esm/protocols/agent-client-protocol.external-connectors-models.schemas.d.ts +141 -1
  13. package/dist/esm/protocols/agent-client-protocol.external-connectors-models.schemas.d.ts.map +1 -1
  14. package/dist/esm/protocols/agent-client-protocol.external-connectors-models.schemas.js +167 -1
  15. package/dist/esm/protocols/agent-client-protocol.external-connectors-models.schemas.js.map +1 -1
  16. package/dist/esm/protocols/billing.standard-interface.schemas.d.ts.map +1 -1
  17. package/dist/esm/protocols/billing.standard-interface.schemas.js +1 -1
  18. package/dist/esm/protocols/billing.standard-interface.schemas.js.map +1 -1
  19. package/dist/esm/protocols/document-extraction.external-connectors-models.schemas.d.ts +72 -0
  20. package/dist/esm/protocols/document-extraction.external-connectors-models.schemas.d.ts.map +1 -1
  21. package/dist/esm/protocols/document-extraction.external-connectors-models.schemas.js +77 -2
  22. package/dist/esm/protocols/document-extraction.external-connectors-models.schemas.js.map +1 -1
  23. package/dist/esm/protocols/email.external-connectors-models.schemas.d.ts.map +1 -1
  24. package/dist/esm/protocols/email.standard-interface.schemas.d.ts +5 -5
  25. package/dist/esm/protocols/email.standard-interface.schemas.d.ts.map +1 -1
  26. package/dist/esm/protocols/embeddings.external-connectors-models.schemas.d.ts.map +1 -1
  27. package/dist/esm/protocols/frontend.external-connectors-models.schemas.d.ts.map +1 -1
  28. package/dist/esm/protocols/hooks-capability.external-connectors-models.schemas.d.ts.map +1 -1
  29. package/dist/esm/protocols/hooks-capability.external-connectors-models.schemas.js.map +1 -1
  30. package/dist/esm/protocols/hooks.external-connectors-models.schemas.d.ts.map +1 -1
  31. package/dist/esm/protocols/image.external-connectors-models.schemas.d.ts.map +1 -1
  32. package/dist/esm/protocols/llm.external-connectors-models.schemas.d.ts.map +1 -1
  33. package/dist/esm/protocols/llm.external-connectors-models.schemas.js.map +1 -1
  34. package/dist/esm/protocols/oauth2.external-connectors-models.schemas.d.ts.map +1 -1
  35. package/dist/esm/protocols/rest-api.external-connectors-models.schemas.d.ts.map +1 -1
  36. package/dist/esm/protocols/rest-api.external-connectors-models.schemas.js.map +1 -1
  37. package/dist/esm/protocols/rest-operations.external-connectors-models.schemas.d.ts.map +1 -1
  38. package/dist/esm/protocols/rest-operations.external-connectors-models.schemas.js.map +1 -1
  39. package/dist/esm/protocols/sms.external-connectors-models.schemas.d.ts.map +1 -1
  40. package/dist/esm/protocols/sms.standard-interface.schemas.d.ts +67 -7
  41. package/dist/esm/protocols/sms.standard-interface.schemas.d.ts.map +1 -1
  42. package/dist/esm/protocols/sms.standard-interface.schemas.js +71 -1
  43. package/dist/esm/protocols/sms.standard-interface.schemas.js.map +1 -1
  44. package/dist/tsconfig.build.tsbuildinfo +1 -1
  45. package/package.json +2 -2
  46. package/dist/esm/features/core.external-connectors-models.schemas.d.ts +0 -0
  47. package/dist/esm/features/core.external-connectors-models.schemas.d.ts.map +0 -0
  48. package/dist/esm/features/core.external-connectors-models.schemas.js +0 -0
  49. package/dist/esm/features/core.external-connectors-models.schemas.js.map +0 -0
  50. package/dist/esm/features/email.external-connectors-models.schemas.d.ts +0 -0
  51. package/dist/esm/features/email.external-connectors-models.schemas.d.ts.map +0 -0
  52. package/dist/esm/features/email.external-connectors-models.schemas.js +0 -0
  53. package/dist/esm/features/email.external-connectors-models.schemas.js.map +0 -0
  54. package/dist/esm/features/hooks.external-connectors-models.schemas.d.ts +0 -0
  55. package/dist/esm/features/hooks.external-connectors-models.schemas.d.ts.map +0 -0
  56. package/dist/esm/features/hooks.external-connectors-models.schemas.js +0 -0
  57. package/dist/esm/features/hooks.external-connectors-models.schemas.js.map +0 -0
  58. package/dist/esm/features/sms.external-connectors-models.schemas.d.ts +0 -0
  59. package/dist/esm/features/sms.external-connectors-models.schemas.d.ts.map +0 -0
  60. package/dist/esm/features/sms.external-connectors-models.schemas.js +0 -0
  61. package/dist/esm/features/sms.external-connectors-models.schemas.js.map +0 -0
  62. package/dist/esm/protocols/a2a.external-connectors-models.schemas.d.ts +0 -0
  63. package/dist/esm/protocols/a2a.external-connectors-models.schemas.d.ts.map +0 -0
  64. package/dist/esm/protocols/a2a.external-connectors-models.schemas.js +0 -0
  65. package/dist/esm/protocols/a2a.external-connectors-models.schemas.js.map +0 -0
  66. package/dist/esm/protocols/git.external-connectors-models.schemas.d.ts +0 -0
  67. package/dist/esm/protocols/git.external-connectors-models.schemas.d.ts.map +0 -0
  68. package/dist/esm/protocols/git.external-connectors-models.schemas.js +0 -0
  69. package/dist/esm/protocols/git.external-connectors-models.schemas.js.map +0 -0
  70. package/dist/esm/protocols/grpc.external-connectors-models.schemas.d.ts +0 -0
  71. package/dist/esm/protocols/grpc.external-connectors-models.schemas.d.ts.map +0 -0
  72. package/dist/esm/protocols/grpc.external-connectors-models.schemas.js +0 -0
  73. package/dist/esm/protocols/grpc.external-connectors-models.schemas.js.map +0 -0
  74. package/dist/esm/protocols/mcp.external-connectors-models.schemas.d.ts +0 -0
  75. package/dist/esm/protocols/mcp.external-connectors-models.schemas.d.ts.map +0 -0
  76. package/dist/esm/protocols/mcp.external-connectors-models.schemas.js +0 -0
  77. package/dist/esm/protocols/mcp.external-connectors-models.schemas.js.map +0 -0
  78. package/dist/esm/protocols/saml.external-connectors-models.schemas.d.ts +0 -0
  79. package/dist/esm/protocols/saml.external-connectors-models.schemas.d.ts.map +0 -0
  80. package/dist/esm/protocols/saml.external-connectors-models.schemas.js +0 -0
  81. package/dist/esm/protocols/saml.external-connectors-models.schemas.js.map +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"rest-operations.external-connectors-models.schemas.d.ts","sourceRoot":"","sources":["../../../../src/protocols/rest-operations.external-connectors-models.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,cAAc,EAAE,MAAM,oDAAoD,CAAC;AACpF,OAAO,EAAE,gCAAgC,EAAE,MAAM,qEAAqE,CAAC;AACvH,OAAO,KAAK,EAAE,iCAAiC,EAAE,MAAM,qDAAqD,CAAC;AAE7G,oDAAoD;AACpD,oBAAY,6BAA6B;IACvC,sGAAsG;IACtG,IAAI,SAAS;IACb,KAAK,UAAU;IACf,MAAM,WAAW;CAClB;AAED;;;;GAIG;AACH,oBAAY,+BAA+B;IACzC,IAAI,SAAS;IACb,eAAe,oBAAoB;IACnC,SAAS,cAAc;IACvB,uFAAuF;IACvF,IAAI,SAAS;CACd;AAED;;;;GAIG;AACH,oBAAY,2BAA2B;IACrC,MAAM,WAAW;IACjB,IAAI,SAAS;IACb,MAAM,WAAW;IACjB,qFAAqF;IACrF,IAAI,SAAS;CACd;AAED,2FAA2F;AAC3F,MAAM,WAAW,8BAA8B;IAC7C,4FAA4F;IAC5F,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,EAAE,6BAA6B,CAAC;IAC3C;;;;;OAKG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,gGAAgG;IAChG,QAAQ,CAAC,QAAQ,CAAC,E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E,MAAM,CAAC;CACpC;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,MAAM,wBAAwB,GAAG,CACrC,WAAW,EAAE,MAAM,EACnB,WAAW,EAAE,MAAM,EACnB,KAAK,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,EACxC,UAAU,CAAC,EAAE,iCAAiC,KAC3C,OAAO,CAAC,OAAO,CAAC,CAAC"}
1
+ {"version":3,"file":"rest-operations.external-connectors-models.schemas.d.ts","sourceRoot":"","sources":["../../../src/protocols/rest-operations.external-connectors-models.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,cAAc,EAAE,MAAM,oDAAoD,CAAC;AACpF,OAAO,EAAE,gCAAgC,EAAE,MAAM,qEAAqE,CAAC;AACvH,OAAO,KAAK,EAAE,iCAAiC,EAAE,MAAM,qDAAqD,CAAC;AAE7G,oDAAoD;AACpD,oBAAY,6BAA6B;IACvC,sGAAsG;IACtG,IAAI,SAAS;IACb,KAAK,UAAU;IACf,MAAM,WAAW;CAClB;AAED;;;;GAIG;AACH,oBAAY,+BAA+B;IACzC,IAAI,SAAS;IACb,eAAe,oBAAoB;IACnC,SAAS,cAAc;IACvB,uFAAuF;IACvF,IAAI,SAAS;CACd;AAED;;;;GAIG;AACH,oBAAY,2BAA2B;IACrC,MAAM,WAAW;IACjB,IAAI,SAAS;IACb,MAAM,WAAW;IACjB,qFAAqF;IACrF,IAAI,SAAS;CACd;AAED,2FAA2F;AAC3F,MAAM,WAAW,8BAA8B;IAC7C,4FAA4F;IAC5F,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,EAAE,6BAA6B,CAAC;IAC3C;;;;;OAKG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,gGAAgG;IA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QAAQ,CAAC,gBAAgB,CAAC,EAAE,MAAM,CAAC;CACpC;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,MAAM,wBAAwB,GAAG,CACrC,WAAW,EAAE,MAAM,EACnB,WAAW,EAAE,MAAM,EACnB,KAAK,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,EACxC,UAAU,CAAC,EAAE,iCAAiC,KAC3C,OAAO,CAAC,OAAO,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"rest-operations.external-connectors-models.schemas.js","sourceRoot":"","sources":["../../../../src/protocols/rest-operations.external-connectors-models.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAQH,oDAAoD;AACpD,MAAM,CAAN,IAAY,6BAKX;AALD,WAAY,6BAA6B;IACvC,sGAAsG;IACtG,8CAAa,CAAA;IACb,gDAAe,CAAA;IACf,kDAAiB,CAAA;AACnB,CAAC,EALW,6BAA6B,KAA7B,6BAA6B,QAKxC;AAED;;;;GAIG;AACH,MAAM,CAAN,IAAY,+BAMX;AAND,WAAY,+BAA+B;IACzC,gDAAa,CAAA;IACb,sEAAmC,CAAA;IACnC,0DAAuB,CAAA;IACvB,uFAAuF;IACvF,gDAAa,CAAA;AACf,CAAC,EANW,+BAA+B,KAA/B,+BAA+B,QAM1C;AAED;;;;GAIG;AACH,MAAM,CAAN,IAAY,2BAMX;AAND,WAAY,2BAA2B;IACrC,gDAAiB,CAAA;IACjB,4CAAa,CAAA;IACb,gDAAiB,CAAA;IACjB,qFAAqF;IACrF,4CAAa,CAAA;AACf,CAAC,EANW,2BAA2B,KAA3B,2BAA2B,QAMtC;AA0OD;;;;;;;;;;;;;;GAcG;AACH,MAAM,CAAN,IAAY,yBAeX;AAfD,WAAY,yBAAyB;IACnC;;;;;OAKG;IACH,oDAAuB,CAAA;IACvB;;;;;OAKG;IACH,kEAAqC,CAAA;AACvC,CAAC,EAfW,yBAAyB,KAAzB,yBAAyB,QAepC","sourcesContent":["/**\n * The REST OPERATION vocabulary — what an operation IS, independent of who executes one.\n *\n * Moved here from `@wildo-ai/external-connectors-private/backend` on 2026-09-06 (#378), and the\n * reason is a measurement rather than tidiness. A generated provider's operation catalogue is loaded\n * LAZILY on purpose: the loader contract forbids evaluating it at boot, because a provider whose\n * operations are eager puts every vendor's operations into every process's boot graph. But the\n * catalogue module needs `ProviderRestParameterLocation` and `ProviderRestRequestBodyEncoding` as\n * VALUES, and their only public door was the backend barrel — so reading two string enums pulled the\n * entire backend provider surface in behind them:\n *\n * | import | heap | time |\n * |---|---|---|\n * | `@wildo-ai/external-connectors-models` | 20.8 MB | 39 ms |\n * | `@wildo-ai/external-connectors-private/backend` | 160.7 MB | 251 ms |\n *\n * 161 MB to answer \"is this parameter in the path or the query\". The vocabulary belongs here for a\n * reason that survives the measurement, too: it describes what an operation IS — its method, its\n * path template, where its parameters ride — and none of that is backend runtime. The arrow already\n * pointed this way, since this package has no dependency on the private backend and the private\n * backend depends on it.\n */\n\nimport { z } from 'zod';\n\nimport { API_HttpMethod } from '../core/commons.external-connectors-models.schemas';\nimport { ExternalOperation_Classification } from '../core/operation-classification.external-connectors-models.schemas';\nimport type { ExternalProvider_ConnectionTarget } from '../core/security.external-connectors-models.schemas';\n\n/** Where a declared parameter rides on the wire. */\nexport enum ProviderRestParameterLocation {\n /** Substituted into a `{token}` of the path template. Always required — a path cannot have a hole. */\n PATH = 'path',\n QUERY = 'query',\n HEADER = 'header',\n}\n\n/**\n * How the request body is encoded. The ETL read surface only ever needed JSON; a hand-authored\n * write reaches vendors that take form bodies (OAuth-adjacent endpoints, older CRMs) and file\n * uploads, so the encoding is DECLARED per operation rather than inferred from the method.\n */\nexport enum ProviderRestRequestBodyEncoding {\n JSON = 'json',\n FORM_URLENCODED = 'form-urlencoded',\n MULTIPART = 'multipart',\n /** A raw text body; `contentType` on the declaration says which media type is sent. */\n TEXT = 'text',\n}\n\n/**\n * How a listing operation continues. A HINT the caller reads, never something the executor acts\n * on: an executor that paged on its own would decide a caller's memory budget for it, and the\n * ETL lane already owns paging as a discipline (drift-safe continuation only).\n */\nexport enum ProviderRestPaginationStyle {\n OFFSET = 'offset',\n PAGE = 'page',\n CURSOR = 'cursor',\n /** The vendor returns its own continuation URL (`@odata.nextLink`, `links.next`). */\n LINK = 'link',\n}\n\n/** One declared parameter: a wire name, where it rides, and which input field feeds it. */\nexport interface ProviderRestOperationParameter {\n /** The name ON THE WIRE (`page_size`, `X-Vendor-Version`, or the `{token}` in the path). */\n readonly name: string;\n readonly in: ProviderRestParameterLocation;\n /**\n * The INPUT field that feeds it, when the two differ (`pageSize` → `page_size`). Absent means\n * the input field is spelled exactly like the wire name. Declared, never camel/snake-guessed:\n * a guess that is wrong drops a parameter silently and the vendor answers a valid-looking\n * default page.\n */\n readonly from?: string;\n /** PATH parameters are required whatever this says; for QUERY/HEADER, absent means optional. */\n readonly required?: boolean;\n /** A literal value sent on every call — for a version pin or a fixed format selector. */\n readonly constantValue?: string;\n readonly description?: string;\n}\n\n/** How the request body is built from the operation's input. */\nexport interface ProviderRestOperationRequestBody {\n readonly encoding: ProviderRestRequestBodyEncoding;\n /**\n * The input field carrying the whole body. Absent = the body is every input field NOT consumed\n * by a declared parameter — the ordinary shape, and the reason parameters declare `from`.\n */\n readonly from?: string;\n /** For `TEXT`: the media type actually sent (`text/csv`, `application/xml`). */\n readonly contentType?: string;\n}\n\n/** Where the payload sits inside a response, and how a listing continues. */\nexport interface ProviderRestOperationPagination {\n readonly style: ProviderRestPaginationStyle;\n /** OFFSET/PAGE/CURSOR: the request parameter names the caller advances. */\n readonly limitParam?: string;\n readonly offsetParam?: string;\n readonly pageParam?: string;\n readonly cursorParam?: string;\n /** CURSOR/LINK: dot-path in the RESPONSE carrying the next cursor or the next URL. */\n readonly nextPath?: string;\n}\n\n/**\n * A provider operation, hand-authored. The unit an application addresses:\n * `executeProviderOperation({ providerRef: 'slack', operationId: 'conversations.list', input })`.\n */\nexport interface ProviderRestOperation {\n /** Unique within the provider, and the address an ETL binding reference uses. */\n readonly operationId: string;\n /**\n * The lazy-load unit. `operations('conversations')` answers only this domain's operations, so a\n * vendor with hundreds need not evaluate them all to run one.\n */\n readonly domain: string;\n readonly method: API_HttpMethod;\n /** Relative to the provider's base URL. `{token}` interpolates a PATH parameter of that name. */\n readonly pathTemplate: string;\n readonly summary?: string;\n /**\n * Whether the operation MUTATES the vendor.\n *\n * ONE vocabulary for every operation catalogue, whatever produced it: a hand-authored operation\n * and a generated one are the same concept, and two enums over the same two values is precisely\n * the drift D1 exists to remove. Read by an ETL binding reference (which refuses to serve a read\n * surface from a WRITE), by the audit trail as the axis a reviewer filters on first, and by a UI\n * deciding whether to confirm.\n *\n * The name carried a source catalogue's spelling until 2026-09-06 and no longer does — an\n * operation's EFFECT is not a property of where its definition came from.\n */\n readonly classification: ExternalOperation_Classification;\n readonly parameters?: readonly ProviderRestOperationParameter[];\n readonly requestBody?: ProviderRestOperationRequestBody;\n /**\n * Zod schema the caller's input is parsed through BEFORE anything is compiled. A typed client\n * (S3b) derives its argument type from it. Absent = the input is passed through unvalidated,\n * which is legal for a thin wrapper and honest about carrying no contract.\n */\n readonly inputSchema?: z.ZodType;\n /**\n * Zod schema the RESPONSE is parsed through. Absent = the parsed body is returned as `unknown`.\n * A vendor adding a field must never break a call, so authors should keep these permissive; the\n * value is in naming the fields a caller may rely on, not in policing the vendor.\n */\n readonly outputSchema?: z.ZodType;\n /** Dot-path to the payload inside the response body. Absent = the body IS the payload. */\n readonly resultPath?: string;\n readonly pagination?: ProviderRestOperationPagination;\n /**\n * OAuth scopes (or vendor permission names) the credential must carry. DECLARED in S3a and not\n * yet CHECKED: checking it needs the composed registry's view of the secrets contract, which is\n * #329's. Recorded as owed rather than half-enforced — a check that silently passes is worse\n * than no check.\n */\n readonly requiredScopes?: readonly string[];\n /**\n * Whether re-sending this request is safe. Absent = derived from the method: GET, HEAD, OPTIONS,\n * PUT and DELETE are idempotent, POST and PATCH are not.\n * spec-cite: RFC 9110 §9.2.2 (PUT, DELETE and the safe methods are idempotent) and §9.2.1\n * (GET, HEAD, OPTIONS, TRACE are safe).\n * Declare it TRUE on a POST the vendor documents as idempotent (an idempotency-key endpoint);\n * declaring it wrongly is how a retried timeout charges a customer twice.\n */\n readonly idempotent?: boolean;\n /** Narrows the provider's semantics for this one operation (a slow export, a tight endpoint). */\n readonly remoteCallSemantics?: Partial<ProviderRestCallSemantics>;\n /** Set when the vendor has deprecated it; the executor logs once per operation, never refuses. */\n readonly deprecated?: {\n readonly reason: string;\n readonly since?: string;\n readonly replacedByOperationId?: string;\n };\n}\n\n/** What one `operations(domain?)` call answers. */\nexport interface ProviderRestOperationCatalogue {\n /** The domains this load carries — the whole set when called with no argument. */\n readonly domains: readonly string[];\n /** Keyed by `operationId`. */\n readonly operations: Readonly<Record<string, ProviderRestOperation>>;\n}\n\n/**\n * The lazy catalogue loader — the seam #330's host loader consumes (interface note on #331).\n *\n * MUST NOT be called during composition, discovery or boot: it exists so a provider package can\n * `import()` its own operation module only when a run needs it, and calling it at boot puts every\n * provider's operations back into every process's boot graph, which is the thing on-demand\n * loading exists to remove. Async, idempotent, and memoized by the executor per\n * `(providerRef, domain)` — a loader may assume one call per pair and must stay correct on two.\n *\n * The values it returns carry live Zod schemas, so a catalogue is an IN-PROCESS value and is\n * never serializable into a runtime artifact or any JSON the CLI emits.\n */\nexport type ProviderRestOperationCatalogueLoader = (domain?: string) => Promise<ProviderRestOperationCatalogue>;\n\n/**\n * Provider-level call semantics: the defaults every operation of this provider runs under.\n *\n * Structurally the executable subset of the ETL's `HttpApiRemoteCallSemantics`, and deliberately\n * NOT that type: the ETL's lives in `@wildo-ai/saas-models/external-data` and carries\n * `maxIdSetSize`, an ETL query-translation bound that means nothing to a provider operation.\n * Importing it here would point the PROVIDER contract at the ETL read surface — backwards, since\n * the ETL references provider operations and not the reverse. Three fields is the price of\n * keeping that arrow pointing the right way.\n */\nexport interface ProviderRestCallSemantics {\n /** Per-attempt timeout. */\n readonly timeoutMs: number;\n readonly retry: {\n /** Total attempts including the first; 1 disables retry. */\n readonly maxAttempts: number;\n /** Linear backoff base — attempt N waits `backoffMs * (N - 1)`. */\n readonly backoffMs: number;\n };\n /** A local sliding-window ceiling; the call REFUSES when exhausted rather than queueing. */\n readonly maxRequestsPerMinute?: number;\n}\n\n\n/**\n * A provider whose credential is MINTED by an authorization-code exchange rather than pasted.\n *\n * Recorded because the source catalogues state it and nothing else does. 131 of the 699 transposed\n * vendors declare OAuth2, and their authorize URL, token URL and scopes exist nowhere in this\n * repository except the catalogue that was read — so extracting them and keeping them only in a\n * comment (which is what the transposer did until 2026-09-07) means the delegated-authorization lane\n * re-derives 131 vendors' endpoints by hand.\n *\n * ## What it does NOT change\n *\n * The wire placement. An OAuth2 access token rides in the same header as an API key —\n * `Authorization: Bearer …` — so `apiKey.headerName` and `apiKey.prefix` still describe the request,\n * and `apiKey.secretRef` still names the slot the credential is read from. What this block adds is\n * where that value COMES FROM: an exchange, per organization or per user, refreshable — rather than\n * an operator pasting a long-lived token into an environment variable.\n *\n * That distinction is the whole point. Without it a provider declares a static bearer key and, if an\n * operator happens to paste a long-lived token, WORKS — while advertising a credential model the\n * vendor does not offer, with no authorize step, no refresh and no per-tenant token. A wrong\n * configuration that works is worse than one that fails, because nothing surfaces it.\n *\n * The FLOW is not here and is not implied: connected accounts, the authorization round trip, refresh\n * and revocation are their own lane. This is the declaration that lane consumes.\n */\nexport interface ProviderRestOAuth2 {\n /** Where the user is sent to grant access. Carries the vendor's own default scopes when it states them. */\n readonly authorizeUrl: string;\n /** Where an authorization code (or a refresh token) is exchanged for an access token. */\n readonly tokenUrl: string;\n /**\n * Scopes the vendor's own catalogue entry asked for. Advisory rather than enforced: an application\n * may need fewer, and an operation's `requiredScopes` is the finer statement. Kept because it is\n * the only record of what the vendor expects for the operations transposed beside it.\n */\n readonly scopes?: readonly string[];\n /**\n * Env-var names resolving the APPLICATION's registration with the vendor. These are the two values\n * an operator genuinely does paste — they identify the integration, not the end user — and they\n * are separate from `apiKey.secretRef`, which names the minted access token.\n */\n readonly clientIdSecretRef?: string;\n readonly clientSecretSecretRef?: string;\n /**\n * Placeholders the endpoints above carry, which a CONNECTION must supply before either URL is a\n * URL at all — `{cloud}`, `{tenantId}`, `{region}`, `{domain}`.\n *\n * Measured over the transposed catalogue on 2026-09-08: of the 96 vendors that recovered both\n * endpoints, **21 carry at least one placeholder**, led by `{cloud}` (18), `{location}` (10) and\n * `{tenantId}` (6). Microsoft's authorize URL is\n * `https://{cloud}/{tenantId}/oauth2/v2.0/authorize`, and no amount of application configuration\n * supplies those: which Azure cloud and which directory are facts about the ACCOUNT BEING\n * CONNECTED, known only to the person connecting it.\n *\n * So this is not decoration on the endpoint strings — it is the difference between a vendor that\n * can be connected and one that cannot. Without it the flow would build\n * `https://{cloud}/…/authorize`, send somebody to a hostname containing a brace, and fail in the\n * browser rather than at the point where the missing input could have been asked for.\n *\n * DERIVED from the endpoint strings rather than authored, so a vendor whose URL gains a\n * placeholder declares one the next time the batch runs. Absent — not empty — when the endpoints\n * are plain, which is the common case and must stay distinguishable from \"nobody has looked\".\n *\n * Deliberately NOT a judgement about which connections a provider admits. That is a recorded\n * decision in the catalogue record and is never read from a vendor's API surface; this is a\n * mechanical fact about a string.\n */\n readonly connectionParameters?: readonly string[];\n}\n\n\n/**\n * Vendors whose credential is COMPUTED per request rather than sent as a fixed header.\n *\n * A static header covers bearer tokens and API keys, which is most of the world. It cannot express a\n * signature: AWS Signature Version 4 signs the method, the canonical path, the sorted query, a\n * subset of headers, a SHA-256 of the payload and a timestamp, with a key derived from the secret,\n * the date, the region and the service — so the header's VALUE differs for every request and none of\n * its inputs exist when a provider module is authored.\n *\n * Until this existed, such a vendor could not be expressed at all — not badly, not partially. There\n * was no `if` to write, because the field where the answer goes did not exist. 45 transposed actions\n * across `amazon-s3`, `amazon-ses`, `amazon-textract`, `amazon-secrets-manager`, `amazon-sqs`,\n * `amazon-bedrock`, `azure-blob-storage`, `azure-communication-services` and `azure-openai` are\n * blocked on it (#373).\n */\nexport enum ProviderRestSigningScheme {\n /**\n * AWS Signature Version 4 — the `Authorization: AWS4-HMAC-SHA256 …` scheme used by every current\n * AWS service API.\n * spec-cite: AWS General Reference, \"Signature Version 4 signing process\"\n * (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_sigv4-signing-process.html)\n */\n AWS_SIGV4 = 'AWS_SIGV4',\n /**\n * Azure Storage shared-key — `Authorization: SharedKey <account>:<signature>` over a canonicalized\n * request and resource.\n * spec-cite: Azure Storage REST, \"Authorize with Shared Key\"\n * (https://learn.microsoft.com/en-us/rest/api/storageservices/authorize-with-shared-key)\n */\n AZURE_SHARED_KEY = 'AZURE_SHARED_KEY',\n}\n\n/**\n * How a provider signs each request.\n *\n * Declared by the provider module and executed by the engine, with NO vendor branch in the executor:\n * the scheme is data, and the signer dispatches on it exhaustively. That is the same discipline the\n * rest of the provider contract keeps — a consumer branches on a contract field, never on a\n * provider ref.\n *\n * The credential is TWO values for both schemes (an identity and a secret), and optionally a third\n * for temporary credentials, which is why it cannot ride in the single `apiKey.secretRef` slot.\n */\nexport interface ProviderRestRequestSigning {\n readonly scheme: ProviderRestSigningScheme;\n /** Env-var naming the identity half — an AWS access-key id, an Azure storage account name. */\n readonly keyIdSecretRef: string;\n /** Env-var naming the secret half. */\n readonly secretKeySecretRef: string;\n /**\n * Env-var naming a session token, for temporary credentials (STS, a role assumption). Absent means\n * long-lived credentials; present-but-unset is treated as long-lived rather than as an error,\n * because the same provider serves both.\n */\n readonly sessionTokenSecretRef?: string;\n /**\n * AWS_SIGV4: the region and service that scope the derived key. Both are part of the SIGNATURE,\n * not merely of the URL, so a wrong value fails authentication rather than routing — which is why\n * they are declared rather than parsed out of the host.\n */\n readonly region?: string;\n readonly service?: string;\n /**\n * Env-var overriding {@link region} per deployment, for an application that runs in more than one.\n * The declared value is the default.\n */\n readonly regionEnvVarName?: string;\n}\n\n/**\n * The one function a generated typed client needs, as a TYPE.\n *\n * A generated provider package must not import the engine's runtime to be callable: that would put\n * the whole backend into the module graph of anything that touches a vendor, which is precisely the\n * weight #378 removed (models 20.8 MB against the backend barrel's 160.7 MB). So a client is a\n * FACTORY that takes the executor as an argument — the application wires its own, the package\n * declares only this signature, and nothing crosses at runtime.\n *\n * R3's ergonomics bought with a type rather than a dependency.\n *\n * ## The connection is a parameter, and OPTIONAL for a reason that is not convenience\n *\n * Omitted means the application's own account, acting as itself — the floor, and the only connection\n * that needs no store and no authorization. That default is what keeps the ordinary single-account\n * call as short as it should be.\n *\n * It could not be anything BUT a parameter. One execution may legitimately spend several tenants'\n * accounts — a user action pushing a message to every organization that user belongs to — so a client\n * that read the owner from ambient state could not vary it per call, and the fan-out would be\n * inexpressible through the generated surface even though the engine beneath it supports one.\n */\nexport type ProviderOperationExecute = (\n providerRef: string,\n operationId: string,\n input: Readonly<Record<string, unknown>>,\n connection?: ExternalProvider_ConnectionTarget,\n) => Promise<unknown>;\n"]}
1
+ {"version":3,"file":"rest-operations.external-connectors-models.schemas.js","sourceRoot":"","sources":["../../../src/protocols/rest-operations.external-connectors-models.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAQH,oDAAoD;AACpD,MAAM,CAAN,IAAY,6BAKX;AALD,WAAY,6BAA6B;IACvC,sGAAsG;IACtG,8CAAa,CAAA;IACb,gDAAe,CAAA;IACf,kDAAiB,CAAA;AACnB,CAAC,EALW,6BAA6B,KAA7B,6BAA6B,QAKxC;AAED;;;;GAIG;AACH,MAAM,CAAN,IAAY,+BAMX;AAND,WAAY,+BAA+B;IACzC,gDAAa,CAAA;IACb,sEAAmC,CAAA;IACnC,0DAAuB,CAAA;IACvB,uFAAuF;IACvF,gDAAa,CAAA;AACf,CAAC,EANW,+BAA+B,KAA/B,+BAA+B,QAM1C;AAED;;;;GAIG;AACH,MAAM,CAAN,IAAY,2BAMX;AAND,WAAY,2BAA2B;IACrC,gDAAiB,CAAA;IACjB,4CAAa,CAAA;IACb,gDAAiB,CAAA;IACjB,qFAAqF;IACrF,4CAAa,CAAA;AACf,CAAC,EANW,2BAA2B,KAA3B,2BAA2B,QAMtC;AA0OD;;;;;;;;;;;;;;GAcG;AACH,MAAM,CAAN,IAAY,yBAeX;AAfD,WAAY,yBAAyB;IACnC;;;;;OAKG;IACH,oDAAuB,CAAA;IACvB;;;;;OAKG;IACH,kEAAqC,CAAA;AACvC,CAAC,EAfW,yBAAyB,KAAzB,yBAAyB,QAepC","sourcesContent":["/**\n * The REST OPERATION vocabulary — what an operation IS, independent of who executes one.\n *\n * Moved here from `@wildo-ai/external-connectors-private/backend` on 2026-09-06 (#378), and the\n * reason is a measurement rather than tidiness. A generated provider's operation catalogue is loaded\n * LAZILY on purpose: the loader contract forbids evaluating it at boot, because a provider whose\n * operations are eager puts every vendor's operations into every process's boot graph. But the\n * catalogue module needs `ProviderRestParameterLocation` and `ProviderRestRequestBodyEncoding` as\n * VALUES, and their only public door was the backend barrel — so reading two string enums pulled the\n * entire backend provider surface in behind them:\n *\n * | import | heap | time |\n * |---|---|---|\n * | `@wildo-ai/external-connectors-models` | 20.8 MB | 39 ms |\n * | `@wildo-ai/external-connectors-private/backend` | 160.7 MB | 251 ms |\n *\n * 161 MB to answer \"is this parameter in the path or the query\". The vocabulary belongs here for a\n * reason that survives the measurement, too: it describes what an operation IS — its method, its\n * path template, where its parameters ride — and none of that is backend runtime. The arrow already\n * pointed this way, since this package has no dependency on the private backend and the private\n * backend depends on it.\n */\n\nimport { z } from 'zod';\n\nimport { API_HttpMethod } from '../core/commons.external-connectors-models.schemas';\nimport { ExternalOperation_Classification } from '../core/operation-classification.external-connectors-models.schemas';\nimport type { ExternalProvider_ConnectionTarget } from '../core/security.external-connectors-models.schemas';\n\n/** Where a declared parameter rides on the wire. */\nexport enum ProviderRestParameterLocation {\n /** Substituted into a `{token}` of the path template. Always required — a path cannot have a hole. */\n PATH = 'path',\n QUERY = 'query',\n HEADER = 'header',\n}\n\n/**\n * How the request body is encoded. The ETL read surface only ever needed JSON; a hand-authored\n * write reaches vendors that take form bodies (OAuth-adjacent endpoints, older CRMs) and file\n * uploads, so the encoding is DECLARED per operation rather than inferred from the method.\n */\nexport enum ProviderRestRequestBodyEncoding {\n JSON = 'json',\n FORM_URLENCODED = 'form-urlencoded',\n MULTIPART = 'multipart',\n /** A raw text body; `contentType` on the declaration says which media type is sent. */\n TEXT = 'text',\n}\n\n/**\n * How a listing operation continues. A HINT the caller reads, never something the executor acts\n * on: an executor that paged on its own would decide a caller's memory budget for it, and the\n * ETL lane already owns paging as a discipline (drift-safe continuation only).\n */\nexport enum ProviderRestPaginationStyle {\n OFFSET = 'offset',\n PAGE = 'page',\n CURSOR = 'cursor',\n /** The vendor returns its own continuation URL (`@odata.nextLink`, `links.next`). */\n LINK = 'link',\n}\n\n/** One declared parameter: a wire name, where it rides, and which input field feeds it. */\nexport interface ProviderRestOperationParameter {\n /** The name ON THE WIRE (`page_size`, `X-Vendor-Version`, or the `{token}` in the path). */\n readonly name: string;\n readonly in: ProviderRestParameterLocation;\n /**\n * The INPUT field that feeds it, when the two differ (`pageSize` → `page_size`). Absent means\n * the input field is spelled exactly like the wire name. Declared, never camel/snake-guessed:\n * a guess that is wrong drops a parameter silently and the vendor answers a valid-looking\n * default page.\n */\n readonly from?: string;\n /** PATH parameters are required whatever this says; for QUERY/HEADER, absent means optional. */\n readonly required?: boolean;\n /** A literal value sent on every call — for a version pin or a fixed format selector. */\n readonly constantValue?: string;\n readonly description?: string;\n}\n\n/** How the request body is built from the operation's input. */\nexport interface ProviderRestOperationRequestBody {\n readonly encoding: ProviderRestRequestBodyEncoding;\n /**\n * The input field carrying the whole body. Absent = the body is every input field NOT consumed\n * by a declared parameter — the ordinary shape, and the reason parameters declare `from`.\n */\n readonly from?: string;\n /** For `TEXT`: the media type actually sent (`text/csv`, `application/xml`). */\n readonly contentType?: string;\n}\n\n/** Where the payload sits inside a response, and how a listing continues. */\nexport interface ProviderRestOperationPagination {\n readonly style: ProviderRestPaginationStyle;\n /** OFFSET/PAGE/CURSOR: the request parameter names the caller advances. */\n readonly limitParam?: string;\n readonly offsetParam?: string;\n readonly pageParam?: string;\n readonly cursorParam?: string;\n /** CURSOR/LINK: dot-path in the RESPONSE carrying the next cursor or the next URL. */\n readonly nextPath?: string;\n}\n\n/**\n * A provider operation, hand-authored. The unit an application addresses:\n * `executeProviderOperation({ providerRef: 'slack', operationId: 'conversations.list', input })`.\n */\nexport interface ProviderRestOperation {\n /** Unique within the provider, and the address an ETL binding reference uses. */\n readonly operationId: string;\n /**\n * The lazy-load unit. `operations('conversations')` answers only this domain's operations, so a\n * vendor with hundreds need not evaluate them all to run one.\n */\n readonly domain: string;\n readonly method: API_HttpMethod;\n /** Relative to the provider's base URL. `{token}` interpolates a PATH parameter of that name. */\n readonly pathTemplate: string;\n readonly summary?: string;\n /**\n * Whether the operation MUTATES the vendor.\n *\n * ONE vocabulary for every operation catalogue, whatever produced it: a hand-authored operation\n * and a generated one are the same concept, and two enums over the same two values is precisely\n * the drift D1 exists to remove. Read by an ETL binding reference (which refuses to serve a read\n * surface from a WRITE), by the audit trail as the axis a reviewer filters on first, and by a UI\n * deciding whether to confirm.\n *\n * The name carried a source catalogue's spelling until 2026-09-06 and no longer does — an\n * operation's EFFECT is not a property of where its definition came from.\n */\n readonly classification: ExternalOperation_Classification;\n readonly parameters?: readonly ProviderRestOperationParameter[];\n readonly requestBody?: ProviderRestOperationRequestBody;\n /**\n * Zod schema the caller's input is parsed through BEFORE anything is compiled. A typed client\n * (S3b) derives its argument type from it. Absent = the input is passed through unvalidated,\n * which is legal for a thin wrapper and honest about carrying no contract.\n */\n readonly inputSchema?: z.ZodType;\n /**\n * Zod schema the RESPONSE is parsed through. Absent = the parsed body is returned as `unknown`.\n * A vendor adding a field must never break a call, so authors should keep these permissive; the\n * value is in naming the fields a caller may rely on, not in policing the vendor.\n */\n readonly outputSchema?: z.ZodType;\n /** Dot-path to the payload inside the response body. Absent = the body IS the payload. */\n readonly resultPath?: string;\n readonly pagination?: ProviderRestOperationPagination;\n /**\n * OAuth scopes (or vendor permission names) the credential must carry. DECLARED in S3a and not\n * yet CHECKED: checking it needs the composed registry's view of the secrets contract, which is\n * #329's. Recorded as owed rather than half-enforced — a check that silently passes is worse\n * than no check.\n */\n readonly requiredScopes?: readonly string[];\n /**\n * Whether re-sending this request is safe. Absent = derived from the method: GET, HEAD, OPTIONS,\n * PUT and DELETE are idempotent, POST and PATCH are not.\n * spec-cite: RFC 9110 §9.2.2 (PUT, DELETE and the safe methods are idempotent) and §9.2.1\n * (GET, HEAD, OPTIONS, TRACE are safe).\n * Declare it TRUE on a POST the vendor documents as idempotent (an idempotency-key endpoint);\n * declaring it wrongly is how a retried timeout charges a customer twice.\n */\n readonly idempotent?: boolean;\n /** Narrows the provider's semantics for this one operation (a slow export, a tight endpoint). */\n readonly remoteCallSemantics?: Partial<ProviderRestCallSemantics>;\n /** Set when the vendor has deprecated it; the executor logs once per operation, never refuses. */\n readonly deprecated?: {\n readonly reason: string;\n readonly since?: string;\n readonly replacedByOperationId?: string;\n };\n}\n\n/** What one `operations(domain?)` call answers. */\nexport interface ProviderRestOperationCatalogue {\n /** The domains this load carries — the whole set when called with no argument. */\n readonly domains: readonly string[];\n /** Keyed by `operationId`. */\n readonly operations: Readonly<Record<string, ProviderRestOperation>>;\n}\n\n/**\n * The lazy catalogue loader — the seam #330's host loader consumes (interface note on #331).\n *\n * MUST NOT be called during composition, discovery or boot: it exists so a provider package can\n * `import()` its own operation module only when a run needs it, and calling it at boot puts every\n * provider's operations back into every process's boot graph, which is the thing on-demand\n * loading exists to remove. Async, idempotent, and memoized by the executor per\n * `(providerRef, domain)` — a loader may assume one call per pair and must stay correct on two.\n *\n * The values it returns carry live Zod schemas, so a catalogue is an IN-PROCESS value and is\n * never serializable into a runtime artifact or any JSON the CLI emits.\n */\nexport type ProviderRestOperationCatalogueLoader = (domain?: string) => Promise<ProviderRestOperationCatalogue>;\n\n/**\n * Provider-level call semantics: the defaults every operation of this provider runs under.\n *\n * Structurally the executable subset of the ETL's `HttpApiRemoteCallSemantics`, and deliberately\n * NOT that type: the ETL's lives in `@wildo-ai/saas-models/external-data` and carries\n * `maxIdSetSize`, an ETL query-translation bound that means nothing to a provider operation.\n * Importing it here would point the PROVIDER contract at the ETL read surface — backwards, since\n * the ETL references provider operations and not the reverse. Three fields is the price of\n * keeping that arrow pointing the right way.\n */\nexport interface ProviderRestCallSemantics {\n /** Per-attempt timeout. */\n readonly timeoutMs: number;\n readonly retry: {\n /** Total attempts including the first; 1 disables retry. */\n readonly maxAttempts: number;\n /** Linear backoff base — attempt N waits `backoffMs * (N - 1)`. */\n readonly backoffMs: number;\n };\n /** A local sliding-window ceiling; the call REFUSES when exhausted rather than queueing. */\n readonly maxRequestsPerMinute?: number;\n}\n\n\n/**\n * A provider whose credential is MINTED by an authorization-code exchange rather than pasted.\n *\n * Recorded because the source catalogues state it and nothing else does. 131 of the 699 transposed\n * vendors declare OAuth2, and their authorize URL, token URL and scopes exist nowhere in this\n * repository except the catalogue that was read — so extracting them and keeping them only in a\n * comment (which is what the transposer did until 2026-09-07) means the delegated-authorization lane\n * re-derives 131 vendors' endpoints by hand.\n *\n * ## What it does NOT change\n *\n * The wire placement. An OAuth2 access token rides in the same header as an API key —\n * `Authorization: Bearer …` — so `apiKey.headerName` and `apiKey.prefix` still describe the request,\n * and `apiKey.secretRef` still names the slot the credential is read from. What this block adds is\n * where that value COMES FROM: an exchange, per organization or per user, refreshable — rather than\n * an operator pasting a long-lived token into an environment variable.\n *\n * That distinction is the whole point. Without it a provider declares a static bearer key and, if an\n * operator happens to paste a long-lived token, WORKS — while advertising a credential model the\n * vendor does not offer, with no authorize step, no refresh and no per-tenant token. A wrong\n * configuration that works is worse than one that fails, because nothing surfaces it.\n *\n * The FLOW is not here and is not implied: connected accounts, the authorization round trip, refresh\n * and revocation are their own lane. This is the declaration that lane consumes.\n */\nexport interface ProviderRestOAuth2 {\n /** Where the user is sent to grant access. Carries the vendor's own default scopes when it states them. */\n readonly authorizeUrl: string;\n /** Where an authorization code (or a refresh token) is exchanged for an access token. */\n readonly tokenUrl: string;\n /**\n * Scopes the vendor's own catalogue entry asked for. Advisory rather than enforced: an application\n * may need fewer, and an operation's `requiredScopes` is the finer statement. Kept because it is\n * the only record of what the vendor expects for the operations transposed beside it.\n */\n readonly scopes?: readonly string[];\n /**\n * Env-var names resolving the APPLICATION's registration with the vendor. These are the two values\n * an operator genuinely does paste — they identify the integration, not the end user — and they\n * are separate from `apiKey.secretRef`, which names the minted access token.\n */\n readonly clientIdSecretRef?: string;\n readonly clientSecretSecretRef?: string;\n /**\n * Placeholders the endpoints above carry, which a CONNECTION must supply before either URL is a\n * URL at all — `{cloud}`, `{tenantId}`, `{region}`, `{domain}`.\n *\n * Measured over the transposed catalogue on 2026-09-08: of the 96 vendors that recovered both\n * endpoints, **21 carry at least one placeholder**, led by `{cloud}` (18), `{location}` (10) and\n * `{tenantId}` (6). Microsoft's authorize URL is\n * `https://{cloud}/{tenantId}/oauth2/v2.0/authorize`, and no amount of application configuration\n * supplies those: which Azure cloud and which directory are facts about the ACCOUNT BEING\n * CONNECTED, known only to the person connecting it.\n *\n * So this is not decoration on the endpoint strings — it is the difference between a vendor that\n * can be connected and one that cannot. Without it the flow would build\n * `https://{cloud}/…/authorize`, send somebody to a hostname containing a brace, and fail in the\n * browser rather than at the point where the missing input could have been asked for.\n *\n * DERIVED from the endpoint strings rather than authored, so a vendor whose URL gains a\n * placeholder declares one the next time the batch runs. Absent — not empty — when the endpoints\n * are plain, which is the common case and must stay distinguishable from \"nobody has looked\".\n *\n * Deliberately NOT a judgement about which connections a provider admits. That is a recorded\n * decision in the catalogue record and is never read from a vendor's API surface; this is a\n * mechanical fact about a string.\n */\n readonly connectionParameters?: readonly string[];\n}\n\n\n/**\n * Vendors whose credential is COMPUTED per request rather than sent as a fixed header.\n *\n * A static header covers bearer tokens and API keys, which is most of the world. It cannot express a\n * signature: AWS Signature Version 4 signs the method, the canonical path, the sorted query, a\n * subset of headers, a SHA-256 of the payload and a timestamp, with a key derived from the secret,\n * the date, the region and the service — so the header's VALUE differs for every request and none of\n * its inputs exist when a provider module is authored.\n *\n * Until this existed, such a vendor could not be expressed at all — not badly, not partially. There\n * was no `if` to write, because the field where the answer goes did not exist. 45 transposed actions\n * across `amazon-s3`, `amazon-ses`, `amazon-textract`, `amazon-secrets-manager`, `amazon-sqs`,\n * `amazon-bedrock`, `azure-blob-storage`, `azure-communication-services` and `azure-openai` are\n * blocked on it (#373).\n */\nexport enum ProviderRestSigningScheme {\n /**\n * AWS Signature Version 4 — the `Authorization: AWS4-HMAC-SHA256 …` scheme used by every current\n * AWS service API.\n * spec-cite: AWS General Reference, \"Signature Version 4 signing process\"\n * (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_sigv4-signing-process.html)\n */\n AWS_SIGV4 = 'AWS_SIGV4',\n /**\n * Azure Storage shared-key — `Authorization: SharedKey <account>:<signature>` over a canonicalized\n * request and resource.\n * spec-cite: Azure Storage REST, \"Authorize with Shared Key\"\n * (https://learn.microsoft.com/en-us/rest/api/storageservices/authorize-with-shared-key)\n */\n AZURE_SHARED_KEY = 'AZURE_SHARED_KEY',\n}\n\n/**\n * How a provider signs each request.\n *\n * Declared by the provider module and executed by the engine, with NO vendor branch in the executor:\n * the scheme is data, and the signer dispatches on it exhaustively. That is the same discipline the\n * rest of the provider contract keeps — a consumer branches on a contract field, never on a\n * provider ref.\n *\n * The credential is TWO values for both schemes (an identity and a secret), and optionally a third\n * for temporary credentials, which is why it cannot ride in the single `apiKey.secretRef` slot.\n */\nexport interface ProviderRestRequestSigning {\n readonly scheme: ProviderRestSigningScheme;\n /** Env-var naming the identity half — an AWS access-key id, an Azure storage account name. */\n readonly keyIdSecretRef: string;\n /** Env-var naming the secret half. */\n readonly secretKeySecretRef: string;\n /**\n * Env-var naming a session token, for temporary credentials (STS, a role assumption). Absent means\n * long-lived credentials; present-but-unset is treated as long-lived rather than as an error,\n * because the same provider serves both.\n */\n readonly sessionTokenSecretRef?: string;\n /**\n * AWS_SIGV4: the region and service that scope the derived key. Both are part of the SIGNATURE,\n * not merely of the URL, so a wrong value fails authentication rather than routing — which is why\n * they are declared rather than parsed out of the host.\n */\n readonly region?: string;\n readonly service?: string;\n /**\n * Env-var overriding {@link region} per deployment, for an application that runs in more than one.\n * The declared value is the default.\n */\n readonly regionEnvVarName?: string;\n}\n\n/**\n * The one function a generated typed client needs, as a TYPE.\n *\n * A generated provider package must not import the engine's runtime to be callable: that would put\n * the whole backend into the module graph of anything that touches a vendor, which is precisely the\n * weight #378 removed (models 20.8 MB against the backend barrel's 160.7 MB). So a client is a\n * FACTORY that takes the executor as an argument — the application wires its own, the package\n * declares only this signature, and nothing crosses at runtime.\n *\n * R3's ergonomics bought with a type rather than a dependency.\n *\n * ## The connection is a parameter, and OPTIONAL for a reason that is not convenience\n *\n * Omitted means the application's own account, acting as itself — the floor, and the only connection\n * that needs no store and no authorization. That default is what keeps the ordinary single-account\n * call as short as it should be.\n *\n * It could not be anything BUT a parameter. One execution may legitimately spend several tenants'\n * accounts — a user action pushing a message to every organization that user belongs to — so a client\n * that read the owner from ambient state could not vary it per call, and the fan-out would be\n * inexpressible through the generated surface even though the engine beneath it supports one.\n */\nexport type ProviderOperationExecute = (\n providerRef: string,\n operationId: string,\n input: Readonly<Record<string, unknown>>,\n connection?: ExternalProvider_ConnectionTarget,\n) => Promise<unknown>;\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"sms.external-connectors-models.schemas.d.ts","sourceRoot":"","sources":["../../../../src/protocols/sms.external-connectors-models.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,oDAAoD,EACpD,sCAAsC,EACtC,8CAA8C,EAE/C,MAAM,oDAAoD,CAAC;AAmB5D;;GAEG;AACH,oBAAY,sBAAsB;IAChC,YAAY,iBAAiB;IAC7B,wBAAwB,6BAA6B;IACrD,iBAAiB,sBAAsB;CACxC;AAED;;GAEG;AACH,oBAAY,wBAAwB;IAClC,QAAQ,aAAa;IACrB,kBAAkB,0BAA0B;CAC7C;AAMD,MAAM,MAAM,mBAAmB,GAAG,8CAA8C,GAAG;IACjF,mCAAmC;IACnC,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,4BAA4B;IAC5B,OAAO,EAAE,MAAM,CAAC;IAEhB,kBAAkB;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB,oCAAoC;IACpC,YAAY,EAAE,sBAAsB,EAAE,CAAC;IAEvC,sCAAsC;IACtC,MAAM,EAAE;QACN,gBAAgB,CAAC,EAAE,MAAM,CAAC;QAC1B,SAAS,CAAC,EAAE;YACV,QAAQ,EAAE,MAAM,CAAC;YACjB,MAAM,EAAE,QAAQ,GAAG,QAAQ,GAAG,MAAM,GAAG,KAAK,CAAC;SAC9C,CAAC;KACH,CAAC;CACH,CAAC;AAMF,MAAM,MAAM,yBAAyB,GAAG,oDAAoD,GAAG;IAC7F,gDAAgD;IAChD,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAE3B,kCAAkC;IAClC,aAAa,CAAC,EAAE;QACd,GAAG,EAAE,MAAM,CAAC;QACZ,SAAS,CAAC,EAAE,MAAM,CAAC;KACpB,CAAC;CACH,CAAC;AAMF,eAAO,MAAM,wBAAwB;;;;;;;;iBASnC,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC"}
1
+ {"version":3,"file":"sms.external-connectors-models.schemas.d.ts","sourceRoot":"","sources":["../../../src/protocols/sms.external-connectors-models.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,oDAAoD,EACpD,sCAAsC,EACtC,8CAA8C,EAE/C,MAAM,oDAAoD,CAAC;AAmB5D;;GAEG;AACH,oBAAY,sBAAsB;IAChC,YAAY,iBAAiB;IAC7B,wBAAwB,6BAA6B;IACrD,iBAAiB,sBAAsB;CACxC;AAED;;GAEG;AACH,oBAAY,wBAAwB;IAClC,QAAQ,aAAa;IACrB,kBAAkB,0BAA0B;CAC7C;AAMD,MAAM,MAAM,mBAAmB,GAAG,8CAA8C,GAAG;IACjF,mCAAmC;IACnC,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,4BAA4B;IAC5B,OAAO,EAAE,MAAM,CAAC;IAEhB,kBAAkB;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB,oCAAoC;IACpC,YAAY,EAAE,sBAAsB,EAAE,CAAC;IAEvC,sCAAsC;IACtC,MAAM,EAAE;QACN,gBAAgB,CAAC,EAAE,MAAM,CAAC;QAC1B,SAAS,CAAC,EAAE;YACV,QAAQ,EAAE,MAAM,CAAC;YACjB,MAAM,EAAE,QAAQ,GAAG,QAAQ,GAAG,MAAM,GAAG,KAAK,CAAC;SAC9C,CAAC;KACH,CAAC;CACH,CAAC;AAMF,MAAM,MAAM,yBAAyB,GAAG,oDAAoD,GAAG;IAC7F,gDAAgD;IAChD,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAE3B,kCAAkC;IAClC,aAAa,CAAC,EAAE;QACd,GAAG,EAAE,MAAM,CAAC;QACZ,SAAS,CAAC,EAAE,MAAM,CAAC;KACpB,CAAC;CACH,CAAC;AAMF,eAAO,MAAM,wBAAwB;;;;;;;;iBASnC,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC"}
@@ -1,4 +1,45 @@
1
1
  import { z } from "zod";
2
+ /**
3
+ * How a `kind: SMS` provider's credential bundle is SHAPED, and therefore how the engine parses
4
+ * the resolved secret and authenticates the send request.
5
+ *
6
+ * The engine owns this — not the provider — because parsing a bundle means touching the secret,
7
+ * and a provider module's request builder is a pure function that must never see one. So the
8
+ * contract DECLARES which shape it uses and the engine implements it, exactly as the email arm
9
+ * declares `apiKey.scheme` and lets the engine compose the header.
10
+ *
11
+ * ## Why a single member, and why that is the point
12
+ *
13
+ * One shape has a declarer today. A member is added here only together with its parse-and-
14
+ * authenticate branch in the SMS transport, and that branch is an exhaustive `switch` with a
15
+ * `never` check — so a member added without an implementation fails COMPILATION rather than
16
+ * shipping a provider the engine cannot authenticate. Equally, a second SMS provider whose
17
+ * credential is shaped differently cannot name a member that does not exist: it is refused at
18
+ * declaration time, which is the strongest available form of "never silently handed Twilio's".
19
+ *
20
+ * An `'api-key'` member stood here until 2026-09-09 and was pure declaration: no production
21
+ * provider named it, no consumer read it, and no code implemented it — its only use anywhere was
22
+ * one test fixture about an unrelated projection. It was removed rather than implemented, because
23
+ * inventing a header shape for a provider that does not exist is inventing a contract nobody can
24
+ * check.
25
+ */
26
+ export declare enum SmsProviderCredentialShape {
27
+ /**
28
+ * A two-part bundle: a non-secret account IDENTIFIER and the secret that authenticates it.
29
+ * The engine authenticates with HTTP Basic — `base64(accountId:secret)` — and makes the
30
+ * account identifier available for substitution into the contract's `sendEndpointPath`.
31
+ *
32
+ * Basic credentials are carried in the `Authorization` header by definition, so the header name
33
+ * is not a per-provider choice and is deliberately not declared.
34
+ * spec-cite: RFC 7617 §2 (The 'Basic' HTTP Authentication Scheme) — the credentials are the
35
+ * base64 of `user-id ":" password`, transmitted in the `Authorization` header.
36
+ *
37
+ * Twilio's `AccountSid` + `AuthToken` is this shape. The name is deliberately NOT Twilio's:
38
+ * the value was `'account-sid-auth-token'` until 2026-09-09, which put one vendor's vocabulary
39
+ * on a contract every SMS provider has to speak.
40
+ */
41
+ ACCOUNT_ID_AND_SECRET = "account-id-and-secret"
42
+ }
2
43
  export declare const StandardSMS_SendRequestSchema: z.ZodObject<{
3
44
  to: z.ZodString;
4
45
  from: z.ZodOptional<z.ZodString>;
@@ -6,26 +47,45 @@ export declare const StandardSMS_SendRequestSchema: z.ZodObject<{
6
47
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
7
48
  }, z.core.$strip>;
8
49
  export type StandardSMS_SendRequest = z.infer<typeof StandardSMS_SendRequestSchema>;
50
+ /**
51
+ * The delivery states this framework recognises, and the vocabulary a provider's
52
+ * `parseSendResponse` projects its vendor's own states onto.
53
+ *
54
+ * Named rather than left inline because a vendor's vocabulary is LARGER than this one and the
55
+ * mapping between them is the interesting part. Twilio alone reports `accepted`, `scheduled`,
56
+ * `sending`, `undelivered` and `canceled`, none of which is a member here — so the per-member
57
+ * question "which vendor states land on this one, and why" needs somewhere to be answered, and an
58
+ * inline `z.enum` has nowhere to put it.
59
+ *
60
+ * The four members are unchanged; this only gives them a home. `.optional()` on the field is what
61
+ * says a provider may report NO state, which is the honest answer for a vendor state this
62
+ * vocabulary does not cover — better than forcing a wrong one.
63
+ */
64
+ export declare enum SmsDeliveryStatus {
65
+ /** Accepted by the provider, not yet handed to a carrier. */
66
+ QUEUED = "queued",
67
+ /** Handed to a carrier; delivery not yet confirmed. */
68
+ SENT = "sent",
69
+ /** The carrier confirmed handset delivery. */
70
+ DELIVERED = "delivered",
71
+ /** Terminal failure, whether the provider rejected it or the carrier could not deliver it. */
72
+ FAILED = "failed"
73
+ }
9
74
  export declare const StandardSMS_SendResponseSchema: z.ZodObject<{
10
75
  success: z.ZodBoolean;
11
76
  messageId: z.ZodString;
12
- status: z.ZodOptional<z.ZodEnum<{
13
- queued: "queued";
14
- sent: "sent";
15
- delivered: "delivered";
16
- failed: "failed";
17
- }>>;
77
+ status: z.ZodOptional<z.ZodEnum<typeof SmsDeliveryStatus>>;
18
78
  }, z.core.$strip>;
19
79
  export type StandardSMS_SendResponse = z.infer<typeof StandardSMS_SendResponseSchema>;
20
80
  export declare const StandardSMS_ErrorSchema: z.ZodObject<{
21
81
  code: z.ZodEnum<{
22
82
  VALIDATION_ERROR: "VALIDATION_ERROR";
23
83
  PROVIDER_ERROR: "PROVIDER_ERROR";
84
+ INVALID_PHONE_NUMBER: "INVALID_PHONE_NUMBER";
24
85
  RATE_LIMIT_EXCEEDED: "RATE_LIMIT_EXCEEDED";
25
86
  AUTHENTICATION_FAILED: "AUTHENTICATION_FAILED";
26
87
  QUOTA_EXCEEDED: "QUOTA_EXCEEDED";
27
88
  UNKNOWN_ERROR: "UNKNOWN_ERROR";
28
- INVALID_PHONE_NUMBER: "INVALID_PHONE_NUMBER";
29
89
  }>;
30
90
  message: z.ZodString;
31
91
  provider: z.ZodOptional<z.ZodString>;
@@ -1 +1 @@
1
- {"version":3,"file":"sms.standard-interface.schemas.d.ts","sourceRoot":"","sources":["../../../../src/protocols/sms.standard-interface.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAmBxB,eAAO,MAAM,6BAA6B;;;;;iBAYxC,CAAC;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC;AAMpF,eAAO,MAAM,8BAA8B;;;;;;;;;iBAMzC,CAAC;AACH,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,8BAA8B,CAAC,CAAC;AAMtF,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;iBAalC,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC"}
1
+ {"version":3,"file":"sms.standard-interface.schemas.d.ts","sourceRoot":"","sources":["../../../src/protocols/sms.standard-interface.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAmBxB;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,oBAAY,0BAA0B;IACpC;;;;;;;;;;;;;OAaG;IACH,qBAAqB,0BAA0B;CAChD;AAMD,eAAO,MAAM,6BAA6B;;;;;iBAYxC,CAAC;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC;AAMpF;;;;;;;;;;;;;GAaG;AACH,oBAAY,iBAAiB;IAC3B,6DAA6D;IAC7D,MAAM,WAAW;IACjB,uDAAuD;IACvD,IAAI,SAAS;IACb,8CAA8C;IAC9C,SAAS,cAAc;IACvB,8FAA8F;IAC9F,MAAM,WAAW;CAClB;AAED,eAAO,MAAM,8BAA8B;;;;iBAMzC,CAAC;AACH,MAAM,MAAM,wBAAwB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,8BAA8B,CAAC,CAAC;AAMtF,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;iBAalC,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC"}
@@ -12,6 +12,51 @@ import { z } from "zod";
12
12
  // 3. Extensible - new fields can be added without breaking existing code
13
13
  // ===============================================================
14
14
  // ===============================================================
15
+ // SMS Provider Credential Shape
16
+ // ===============================================================
17
+ /**
18
+ * How a `kind: SMS` provider's credential bundle is SHAPED, and therefore how the engine parses
19
+ * the resolved secret and authenticates the send request.
20
+ *
21
+ * The engine owns this — not the provider — because parsing a bundle means touching the secret,
22
+ * and a provider module's request builder is a pure function that must never see one. So the
23
+ * contract DECLARES which shape it uses and the engine implements it, exactly as the email arm
24
+ * declares `apiKey.scheme` and lets the engine compose the header.
25
+ *
26
+ * ## Why a single member, and why that is the point
27
+ *
28
+ * One shape has a declarer today. A member is added here only together with its parse-and-
29
+ * authenticate branch in the SMS transport, and that branch is an exhaustive `switch` with a
30
+ * `never` check — so a member added without an implementation fails COMPILATION rather than
31
+ * shipping a provider the engine cannot authenticate. Equally, a second SMS provider whose
32
+ * credential is shaped differently cannot name a member that does not exist: it is refused at
33
+ * declaration time, which is the strongest available form of "never silently handed Twilio's".
34
+ *
35
+ * An `'api-key'` member stood here until 2026-09-09 and was pure declaration: no production
36
+ * provider named it, no consumer read it, and no code implemented it — its only use anywhere was
37
+ * one test fixture about an unrelated projection. It was removed rather than implemented, because
38
+ * inventing a header shape for a provider that does not exist is inventing a contract nobody can
39
+ * check.
40
+ */
41
+ export var SmsProviderCredentialShape;
42
+ (function (SmsProviderCredentialShape) {
43
+ /**
44
+ * A two-part bundle: a non-secret account IDENTIFIER and the secret that authenticates it.
45
+ * The engine authenticates with HTTP Basic — `base64(accountId:secret)` — and makes the
46
+ * account identifier available for substitution into the contract's `sendEndpointPath`.
47
+ *
48
+ * Basic credentials are carried in the `Authorization` header by definition, so the header name
49
+ * is not a per-provider choice and is deliberately not declared.
50
+ * spec-cite: RFC 7617 §2 (The 'Basic' HTTP Authentication Scheme) — the credentials are the
51
+ * base64 of `user-id ":" password`, transmitted in the `Authorization` header.
52
+ *
53
+ * Twilio's `AccountSid` + `AuthToken` is this shape. The name is deliberately NOT Twilio's:
54
+ * the value was `'account-sid-auth-token'` until 2026-09-09, which put one vendor's vocabulary
55
+ * on a contract every SMS provider has to speak.
56
+ */
57
+ SmsProviderCredentialShape["ACCOUNT_ID_AND_SECRET"] = "account-id-and-secret";
58
+ })(SmsProviderCredentialShape || (SmsProviderCredentialShape = {}));
59
+ // ===============================================================
15
60
  // Standard SMS Send Request
16
61
  // ===============================================================
17
62
  export const StandardSMS_SendRequestSchema = z.object({
@@ -27,12 +72,37 @@ export const StandardSMS_SendRequestSchema = z.object({
27
72
  // ===============================================================
28
73
  // Standard SMS Send Response
29
74
  // ===============================================================
75
+ /**
76
+ * The delivery states this framework recognises, and the vocabulary a provider's
77
+ * `parseSendResponse` projects its vendor's own states onto.
78
+ *
79
+ * Named rather than left inline because a vendor's vocabulary is LARGER than this one and the
80
+ * mapping between them is the interesting part. Twilio alone reports `accepted`, `scheduled`,
81
+ * `sending`, `undelivered` and `canceled`, none of which is a member here — so the per-member
82
+ * question "which vendor states land on this one, and why" needs somewhere to be answered, and an
83
+ * inline `z.enum` has nowhere to put it.
84
+ *
85
+ * The four members are unchanged; this only gives them a home. `.optional()` on the field is what
86
+ * says a provider may report NO state, which is the honest answer for a vendor state this
87
+ * vocabulary does not cover — better than forcing a wrong one.
88
+ */
89
+ export var SmsDeliveryStatus;
90
+ (function (SmsDeliveryStatus) {
91
+ /** Accepted by the provider, not yet handed to a carrier. */
92
+ SmsDeliveryStatus["QUEUED"] = "queued";
93
+ /** Handed to a carrier; delivery not yet confirmed. */
94
+ SmsDeliveryStatus["SENT"] = "sent";
95
+ /** The carrier confirmed handset delivery. */
96
+ SmsDeliveryStatus["DELIVERED"] = "delivered";
97
+ /** Terminal failure, whether the provider rejected it or the carrier could not deliver it. */
98
+ SmsDeliveryStatus["FAILED"] = "failed";
99
+ })(SmsDeliveryStatus || (SmsDeliveryStatus = {}));
30
100
  export const StandardSMS_SendResponseSchema = z.object({
31
101
  success: z.boolean(),
32
102
  /** Provider-assigned message ID */
33
103
  messageId: z.string(),
34
104
  /** Delivery status if available immediately */
35
- status: z.enum(["queued", "sent", "delivered", "failed"]).optional(),
105
+ status: z.enum(SmsDeliveryStatus).optional(),
36
106
  });
37
107
  // ===============================================================
38
108
  // Standard SMS Error
@@ -1 +1 @@
1
- {"version":3,"file":"sms.standard-interface.schemas.js","sourceRoot":"","sources":["../../../../src/protocols/sms.standard-interface.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,kEAAkE;AAClE,yBAAyB;AACzB,WAAW;AACX,qEAAqE;AACrE,sEAAsE;AACtE,+BAA+B;AAC/B,EAAE;AACF,qBAAqB;AACrB,qDAAqD;AACrD,6EAA6E;AAC7E,yEAAyE;AACzE,kEAAkE;AAElE,kEAAkE;AAClE,4BAA4B;AAC5B,kEAAkE;AAElE,MAAM,CAAC,MAAM,6BAA6B,GAAG,CAAC,CAAC,MAAM,CAAC;IACpD,6CAA6C;IAC7C,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,oBAAoB,EAAE,EAAE,KAAK,EAAE,8CAA8C,EAAE,CAAC;IAErG,qFAAqF;IACrF,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAE3B,uBAAuB;IACvB,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC;IAEjC,wCAAwC;IACxC,QAAQ,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;CACtD,CAAC,CAAC;AAGH,kEAAkE;AAClE,6BAA6B;AAC7B,kEAAkE;AAElE,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC,CAAC,MAAM,CAAC;IACrD,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE;IACpB,mCAAmC;IACnC,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE;IACrB,+CAA+C;IAC/C,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,MAAM,EAAE,WAAW,EAAE,QAAQ,CAAC,CAAC,CAAC,QAAQ,EAAE;CACrE,CAAC,CAAC;AAGH,kEAAkE;AAClE,qBAAqB;AACrB,kEAAkE;AAElE,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC9C,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC;QACX,kBAAkB;QAClB,gBAAgB;QAChB,sBAAsB;QACtB,qBAAqB;QACrB,uBAAuB;QACvB,gBAAgB;QAChB,eAAe;KAChB,CAAC;IACF,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;IACnB,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC/B,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CAChC,CAAC,CAAC","sourcesContent":["import { z } from \"zod\";\n\n// ===============================================================\n// Standard SMS Interface\n// --------\n// This is the canonical interface that Wildo uses internally to send\n// SMS messages. The ETL layer transforms these standard requests into\n// provider-specific API calls.\n//\n// Design Principles:\n// 1. Provider-agnostic - works with any SMS provider\n// 2. Minimal surface area - focused on transactional SMS (OTP, verification)\n// 3. Extensible - new fields can be added without breaking existing code\n// ===============================================================\n\n// ===============================================================\n// Standard SMS Send Request\n// ===============================================================\n\nexport const StandardSMS_SendRequestSchema = z.object({\n /** Recipient phone number in E.164 format */\n to: z.string().regex(/^\\+?[1-9]\\d{1,14}$/, { error: \"Invalid phone number (E.164 format required)\" }),\n\n /** Sender phone number or short code (optional, uses provider default if not set) */\n from: z.string().optional(),\n\n /** SMS message body */\n body: z.string().min(1).max(1600),\n\n /** Metadata for correlation/tracking */\n metadata: z.record(z.string(), z.string()).optional(),\n});\nexport type StandardSMS_SendRequest = z.infer<typeof StandardSMS_SendRequestSchema>;\n\n// ===============================================================\n// Standard SMS Send Response\n// ===============================================================\n\nexport const StandardSMS_SendResponseSchema = z.object({\n success: z.boolean(),\n /** Provider-assigned message ID */\n messageId: z.string(),\n /** Delivery status if available immediately */\n status: z.enum([\"queued\", \"sent\", \"delivered\", \"failed\"]).optional(),\n});\nexport type StandardSMS_SendResponse = z.infer<typeof StandardSMS_SendResponseSchema>;\n\n// ===============================================================\n// Standard SMS Error\n// ===============================================================\n\nexport const StandardSMS_ErrorSchema = z.object({\n code: z.enum([\n \"VALIDATION_ERROR\",\n \"PROVIDER_ERROR\",\n \"INVALID_PHONE_NUMBER\",\n \"RATE_LIMIT_EXCEEDED\",\n \"AUTHENTICATION_FAILED\",\n \"QUOTA_EXCEEDED\",\n \"UNKNOWN_ERROR\",\n ]),\n message: z.string(),\n provider: z.string().optional(),\n details: z.unknown().optional(),\n});\nexport type StandardSMS_Error = z.infer<typeof StandardSMS_ErrorSchema>;\n"]}
1
+ {"version":3,"file":"sms.standard-interface.schemas.js","sourceRoot":"","sources":["../../../src/protocols/sms.standard-interface.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,kEAAkE;AAClE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B,CAAC,EATW,iBAAiB,KAAjB,iBAAiB,QAS5B;AAED,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC,CAAC,MAAM,CAAC;IACrD,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE;IACpB,mCAAmC;IACnC,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE;IACrB,+CAA+C;IAC/C,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC,QAAQ,EAAE;CAC7C,CAAC,CAAC;AAGH,kEAAkE;AAClE,qBAAqB;AACrB,kEAAkE;AAElE,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC9C,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC;QACX,kBAAkB;QAClB,gBAAgB;QAChB,sBAAsB;QACtB,qBAAqB;QACrB,uBAAuB;QACvB,gBAAgB;QAChB,eAAe;KAChB,CAAC;IACF,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;IACnB,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC/B,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CAChC,CAAC,CAAC","sourcesContent":["import { z } from \"zod\";\n\n// ===============================================================\n// Standard SMS Interface\n// --------\n// This is the canonical interface that Wildo uses internally to send\n// SMS messages. The ETL layer transforms these standard requests into\n// provider-specific API calls.\n//\n// Design Principles:\n// 1. Provider-agnostic - works with any SMS provider\n// 2. Minimal surface area - focused on transactional SMS (OTP, verification)\n// 3. Extensible - new fields can be added without breaking existing code\n// ===============================================================\n\n// ===============================================================\n// SMS Provider Credential Shape\n// ===============================================================\n\n/**\n * How a `kind: SMS` provider's credential bundle is SHAPED, and therefore how the engine parses\n * the resolved secret and authenticates the send request.\n *\n * The engine owns this — not the provider — because parsing a bundle means touching the secret,\n * and a provider module's request builder is a pure function that must never see one. So the\n * contract DECLARES which shape it uses and the engine implements it, exactly as the email arm\n * declares `apiKey.scheme` and lets the engine compose the header.\n *\n * ## Why a single member, and why that is the point\n *\n * One shape has a declarer today. A member is added here only together with its parse-and-\n * authenticate branch in the SMS transport, and that branch is an exhaustive `switch` with a\n * `never` check — so a member added without an implementation fails COMPILATION rather than\n * shipping a provider the engine cannot authenticate. Equally, a second SMS provider whose\n * credential is shaped differently cannot name a member that does not exist: it is refused at\n * declaration time, which is the strongest available form of \"never silently handed Twilio's\".\n *\n * An `'api-key'` member stood here until 2026-09-09 and was pure declaration: no production\n * provider named it, no consumer read it, and no code implemented it — its only use anywhere was\n * one test fixture about an unrelated projection. It was removed rather than implemented, because\n * inventing a header shape for a provider that does not exist is inventing a contract nobody can\n * check.\n */\nexport enum SmsProviderCredentialShape {\n /**\n * A two-part bundle: a non-secret account IDENTIFIER and the secret that authenticates it.\n * The engine authenticates with HTTP Basic — `base64(accountId:secret)` — and makes the\n * account identifier available for substitution into the contract's `sendEndpointPath`.\n *\n * Basic credentials are carried in the `Authorization` header by definition, so the header name\n * is not a per-provider choice and is deliberately not declared.\n * spec-cite: RFC 7617 §2 (The 'Basic' HTTP Authentication Scheme) — the credentials are the\n * base64 of `user-id \":\" password`, transmitted in the `Authorization` header.\n *\n * Twilio's `AccountSid` + `AuthToken` is this shape. The name is deliberately NOT Twilio's:\n * the value was `'account-sid-auth-token'` until 2026-09-09, which put one vendor's vocabulary\n * on a contract every SMS provider has to speak.\n */\n ACCOUNT_ID_AND_SECRET = \"account-id-and-secret\",\n}\n\n// ===============================================================\n// Standard SMS Send Request\n// ===============================================================\n\nexport const StandardSMS_SendRequestSchema = z.object({\n /** Recipient phone number in E.164 format */\n to: z.string().regex(/^\\+?[1-9]\\d{1,14}$/, { error: \"Invalid phone number (E.164 format required)\" }),\n\n /** Sender phone number or short code (optional, uses provider default if not set) */\n from: z.string().optional(),\n\n /** SMS message body */\n body: z.string().min(1).max(1600),\n\n /** Metadata for correlation/tracking */\n metadata: z.record(z.string(), z.string()).optional(),\n});\nexport type StandardSMS_SendRequest = z.infer<typeof StandardSMS_SendRequestSchema>;\n\n// ===============================================================\n// Standard SMS Send Response\n// ===============================================================\n\n/**\n * The delivery states this framework recognises, and the vocabulary a provider's\n * `parseSendResponse` projects its vendor's own states onto.\n *\n * Named rather than left inline because a vendor's vocabulary is LARGER than this one and the\n * mapping between them is the interesting part. Twilio alone reports `accepted`, `scheduled`,\n * `sending`, `undelivered` and `canceled`, none of which is a member here — so the per-member\n * question \"which vendor states land on this one, and why\" needs somewhere to be answered, and an\n * inline `z.enum` has nowhere to put it.\n *\n * The four members are unchanged; this only gives them a home. `.optional()` on the field is what\n * says a provider may report NO state, which is the honest answer for a vendor state this\n * vocabulary does not cover — better than forcing a wrong one.\n */\nexport enum SmsDeliveryStatus {\n /** Accepted by the provider, not yet handed to a carrier. */\n QUEUED = \"queued\",\n /** Handed to a carrier; delivery not yet confirmed. */\n SENT = \"sent\",\n /** The carrier confirmed handset delivery. */\n DELIVERED = \"delivered\",\n /** Terminal failure, whether the provider rejected it or the carrier could not deliver it. */\n FAILED = \"failed\",\n}\n\nexport const StandardSMS_SendResponseSchema = z.object({\n success: z.boolean(),\n /** Provider-assigned message ID */\n messageId: z.string(),\n /** Delivery status if available immediately */\n status: z.enum(SmsDeliveryStatus).optional(),\n});\nexport type StandardSMS_SendResponse = z.infer<typeof StandardSMS_SendResponseSchema>;\n\n// ===============================================================\n// Standard SMS Error\n// ===============================================================\n\nexport const StandardSMS_ErrorSchema = z.object({\n code: z.enum([\n \"VALIDATION_ERROR\",\n \"PROVIDER_ERROR\",\n \"INVALID_PHONE_NUMBER\",\n \"RATE_LIMIT_EXCEEDED\",\n \"AUTHENTICATION_FAILED\",\n \"QUOTA_EXCEEDED\",\n \"UNKNOWN_ERROR\",\n ]),\n message: z.string(),\n provider: z.string().optional(),\n details: z.unknown().optional(),\n});\nexport type StandardSMS_Error = z.infer<typeof StandardSMS_ErrorSchema>;\n"]}