@vercel/sdk 1.8.2 → 1.8.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/bin/mcp-server.js +178 -149
- package/bin/mcp-server.js.map +10 -10
- package/esm/__tests__/projects.test.js +13 -15
- package/esm/__tests__/projects.test.js.map +1 -1
- package/esm/lib/config.d.ts +3 -3
- package/esm/lib/config.js +3 -3
- package/esm/lib/security.d.ts +2 -2
- package/esm/lib/security.d.ts.map +1 -1
- package/esm/mcp-server/mcp-server.js +1 -1
- package/esm/mcp-server/server.js +1 -1
- package/esm/models/filterprojectenvsop.d.ts +9 -9
- package/esm/models/filterprojectenvsop.js +3 -3
- package/esm/models/filterprojectenvsop.js.map +1 -1
- package/esm/models/getconfigurationop.d.ts +61 -0
- package/esm/models/getconfigurationop.d.ts.map +1 -1
- package/esm/models/getconfigurationop.js +53 -0
- package/esm/models/getconfigurationop.js.map +1 -1
- package/esm/models/getprojectenvop.d.ts +9 -9
- package/esm/models/getprojectenvop.js +3 -3
- package/esm/models/getprojectenvop.js.map +1 -1
- package/esm/models/getprojectsop.d.ts +128 -128
- package/esm/models/getprojectsop.d.ts.map +1 -1
- package/esm/models/getprojectsop.js +132 -132
- package/esm/models/getprojectsop.js.map +1 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/__tests__/projects.test.ts +13 -15
- package/src/lib/config.ts +3 -3
- package/src/lib/security.ts +2 -2
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/src/models/filterprojectenvsop.ts +3 -3
- package/src/models/getconfigurationop.ts +105 -0
- package/src/models/getprojectenvop.ts +3 -3
- package/src/models/getprojectsop.ts +260 -260
- package/vercel-spec.json +242 -215
package/jsr.json
CHANGED
package/package.json
CHANGED
|
@@ -740,21 +740,19 @@ test("Projects Create Project Env", async () => {
|
|
|
740
740
|
upsert: "true",
|
|
741
741
|
teamId: "team_1a2b3c4d5e6f7g8h9i0j1k2l",
|
|
742
742
|
slug: "my-team-url-slug",
|
|
743
|
-
requestBody:
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
},
|
|
757
|
-
],
|
|
743
|
+
requestBody: {
|
|
744
|
+
key: "API_URL",
|
|
745
|
+
value: "https://api.vercel.com",
|
|
746
|
+
type: "plain",
|
|
747
|
+
target: [
|
|
748
|
+
"preview",
|
|
749
|
+
],
|
|
750
|
+
gitBranch: "feature-1",
|
|
751
|
+
comment: "database connection string for production",
|
|
752
|
+
customEnvironmentIds: [
|
|
753
|
+
"env_1234567890",
|
|
754
|
+
],
|
|
755
|
+
},
|
|
758
756
|
});
|
|
759
757
|
expect(result).toBeDefined();
|
|
760
758
|
expect(result).toEqual({
|
package/src/lib/config.ts
CHANGED
|
@@ -61,7 +61,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
61
61
|
export const SDK_METADATA = {
|
|
62
62
|
language: "typescript",
|
|
63
63
|
openapiDocVersion: "0.0.1",
|
|
64
|
-
sdkVersion: "1.8.
|
|
65
|
-
genVersion: "2.
|
|
66
|
-
userAgent: "speakeasy-sdk/typescript 1.8.
|
|
64
|
+
sdkVersion: "1.8.3",
|
|
65
|
+
genVersion: "2.629.1",
|
|
66
|
+
userAgent: "speakeasy-sdk/typescript 1.8.3 2.629.1 0.0.1 @vercel/sdk",
|
|
67
67
|
} as const;
|
package/src/lib/security.ts
CHANGED
|
@@ -6,8 +6,8 @@ import { Security } from "../models/security.js";
|
|
|
6
6
|
|
|
7
7
|
type OAuth2PasswordFlow = {
|
|
8
8
|
username: string;
|
|
9
|
-
password
|
|
10
|
-
clientID
|
|
9
|
+
password: string;
|
|
10
|
+
clientID?: string | undefined;
|
|
11
11
|
clientSecret?: string | undefined;
|
|
12
12
|
tokenURL: string;
|
|
13
13
|
};
|
package/src/mcp-server/server.ts
CHANGED
|
@@ -89,10 +89,10 @@ export type FilterProjectEnvsResponseBodyProjectsResponseTarget =
|
|
|
89
89
|
|
|
90
90
|
export const FilterProjectEnvsResponseBodyProjectsResponse200Type = {
|
|
91
91
|
System: "system",
|
|
92
|
-
Secret: "secret",
|
|
93
92
|
Encrypted: "encrypted",
|
|
94
93
|
Plain: "plain",
|
|
95
94
|
Sensitive: "sensitive",
|
|
95
|
+
Secret: "secret",
|
|
96
96
|
} as const;
|
|
97
97
|
export type FilterProjectEnvsResponseBodyProjectsResponse200Type = ClosedEnum<
|
|
98
98
|
typeof FilterProjectEnvsResponseBodyProjectsResponse200Type
|
|
@@ -447,10 +447,10 @@ export type FilterProjectEnvsResponseBodyProjectsTarget =
|
|
|
447
447
|
|
|
448
448
|
export const FilterProjectEnvsResponseBodyProjectsResponseType = {
|
|
449
449
|
System: "system",
|
|
450
|
-
Secret: "secret",
|
|
451
450
|
Encrypted: "encrypted",
|
|
452
451
|
Plain: "plain",
|
|
453
452
|
Sensitive: "sensitive",
|
|
453
|
+
Secret: "secret",
|
|
454
454
|
} as const;
|
|
455
455
|
export type FilterProjectEnvsResponseBodyProjectsResponseType = ClosedEnum<
|
|
456
456
|
typeof FilterProjectEnvsResponseBodyProjectsResponseType
|
|
@@ -806,10 +806,10 @@ export type FilterProjectEnvsResponseBodyTarget =
|
|
|
806
806
|
|
|
807
807
|
export const FilterProjectEnvsResponseBodyType = {
|
|
808
808
|
System: "system",
|
|
809
|
-
Secret: "secret",
|
|
810
809
|
Encrypted: "encrypted",
|
|
811
810
|
Plain: "plain",
|
|
812
811
|
Sensitive: "sensitive",
|
|
812
|
+
Secret: "secret",
|
|
813
813
|
} as const;
|
|
814
814
|
export type FilterProjectEnvsResponseBodyType = ClosedEnum<
|
|
815
815
|
typeof FilterProjectEnvsResponseBodyType
|
|
@@ -35,6 +35,22 @@ export const ProjectSelection = {
|
|
|
35
35
|
*/
|
|
36
36
|
export type ProjectSelection = ClosedEnum<typeof ProjectSelection>;
|
|
37
37
|
|
|
38
|
+
export const GetConfigurationResponseBodyLevel = {
|
|
39
|
+
Error: "error",
|
|
40
|
+
Info: "info",
|
|
41
|
+
Warn: "warn",
|
|
42
|
+
} as const;
|
|
43
|
+
export type GetConfigurationResponseBodyLevel = ClosedEnum<
|
|
44
|
+
typeof GetConfigurationResponseBodyLevel
|
|
45
|
+
>;
|
|
46
|
+
|
|
47
|
+
export type ResponseBodyNotification = {
|
|
48
|
+
level: GetConfigurationResponseBodyLevel;
|
|
49
|
+
title: string;
|
|
50
|
+
message?: string | undefined;
|
|
51
|
+
href?: string | undefined;
|
|
52
|
+
};
|
|
53
|
+
|
|
38
54
|
export const TransferRequestKind = {
|
|
39
55
|
TransferFromMarketplace: "transfer-from-marketplace",
|
|
40
56
|
} as const;
|
|
@@ -162,6 +178,7 @@ export type GetConfigurationResponseBody2 = {
|
|
|
162
178
|
* A string representing the permission for projects. Possible values are `all` or `selected`.
|
|
163
179
|
*/
|
|
164
180
|
projectSelection: ProjectSelection;
|
|
181
|
+
notification: ResponseBodyNotification;
|
|
165
182
|
transferRequest: TransferRequest2 | TransferRequest1;
|
|
166
183
|
/**
|
|
167
184
|
* When a configuration is limited to access certain projects, this will contain each of the project ID it is allowed to access. If it is not defined, the configuration has full access.
|
|
@@ -445,6 +462,91 @@ export namespace ProjectSelection$ {
|
|
|
445
462
|
export const outboundSchema = ProjectSelection$outboundSchema;
|
|
446
463
|
}
|
|
447
464
|
|
|
465
|
+
/** @internal */
|
|
466
|
+
export const GetConfigurationResponseBodyLevel$inboundSchema: z.ZodNativeEnum<
|
|
467
|
+
typeof GetConfigurationResponseBodyLevel
|
|
468
|
+
> = z.nativeEnum(GetConfigurationResponseBodyLevel);
|
|
469
|
+
|
|
470
|
+
/** @internal */
|
|
471
|
+
export const GetConfigurationResponseBodyLevel$outboundSchema: z.ZodNativeEnum<
|
|
472
|
+
typeof GetConfigurationResponseBodyLevel
|
|
473
|
+
> = GetConfigurationResponseBodyLevel$inboundSchema;
|
|
474
|
+
|
|
475
|
+
/**
|
|
476
|
+
* @internal
|
|
477
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
478
|
+
*/
|
|
479
|
+
export namespace GetConfigurationResponseBodyLevel$ {
|
|
480
|
+
/** @deprecated use `GetConfigurationResponseBodyLevel$inboundSchema` instead. */
|
|
481
|
+
export const inboundSchema = GetConfigurationResponseBodyLevel$inboundSchema;
|
|
482
|
+
/** @deprecated use `GetConfigurationResponseBodyLevel$outboundSchema` instead. */
|
|
483
|
+
export const outboundSchema =
|
|
484
|
+
GetConfigurationResponseBodyLevel$outboundSchema;
|
|
485
|
+
}
|
|
486
|
+
|
|
487
|
+
/** @internal */
|
|
488
|
+
export const ResponseBodyNotification$inboundSchema: z.ZodType<
|
|
489
|
+
ResponseBodyNotification,
|
|
490
|
+
z.ZodTypeDef,
|
|
491
|
+
unknown
|
|
492
|
+
> = z.object({
|
|
493
|
+
level: GetConfigurationResponseBodyLevel$inboundSchema,
|
|
494
|
+
title: z.string(),
|
|
495
|
+
message: z.string().optional(),
|
|
496
|
+
href: z.string().optional(),
|
|
497
|
+
});
|
|
498
|
+
|
|
499
|
+
/** @internal */
|
|
500
|
+
export type ResponseBodyNotification$Outbound = {
|
|
501
|
+
level: string;
|
|
502
|
+
title: string;
|
|
503
|
+
message?: string | undefined;
|
|
504
|
+
href?: string | undefined;
|
|
505
|
+
};
|
|
506
|
+
|
|
507
|
+
/** @internal */
|
|
508
|
+
export const ResponseBodyNotification$outboundSchema: z.ZodType<
|
|
509
|
+
ResponseBodyNotification$Outbound,
|
|
510
|
+
z.ZodTypeDef,
|
|
511
|
+
ResponseBodyNotification
|
|
512
|
+
> = z.object({
|
|
513
|
+
level: GetConfigurationResponseBodyLevel$outboundSchema,
|
|
514
|
+
title: z.string(),
|
|
515
|
+
message: z.string().optional(),
|
|
516
|
+
href: z.string().optional(),
|
|
517
|
+
});
|
|
518
|
+
|
|
519
|
+
/**
|
|
520
|
+
* @internal
|
|
521
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
522
|
+
*/
|
|
523
|
+
export namespace ResponseBodyNotification$ {
|
|
524
|
+
/** @deprecated use `ResponseBodyNotification$inboundSchema` instead. */
|
|
525
|
+
export const inboundSchema = ResponseBodyNotification$inboundSchema;
|
|
526
|
+
/** @deprecated use `ResponseBodyNotification$outboundSchema` instead. */
|
|
527
|
+
export const outboundSchema = ResponseBodyNotification$outboundSchema;
|
|
528
|
+
/** @deprecated use `ResponseBodyNotification$Outbound` instead. */
|
|
529
|
+
export type Outbound = ResponseBodyNotification$Outbound;
|
|
530
|
+
}
|
|
531
|
+
|
|
532
|
+
export function responseBodyNotificationToJSON(
|
|
533
|
+
responseBodyNotification: ResponseBodyNotification,
|
|
534
|
+
): string {
|
|
535
|
+
return JSON.stringify(
|
|
536
|
+
ResponseBodyNotification$outboundSchema.parse(responseBodyNotification),
|
|
537
|
+
);
|
|
538
|
+
}
|
|
539
|
+
|
|
540
|
+
export function responseBodyNotificationFromJSON(
|
|
541
|
+
jsonString: string,
|
|
542
|
+
): SafeParseResult<ResponseBodyNotification, SDKValidationError> {
|
|
543
|
+
return safeParse(
|
|
544
|
+
jsonString,
|
|
545
|
+
(x) => ResponseBodyNotification$inboundSchema.parse(JSON.parse(x)),
|
|
546
|
+
`Failed to parse 'ResponseBodyNotification' from JSON`,
|
|
547
|
+
);
|
|
548
|
+
}
|
|
549
|
+
|
|
448
550
|
/** @internal */
|
|
449
551
|
export const TransferRequestKind$inboundSchema: z.ZodNativeEnum<
|
|
450
552
|
typeof TransferRequestKind
|
|
@@ -1043,6 +1145,7 @@ export const GetConfigurationResponseBody2$inboundSchema: z.ZodType<
|
|
|
1043
1145
|
unknown
|
|
1044
1146
|
> = z.object({
|
|
1045
1147
|
projectSelection: ProjectSelection$inboundSchema,
|
|
1148
|
+
notification: z.lazy(() => ResponseBodyNotification$inboundSchema),
|
|
1046
1149
|
transferRequest: z.union([
|
|
1047
1150
|
z.lazy(() => TransferRequest2$inboundSchema),
|
|
1048
1151
|
z.lazy(() => TransferRequest1$inboundSchema),
|
|
@@ -1076,6 +1179,7 @@ export const GetConfigurationResponseBody2$inboundSchema: z.ZodType<
|
|
|
1076
1179
|
/** @internal */
|
|
1077
1180
|
export type GetConfigurationResponseBody2$Outbound = {
|
|
1078
1181
|
projectSelection: string;
|
|
1182
|
+
notification: ResponseBodyNotification$Outbound;
|
|
1079
1183
|
transferRequest: TransferRequest2$Outbound | TransferRequest1$Outbound;
|
|
1080
1184
|
projects?: Array<string> | undefined;
|
|
1081
1185
|
completedAt?: number | undefined;
|
|
@@ -1105,6 +1209,7 @@ export const GetConfigurationResponseBody2$outboundSchema: z.ZodType<
|
|
|
1105
1209
|
GetConfigurationResponseBody2
|
|
1106
1210
|
> = z.object({
|
|
1107
1211
|
projectSelection: ProjectSelection$outboundSchema,
|
|
1212
|
+
notification: z.lazy(() => ResponseBodyNotification$outboundSchema),
|
|
1108
1213
|
transferRequest: z.union([
|
|
1109
1214
|
z.lazy(() => TransferRequest2$outboundSchema),
|
|
1110
1215
|
z.lazy(() => TransferRequest1$outboundSchema),
|
|
@@ -42,10 +42,10 @@ export type GetProjectEnvResponseBodyProjectsResponseTarget =
|
|
|
42
42
|
|
|
43
43
|
export const GetProjectEnvResponseBodyProjectsResponseType = {
|
|
44
44
|
System: "system",
|
|
45
|
-
Secret: "secret",
|
|
46
45
|
Encrypted: "encrypted",
|
|
47
46
|
Plain: "plain",
|
|
48
47
|
Sensitive: "sensitive",
|
|
48
|
+
Secret: "secret",
|
|
49
49
|
} as const;
|
|
50
50
|
export type GetProjectEnvResponseBodyProjectsResponseType = ClosedEnum<
|
|
51
51
|
typeof GetProjectEnvResponseBodyProjectsResponseType
|
|
@@ -388,10 +388,10 @@ export type GetProjectEnvResponseBodyProjectsTarget =
|
|
|
388
388
|
|
|
389
389
|
export const GetProjectEnvResponseBodyProjectsType = {
|
|
390
390
|
System: "system",
|
|
391
|
-
Secret: "secret",
|
|
392
391
|
Encrypted: "encrypted",
|
|
393
392
|
Plain: "plain",
|
|
394
393
|
Sensitive: "sensitive",
|
|
394
|
+
Secret: "secret",
|
|
395
395
|
} as const;
|
|
396
396
|
export type GetProjectEnvResponseBodyProjectsType = ClosedEnum<
|
|
397
397
|
typeof GetProjectEnvResponseBodyProjectsType
|
|
@@ -732,10 +732,10 @@ export type GetProjectEnvResponseBodyTarget =
|
|
|
732
732
|
|
|
733
733
|
export const GetProjectEnvResponseBodyType = {
|
|
734
734
|
System: "system",
|
|
735
|
-
Secret: "secret",
|
|
736
735
|
Encrypted: "encrypted",
|
|
737
736
|
Plain: "plain",
|
|
738
737
|
Sensitive: "sensitive",
|
|
738
|
+
Secret: "secret",
|
|
739
739
|
} as const;
|
|
740
740
|
export type GetProjectEnvResponseBodyType = ClosedEnum<
|
|
741
741
|
typeof GetProjectEnvResponseBodyType
|