@workos/oagen 0.30.2 → 0.31.0

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 (46) hide show
  1. package/README.md +4 -12
  2. package/dist/cli/index.d.mts +1 -1
  3. package/dist/cli/index.mjs +2885 -651
  4. package/dist/cli/index.mjs.map +1 -1
  5. package/dist/compat/index.d.mts +85 -36
  6. package/dist/compat/index.d.mts.map +1 -1
  7. package/dist/compat/index.mjs +33 -23
  8. package/dist/compat/index.mjs.map +1 -1
  9. package/dist/{diff-BO5FieX5.mjs → diff-CAsypxXV.mjs} +107 -89
  10. package/dist/{diff-BO5FieX5.mjs.map → diff-CAsypxXV.mjs.map} +1 -1
  11. package/dist/differ-B0DSuKUZ.d.mts +72 -0
  12. package/dist/differ-B0DSuKUZ.d.mts.map +1 -0
  13. package/dist/index.d.mts +129 -61
  14. package/dist/index.d.mts.map +1 -1
  15. package/dist/index.mjs +2877 -546
  16. package/dist/index.mjs.map +1 -1
  17. package/dist/{overlay-DWAHPofk.mjs → overlay-Dj3WWlNP.mjs} +44 -38
  18. package/dist/overlay-Dj3WWlNP.mjs.map +1 -0
  19. package/dist/scripts/smoke/baseline.d.mts +1 -1
  20. package/dist/scripts/smoke/baseline.mjs +2740 -527
  21. package/dist/scripts/smoke/baseline.mjs.map +1 -1
  22. package/dist/scripts/smoke/sdk-test.d.mts +1 -1
  23. package/dist/scripts/smoke/sdk-test.mjs +4 -2
  24. package/dist/scripts/smoke/sdk-test.mjs.map +1 -1
  25. package/dist/smoke.d.mts +251 -36
  26. package/dist/smoke.d.mts.map +1 -1
  27. package/dist/smoke.mjs +2740 -527
  28. package/dist/smoke.mjs.map +1 -1
  29. package/dist/{tree-sitter-CDKm3n64.mjs → tree-sitter-C7Hk-NDu.mjs} +35 -7
  30. package/dist/tree-sitter-C7Hk-NDu.mjs.map +1 -0
  31. package/dist/{types-BcbGLNkh.d.mts → types-I7W7CNl1.d.mts} +219 -9
  32. package/dist/types-I7W7CNl1.d.mts.map +1 -0
  33. package/dist/verify/index.d.mts +7 -8
  34. package/dist/verify/index.d.mts.map +1 -1
  35. package/dist/verify/index.mjs +24 -14
  36. package/dist/verify/index.mjs.map +1 -1
  37. package/docs/architecture/emitter-contract.md +1 -0
  38. package/docs/architecture/ir-types.md +170 -17
  39. package/docs/cli.md +13 -13
  40. package/package.json +3 -3
  41. package/skills/check-emitter-parity/SKILL.md +15 -1
  42. package/dist/differ-nZSxhCfC.d.mts +0 -123
  43. package/dist/differ-nZSxhCfC.d.mts.map +0 -1
  44. package/dist/overlay-DWAHPofk.mjs.map +0 -1
  45. package/dist/tree-sitter-CDKm3n64.mjs.map +0 -1
  46. package/dist/types-BcbGLNkh.d.mts.map +0 -1
@@ -1 +1 @@
1
- export { };
1
+ export {}
@@ -15,7 +15,8 @@ import { execFileSync } from "node:child_process";
15
15
  * The --lang flag is required and selects which SDK runner to use
16
16
  * (e.g. "node" → scripts/smoke/sdk-node.ts).
17
17
  */
18
- const __dirname = dirname(fileURLToPath(import.meta.url));
18
+ const __filename = fileURLToPath(import.meta.url);
19
+ const __dirname = dirname(__filename);
19
20
  const args = process.argv.slice(2);
20
21
  const langIdx = args.indexOf("--lang");
21
22
  const forwardedArgs = [...args];
