@postman/sdk-config 0.24.0 → 0.25.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 (34) hide show
  1. package/dist/index.cjs +60 -1
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.d.cts +2 -2
  4. package/dist/index.d.ts +2 -2
  5. package/dist/index.js +60 -2
  6. package/dist/index.js.map +1 -1
  7. package/dist/sdk-config/index.cjs +42 -0
  8. package/dist/sdk-config/index.cjs.map +1 -1
  9. package/dist/sdk-config/index.d.cts +1 -1
  10. package/dist/sdk-config/index.d.ts +1 -1
  11. package/dist/sdk-config/index.js +42 -0
  12. package/dist/sdk-config/index.js.map +1 -1
  13. package/dist/sdk-config/v1/index.cjs +42 -0
  14. package/dist/sdk-config/v1/index.cjs.map +1 -1
  15. package/dist/sdk-config/v1/index.d.cts +10 -2
  16. package/dist/sdk-config/v1/index.d.ts +10 -2
  17. package/dist/sdk-config/v1/index.js +42 -0
  18. package/dist/sdk-config/v1/index.js.map +1 -1
  19. package/dist/sdk-config-ir/index.cjs +55 -1
  20. package/dist/sdk-config-ir/index.cjs.map +1 -1
  21. package/dist/sdk-config-ir/index.d.cts +2 -2
  22. package/dist/sdk-config-ir/index.d.ts +2 -2
  23. package/dist/sdk-config-ir/index.js +55 -2
  24. package/dist/sdk-config-ir/index.js.map +1 -1
  25. package/dist/sdk-config-ir/v1/index.cjs +55 -1
  26. package/dist/sdk-config-ir/v1/index.cjs.map +1 -1
  27. package/dist/sdk-config-ir/v1/index.d.cts +30 -3
  28. package/dist/sdk-config-ir/v1/index.d.ts +30 -3
  29. package/dist/sdk-config-ir/v1/index.js +55 -2
  30. package/dist/sdk-config-ir/v1/index.js.map +1 -1
  31. package/dist/{typescript-BcBGIPrg.d.cts → typescript-BIq_eF34.d.cts} +2 -0
  32. package/dist/{typescript-BcBGIPrg.d.ts → typescript-BIq_eF34.d.ts} +2 -0
  33. package/package.json +1 -1
  34. package/src/sdk-config/v1/README.md +31 -0
@@ -453,6 +453,8 @@ declare const mcpGenerationConfigSchema: z.ZodObject<{
453
453
  }, z.core.$strict>>>;
454
454
  serverName: z.ZodOptional<z.ZodString>;
455
455
  serverDescription: z.ZodOptional<z.ZodString>;
456
+ instructions: z.ZodOptional<z.ZodString>;
457
+ appendInstructions: z.ZodOptional<z.ZodString>;
456
458
  excludeAvailability: z.ZodOptional<z.ZodArray<z.ZodEnum<{
457
459
  IN_DEVELOPMENT: "IN_DEVELOPMENT";
458
460
  PRE_RELEASE: "PRE_RELEASE";
@@ -453,6 +453,8 @@ declare const mcpGenerationConfigSchema: z.ZodObject<{
453
453
  }, z.core.$strict>>>;
454
454
  serverName: z.ZodOptional<z.ZodString>;
455
455
  serverDescription: z.ZodOptional<z.ZodString>;
456
+ instructions: z.ZodOptional<z.ZodString>;
457
+ appendInstructions: z.ZodOptional<z.ZodString>;
456
458
  excludeAvailability: z.ZodOptional<z.ZodArray<z.ZodEnum<{
457
459
  IN_DEVELOPMENT: "IN_DEVELOPMENT";
458
460
  PRE_RELEASE: "PRE_RELEASE";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@postman/sdk-config",
3
- "version": "0.24.0",
3
+ "version": "0.25.0",
4
4
  "description": "Shared SDK configuration contracts and transformations for Postman SDK generation",
5
5
  "license": "UNLICENSED",
6
6
  "sideEffects": false,
@@ -165,6 +165,37 @@ The flow-level `clientId` of an `authorization-code` flow is optional so existin
165
165
  parsing. A generator that needs it for an interactive login reports an error when it is absent. A
166
166
  `device-code` flow exists only for interactive login, so it requires it.
167
167
 
168
+ ### OAuth token URL per environment
169
+
170
+ A `client-credentials` flow has one required `tokenUrl`. When the API's token endpoint differs per
171
+ environment (production, staging, development), add `environmentTokenUrls`, a map from environment
172
+ name to token URL:
173
+
174
+ ```yaml
175
+ api:
176
+ environments:
177
+ - name: Production
178
+ urls: [{ name: default, url: https://api.example.com }]
179
+ - name: Staging
180
+ urls: [{ name: default, url: https://api.stage.example.com }]
181
+ auth:
182
+ schemes:
183
+ - id: oauth
184
+ type: oauth2
185
+ flows:
186
+ - type: client-credentials
187
+ tokenUrl: https://auth.example.com/token
188
+ environmentTokenUrls:
189
+ Staging: https://auth.stage.example.com/token
190
+ ```
191
+
192
+ When the selected environment has an entry, its URL replaces `tokenUrl`; an environment without an
193
+ entry uses `tokenUrl`. Every key must name an entry of `api.environments`, so a misspelled name is
194
+ rejected instead of leaving that environment on the production endpoint. The field is only accepted on
195
+ `client-credentials` flows. Because a generator that ignores it would call the production token endpoint
196
+ from every environment, serializing an IR that uses it requires the
197
+ `api.auth.oauth.environmentTokenUrls` capability.
198
+
168
199
  ### OAuth interactive login
169
200
 
170
201
  The flows a CLI logs in with take a few more settings, all optional (they carry what the identity