@postman/sdk-config 0.0.1 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +71 -2
- package/dist/index.cjs +186 -131
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +183 -132
- package/dist/index.js.map +1 -1
- package/dist/sdk-config-ir/index.cjs +186 -131
- package/dist/sdk-config-ir/index.cjs.map +1 -1
- package/dist/sdk-config-ir/index.d.cts +1 -1
- package/dist/sdk-config-ir/index.d.ts +1 -1
- package/dist/sdk-config-ir/index.js +183 -132
- package/dist/sdk-config-ir/index.js.map +1 -1
- package/dist/sdk-config-ir/v1/index.cjs +186 -131
- package/dist/sdk-config-ir/v1/index.cjs.map +1 -1
- package/dist/sdk-config-ir/v1/index.d.cts +426 -78
- package/dist/sdk-config-ir/v1/index.d.ts +426 -78
- package/dist/sdk-config-ir/v1/index.js +183 -132
- package/dist/sdk-config-ir/v1/index.js.map +1 -1
- package/package.json +2 -2
- package/src/sdk-config-ir/v1/README.md +8 -1
package/README.md
CHANGED
|
@@ -64,7 +64,76 @@ npm pack --dry-run
|
|
|
64
64
|
- Breaking wire changes get a new schema directory and discriminator such as `sdk-config-ir/v2`.
|
|
65
65
|
- Keep the previous version exported while consumers migrate.
|
|
66
66
|
|
|
67
|
-
|
|
68
|
-
|
|
67
|
+
### Manual release process
|
|
68
|
+
|
|
69
|
+
Release automation is intentionally deferred while the tagging and publishing process is reviewed
|
|
70
|
+
with Postman's security team. Until that process is established, use the following manual release
|
|
71
|
+
procedure. The commands use `1.1.0` as an example; replace it consistently with the version being
|
|
72
|
+
released.
|
|
73
|
+
|
|
74
|
+
#### 1. Prepare a release branch from develop
|
|
75
|
+
|
|
76
|
+
Normal feature pull requests target `develop`. Start the release from an up-to-date `develop`
|
|
77
|
+
branch, update the version without creating a tag, and run the complete check suite:
|
|
78
|
+
|
|
79
|
+
```sh
|
|
80
|
+
git switch develop
|
|
81
|
+
git pull --ff-only origin develop
|
|
82
|
+
git switch -c release/v1.1.0
|
|
83
|
+
npm version 1.1.0 --no-git-tag-version
|
|
84
|
+
npm run check
|
|
85
|
+
git add package.json package-lock.json
|
|
86
|
+
git commit -m "release: v1.1.0"
|
|
87
|
+
git push -u origin release/v1.1.0
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
Open a pull request from `release/v1.1.0` into `main`. Review the version change, wait for required
|
|
91
|
+
checks and approvals, and merge it. The release branch isolates the version bump and preserves the
|
|
92
|
+
exact `develop` snapshot being reviewed, while work can continue independently on `develop`.
|
|
93
|
+
|
|
94
|
+
#### 2. Merge main back into develop
|
|
95
|
+
|
|
96
|
+
The publishing workflow requires the tagged commit to be in the history of the repository's default
|
|
97
|
+
branch, `develop`. After the release pull request is merged, create a synchronization branch from
|
|
98
|
+
the latest `develop` and merge the released `main` into it:
|
|
99
|
+
|
|
100
|
+
```sh
|
|
101
|
+
git fetch origin
|
|
102
|
+
git switch -c chore/merge-main-after-v1.1.0 origin/develop
|
|
103
|
+
git merge --no-ff origin/main -m "Merge main back to develop after v1.1.0"
|
|
104
|
+
git push -u origin chore/merge-main-after-v1.1.0
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
Open a pull request from `chore/merge-main-after-v1.1.0` into `develop`, wait for its checks, and use
|
|
108
|
+
**Create a merge commit** to merge it. Do not squash or rebase this pull request: the original
|
|
109
|
+
`main` commit must remain in `develop`'s ancestry for the publishing workflow's validation. The
|
|
110
|
+
temporary branch can then be deleted safely.
|
|
111
|
+
|
|
112
|
+
#### 3. Create the release tag from main
|
|
113
|
+
|
|
114
|
+
After the synchronization pull request is merged, update your local `main` and verify that
|
|
115
|
+
`package.json` contains the version you are about to tag:
|
|
116
|
+
|
|
117
|
+
```sh
|
|
118
|
+
git switch main
|
|
119
|
+
git pull --ff-only origin main
|
|
120
|
+
node -p "require('./package.json').version"
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
Create a signed, annotated tag on the checked-out `main` commit, verify it locally, and push it:
|
|
124
|
+
|
|
125
|
+
```sh
|
|
126
|
+
git tag -s v1.1.0 -m "Release v1.1.0"
|
|
127
|
+
git tag -v v1.1.0
|
|
128
|
+
git push origin v1.1.0
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
Pushing a tag matching `v*.*.*` automatically triggers the **Package Release** workflow defined in
|
|
132
|
+
`.github/workflows/npm-publish.yml`. In GitHub, open **Actions** → **Package Release** and confirm
|
|
133
|
+
the tag-triggered run succeeds.
|
|
134
|
+
|
|
135
|
+
If publishing fails after the tag has been created, do not delete, move, or recreate the tag. After
|
|
136
|
+
the underlying problem is fixed, open **Actions** → **Package Release** → **Run workflow** and enter
|
|
137
|
+
the existing tag, such as `v1.1.0`, to retry it.
|
|
69
138
|
|
|
70
139
|
See the [SDK Config IR v1 reference](src/sdk-config-ir/v1/README.md) for the complete contract.
|
package/dist/index.cjs
CHANGED
|
@@ -176,25 +176,26 @@ var environmentVariableSchema = zod.z.strictObject({
|
|
|
176
176
|
defaultValue: zod.z.string().optional()
|
|
177
177
|
});
|
|
178
178
|
var apiConfigSchema = zod.z.strictObject({
|
|
179
|
-
baseUrl:
|
|
179
|
+
baseUrl: zod.z.string().default(""),
|
|
180
|
+
environments: zod.z.array(environmentSchema).default([]),
|
|
181
|
+
environmentVariables: zod.z.array(environmentVariableSchema).default([]),
|
|
180
182
|
defaultEnvironment: nonEmptyStringSchema.optional(),
|
|
181
|
-
environments: zod.z.array(environmentSchema).optional(),
|
|
182
183
|
auth: authConfigSchema.optional(),
|
|
183
|
-
headers: zod.z.array(headerSchema).optional()
|
|
184
|
-
environmentVariables: zod.z.array(environmentVariableSchema).optional()
|
|
184
|
+
headers: zod.z.array(headerSchema).optional()
|
|
185
185
|
});
|
|
186
186
|
var retryConfigSchema = zod.z.strictObject({
|
|
187
|
-
enabled: zod.z.boolean(),
|
|
188
|
-
maxAttempts: zod.z.number().int().min(1).
|
|
189
|
-
retryDelayMs: zod.z.number().nonnegative().
|
|
190
|
-
maxDelayMs: zod.z.number().nonnegative().
|
|
191
|
-
jitterMs: zod.z.number().nonnegative().
|
|
192
|
-
backoffFactor: zod.z.number().positive().
|
|
187
|
+
enabled: zod.z.boolean().default(true),
|
|
188
|
+
maxAttempts: zod.z.number().int().min(1).default(3),
|
|
189
|
+
retryDelayMs: zod.z.number().nonnegative().default(150),
|
|
190
|
+
maxDelayMs: zod.z.number().nonnegative().default(5e3),
|
|
191
|
+
jitterMs: zod.z.number().nonnegative().default(50),
|
|
192
|
+
backoffFactor: zod.z.number().positive().default(2),
|
|
193
193
|
statusCodes: zod.z.array(zod.z.number().int().min(100).max(599)).optional(),
|
|
194
|
-
methods: zod.z.array(nonEmptyStringSchema).
|
|
195
|
-
statusCodeProfile: zod.z.enum(["legacy", "recommended"]).optional()
|
|
194
|
+
methods: zod.z.array(nonEmptyStringSchema).default(["GET", "POST", "PUT", "DELETE", "PATCH", "HEAD", "OPTIONS"]),
|
|
195
|
+
statusCodeProfile: zod.z.enum(["legacy", "recommended"]).optional(),
|
|
196
|
+
maxRetryAfterDelayMs: zod.z.number().nonnegative().default(6e4)
|
|
196
197
|
}).superRefine(({ maxDelayMs, retryDelayMs }, context) => {
|
|
197
|
-
if (maxDelayMs
|
|
198
|
+
if (maxDelayMs < retryDelayMs) {
|
|
198
199
|
context.addIssue({
|
|
199
200
|
code: "custom",
|
|
200
201
|
message: "maxDelayMs must be greater than or equal to retryDelayMs",
|
|
@@ -224,17 +225,17 @@ var tokenRefreshConfigSchema = zod.z.strictObject({
|
|
|
224
225
|
}
|
|
225
226
|
});
|
|
226
227
|
var clientConfigSchema = zod.z.strictObject({
|
|
227
|
-
retry: retryConfigSchema.
|
|
228
|
-
|
|
229
|
-
responseHeaders: zod.z.boolean().optional(),
|
|
228
|
+
retry: retryConfigSchema.prefault({}),
|
|
229
|
+
responseHeaders: zod.z.boolean().default(false),
|
|
230
230
|
responseValidation: zod.z.boolean().optional(),
|
|
231
|
+
multiTenant: zod.z.boolean().default(false),
|
|
232
|
+
additionalConstructorParameters: zod.z.array(constructorParameterSchema).default([]),
|
|
233
|
+
timeoutMs: zod.z.union([zod.z.number().nonnegative(), zod.z.literal("infinity")]).optional(),
|
|
231
234
|
requestParameterStyle: parameterStyleSchema.optional(),
|
|
232
235
|
pathParameterStyle: parameterStyleSchema.optional(),
|
|
233
236
|
filePropertyStyle: parameterStyleSchema.optional(),
|
|
234
237
|
useDefaultRequestParameterValues: zod.z.boolean().optional(),
|
|
235
|
-
|
|
236
|
-
tokenRefresh: tokenRefreshConfigSchema.optional(),
|
|
237
|
-
multiTenant: zod.z.boolean().optional()
|
|
238
|
+
tokenRefresh: tokenRefreshConfigSchema.optional()
|
|
238
239
|
});
|
|
239
240
|
var unsupportedFieldSchema = zod.z.strictObject({
|
|
240
241
|
source: zod.z.enum(["fern", "postman", "sdk-config-ir"]),
|
|
@@ -331,6 +332,38 @@ var javaGenerationConfigSchema = jvmGenerationConfigSchema.extend({
|
|
|
331
332
|
|
|
332
333
|
// src/sdk-config-ir/v1/language/kotlin.ts
|
|
333
334
|
var kotlinGenerationConfigSchema = jvmGenerationConfigSchema;
|
|
335
|
+
var compilerOptionsSchema = zod.z.strictObject({
|
|
336
|
+
target: nonEmptyStringSchema.optional(),
|
|
337
|
+
module: nonEmptyStringSchema.optional(),
|
|
338
|
+
lib: zod.z.array(nonEmptyStringSchema).optional()
|
|
339
|
+
});
|
|
340
|
+
var packageScriptSchema = zod.z.strictObject({
|
|
341
|
+
name: nonEmptyStringSchema,
|
|
342
|
+
command: nonEmptyStringSchema
|
|
343
|
+
});
|
|
344
|
+
var httpClientSchema = zod.z.strictObject({
|
|
345
|
+
name: zod.z.enum(["axios", "fetch"])
|
|
346
|
+
});
|
|
347
|
+
var typescriptGenerationConfigSchema = zod.z.strictObject({
|
|
348
|
+
typescriptVersion: nonEmptyStringSchema.optional(),
|
|
349
|
+
zodVersion: nonEmptyStringSchema.optional(),
|
|
350
|
+
compilerOptions: compilerOptionsSchema.optional(),
|
|
351
|
+
httpClient: httpClientSchema.optional(),
|
|
352
|
+
packageManager: zod.z.enum(["pnpm", "yarn"]).optional(),
|
|
353
|
+
testFramework: zod.z.enum(["jest", "vitest"]).optional(),
|
|
354
|
+
namingStrategy: zod.z.enum(["base", "originalPropertyNames"]).optional(),
|
|
355
|
+
bundle: zod.z.boolean().optional(),
|
|
356
|
+
exportClassDefault: zod.z.boolean().optional(),
|
|
357
|
+
allowCustomFetcher: zod.z.boolean().optional(),
|
|
358
|
+
useBrandedStringAliases: zod.z.boolean().optional(),
|
|
359
|
+
useLegacyExports: zod.z.boolean().optional(),
|
|
360
|
+
useBigInt: zod.z.boolean().optional(),
|
|
361
|
+
serdeLayer: zod.z.boolean().optional(),
|
|
362
|
+
scripts: zod.z.array(packageScriptSchema).optional()
|
|
363
|
+
});
|
|
364
|
+
|
|
365
|
+
// src/sdk-config-ir/v1/language/mcp.ts
|
|
366
|
+
var mcpGenerationConfigSchema = typescriptGenerationConfigSchema;
|
|
334
367
|
var phpGenerationConfigSchema = zod.z.strictObject({
|
|
335
368
|
propertyAccess: zod.z.enum(["public", "private"]).optional(),
|
|
336
369
|
generateClientInterfaces: zod.z.boolean().optional()
|
|
@@ -357,34 +390,122 @@ var pythonGenerationConfigSchema = zod.z.strictObject({
|
|
|
357
390
|
var rubyGenerationConfigSchema = zod.z.strictObject({
|
|
358
391
|
requirePaths: zod.z.array(nonEmptyStringSchema).optional()
|
|
359
392
|
});
|
|
360
|
-
var
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
393
|
+
var rustGenerationConfigSchema = zod.z.strictObject({
|
|
394
|
+
/**
|
|
395
|
+
* Rust type for datetime primitives. `offset` maps to `DateTime<FixedOffset>` and preserves the
|
|
396
|
+
* timezone the payload carried; `utc` maps to `DateTime<Utc>` and normalizes to UTC.
|
|
397
|
+
*/
|
|
398
|
+
dateTimeType: zod.z.enum(["offset", "utc"]).optional(),
|
|
399
|
+
/** Uppercase common initialisms in generated names (`UserID` rather than `UserId`). */
|
|
400
|
+
capitalizeInitialisms: zod.z.boolean().optional(),
|
|
401
|
+
/** Cargo features, mapping a feature name to the dependencies or features it enables. */
|
|
402
|
+
features: zod.z.record(zod.z.string(), zod.z.array(nonEmptyStringSchema)).optional(),
|
|
403
|
+
/** Overrides which features make up Cargo's `default` feature set. */
|
|
404
|
+
defaultFeatures: zod.z.array(nonEmptyStringSchema).optional()
|
|
405
|
+
});
|
|
406
|
+
var swiftGenerationConfigSchema = zod.z.strictObject({
|
|
407
|
+
moduleName: nonEmptyStringSchema.optional()
|
|
364
408
|
});
|
|
365
|
-
var
|
|
409
|
+
var goModulePathSchema = nonEmptyStringSchema.regex(
|
|
410
|
+
/^(?!.*(?:^|\/)\.{1,2}(?:\/|$))[A-Za-z0-9._~-]+(?:\/[A-Za-z0-9._~-]+)+$/,
|
|
411
|
+
"Go module path must be a slash-delimited path using letters, numbers, dots, dashes, underscores, or tildes"
|
|
412
|
+
);
|
|
413
|
+
var composerPackageNameSchema = nonEmptyStringSchema.regex(
|
|
414
|
+
/^[a-z0-9]([_.-]?[a-z0-9]+)*\/[a-z0-9](([_.]?|-{0,2})[a-z0-9]+)*$/,
|
|
415
|
+
'Composer package name must be a lowercase "vendor/package" name'
|
|
416
|
+
);
|
|
417
|
+
var authorSchema = zod.z.strictObject({
|
|
366
418
|
name: nonEmptyStringSchema,
|
|
367
|
-
|
|
419
|
+
email: zod.z.email().optional()
|
|
368
420
|
});
|
|
369
|
-
var
|
|
370
|
-
name:
|
|
421
|
+
var developerSchema = zod.z.strictObject({
|
|
422
|
+
name: nonEmptyStringSchema,
|
|
423
|
+
email: zod.z.email().optional(),
|
|
424
|
+
organization: nonEmptyStringSchema.optional(),
|
|
425
|
+
organizationUrl: nonEmptyStringSchema.optional()
|
|
371
426
|
});
|
|
372
|
-
var
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
427
|
+
var licenseSchema = zod.z.strictObject({
|
|
428
|
+
type: nonEmptyStringSchema,
|
|
429
|
+
name: nonEmptyStringSchema.optional(),
|
|
430
|
+
url: nonEmptyStringSchema.optional(),
|
|
431
|
+
path: nonEmptyStringSchema.optional()
|
|
432
|
+
});
|
|
433
|
+
var dependencySourceSchema = zod.z.discriminatedUnion("type", [
|
|
434
|
+
zod.z.strictObject({
|
|
435
|
+
type: zod.z.literal("registry"),
|
|
436
|
+
registry: nonEmptyStringSchema.optional()
|
|
437
|
+
}),
|
|
438
|
+
zod.z.strictObject({
|
|
439
|
+
type: zod.z.literal("git"),
|
|
440
|
+
url: nonEmptyStringSchema,
|
|
441
|
+
ref: nonEmptyStringSchema.optional(),
|
|
442
|
+
subdirectory: nonEmptyStringSchema.optional()
|
|
443
|
+
}),
|
|
444
|
+
zod.z.strictObject({
|
|
445
|
+
type: zod.z.literal("path"),
|
|
446
|
+
path: nonEmptyStringSchema
|
|
447
|
+
})
|
|
448
|
+
]);
|
|
449
|
+
var dependencySchema = zod.z.strictObject({
|
|
450
|
+
name: nonEmptyStringSchema,
|
|
451
|
+
version: nonEmptyStringSchema.optional(),
|
|
452
|
+
source: dependencySourceSchema.optional(),
|
|
453
|
+
packageName: nonEmptyStringSchema.optional(),
|
|
454
|
+
features: zod.z.array(nonEmptyStringSchema).optional(),
|
|
455
|
+
extras: zod.z.array(nonEmptyStringSchema).optional(),
|
|
456
|
+
optional: zod.z.boolean().optional(),
|
|
457
|
+
defaultFeatures: zod.z.boolean().optional(),
|
|
458
|
+
environmentMarker: nonEmptyStringSchema.optional()
|
|
459
|
+
}).refine(({ source, version }) => source !== void 0 || version !== void 0, {
|
|
460
|
+
message: "dependency must define a version or a source"
|
|
461
|
+
});
|
|
462
|
+
var projectUrlSchema = zod.z.strictObject({
|
|
463
|
+
label: nonEmptyStringSchema,
|
|
464
|
+
url: nonEmptyStringSchema
|
|
465
|
+
});
|
|
466
|
+
var packageConfigSchema = zod.z.strictObject({
|
|
467
|
+
packageName: nonEmptyStringSchema.optional(),
|
|
468
|
+
moduleName: nonEmptyStringSchema.optional(),
|
|
469
|
+
modulePath: goModulePathSchema.optional(),
|
|
470
|
+
namespace: nonEmptyStringSchema.optional(),
|
|
471
|
+
groupId: nonEmptyStringSchema.optional(),
|
|
472
|
+
artifactId: nonEmptyStringSchema.optional(),
|
|
473
|
+
description: zod.z.string().optional(),
|
|
474
|
+
repository: nonEmptyStringSchema.optional(),
|
|
475
|
+
homepage: nonEmptyStringSchema.optional(),
|
|
476
|
+
documentationUrl: nonEmptyStringSchema.optional(),
|
|
477
|
+
authors: zod.z.array(authorSchema).optional(),
|
|
478
|
+
developers: zod.z.array(developerSchema).optional(),
|
|
479
|
+
license: licenseSchema.optional(),
|
|
480
|
+
keywords: zod.z.array(nonEmptyStringSchema).optional(),
|
|
481
|
+
classifiers: zod.z.array(nonEmptyStringSchema).optional(),
|
|
482
|
+
projectUrls: zod.z.array(projectUrlSchema).optional(),
|
|
483
|
+
extraDependencies: zod.z.array(dependencySchema).optional(),
|
|
484
|
+
extraDevDependencies: zod.z.array(dependencySchema).optional(),
|
|
485
|
+
extraPeerDependencies: zod.z.array(dependencySchema).optional()
|
|
486
|
+
});
|
|
487
|
+
|
|
488
|
+
// src/sdk-config-ir/v1/language/terraform.ts
|
|
489
|
+
var planModifierSourceSchema = zod.z.discriminatedUnion("enabled", [
|
|
490
|
+
zod.z.strictObject({ enabled: zod.z.literal(true), sourceDir: nonEmptyStringSchema }),
|
|
491
|
+
zod.z.strictObject({ enabled: zod.z.literal(false) })
|
|
492
|
+
]);
|
|
493
|
+
var planModifiersSchema = zod.z.strictObject({
|
|
494
|
+
resources: planModifierSourceSchema,
|
|
495
|
+
attributes: planModifierSourceSchema
|
|
496
|
+
});
|
|
497
|
+
var providerSchemaSchema = zod.z.strictObject({
|
|
498
|
+
addressKey: nonEmptyStringSchema,
|
|
499
|
+
authTokenKey: nonEmptyStringSchema
|
|
500
|
+
});
|
|
501
|
+
var terraformGenerationConfigSchema = zod.z.strictObject({
|
|
502
|
+
providerName: nonEmptyStringSchema.optional(),
|
|
503
|
+
providerVersion: nonEmptyStringSchema.optional(),
|
|
504
|
+
providerModulePath: goModulePathSchema.optional(),
|
|
505
|
+
mockAcceptance: zod.z.boolean().optional(),
|
|
506
|
+
hideComputedDiff: zod.z.boolean().optional(),
|
|
507
|
+
providerSchema: providerSchemaSchema.optional(),
|
|
508
|
+
planModifiers: planModifiersSchema.optional()
|
|
388
509
|
});
|
|
389
510
|
|
|
390
511
|
// src/sdk-config-ir/v1/generation.ts
|
|
@@ -473,17 +594,23 @@ var languageGenerationConfigSchema = zod.z.strictObject({
|
|
|
473
594
|
csharp: csharpGenerationConfigSchema.optional(),
|
|
474
595
|
php: phpGenerationConfigSchema.optional(),
|
|
475
596
|
ruby: rubyGenerationConfigSchema.optional(),
|
|
476
|
-
|
|
597
|
+
rust: rustGenerationConfigSchema.optional(),
|
|
598
|
+
cli: cliGenerationConfigSchema.optional(),
|
|
599
|
+
mcp: mcpGenerationConfigSchema.optional(),
|
|
600
|
+
swift: swiftGenerationConfigSchema.optional(),
|
|
601
|
+
terraform: terraformGenerationConfigSchema.optional()
|
|
477
602
|
});
|
|
478
603
|
var generationConfigSchema = zod.z.strictObject({
|
|
479
|
-
includeWatermark: zod.z.boolean().
|
|
604
|
+
includeWatermark: zod.z.boolean().default(false),
|
|
605
|
+
/** Emits an AI service into the generated SDK. Python, Java and TypeScript honour it. */
|
|
606
|
+
ai: zod.z.boolean().default(false),
|
|
480
607
|
includeOptionalSnippetParameters: zod.z.boolean().optional(),
|
|
481
|
-
buildAllModels: zod.z.boolean().
|
|
482
|
-
inferServiceNames: zod.z.boolean().
|
|
483
|
-
includeDeprecatedOperations: zod.z.boolean().
|
|
484
|
-
multipleResponses: zod.z.boolean().
|
|
485
|
-
devContainer: zod.z.boolean().
|
|
486
|
-
allowMockClient: zod.z.boolean().
|
|
608
|
+
buildAllModels: zod.z.boolean().default(false),
|
|
609
|
+
inferServiceNames: zod.z.boolean().default(false),
|
|
610
|
+
includeDeprecatedOperations: zod.z.boolean().default(true),
|
|
611
|
+
multipleResponses: zod.z.boolean().default(false),
|
|
612
|
+
devContainer: zod.z.boolean().default(false),
|
|
613
|
+
allowMockClient: zod.z.boolean().default(false),
|
|
487
614
|
ignoreFiles: zod.z.array(nonEmptyStringSchema).optional(),
|
|
488
615
|
reservedKeywords: zod.z.array(nonEmptyStringSchema).optional(),
|
|
489
616
|
hooks: hooksConfigSchema.optional(),
|
|
@@ -564,84 +691,6 @@ var outputConfigSchema = zod.z.discriminatedUnion(
|
|
|
564
691
|
error: 'output.delivery must be one of "files", "zip", or "github"'
|
|
565
692
|
}
|
|
566
693
|
);
|
|
567
|
-
var goModulePathSchema = nonEmptyStringSchema.regex(
|
|
568
|
-
/^(?!.*(?:^|\/)\.{1,2}(?:\/|$))[A-Za-z0-9._~-]+(?:\/[A-Za-z0-9._~-]+)+$/,
|
|
569
|
-
"Go module path must be a slash-delimited path using letters, numbers, dots, dashes, underscores, or tildes"
|
|
570
|
-
);
|
|
571
|
-
var composerPackageNameSchema = nonEmptyStringSchema.regex(
|
|
572
|
-
/^[a-z0-9]([_.-]?[a-z0-9]+)*\/[a-z0-9](([_.]?|-{0,2})[a-z0-9]+)*$/,
|
|
573
|
-
'Composer package name must be a lowercase "vendor/package" name'
|
|
574
|
-
);
|
|
575
|
-
var authorSchema = zod.z.strictObject({
|
|
576
|
-
name: nonEmptyStringSchema,
|
|
577
|
-
email: zod.z.email().optional()
|
|
578
|
-
});
|
|
579
|
-
var developerSchema = zod.z.strictObject({
|
|
580
|
-
name: nonEmptyStringSchema,
|
|
581
|
-
email: zod.z.email().optional(),
|
|
582
|
-
organization: nonEmptyStringSchema.optional(),
|
|
583
|
-
organizationUrl: nonEmptyStringSchema.optional()
|
|
584
|
-
});
|
|
585
|
-
var licenseSchema = zod.z.strictObject({
|
|
586
|
-
type: nonEmptyStringSchema,
|
|
587
|
-
name: nonEmptyStringSchema.optional(),
|
|
588
|
-
url: nonEmptyStringSchema.optional(),
|
|
589
|
-
path: nonEmptyStringSchema.optional()
|
|
590
|
-
});
|
|
591
|
-
var dependencySourceSchema = zod.z.discriminatedUnion("type", [
|
|
592
|
-
zod.z.strictObject({
|
|
593
|
-
type: zod.z.literal("registry"),
|
|
594
|
-
registry: nonEmptyStringSchema.optional()
|
|
595
|
-
}),
|
|
596
|
-
zod.z.strictObject({
|
|
597
|
-
type: zod.z.literal("git"),
|
|
598
|
-
url: nonEmptyStringSchema,
|
|
599
|
-
ref: nonEmptyStringSchema.optional(),
|
|
600
|
-
subdirectory: nonEmptyStringSchema.optional()
|
|
601
|
-
}),
|
|
602
|
-
zod.z.strictObject({
|
|
603
|
-
type: zod.z.literal("path"),
|
|
604
|
-
path: nonEmptyStringSchema
|
|
605
|
-
})
|
|
606
|
-
]);
|
|
607
|
-
var dependencySchema = zod.z.strictObject({
|
|
608
|
-
name: nonEmptyStringSchema,
|
|
609
|
-
version: nonEmptyStringSchema.optional(),
|
|
610
|
-
source: dependencySourceSchema.optional(),
|
|
611
|
-
packageName: nonEmptyStringSchema.optional(),
|
|
612
|
-
features: zod.z.array(nonEmptyStringSchema).optional(),
|
|
613
|
-
extras: zod.z.array(nonEmptyStringSchema).optional(),
|
|
614
|
-
optional: zod.z.boolean().optional(),
|
|
615
|
-
defaultFeatures: zod.z.boolean().optional(),
|
|
616
|
-
environmentMarker: nonEmptyStringSchema.optional()
|
|
617
|
-
}).refine(({ source, version }) => source !== void 0 || version !== void 0, {
|
|
618
|
-
message: "dependency must define a version or a source"
|
|
619
|
-
});
|
|
620
|
-
var projectUrlSchema = zod.z.strictObject({
|
|
621
|
-
label: nonEmptyStringSchema,
|
|
622
|
-
url: nonEmptyStringSchema
|
|
623
|
-
});
|
|
624
|
-
var packageConfigSchema = zod.z.strictObject({
|
|
625
|
-
packageName: nonEmptyStringSchema.optional(),
|
|
626
|
-
moduleName: nonEmptyStringSchema.optional(),
|
|
627
|
-
modulePath: goModulePathSchema.optional(),
|
|
628
|
-
namespace: nonEmptyStringSchema.optional(),
|
|
629
|
-
groupId: nonEmptyStringSchema.optional(),
|
|
630
|
-
artifactId: nonEmptyStringSchema.optional(),
|
|
631
|
-
description: zod.z.string().optional(),
|
|
632
|
-
repository: nonEmptyStringSchema.optional(),
|
|
633
|
-
homepage: nonEmptyStringSchema.optional(),
|
|
634
|
-
documentationUrl: nonEmptyStringSchema.optional(),
|
|
635
|
-
authors: zod.z.array(authorSchema).optional(),
|
|
636
|
-
developers: zod.z.array(developerSchema).optional(),
|
|
637
|
-
license: licenseSchema.optional(),
|
|
638
|
-
keywords: zod.z.array(nonEmptyStringSchema).optional(),
|
|
639
|
-
classifiers: zod.z.array(nonEmptyStringSchema).optional(),
|
|
640
|
-
projectUrls: zod.z.array(projectUrlSchema).optional(),
|
|
641
|
-
extraDependencies: zod.z.array(dependencySchema).optional(),
|
|
642
|
-
extraDevDependencies: zod.z.array(dependencySchema).optional(),
|
|
643
|
-
extraPeerDependencies: zod.z.array(dependencySchema).optional()
|
|
644
|
-
});
|
|
645
694
|
var apiImportSettingsSchema = zod.z.strictObject({
|
|
646
695
|
respectNullableSchemas: zod.z.boolean().optional(),
|
|
647
696
|
titleAsSchemaName: zod.z.boolean().optional(),
|
|
@@ -701,7 +750,9 @@ var targetLanguageSchema = zod.z.enum([
|
|
|
701
750
|
"ruby",
|
|
702
751
|
"rust",
|
|
703
752
|
"swift",
|
|
704
|
-
"cli"
|
|
753
|
+
"cli",
|
|
754
|
+
"mcp",
|
|
755
|
+
"terraform"
|
|
705
756
|
]);
|
|
706
757
|
var targetConfigSchema = zod.z.strictObject({
|
|
707
758
|
language: targetLanguageSchema,
|
|
@@ -709,7 +760,7 @@ var targetConfigSchema = zod.z.strictObject({
|
|
|
709
760
|
sourceOrigin: zod.z.enum(["postman", "fern"]),
|
|
710
761
|
sdkName: nonEmptyStringSchema,
|
|
711
762
|
organization: nonEmptyStringSchema.optional(),
|
|
712
|
-
sdkVersion: nonEmptyStringSchema.
|
|
763
|
+
sdkVersion: nonEmptyStringSchema.default("1.0.0"),
|
|
713
764
|
apiVersion: nonEmptyStringSchema.optional()
|
|
714
765
|
});
|
|
715
766
|
|
|
@@ -842,6 +893,7 @@ exports.jsonValueSchema = jsonValueSchema;
|
|
|
842
893
|
exports.kotlinGenerationConfigSchema = kotlinGenerationConfigSchema;
|
|
843
894
|
exports.languageGenerationConfigSchema = languageGenerationConfigSchema;
|
|
844
895
|
exports.legacyInputSchema = legacyInputSchema;
|
|
896
|
+
exports.mcpGenerationConfigSchema = mcpGenerationConfigSchema;
|
|
845
897
|
exports.nonEmptyStringSchema = nonEmptyStringSchema;
|
|
846
898
|
exports.outputConfigSchema = outputConfigSchema;
|
|
847
899
|
exports.packageConfigSchema = packageConfigSchema;
|
|
@@ -852,12 +904,15 @@ exports.publishRegistrySchema = publishRegistrySchema;
|
|
|
852
904
|
exports.pythonGenerationConfigSchema = pythonGenerationConfigSchema;
|
|
853
905
|
exports.readmeEndpointSchema = readmeEndpointSchema;
|
|
854
906
|
exports.rubyGenerationConfigSchema = rubyGenerationConfigSchema;
|
|
907
|
+
exports.rustGenerationConfigSchema = rustGenerationConfigSchema;
|
|
855
908
|
exports.sdkConfigIrV1Schema = sdkConfigIrV1Schema;
|
|
856
909
|
exports.sourceConfigSchema = sourceConfigSchema;
|
|
857
910
|
exports.sourceSpecConfigSchema = sourceSpecConfigSchema;
|
|
858
911
|
exports.sourceSpecTypeSchema = sourceSpecTypeSchema;
|
|
912
|
+
exports.swiftGenerationConfigSchema = swiftGenerationConfigSchema;
|
|
859
913
|
exports.targetConfigSchema = targetConfigSchema;
|
|
860
914
|
exports.targetLanguageSchema = targetLanguageSchema;
|
|
915
|
+
exports.terraformGenerationConfigSchema = terraformGenerationConfigSchema;
|
|
861
916
|
exports.typescriptGenerationConfigSchema = typescriptGenerationConfigSchema;
|
|
862
917
|
exports.unsupportedFieldSchema = unsupportedFieldSchema;
|
|
863
918
|
//# sourceMappingURL=index.cjs.map
|