@@ -52,7 +53,8 @@ const diffArgs = [
52
53
  const sdkPathIdx = forwardedArgs.indexOf("--sdk-path");
53
54
  const sdkPathValue = sdkPathIdx !== -1 && forwardedArgs[sdkPathIdx + 1] ? forwardedArgs[sdkPathIdx + 1] : void 0;
54
55
  if (sdkPathValue) {
55
- if (existsSync(resolve(sdkPathValue, "tsconfig.json"))) {
56
+ const tsconfigPath = resolve(sdkPathValue, "tsconfig.json");
57
+ if (existsSync(tsconfigPath)) {
56
58
  console.log(`\n${"=".repeat(60)}`);
57
59
  console.log(`Type-checking SDK at ${sdkPathValue}`);
58
60
  console.log("=".repeat(60));
@@ -1 +1 @@
1
- {"version":3,"file":"sdk-test.mjs","names":[],"sources":["../../../scripts/smoke/sdk-test.ts"],"sourcesContent":["/**\n * Runs an SDK smoke test + diff against an existing raw baseline.\n *\n * Usage:\n * npm run smoke -- --lang node --sdk-path path/to/acme-node\n * npm run smoke -- --lang ruby --sdk-path path/to/acme-ruby\n * npm run smoke -- --lang node --sdk-path path/to/acme-node --raw-results custom-baseline.json\n *\n * Requires OPENAPI_SPEC_PATH env var (or --spec <path>) pointing to the OpenAPI spec.\n * The --lang flag is required and selects which SDK runner to use\n * (e.g. \"node\" → scripts/smoke/sdk-node.ts).\n */\n\nimport { existsSync, writeFileSync } from 'node:fs';\nimport { execFileSync } from 'node:child_process';\nimport { resolve, dirname } from 'node:path';\nimport { fileURLToPath } from 'node:url';\n\nconst __filename = fileURLToPath(import.meta.url);\nconst __dirname = dirname(__filename);\n\nconst args = process.argv.slice(2);\n\n// Extract --lang <name> (required)\nconst langIdx = args.indexOf('--lang');\nconst forwardedArgs = [...args];\n\nif (langIdx === -1 || !args[langIdx + 1]) {\n console.error('--lang is required (e.g. --lang node, --lang ruby)');\n process.exit(1);\n}\n\nconst lang = args[langIdx + 1];\nforwardedArgs.splice(langIdx, 2);\n\n// Extract --raw-results <path>\nconst rawResultsIdx = forwardedArgs.indexOf('--raw-results');\nlet rawResultsPath = 'smoke-results-raw.json';\n\nif (rawResultsIdx !== -1 && forwardedArgs[rawResultsIdx + 1]) {\n rawResultsPath = forwardedArgs[rawResultsIdx + 1];\n forwardedArgs.splice(rawResultsIdx, 2);\n}\n\n// Resolve the SDK runner script relative to this file's directory\nconst sdkScript = resolve(__dirname, `sdk-${lang}.ts`);\nif (!existsSync(sdkScript)) {\n console.error(`No smoke runner found for language \"${lang}\" (expected ${sdkScript})`);\n console.error(`Available runners:`);\n const { readdirSync } = await import('node:fs');\n for (const f of readdirSync(__dirname)) {\n const match = f.match(/^sdk-(.+)\\.ts$/);\n if (match && match[1] !== 'test') {\n console.error(` --lang ${match[1]}`);\n }\n }\n process.exit(1);\n}\n\nconst sdkResultsPath = `smoke-results-sdk-${lang}.json`;\n\nconst diffArgs = ['--raw', rawResultsPath, '--sdk', sdkResultsPath];\n\n// Pre-flight: tsc compile check on SDK if tsconfig.json exists\nconst sdkPathIdx = forwardedArgs.indexOf('--sdk-path');\nconst sdkPathValue = sdkPathIdx !== -1 && forwardedArgs[sdkPathIdx + 1] ? forwardedArgs[sdkPathIdx + 1] : undefined;\n\nif (sdkPathValue) {\n const tsconfigPath = resolve(sdkPathValue, 'tsconfig.json');\n if (existsSync(tsconfigPath)) {\n console.log(`\\n${'='.repeat(60)}`);\n console.log(`Type-checking SDK at ${sdkPathValue}`);\n console.log('='.repeat(60));\n\n try {\n execFileSync('npx', ['tsc', '--noEmit', '--project', sdkPathValue], {\n stdio: 'pipe',\n env: process.env,\n });\n console.log(' Type check passed');\n } catch (err) {\n const output = (err as { stdout?: Buffer; stderr?: Buffer }).stdout?.toString() ?? '';\n const findings = parseTscOutput(output);\n writeFileSync('smoke-compile-errors.json', JSON.stringify(findings, null, 2));\n console.error(` Type check failed (${findings.length} errors). See smoke-compile-errors.json`);\n process.exit(2);\n }\n }\n}\n\nconst steps: [string, string[]][] = [\n [sdkScript, forwardedArgs],\n [resolve(__dirname, 'diff.ts'), diffArgs],\n];\n\nfor (const [script, scriptArgs] of steps) {\n console.log(`\\n${'='.repeat(60)}`);\n console.log(`Running ${script}`);\n console.log('='.repeat(60));\n\n try {\n execFileSync('npx', ['tsx', script, ...scriptArgs], {\n stdio: 'inherit',\n env: process.env,\n });\n } catch {\n process.exit(1);\n }\n}\n\nfunction parseTscOutput(output: string): Array<{ file: string; line: number; code: string; message: string }> {\n const errors: Array<{ file: string; line: number; code: string; message: string }> = [];\n const re = /^(.+)\\((\\d+),\\d+\\): error (TS\\d+): (.+)$/gm;\n let match;\n while ((match = re.exec(output)) !== null) {\n errors.push({\n file: match[1],\n line: Number(match[2]),\n code: match[3],\n message: match[4],\n });\n }\n return errors;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAmBA,MAAM,YAAY,QADC,cA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,IAAI,OAAO,GAAG,CAAC;AAE3B,MAAI;AACF,gBAAa,OAAO;IAAC;IAAO;IAAY;IAAa;IAAa,EAAE;IAClE,OAAO;IACP,KAAK,QAAQ;IACd,CAAC;AACF,WAAQ,IAAI,sBAAsB;WAC3B,KAAK;GAEZ,MAAM,WAAW,eADD,IAA6C,QAAQ,UAAU,IAAI,GAC5C;AACvC,iBAAc,6BAA6B,KAAK,UAAU,UAAU,MAAM,EAAE,CAAC;AAC7E,WAAQ,MAAM,wBAAwB,SAAS,OAAO,yCAAyC;AAC/F,WAAQ,KAAK,EAAE;;;;AAKrB,MAAM,QAA8B,CAClC,CAAC,WAAW,cAAc,EAC1B,CAAC,QAAQ,WAAW,UAAU,EAAE,SAAS,CAC1C;AAED,KAAK,MAAM,CAAC,QAAQ,eAAe,OAAO;AACxC,SAAQ,IAAI,KAAK,IAAI,OAAO,GAAG,GAAG;AAClC,SAAQ,IAAI,WAAW,SAAS;AAChC,SAAQ,IAAI,IAAI,OAAO,GAAG,CAAC;AAE3B,KAAI;AACF,eAAa,OAAO;GAAC;GAAO;GAAQ,GAAG;GAAW,EAAE;GAClD,OAAO;GACP,KAAK,QAAQ;GACd,CAAC;SACI;AACN,UAAQ,KAAK,EAAE;;;AAInB,SAAS,eAAe,QAAsF;CAC5G,MAAM,SAA+E,EAAE;CACvF,MAAM,KAAK;CACX,IAAI;AACJ,SAAQ,QAAQ,GAAG,KAAK,OAAO,MAAM,KACnC,QAAO,KAAK;EACV,MAAM,MAAM;EACZ,MAAM,OAAO,MAAM,GAAG;EACtB,MAAM,MAAM;EACZ,SAAS,MAAM;EAChB,CAAC;AAEJ,QAAO"}
1
+ {"version":3,"file":"sdk-test.mjs","names":[],"sources":["../../../scripts/smoke/sdk-test.ts"],"sourcesContent":["/**\n * Runs an SDK smoke test + diff against an existing raw baseline.\n *\n * Usage:\n * npm run smoke -- --lang node --sdk-path path/to/acme-node\n * npm run smoke -- --lang ruby --sdk-path path/to/acme-ruby\n * npm run smoke -- --lang node --sdk-path path/to/acme-node --raw-results custom-baseline.json\n *\n * Requires OPENAPI_SPEC_PATH env var (or --spec <path>) pointing to the OpenAPI spec.\n * The --lang flag is required and selects which SDK runner to use\n * (e.g. \"node\" → scripts/smoke/sdk-node.ts).\n */\n\nimport { existsSync, writeFileSync } from 'node:fs';\nimport { execFileSync } from 'node:child_process';\nimport { resolve, dirname } from 'node:path';\nimport { fileURLToPath } from 'node:url';\n\nconst __filename = fileURLToPath(import.meta.url);\nconst __dirname = dirname(__filename);\n\nconst args = process.argv.slice(2);\n\n// Extract --lang <name> (required)\nconst langIdx = args.indexOf('--lang');\nconst forwardedArgs = [...args];\n\nif (langIdx === -1 || !args[langIdx + 1]) {\n console.error('--lang is required (e.g. --lang node, --lang ruby)');\n process.exit(1);\n}\n\nconst lang = args[langIdx + 1];\nforwardedArgs.splice(langIdx, 2);\n\n// Extract --raw-results <path>\nconst rawResultsIdx = forwardedArgs.indexOf('--raw-results');\nlet rawResultsPath = 'smoke-results-raw.json';\n\nif (rawResultsIdx !== -1 && forwardedArgs[rawResultsIdx + 1]) {\n rawResultsPath = forwardedArgs[rawResultsIdx + 1];\n forwardedArgs.splice(rawResultsIdx, 2);\n}\n\n// Resolve the SDK runner script relative to this file's directory\nconst sdkScript = resolve(__dirname, `sdk-${lang}.ts`);\nif (!existsSync(sdkScript)) {\n console.error(`No smoke runner found for language \"${lang}\" (expected ${sdkScript})`);\n console.error(`Available runners:`);\n const { readdirSync } = await import('node:fs');\n for (const f of readdirSync(__dirname)) {\n const match = f.match(/^sdk-(.+)\\.ts$/);\n if (match && match[1] !== 'test') {\n console.error(` --lang ${match[1]}`);\n }\n }\n process.exit(1);\n}\n\nconst sdkResultsPath = `smoke-results-sdk-${lang}.json`;\n\nconst diffArgs = ['--raw', rawResultsPath, '--sdk', sdkResultsPath];\n\n// Pre-flight: tsc compile check on SDK if tsconfig.json exists\nconst sdkPathIdx = forwardedArgs.indexOf('--sdk-path');\nconst sdkPathValue = sdkPathIdx !== -1 && forwardedArgs[sdkPathIdx + 1] ? forwardedArgs[sdkPathIdx + 1] : undefined;\n\nif (sdkPathValue) {\n const tsconfigPath = resolve(sdkPathValue, 'tsconfig.json');\n if (existsSync(tsconfigPath)) {\n console.log(`\\n${'='.repeat(60)}`);\n console.log(`Type-checking SDK at ${sdkPathValue}`);\n console.log('='.repeat(60));\n\n try {\n execFileSync('npx', ['tsc', '--noEmit', '--project', sdkPathValue], {\n stdio: 'pipe',\n env: process.env,\n });\n console.log(' Type check passed');\n } catch (err) {\n const output = (err as { stdout?: Buffer; stderr?: Buffer }).stdout?.toString() ?? '';\n const findings = parseTscOutput(output);\n writeFileSync('smoke-compile-errors.json', JSON.stringify(findings, null, 2));\n console.error(` Type check failed (${findings.length} errors). See smoke-compile-errors.json`);\n process.exit(2);\n }\n }\n}\n\nconst steps: [string, string[]][] = [\n [sdkScript, forwardedArgs],\n [resolve(__dirname, 'diff.ts'), diffArgs],\n];\n\nfor (const [script, scriptArgs] of steps) {\n console.log(`\\n${'='.repeat(60)}`);\n console.log(`Running ${script}`);\n console.log('='.repeat(60));\n\n try {\n execFileSync('npx', ['tsx', script, ...scriptArgs], {\n stdio: 'inherit',\n env: process.env,\n });\n } catch {\n process.exit(1);\n }\n}\n\nfunction parseTscOutput(output: string): Array<{ file: string; line: number; code: string; message: string }> {\n const errors: Array<{ file: string; line: number; code: string; message: string }> = [];\n const re = /^(.+)\\((\\d+),\\d+\\): error (TS\\d+): (.+)$/gm;\n let match;\n while ((match = re.exec(output)) !== null) {\n errors.push({\n file: match[1],\n line: Number(match[2]),\n code: match[3],\n message: match[4],\n });\n }\n return errors;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAkBA,MAAM,aAAa,cAAc,YAAY,GAAG;AAChD,MAAM,YAAY,QAAQ,UAAU;AAEpC,MAAM,OAAO,QAAQ,KAAK,MAAM,CAAC;AAGjC,MAAM,UAAU,KAAK,QAAQ,QAAQ;AACrC,MAAM,gBAAgB,CAAC,GAAG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;IACP,KAAK,QAAQ;GACf,CAAC;GACD,QAAQ,IAAI,qBAAqB;EACnC,SAAS,KAAK;GAEZ,MAAM,WAAW,eADD,IAA6C,QAAQ,SAAS,KAAK,EAC7C;GACtC,cAAc,6BAA6B,KAAK,UAAU,UAAU,MAAM,CAAC,CAAC;GAC5E,QAAQ,MAAM,wBAAwB,SAAS,OAAO,wCAAwC;GAC9F,QAAQ,KAAK,CAAC;EAChB;CACF;AACF;AAEA,MAAM,QAA8B,CAClC,CAAC,WAAW,aAAa,GACzB,CAAC,QAAQ,WAAW,SAAS,GAAG,QAAQ,CAC1C;AAEA,KAAK,MAAM,CAAC,QAAQ,eAAe,OAAO;CACxC,QAAQ,IAAI,KAAK,IAAI,OAAO,EAAE,GAAG;CACjC,QAAQ,IAAI,WAAW,QAAQ;CAC/B,QAAQ,IAAI,IAAI,OAAO,EAAE,CAAC;CAE1B,IAAI;EACF,aAAa,OAAO;GAAC;GAAO;GAAQ,GAAG;EAAU,GAAG;GAClD,OAAO;GACP,KAAK,QAAQ;EACf,CAAC;CACH,QAAQ;EACN,QAAQ,KAAK,CAAC;CAChB;AACF;AAEA,SAAS,eAAe,QAAsF;CAC5G,MAAM,SAA+E,CAAC;CACtF,MAAM,KAAK;CACX,IAAI;CACJ,QAAQ,QAAQ,GAAG,KAAK,MAAM,OAAO,MACnC,OAAO,KAAK;EACV,MAAM,MAAM;EACZ,MAAM,OAAO,MAAM,EAAE;EACrB,MAAM,MAAM;EACZ,SAAS,MAAM;CACjB,CAAC;CAEH,OAAO;AACT"}
package/dist/smoke.d.mts CHANGED
@@ -1,3 +1,4 @@
1
+ import "dotenv/config";
1
2
  //#region src/ir/sdk-behavior.d.ts
2
3
  /**
3
4
  * SDK Behavior IR — language-agnostic runtime policies for generated SDKs.
@@ -126,8 +127,21 @@ interface SdkBehavior {
126
127
  }
127
128
  //#endregion
128
129
  //#region src/ir/types.d.ts
129
- /** Authentication scheme extracted from OpenAPI securitySchemes */
130
+ /**
131
+ * Authentication scheme extracted from OpenAPI `components.securitySchemes`.
132
+ *
133
+ * `schemeName` is the key under `components.securitySchemes`, spelled exactly as
134
+ * in the document. The requirements under `ApiSpec.security` and
135
+ * `Operation.security` refer to the same key, so emitters join a requirement to
136
+ * its scheme on that field. `description` is present only when the document
137
+ * declares one.
138
+ */
130
139
  type AuthScheme = {
140
+ description?: string;
141
+ schemeName: string;
142
+ } & ({
143
+ kind: 'basic';
144
+ } | {
131
145
  kind: 'bearer';
132
146
  } | {
133
147
  kind: 'apiKey';
@@ -136,7 +150,7 @@ type AuthScheme = {
136
150
  } | {
137
151
  kind: 'oauth2';
138
152
  flows: Record<string, unknown>;
139
- };
153
+ });
140
154
  /** Root IR node representing the full API surface */
141
155
  /** A server entry from the OpenAPI servers array */
142
156
  interface ServerEntry {
@@ -154,6 +168,12 @@ interface ApiSpec {
154
168
  models: Model[];
155
169
  enums: Enum[];
156
170
  auth?: AuthScheme[];
171
+ /**
172
+ * Document-level security requirements: the default every operation uses
173
+ * unless it declares its own `Operation.security`. Same shape and semantics
174
+ * as that field. `undefined` when the document declares none.
175
+ */
176
+ security?: SecurityRequirementSet[];
157
177
  /** Language-agnostic runtime policies (retry, errors, telemetry, etc.). */
158
178
  sdk: SdkBehavior;
159
179
  }
@@ -163,14 +183,39 @@ interface Service {
163
183
  description?: string;
164
184
  operations: Operation[];
165
185
  }
166
- /** A single API operation (maps to an SDK method) */
167
- /** Per-operation security requirement: scheme name → scope list. */
186
+ /** One scheme a request must satisfy, with the scopes it needs. */
168
187
  interface SecurityRequirement {
188
+ /** Key under `components.securitySchemes`; joins to `AuthScheme.schemeName`. */
169
189
  schemeName: string;
170
190
  scopes: string[];
171
191
  }
192
+ /**
193
+ * One alternative from an OpenAPI security requirement list: a request must
194
+ * satisfy *every* scheme in the set together ("all of"). A list of sets is
195
+ * satisfied by *any one* of them ("either of"). An empty set is an alternative
196
+ * that needs no credentials at all, which is how a document makes
197
+ * authentication optional (`security: [{ userToken: [] }, {}]`).
198
+ */
199
+ type SecurityRequirementSet = SecurityRequirement[];
200
+ /** A single API operation (maps to an SDK method) */
172
201
  interface Operation {
173
202
  name: string;
203
+ /**
204
+ * The document's `summary` alone. Present only when the OpenAPI operation
205
+ * declares one with non-whitespace content; an empty or whitespace-only
206
+ * summary is treated as absent. Read this to use the summary as a one-line
207
+ * label; `description` below still carries the combined form, so emitters
208
+ * that only print `description` are unchanged.
209
+ */
210
+ summary?: string;
211
+ /**
212
+ * Doc text for the operation. When the document declares both a `summary`
213
+ * and a `description` with content, this is `summary + "\n\n" + description`;
214
+ * when only one has content (or both are identical), this is that one. An
215
+ * empty or whitespace-only value is treated as absent, and text with content
216
+ * is kept verbatim. The parts are not separable from this field alone — use
217
+ * `summary` for that.
218
+ */
174
219
  description?: string;
175
220
  httpMethod: HttpMethod;
176
221
  path: string;
@@ -189,14 +234,29 @@ interface Operation {
189
234
  requestBody?: TypeRef;
190
235
  requestBodyEncoding?: 'json' | 'form-data' | 'form-urlencoded' | 'binary' | 'text';
191
236
  response: TypeRef;
237
+ /**
238
+ * Headers the primary success response declares (the one `response` is the
239
+ * body of). Present only when the spec declares at least one. Each entry of
240
+ * `successResponses` carries its own `headers`, but that list only exists
241
+ * when an operation has more than one 2xx, so the primary response's headers
242
+ * need a home of their own.
243
+ */
244
+ responseHeaders?: ResponseHeader[];
192
245
  successResponses?: SuccessResponse[];
193
246
  errors: ErrorResponse[];
194
247
  pagination?: PaginationMeta;
195
248
  injectIdempotencyKey: boolean;
196
249
  deprecated?: boolean;
197
250
  async?: boolean;
198
- /** Per-operation security overrides. When present, overrides the global spec-level security. */
199
- security?: SecurityRequirement[];
251
+ /**
252
+ * Per-operation security requirements, mirroring the OpenAPI document:
253
+ * - `undefined` — the operation declares nothing and inherits
254
+ * `ApiSpec.security` (which may itself be `undefined`).
255
+ * - `[]` — `security: []`: the operation needs no authentication.
256
+ * - otherwise one `SecurityRequirementSet` per requirement object; the
257
+ * request must satisfy any one set, and every scheme within it.
258
+ */
259
+ security?: SecurityRequirementSet[];
200
260
  /**
201
261
  * Mutually-exclusive parameter groups parsed from `x-mutually-exclusive-parameter-groups`.
202
262
  * Each group represents a logical choice the caller must (or may) make between
@@ -265,8 +325,84 @@ interface PaginationMeta {
265
325
  limitParam?: string;
266
326
  dataPath?: string;
267
327
  itemType: TypeRef;
328
+ /**
329
+ * Every property the list envelope carries besides the data array, in
330
+ * document order: the pagination companion (`list_metadata`, `pagination`,
331
+ * `has_more`, …) and any discriminant such as `object: "list"`. Together
332
+ * with `dataPath` and `itemType` this is the envelope's full shape, so an
333
+ * emitter can type what the endpoint returns and read the page details it
334
+ * needs for the next request without parsing the document itself.
335
+ *
336
+ * An inline companion object is lifted to a model. Because the same envelope
337
+ * recurs on every list endpoint of an API, copies that agree structurally
338
+ * share one model named from the property alone (`list_metadata` →
339
+ * `ListMetadata`, or the component schema of that name when one exists); a
340
+ * copy whose shape differs keeps an operation-qualified name
341
+ * (`ListUsersListMetadata`) so it can never change another type's shape.
342
+ *
343
+ * Absent when the response is a bare array, or when pagination was inferred
344
+ * from query parameters alone and no envelope was detected.
345
+ */
346
+ envelopeFields?: Field[];
268
347
  }
269
348
  type HttpMethod = 'get' | 'post' | 'put' | 'patch' | 'delete' | 'head' | 'options' | 'trace';
349
+ /**
350
+ * JSON Schema validation keywords declared directly on a schema, carried so an
351
+ * emitter can document a value's limits ("at most 100"), check a value before
352
+ * sending it, or keep a generated example within range. Every member is
353
+ * optional and present only when the document declares it; a schema with no
354
+ * validation keyword has no `constraints` at all.
355
+ *
356
+ * Numeric bounds use the OpenAPI 3.1 / JSON Schema 2020-12 shape, where
357
+ * `exclusiveMinimum` / `exclusiveMaximum` are the bound itself. OpenAPI 3.0
358
+ * spells them as booleans that make `minimum` / `maximum` exclusive; the
359
+ * parser normalizes that form, so `{ minimum: 0, exclusiveMinimum: true }`
360
+ * arrives as `{ exclusiveMinimum: 0 }` with no `minimum`, and a `false` is
361
+ * dropped. Emitters read one shape whichever version produced it.
362
+ *
363
+ * The keywords on the field, parameter or model schema itself are carried,
364
+ * conjoined with those of its inline `allOf` members (a single-member
365
+ * `allOf` is unwrapped by the parser, so its limit is the value's own; a
366
+ * `$ref` member contributes the keywords written beside the reference while
367
+ * the referenced model keeps its own). Limits nested inside array `items` or
368
+ * map values are not carried. A nullable wrapper — `oneOf`/`anyOf` with a
369
+ * single non-null, non-`$ref` branch — conjoins that branch's keywords with
370
+ * its own; limits on a general multi-variant union are not carried.
371
+ */
372
+ interface Constraints {
373
+ /** Inclusive lower bound (`minimum`). */
374
+ minimum?: number;
375
+ /** Inclusive upper bound (`maximum`). */
376
+ maximum?: number;
377
+ /** Exclusive lower bound as a number; the OAS 3.0 boolean form is normalized to this. */
378
+ exclusiveMinimum?: number;
379
+ /** Exclusive upper bound as a number; the OAS 3.0 boolean form is normalized to this. */
380
+ exclusiveMaximum?: number;
381
+ /** The value must be an integer multiple of this (`multipleOf`). */
382
+ multipleOf?: number;
383
+ /** Minimum string length in characters (`minLength`). */
384
+ minLength?: number;
385
+ /** Maximum string length in characters (`maxLength`). */
386
+ maxLength?: number;
387
+ /** ECMA-262 regular expression the string must match (`pattern`), verbatim from the document. */
388
+ pattern?: string;
389
+ /** Minimum number of array items (`minItems`). */
390
+ minItems?: number;
391
+ /** Maximum number of array items (`maxItems`). */
392
+ maxItems?: number;
393
+ /** Present, and `true`, when array items must be unique; `uniqueItems: false` restates the default and is dropped. */
394
+ uniqueItems?: boolean;
395
+ /** Minimum number of items matching the schema's `contains` (`minContains`). */
396
+ minContains?: number;
397
+ /** Maximum number of items matching the schema's `contains` (`maxContains`). */
398
+ maxContains?: number;
399
+ /** Minimum number of object properties (`minProperties`). */
400
+ minProperties?: number;
401
+ /** Maximum number of object properties (`maxProperties`). */
402
+ maxProperties?: number;
403
+ /** Property name → properties that must also be present when it is (`dependentRequired`). */
404
+ dependentRequired?: Record<string, string[]>;
405
+ }
270
406
  interface Parameter {
271
407
  name: string;
272
408
  type: TypeRef;
@@ -274,9 +410,32 @@ interface Parameter {
274
410
  description?: string;
275
411
  deprecated?: boolean;
276
412
  default?: unknown;
413
+ /**
414
+ * A single illustrative value, resolved level by level: the parameter's own
415
+ * `example` (else the first entry of its `examples` map), then its inline
416
+ * schema's `example` (else the first of its `examples` list), then the same
417
+ * on the component schema its `$ref` points at. A level with neither falls
418
+ * through; an explicit `null` is kept. Absent when no level gives one.
419
+ */
277
420
  example?: unknown;
421
+ /**
422
+ * Every example value the document gives, in document order: the
423
+ * parameter's `examples` map of Example Objects (each entry's `value`, with
424
+ * `$ref`s resolved against `components.examples`), else the JSON Schema
425
+ * `examples` list on its inline schema, else the list on the component
426
+ * schema its `$ref` points at. Present only when at least one value exists.
427
+ */
428
+ examples?: unknown[];
278
429
  style?: 'form' | 'simple' | 'label' | 'matrix';
279
430
  explode?: boolean;
431
+ /**
432
+ * Validation keywords from the parameter's schema. When that schema is a
433
+ * `$ref`, the target's keywords are merged underneath the parameter's own
434
+ * — the per-value fallback `default` and `example` use — so a parameter
435
+ * can be read on its own without chasing the fieldless alias model the
436
+ * target also becomes. Absent when neither declares any.
437
+ */
438
+ constraints?: Constraints;
280
439
  }
281
440
  /** Type reference — the core type system of the IR */
282
441
  type TypeRef = PrimitiveType | ArrayType | ModelRef | EnumRef | UnionType | NullableType | LiteralType | MapType;
@@ -349,6 +508,12 @@ interface Model {
349
508
  property: string;
350
509
  mapping: Record<string, string>;
351
510
  };
511
+ /**
512
+ * Validation keywords declared on the model's own schema — for an object
513
+ * schema, `minProperties`, `maxProperties` and `dependentRequired`. Absent
514
+ * when the schema declares none.
515
+ */
516
+ constraints?: Constraints;
352
517
  }
353
518
  interface Field {
354
519
  name: string;
@@ -368,7 +533,27 @@ interface Field {
368
533
  writeOnly?: boolean;
369
534
  deprecated?: boolean;
370
535
  default?: unknown;
536
+ /**
537
+ * A single illustrative value. The field schema's `example` when present,
538
+ * otherwise the first entry of its `examples`; when the schema is a `$ref`
539
+ * with neither, the same taken from the component it points at. An
540
+ * explicit `null` is kept. Absent when no level gives one.
541
+ */
371
542
  example?: unknown;
543
+ /**
544
+ * Every example value the schema gives, in document order, from the JSON
545
+ * Schema `examples` list (OAS 3.1 deprecates `example` in its favour) —
546
+ * on the field schema, else on the component its `$ref` points at.
547
+ * Present only when the list has at least one entry.
548
+ */
549
+ examples?: unknown[];
550
+ /**
551
+ * Validation keywords declared on the field's schema, including any
552
+ * written beside a `$ref` (OpenAPI 3.1 allows siblings). Absent when the
553
+ * schema declares none; a bare `$ref` yields none, since the referenced
554
+ * model carries its own limits.
555
+ */
556
+ constraints?: Constraints;
372
557
  }
373
558
  /** Enum definition */
374
559
  interface Enum {
@@ -383,16 +568,41 @@ interface EnumValue {
383
568
  description?: string;
384
569
  deprecated?: boolean;
385
570
  }
571
+ /**
572
+ * A header a response declares, typed like a parameter. `name` is kept exactly
573
+ * as written in the spec (e.g. `Content-Disposition`); emitters apply their
574
+ * own casing.
575
+ */
576
+ interface ResponseHeader {
577
+ name: string;
578
+ type: TypeRef;
579
+ required: boolean;
580
+ description?: string;
581
+ deprecated?: boolean;
582
+ }
386
583
  interface ErrorResponse {
387
584
  statusCode: number;
388
585
  type?: TypeRef;
586
+ /** Declared response headers. Present only when the spec declares at least one. */
587
+ headers?: ResponseHeader[];
389
588
  }
390
589
  /** A successful response entry from a 2xx status code */
391
590
  interface SuccessResponse {
392
591
  statusCode: number;
393
592
  type: TypeRef;
593
+ /** Declared response headers. Present only when the spec declares at least one. */
594
+ headers?: ResponseHeader[];
394
595
  }
395
596
  //#endregion
597
+ //#region src/parser/schemas.d.ts
598
+ /**
599
+ * Signature of the `schemaNameTransform` hook. `name` is the cleaned
600
+ * PascalCase name; `originalName` is the `components.schemas` key exactly
601
+ * as spelled in the document, or `undefined` for names oagen synthesises.
602
+ * See `SchemaExtractionOptions.schemaNameTransform`.
603
+ */
604
+ type SchemaNameTransform = (name: string, originalName?: string) => string;
605
+ //#endregion
396
606
  //#region src/parser/parse.d.ts
397
607
  /**
398
608
  * A bundled OpenAPI document, post-`$ref` resolution but pre-IR extraction.
@@ -405,7 +615,13 @@ interface SuccessResponse {
405
615
  type OpenApiDocument = Record<string, unknown>;
406
616
  interface ParseOptions {
407
617
  operationIdTransform?: (id: string) => string;
408
- schemaNameTransform?: (name: string) => string;
618
+ /**
619
+ * Custom transform for schema (model/enum) names. Receives the cleaned
620
+ * PascalCase name and, for component schemas, the original name as spelled
621
+ * in the document. Returning `originalName` opts out of normalization.
622
+ * See `SchemaExtractionOptions.schemaNameTransform`.
623
+ */
624
+ schemaNameTransform?: SchemaNameTransform;
409
625
  /**
410
626
  * Domain-facing field-name overrides, keyed by IR model name then wire field
411
627
  * name: `{ Connection: { connection_type: 'type' } }`. Sets `Field.domainName`
@@ -429,21 +645,21 @@ interface ParseOptions {
429
645
  */
430
646
  transformSpec?: (spec: OpenApiDocument) => OpenApiDocument;
431
647
  }
432
- declare function parseSpec(specPath: string, options?: ParseOptions): Promise<ApiSpec>;
648
+ export declare function parseSpec(specPath: string, options?: ParseOptions): Promise<ApiSpec>;
433
649
  //#endregion
434
650
  //#region src/utils/naming.d.ts
435
- declare function toCamelCase(s: string, acronyms?: Set<string>): string;
436
- declare function toSnakeCase(s: string): string;
651
+ export declare function toCamelCase(s: string, acronyms?: Set<string>): string;
652
+ export declare function toSnakeCase(s: string): string;
437
653
  //#endregion
438
654
  //#region scripts/smoke/shared.d.ts
439
- interface ExchangeProvenance {
655
+ export interface ExchangeProvenance {
440
656
  resolutionTier: 'exact' | 'crud-prefix' | 'fuzzy' | 'manifest';
441
657
  resolutionConfidence: number;
442
658
  sdkMethodName: string;
443
659
  captureIndex: number;
444
660
  totalCaptures: number;
445
661
  }
446
- interface CapturedExchange {
662
+ export interface CapturedExchange {
447
663
  operationId: string;
448
664
  service: string;
449
665
  operationName: string;
@@ -467,51 +683,51 @@ interface CapturedExchange {
467
683
  /** How the SDK method was resolved and which capture was selected */
468
684
  provenance?: ExchangeProvenance;
469
685
  }
470
- interface SmokeResults {
686
+ export interface SmokeResults {
471
687
  source: 'raw' | 'spec-baseline' | `sdk-${string}`;
472
688
  timestamp: string;
473
689
  specVersion: string;
474
690
  exchanges: CapturedExchange[];
475
691
  }
476
- interface PlannedOperation {
692
+ export interface PlannedOperation {
477
693
  service: string;
478
694
  operation: Operation;
479
695
  }
480
- interface PlannedGroup {
696
+ export interface PlannedGroup {
481
697
  service: string;
482
698
  operations: PlannedOperation[];
483
699
  }
484
700
  /** Operations that require complex preconditions and can't be auto-tested */
485
- declare let SKIP_OPERATIONS: Set<string>;
701
+ export declare let SKIP_OPERATIONS: Set<string>;
486
702
  /** Services to skip entirely */
487
- declare let SKIP_SERVICES: Set<string>;
703
+ export declare let SKIP_SERVICES: Set<string>;
488
704
  /**
489
705
  * Map IR service names to SDK property names on the client object.
490
706
  * Empty = use toCamelCase(serviceName) as fallback.
491
707
  */
492
- declare let SERVICE_PROPERTY_MAP: Record<string, string>;
493
- interface SmokeConfig {
708
+ export declare let SERVICE_PROPERTY_MAP: Record<string, string>;
709
+ export interface SmokeConfig {
494
710
  skipOperations: string[];
495
711
  skipServices: string[];
496
712
  servicePriority: Record<string, number>;
497
713
  servicePropertyMap: Record<string, string>;
498
714
  }
499
715
  /** Load smoke test configuration from a JSON file */
500
- declare function loadSmokeConfig(configPath?: string): void;
716
+ export declare function loadSmokeConfig(configPath?: string): void;
501
717
  /** Return the current smoke config values (for diff.ts to consume) */
502
- declare function getSmokeConfig(): {
718
+ export declare function getSmokeConfig(): {
503
719
  skipOperations: Set<string>;
504
720
  skipServices: Set<string>;
505
721
  servicePriority: Record<string, number>;
506
722
  servicePropertyMap: Record<string, string>;
507
723
  };
508
- declare function planOperations(spec: ApiSpec): PlannedGroup[];
724
+ export declare function planOperations(spec: ApiSpec): PlannedGroup[];
509
725
  /**
510
726
  * A single wave of operations that can be planned and executed together.
511
727
  * Wave 0 contains parameterless operations. Subsequent waves contain
512
728
  * operations whose path params became resolvable after earlier waves ran.
513
729
  */
514
- interface OperationWave {
730
+ export interface OperationWave {
515
731
  /** Operations in this wave, with pre-resolved path params */
516
732
  calls: Array<{
517
733
  op: Operation;
@@ -530,17 +746,17 @@ interface OperationWave {
530
746
  * @param ids - the IdRegistry (mutated by the caller between waves)
531
747
  * @param resolveMethod - optional filter; return null to skip an operation
532
748
  */
533
- declare function planWaves(groups: PlannedGroup[], ids: IdRegistry, resolveMethod?: (op: Operation, irService: string) => boolean): Generator<OperationWave, PlannedOperation[], void>;
534
- declare function generateFixtureValue(typeRef: TypeRef, fieldName: string, spec: ApiSpec): unknown;
749
+ export declare function planWaves(groups: PlannedGroup[], ids: IdRegistry, resolveMethod?: (op: Operation, irService: string) => boolean): Generator<OperationWave, PlannedOperation[], void>;
750
+ export declare function generateFixtureValue(typeRef: TypeRef, fieldName: string, spec: ApiSpec): unknown;
535
751
  /** Generate a snake_case request body payload from an operation's requestBody type */
536
- declare function generatePayload(op: Operation, spec: ApiSpec): Record<string, unknown> | null;
752
+ export declare function generatePayload(op: Operation, spec: ApiSpec): Record<string, unknown> | null;
537
753
  /** Generate a camelCase payload for SDK method calls */
538
- declare function generateCamelPayload(op: Operation, spec: ApiSpec): Record<string, unknown> | null;
754
+ export declare function generateCamelPayload(op: Operation, spec: ApiSpec): Record<string, unknown> | null;
539
755
  /** Generate query params for an operation (required params only, plus limit=1 for lists) */
540
- declare function generateQueryParams(op: Operation, spec: ApiSpec): Record<string, string>;
756
+ export declare function generateQueryParams(op: Operation, spec: ApiSpec): Record<string, string>;
541
757
  /** Generate camelCase query params for SDK method calls */
542
- declare function generateCamelQueryParams(op: Operation, spec: ApiSpec): Record<string, unknown>;
543
- declare class IdRegistry {
758
+ export declare function generateCamelQueryParams(op: Operation, spec: ApiSpec): Record<string, unknown>;
759
+ export declare class IdRegistry {
544
760
  private ids;
545
761
  set(service: string, field: string, value: string): void;
546
762
  get(service: string, field: string): string | undefined;
@@ -575,16 +791,15 @@ declare class IdRegistry {
575
791
  private extractNestedIds;
576
792
  }
577
793
  /** Get the set of status codes declared in the spec for an operation (success + errors) */
578
- declare function getExpectedStatusCodes(op: Operation): number[];
794
+ export declare function getExpectedStatusCodes(op: Operation): number[];
579
795
  /** Check if a status code is unexpected (not declared in the spec) */
580
- declare function isUnexpectedStatus(status: number, op: Operation): boolean;
581
- declare function resolvePath(op: Operation, pathParams: Record<string, string>): string;
582
- declare function delay(ms: number): Promise<void>;
583
- declare function parseCliArgs(): {
796
+ export declare function isUnexpectedStatus(status: number, op: Operation): boolean;
797
+ export declare function resolvePath(op: Operation, pathParams: Record<string, string>): string;
798
+ export declare function delay(ms: number): Promise<void>;
799
+ export declare function parseCliArgs(): {
584
800
  spec: string;
585
801
  sdkPath?: string;
586
802
  smokeConfig?: string;
587
803
  };
588
804
  //#endregion
589
- export { CapturedExchange, ExchangeProvenance, IdRegistry, OperationWave, PlannedGroup, PlannedOperation, SERVICE_PROPERTY_MAP, SKIP_OPERATIONS, SKIP_SERVICES, SmokeConfig, SmokeResults, delay, generateCamelPayload, generateCamelQueryParams, generateFixtureValue, generatePayload, generateQueryParams, getExpectedStatusCodes, getSmokeConfig, isUnexpectedStatus, loadSmokeConfig, parseCliArgs, parseSpec, planOperations, planWaves, resolvePath, toCamelCase, toSnakeCase };
590
805
  //# sourceMappingURL=smoke.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"smoke.d.mts","names":[],"sources":["../src/ir/sdk-behavior.ts","../src/ir/types.ts","../src/parser/parse.ts","../src/utils/naming.ts","../scripts/smoke/shared.ts"],"mappings":";;;;AAYA;;;;;;UAAiB,WAAA;EAQf;EANA,oBAAA;EAQS;EANT,UAAA;EAMwB;EAJxB,sBAAA;EAY8B;EAV9B,cAAA;EAU8B;EAR9B,OAAA,EAAS,eAAA;AAAA;;;;;AAsBX;UAdiB,eAAA;;EAEf,YAAA;EAeA;EAbA,UAAA;EAeA;EAbA,QAAA;EAiBA;EAfA,YAAA;AAAA;AAqBF;AAAA,UAfiB,WAAA;;;EAGf,aAAA,EAAe,MAAA;EAgBf;EAdA,eAAA;EAgBe;EAdf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,YAAA,CAAA;EAAkB,IAAA;EAAc,OAAA;EAAkB,WAAA;AAAA"}
1
+ {"version":3,"file":"smoke.d.mts","names":[],"sources":["../src/ir/sdk-behavior.ts","../src/ir/types.ts","../src/parser/schemas.ts","../src/parser/parse.ts","../src/utils/naming.ts","../scripts/smoke/shared.ts"],"mappings":";;;;;;;;;;;UAYiB;;EAEf;;EAEA;;EAEA;;EAEA;;EAEA,SAAS;;;;;;;UAQM;;EAEf;;EAEA;;EAEA;;EAEA;;;UAMe;;;EAGf,eAAe;;EAEf;;EAEA;;EAEA;;;UAMe;;EAEf;;EAEA;;EAEA;;;UAMe;;EAEf;;;UAMe;;EAEf;;EAEA;;;UAMe;;EAEf;;EAEA,QAAQ;;;KAIE;;UAWK;;;;;EAKf;;EAEA;;EAEA;;EAEA,gBAAgB;;;UAID;;EAEf;;EAEA;;;UAMe;;;EAGf;;;UAMe;;EAEf;;EAEA;;;;UAOe;EACf,OAAO;EACP,QAAQ;EACR,WAAW;EACX,YAAY;EACZ,aAAa;EACb,SAAS;EACT,WAAW;EACX,cAAc;EACd,SAAS;;;;;;;;;;;;;KCvJC;EAAe;EAAsB;;EAC3C;;EACA;;EACA;EAAgB;EAAmC;;EACnD;EAAgB,OAAO;;;;UAKZ;EACf;EACA;;;UAIe;EACf;EACA;EACA;EACA;EACA,UAAU;EACV,UAAU;EACV,QAAQ;EACR,OAAO;EACP,OAAO;;;;;;EAMP,WAAW;;EAEX,KAAK;;;UAIU;EACf;EACA;EACA,YAAY;;;UAIG;;EAEf;EACA;;;;;;;;;KAUU,yBAAyB;;UAGpB;EACf;;;;;;;;EAQA;;;;;;;;;EASA;EACA,YAAY;EACZ;EACA,YAAY;EACZ,aAAa;;;;;;;;EAQb,uBAAuB;EACvB,cAAc;EACd,eAAe;EACf,cAAc;EACd;EACA,UAAU;;;;;;;;EAQV,kBAAkB;EAClB,mBAAmB;EACnB,QAAQ;EACR,aAAa;EACb;EACA;EACA;;;;;;;;;EASA,WAAW;;;;;;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