@vercel/sdk 1.6.1 → 1.6.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.
Files changed (220) hide show
  1. package/README.md +4 -10
  2. package/bin/mcp-server.js +1579 -2527
  3. package/bin/mcp-server.js.map +29 -38
  4. package/docs/sdks/integrations/README.md +0 -161
  5. package/docs/sdks/logdrains/README.md +0 -260
  6. package/docs/sdks/projects/README.md +162 -0
  7. package/esm/__tests__/integrations.test.js +5 -40
  8. package/esm/__tests__/integrations.test.js.map +1 -1
  9. package/esm/__tests__/logdrains.test.js +7 -89
  10. package/esm/__tests__/logdrains.test.js.map +1 -1
  11. package/esm/__tests__/projects.test.js +41 -13
  12. package/esm/__tests__/projects.test.js.map +1 -1
  13. package/esm/funcs/projectsCreateProject.js +2 -2
  14. package/esm/funcs/projectsCreateProject.js.map +1 -1
  15. package/esm/funcs/projectsPauseProject.d.ts +18 -0
  16. package/esm/funcs/projectsPauseProject.d.ts.map +1 -0
  17. package/esm/funcs/{logDrainsGetConfigurableLogDrain.js → projectsPauseProject.js} +13 -13
  18. package/esm/funcs/projectsPauseProject.js.map +1 -0
  19. package/esm/funcs/projectsUnpauseProject.d.ts +18 -0
  20. package/esm/funcs/projectsUnpauseProject.d.ts.map +1 -0
  21. package/esm/funcs/{logDrainsGetAllLogDrains.js → projectsUnpauseProject.js} +18 -14
  22. package/esm/funcs/projectsUnpauseProject.js.map +1 -0
  23. package/esm/lib/config.d.ts +3 -3
  24. package/esm/lib/config.js +3 -3
  25. package/esm/lib/matchers.d.ts +3 -1
  26. package/esm/lib/matchers.d.ts.map +1 -1
  27. package/esm/lib/matchers.js +10 -0
  28. package/esm/lib/matchers.js.map +1 -1
  29. package/esm/lib/sdks.js +7 -2
  30. package/esm/lib/sdks.js.map +1 -1
  31. package/esm/mcp-server/mcp-server.js +1 -1
  32. package/esm/mcp-server/server.d.ts.map +1 -1
  33. package/esm/mcp-server/server.js +5 -11
  34. package/esm/mcp-server/server.js.map +1 -1
  35. package/esm/mcp-server/tools/projectsPauseProject.d.ts +7 -0
  36. package/esm/mcp-server/tools/projectsPauseProject.d.ts.map +1 -0
  37. package/esm/mcp-server/tools/projectsPauseProject.js +27 -0
  38. package/esm/mcp-server/tools/projectsPauseProject.js.map +1 -0
  39. package/esm/mcp-server/tools/projectsUnpauseProject.d.ts +7 -0
  40. package/esm/mcp-server/tools/projectsUnpauseProject.d.ts.map +1 -0
  41. package/esm/mcp-server/tools/projectsUnpauseProject.js +27 -0
  42. package/esm/mcp-server/tools/projectsUnpauseProject.js.map +1 -0
  43. package/esm/models/authuser.d.ts +41 -0
  44. package/esm/models/authuser.d.ts.map +1 -1
  45. package/esm/models/authuser.js +29 -0
  46. package/esm/models/authuser.js.map +1 -1
  47. package/esm/models/canceldeploymentop.d.ts +3 -3
  48. package/esm/models/canceldeploymentop.js +1 -1
  49. package/esm/models/canceldeploymentop.js.map +1 -1
  50. package/esm/models/createlogdrainop.d.ts +51 -51
  51. package/esm/models/createlogdrainop.d.ts.map +1 -1
  52. package/esm/models/createlogdrainop.js +74 -75
  53. package/esm/models/createlogdrainop.js.map +1 -1
  54. package/esm/models/createprojectop.d.ts +46 -16
  55. package/esm/models/createprojectop.d.ts.map +1 -1
  56. package/esm/models/createprojectop.js +17 -5
  57. package/esm/models/createprojectop.js.map +1 -1
  58. package/esm/models/exchangessotokenop.d.ts +34 -0
  59. package/esm/models/exchangessotokenop.d.ts.map +1 -1
  60. package/esm/models/exchangessotokenop.js +25 -0
  61. package/esm/models/exchangessotokenop.js.map +1 -1
  62. package/esm/models/getconfigurationsop.d.ts +19 -16
  63. package/esm/models/getconfigurationsop.d.ts.map +1 -1
  64. package/esm/models/getconfigurationsop.js +25 -27
  65. package/esm/models/getconfigurationsop.js.map +1 -1
  66. package/esm/models/getcustomenvironmentop.d.ts +3 -0
  67. package/esm/models/getcustomenvironmentop.d.ts.map +1 -1
  68. package/esm/models/getcustomenvironmentop.js.map +1 -1
  69. package/esm/models/getintegrationlogdrainsop.d.ts +11 -11
  70. package/esm/models/getintegrationlogdrainsop.d.ts.map +1 -1
  71. package/esm/models/getintegrationlogdrainsop.js +14 -13
  72. package/esm/models/getintegrationlogdrainsop.js.map +1 -1
  73. package/esm/models/getprojectsop.d.ts +46 -16
  74. package/esm/models/getprojectsop.d.ts.map +1 -1
  75. package/esm/models/getprojectsop.js +17 -5
  76. package/esm/models/getprojectsop.js.map +1 -1
  77. package/esm/models/getteammembersop.d.ts +9 -9
  78. package/esm/models/getteammembersop.js +3 -3
  79. package/esm/models/getteammembersop.js.map +1 -1
  80. package/esm/models/getv9projectsidornamecustomenvironmentsop.d.ts +3 -0
  81. package/esm/models/getv9projectsidornamecustomenvironmentsop.d.ts.map +1 -1
  82. package/esm/models/getv9projectsidornamecustomenvironmentsop.js.map +1 -1
  83. package/esm/models/pauseprojectop.d.ts +42 -0
  84. package/esm/models/pauseprojectop.d.ts.map +1 -0
  85. package/esm/models/pauseprojectop.js +35 -0
  86. package/esm/models/pauseprojectop.js.map +1 -0
  87. package/esm/models/unpauseprojectop.d.ts +42 -0
  88. package/esm/models/unpauseprojectop.d.ts.map +1 -0
  89. package/esm/models/unpauseprojectop.js +35 -0
  90. package/esm/models/unpauseprojectop.js.map +1 -0
  91. package/esm/models/updateprojectdatacacheop.d.ts +46 -16
  92. package/esm/models/updateprojectdatacacheop.d.ts.map +1 -1
  93. package/esm/models/updateprojectdatacacheop.js +17 -5
  94. package/esm/models/updateprojectdatacacheop.js.map +1 -1
  95. package/esm/models/updateprojectop.d.ts +46 -16
  96. package/esm/models/updateprojectop.d.ts.map +1 -1
  97. package/esm/models/updateprojectop.js +17 -5
  98. package/esm/models/updateprojectop.js.map +1 -1
  99. package/esm/models/userevent.d.ts +569 -512
  100. package/esm/models/userevent.d.ts.map +1 -1
  101. package/esm/models/userevent.js +703 -645
  102. package/esm/models/userevent.js.map +1 -1
  103. package/esm/sdk/integrations.d.ts +0 -16
  104. package/esm/sdk/integrations.d.ts.map +1 -1
  105. package/esm/sdk/integrations.js +0 -20
  106. package/esm/sdk/integrations.js.map +1 -1
  107. package/esm/sdk/logdrains.d.ts +0 -24
  108. package/esm/sdk/logdrains.d.ts.map +1 -1
  109. package/esm/sdk/logdrains.js +0 -30
  110. package/esm/sdk/logdrains.js.map +1 -1
  111. package/esm/sdk/projects.d.ts +16 -0
  112. package/esm/sdk/projects.d.ts.map +1 -1
  113. package/esm/sdk/projects.js +20 -0
  114. package/esm/sdk/projects.js.map +1 -1
  115. package/jsr.json +1 -1
  116. package/package.json +1 -1
  117. package/src/__tests__/integrations.test.ts +9 -44
  118. package/src/__tests__/logdrains.test.ts +13 -95
  119. package/src/__tests__/projects.test.ts +47 -13
  120. package/src/funcs/projectsCreateProject.ts +2 -2
  121. package/src/funcs/{integrationsGitNamespaces.ts → projectsPauseProject.ts} +30 -25
  122. package/src/funcs/{logDrainsGetAllLogDrains.ts → projectsUnpauseProject.ts} +27 -24
  123. package/src/lib/config.ts +3 -3
  124. package/src/lib/matchers.ts +20 -0
  125. package/src/lib/sdks.ts +8 -2
  126. package/src/mcp-server/mcp-server.ts +1 -1
  127. package/src/mcp-server/server.ts +5 -11
  128. package/src/mcp-server/tools/projectsPauseProject.ts +35 -0
  129. package/src/mcp-server/tools/projectsUnpauseProject.ts +35 -0
  130. package/src/models/authuser.ts +74 -0
  131. package/src/models/canceldeploymentop.ts +1 -1
  132. package/src/models/createlogdrainop.ts +95 -112
  133. package/src/models/createprojectop.ts +42 -6
  134. package/src/models/exchangessotokenop.ts +44 -0
  135. package/src/models/getconfigurationsop.ts +34 -39
  136. package/src/models/getcustomenvironmentop.ts +3 -0
  137. package/src/models/getintegrationlogdrainsop.ts +15 -20
  138. package/src/models/getprojectsop.ts +42 -6
  139. package/src/models/getteammembersop.ts +3 -3
  140. package/src/models/getv9projectsidornamecustomenvironmentsop.ts +3 -0
  141. package/src/models/pauseprojectop.ts +83 -0
  142. package/src/models/unpauseprojectop.ts +83 -0
  143. package/src/models/updateprojectdatacacheop.ts +42 -6
  144. package/src/models/updateprojectop.ts +42 -6
  145. package/src/models/userevent.ts +1328 -1193
  146. package/src/sdk/integrations.ts +0 -44
  147. package/src/sdk/logdrains.ts +0 -66
  148. package/src/sdk/projects.ts +38 -0
  149. package/vercel-spec.json +616 -1392
  150. package/esm/funcs/integrationsGitNamespaces.d.ts +0 -18
  151. package/esm/funcs/integrationsGitNamespaces.d.ts.map +0 -1
  152. package/esm/funcs/integrationsGitNamespaces.js +0 -86
  153. package/esm/funcs/integrationsGitNamespaces.js.map +0 -1
  154. package/esm/funcs/integrationsSearchRepo.d.ts +0 -17
  155. package/esm/funcs/integrationsSearchRepo.d.ts.map +0 -1
  156. package/esm/funcs/integrationsSearchRepo.js +0 -89
  157. package/esm/funcs/integrationsSearchRepo.js.map +0 -1
  158. package/esm/funcs/logDrainsCreateConfigurableLogDrain.d.ts +0 -18
  159. package/esm/funcs/logDrainsCreateConfigurableLogDrain.d.ts.map +0 -1
  160. package/esm/funcs/logDrainsCreateConfigurableLogDrain.js +0 -86
  161. package/esm/funcs/logDrainsCreateConfigurableLogDrain.js.map +0 -1
  162. package/esm/funcs/logDrainsGetAllLogDrains.d.ts +0 -18
  163. package/esm/funcs/logDrainsGetAllLogDrains.d.ts.map +0 -1
  164. package/esm/funcs/logDrainsGetAllLogDrains.js.map +0 -1
  165. package/esm/funcs/logDrainsGetConfigurableLogDrain.d.ts +0 -19
  166. package/esm/funcs/logDrainsGetConfigurableLogDrain.d.ts.map +0 -1
  167. package/esm/funcs/logDrainsGetConfigurableLogDrain.js.map +0 -1
  168. package/esm/mcp-server/tools/integrationsGitNamespaces.d.ts +0 -7
  169. package/esm/mcp-server/tools/integrationsGitNamespaces.d.ts.map +0 -1
  170. package/esm/mcp-server/tools/integrationsGitNamespaces.js +0 -28
  171. package/esm/mcp-server/tools/integrationsGitNamespaces.js.map +0 -1
  172. package/esm/mcp-server/tools/integrationsSearchRepo.d.ts +0 -7
  173. package/esm/mcp-server/tools/integrationsSearchRepo.d.ts.map +0 -1
  174. package/esm/mcp-server/tools/integrationsSearchRepo.js +0 -28
  175. package/esm/mcp-server/tools/integrationsSearchRepo.js.map +0 -1
  176. package/esm/mcp-server/tools/logDrainsCreateConfigurableLogDrain.d.ts +0 -7
  177. package/esm/mcp-server/tools/logDrainsCreateConfigurableLogDrain.d.ts.map +0 -1
  178. package/esm/mcp-server/tools/logDrainsCreateConfigurableLogDrain.js +0 -28
  179. package/esm/mcp-server/tools/logDrainsCreateConfigurableLogDrain.js.map +0 -1
  180. package/esm/mcp-server/tools/logDrainsGetAllLogDrains.d.ts +0 -7
  181. package/esm/mcp-server/tools/logDrainsGetAllLogDrains.d.ts.map +0 -1
  182. package/esm/mcp-server/tools/logDrainsGetAllLogDrains.js +0 -28
  183. package/esm/mcp-server/tools/logDrainsGetAllLogDrains.js.map +0 -1
  184. package/esm/mcp-server/tools/logDrainsGetConfigurableLogDrain.d.ts +0 -7
  185. package/esm/mcp-server/tools/logDrainsGetConfigurableLogDrain.d.ts.map +0 -1
  186. package/esm/mcp-server/tools/logDrainsGetConfigurableLogDrain.js +0 -28
  187. package/esm/mcp-server/tools/logDrainsGetConfigurableLogDrain.js.map +0 -1
  188. package/esm/models/createconfigurablelogdrainop.d.ts +0 -451
  189. package/esm/models/createconfigurablelogdrainop.d.ts.map +0 -1
  190. package/esm/models/createconfigurablelogdrainop.js +0 -348
  191. package/esm/models/createconfigurablelogdrainop.js.map +0 -1
  192. package/esm/models/getalllogdrainsop.d.ts +0 -294
  193. package/esm/models/getalllogdrainsop.d.ts.map +0 -1
  194. package/esm/models/getalllogdrainsop.js +0 -231
  195. package/esm/models/getalllogdrainsop.js.map +0 -1
  196. package/esm/models/getconfigurablelogdrainop.d.ts +0 -292
  197. package/esm/models/getconfigurablelogdrainop.d.ts.map +0 -1
  198. package/esm/models/getconfigurablelogdrainop.js +0 -230
  199. package/esm/models/getconfigurablelogdrainop.js.map +0 -1
  200. package/esm/models/gitnamespacesop.d.ts +0 -126
  201. package/esm/models/gitnamespacesop.d.ts.map +0 -1
  202. package/esm/models/gitnamespacesop.js +0 -115
  203. package/esm/models/gitnamespacesop.js.map +0 -1
  204. package/esm/models/searchrepoop.d.ts +0 -421
  205. package/esm/models/searchrepoop.d.ts.map +0 -1
  206. package/esm/models/searchrepoop.js +0 -385
  207. package/esm/models/searchrepoop.js.map +0 -1
  208. package/src/funcs/integrationsSearchRepo.ts +0 -181
  209. package/src/funcs/logDrainsCreateConfigurableLogDrain.ts +0 -185
  210. package/src/funcs/logDrainsGetConfigurableLogDrain.ts +0 -199
  211. package/src/mcp-server/tools/integrationsGitNamespaces.ts +0 -37
  212. package/src/mcp-server/tools/integrationsSearchRepo.ts +0 -37
  213. package/src/mcp-server/tools/logDrainsCreateConfigurableLogDrain.ts +0 -39
  214. package/src/mcp-server/tools/logDrainsGetAllLogDrains.ts +0 -37
  215. package/src/mcp-server/tools/logDrainsGetConfigurableLogDrain.ts +0 -39
  216. package/src/models/createconfigurablelogdrainop.ts +0 -652
  217. package/src/models/getalllogdrainsop.ts +0 -416
  218. package/src/models/getconfigurablelogdrainop.ts +0 -420
  219. package/src/models/gitnamespacesop.ts +0 -235
  220. package/src/models/searchrepoop.ts +0 -784
@@ -1,784 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod";
6
- import { safeParse } from "../lib/schemas.js";
7
- import { ClosedEnum } from "../types/enums.js";
8
- import { Result as SafeParseResult } from "../types/fp.js";
9
- import { SDKValidationError } from "./sdkvalidationerror.js";
10
-
11
- export type NamespaceId = string | number;
12
-
13
- export const QueryParamProvider = {
14
- Github: "github",
15
- GithubCustomHost: "github-custom-host",
16
- Gitlab: "gitlab",
17
- Bitbucket: "bitbucket",
18
- } as const;
19
- export type QueryParamProvider = ClosedEnum<typeof QueryParamProvider>;
20
-
21
- export type SearchRepoRequest = {
22
- query?: string | undefined;
23
- namespaceId?: string | number | null | undefined;
24
- provider?: QueryParamProvider | undefined;
25
- installationId?: string | undefined;
26
- /**
27
- * The custom Git host if using a custom Git provider, like GitHub Enterprise Server
28
- */
29
- host?: string | undefined;
30
- /**
31
- * The Team identifier to perform the request on behalf of.
32
- */
33
- teamId?: string | undefined;
34
- /**
35
- * The Team slug to perform the request on behalf of.
36
- */
37
- slug?: string | undefined;
38
- };
39
-
40
- export const ResponseBodyProvider = {
41
- Github: "github",
42
- GithubCustomHost: "github-custom-host",
43
- Gitlab: "gitlab",
44
- Bitbucket: "bitbucket",
45
- } as const;
46
- export type ResponseBodyProvider = ClosedEnum<typeof ResponseBodyProvider>;
47
-
48
- export type ResponseBodyNamespaceId = string | number;
49
-
50
- export type GitAccount = {
51
- provider: ResponseBodyProvider;
52
- namespaceId: string | number | null;
53
- };
54
-
55
- export type ResponseBodyId = string | number;
56
-
57
- export const SearchRepoResponseBodyProvider = {
58
- Github: "github",
59
- GithubCustomHost: "github-custom-host",
60
- Gitlab: "gitlab",
61
- Bitbucket: "bitbucket",
62
- } as const;
63
- export type SearchRepoResponseBodyProvider = ClosedEnum<
64
- typeof SearchRepoResponseBodyProvider
65
- >;
66
-
67
- export type SearchRepoResponseBodyId = string | number;
68
-
69
- export type Owner = {
70
- id: string | number;
71
- name: string;
72
- };
73
-
74
- export const ResponseBodyOwnerType = {
75
- User: "user",
76
- Team: "team",
77
- } as const;
78
- export type ResponseBodyOwnerType = ClosedEnum<typeof ResponseBodyOwnerType>;
79
-
80
- export type Repos = {
81
- id: string | number;
82
- provider: SearchRepoResponseBodyProvider;
83
- url: string;
84
- name: string;
85
- slug: string;
86
- namespace: string;
87
- owner: Owner;
88
- ownerType: ResponseBodyOwnerType;
89
- private: boolean;
90
- defaultBranch: string;
91
- updatedAt: number;
92
- };
93
-
94
- export type SearchRepoResponseBody2 = {
95
- gitAccount: GitAccount;
96
- repos: Array<Repos>;
97
- };
98
-
99
- export type SearchRepoResponseBody1 = {};
100
-
101
- export type SearchRepoResponseBody =
102
- | SearchRepoResponseBody1
103
- | SearchRepoResponseBody2;
104
-
105
- /** @internal */
106
- export const NamespaceId$inboundSchema: z.ZodType<
107
- NamespaceId,
108
- z.ZodTypeDef,
109
- unknown
110
- > = z.union([z.string(), z.number()]);
111
-
112
- /** @internal */
113
- export type NamespaceId$Outbound = string | number;
114
-
115
- /** @internal */
116
- export const NamespaceId$outboundSchema: z.ZodType<
117
- NamespaceId$Outbound,
118
- z.ZodTypeDef,
119
- NamespaceId
120
- > = z.union([z.string(), z.number()]);
121
-
122
- /**
123
- * @internal
124
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
125
- */
126
- export namespace NamespaceId$ {
127
- /** @deprecated use `NamespaceId$inboundSchema` instead. */
128
- export const inboundSchema = NamespaceId$inboundSchema;
129
- /** @deprecated use `NamespaceId$outboundSchema` instead. */
130
- export const outboundSchema = NamespaceId$outboundSchema;
131
- /** @deprecated use `NamespaceId$Outbound` instead. */
132
- export type Outbound = NamespaceId$Outbound;
133
- }
134
-
135
- export function namespaceIdToJSON(namespaceId: NamespaceId): string {
136
- return JSON.stringify(NamespaceId$outboundSchema.parse(namespaceId));
137
- }
138
-
139
- export function namespaceIdFromJSON(
140
- jsonString: string,
141
- ): SafeParseResult<NamespaceId, SDKValidationError> {
142
- return safeParse(
143
- jsonString,
144
- (x) => NamespaceId$inboundSchema.parse(JSON.parse(x)),
145
- `Failed to parse 'NamespaceId' from JSON`,
146
- );
147
- }
148
-
149
- /** @internal */
150
- export const QueryParamProvider$inboundSchema: z.ZodNativeEnum<
151
- typeof QueryParamProvider
152
- > = z.nativeEnum(QueryParamProvider);
153
-
154
- /** @internal */
155
- export const QueryParamProvider$outboundSchema: z.ZodNativeEnum<
156
- typeof QueryParamProvider
157
- > = QueryParamProvider$inboundSchema;
158
-
159
- /**
160
- * @internal
161
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
162
- */
163
- export namespace QueryParamProvider$ {
164
- /** @deprecated use `QueryParamProvider$inboundSchema` instead. */
165
- export const inboundSchema = QueryParamProvider$inboundSchema;
166
- /** @deprecated use `QueryParamProvider$outboundSchema` instead. */
167
- export const outboundSchema = QueryParamProvider$outboundSchema;
168
- }
169
-
170
- /** @internal */
171
- export const SearchRepoRequest$inboundSchema: z.ZodType<
172
- SearchRepoRequest,
173
- z.ZodTypeDef,
174
- unknown
175
- > = z.object({
176
- query: z.string().optional(),
177
- namespaceId: z.nullable(z.union([z.string(), z.number()])).optional(),
178
- provider: QueryParamProvider$inboundSchema.optional(),
179
- installationId: z.string().optional(),
180
- host: z.string().optional(),
181
- teamId: z.string().optional(),
182
- slug: z.string().optional(),
183
- });
184
-
185
- /** @internal */
186
- export type SearchRepoRequest$Outbound = {
187
- query?: string | undefined;
188
- namespaceId?: string | number | null | undefined;
189
- provider?: string | undefined;
190
- installationId?: string | undefined;
191
- host?: string | undefined;
192
- teamId?: string | undefined;
193
- slug?: string | undefined;
194
- };
195
-
196
- /** @internal */
197
- export const SearchRepoRequest$outboundSchema: z.ZodType<
198
- SearchRepoRequest$Outbound,
199
- z.ZodTypeDef,
200
- SearchRepoRequest
201
- > = z.object({
202
- query: z.string().optional(),
203
- namespaceId: z.nullable(z.union([z.string(), z.number()])).optional(),
204
- provider: QueryParamProvider$outboundSchema.optional(),
205
- installationId: z.string().optional(),
206
- host: z.string().optional(),
207
- teamId: z.string().optional(),
208
- slug: z.string().optional(),
209
- });
210
-
211
- /**
212
- * @internal
213
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
214
- */
215
- export namespace SearchRepoRequest$ {
216
- /** @deprecated use `SearchRepoRequest$inboundSchema` instead. */
217
- export const inboundSchema = SearchRepoRequest$inboundSchema;
218
- /** @deprecated use `SearchRepoRequest$outboundSchema` instead. */
219
- export const outboundSchema = SearchRepoRequest$outboundSchema;
220
- /** @deprecated use `SearchRepoRequest$Outbound` instead. */
221
- export type Outbound = SearchRepoRequest$Outbound;
222
- }
223
-
224
- export function searchRepoRequestToJSON(
225
- searchRepoRequest: SearchRepoRequest,
226
- ): string {
227
- return JSON.stringify(
228
- SearchRepoRequest$outboundSchema.parse(searchRepoRequest),
229
- );
230
- }
231
-
232
- export function searchRepoRequestFromJSON(
233
- jsonString: string,
234
- ): SafeParseResult<SearchRepoRequest, SDKValidationError> {
235
- return safeParse(
236
- jsonString,
237
- (x) => SearchRepoRequest$inboundSchema.parse(JSON.parse(x)),
238
- `Failed to parse 'SearchRepoRequest' from JSON`,
239
- );
240
- }
241
-
242
- /** @internal */
243
- export const ResponseBodyProvider$inboundSchema: z.ZodNativeEnum<
244
- typeof ResponseBodyProvider
245
- > = z.nativeEnum(ResponseBodyProvider);
246
-
247
- /** @internal */
248
- export const ResponseBodyProvider$outboundSchema: z.ZodNativeEnum<
249
- typeof ResponseBodyProvider
250
- > = ResponseBodyProvider$inboundSchema;
251
-
252
- /**
253
- * @internal
254
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
255
- */
256
- export namespace ResponseBodyProvider$ {
257
- /** @deprecated use `ResponseBodyProvider$inboundSchema` instead. */
258
- export const inboundSchema = ResponseBodyProvider$inboundSchema;
259
- /** @deprecated use `ResponseBodyProvider$outboundSchema` instead. */
260
- export const outboundSchema = ResponseBodyProvider$outboundSchema;
261
- }
262
-
263
- /** @internal */
264
- export const ResponseBodyNamespaceId$inboundSchema: z.ZodType<
265
- ResponseBodyNamespaceId,
266
- z.ZodTypeDef,
267
- unknown
268
- > = z.union([z.string(), z.number()]);
269
-
270
- /** @internal */
271
- export type ResponseBodyNamespaceId$Outbound = string | number;
272
-
273
- /** @internal */
274
- export const ResponseBodyNamespaceId$outboundSchema: z.ZodType<
275
- ResponseBodyNamespaceId$Outbound,
276
- z.ZodTypeDef,
277
- ResponseBodyNamespaceId
278
- > = z.union([z.string(), z.number()]);
279
-
280
- /**
281
- * @internal
282
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
283
- */
284
- export namespace ResponseBodyNamespaceId$ {
285
- /** @deprecated use `ResponseBodyNamespaceId$inboundSchema` instead. */
286
- export const inboundSchema = ResponseBodyNamespaceId$inboundSchema;
287
- /** @deprecated use `ResponseBodyNamespaceId$outboundSchema` instead. */
288
- export const outboundSchema = ResponseBodyNamespaceId$outboundSchema;
289
- /** @deprecated use `ResponseBodyNamespaceId$Outbound` instead. */
290
- export type Outbound = ResponseBodyNamespaceId$Outbound;
291
- }
292
-
293
- export function responseBodyNamespaceIdToJSON(
294
- responseBodyNamespaceId: ResponseBodyNamespaceId,
295
- ): string {
296
- return JSON.stringify(
297
- ResponseBodyNamespaceId$outboundSchema.parse(responseBodyNamespaceId),
298
- );
299
- }
300
-
301
- export function responseBodyNamespaceIdFromJSON(
302
- jsonString: string,
303
- ): SafeParseResult<ResponseBodyNamespaceId, SDKValidationError> {
304
- return safeParse(
305
- jsonString,
306
- (x) => ResponseBodyNamespaceId$inboundSchema.parse(JSON.parse(x)),
307
- `Failed to parse 'ResponseBodyNamespaceId' from JSON`,
308
- );
309
- }
310
-
311
- /** @internal */
312
- export const GitAccount$inboundSchema: z.ZodType<
313
- GitAccount,
314
- z.ZodTypeDef,
315
- unknown
316
- > = z.object({
317
- provider: ResponseBodyProvider$inboundSchema,
318
- namespaceId: z.nullable(z.union([z.string(), z.number()])),
319
- });
320
-
321
- /** @internal */
322
- export type GitAccount$Outbound = {
323
- provider: string;
324
- namespaceId: string | number | null;
325
- };
326
-
327
- /** @internal */
328
- export const GitAccount$outboundSchema: z.ZodType<
329
- GitAccount$Outbound,
330
- z.ZodTypeDef,
331
- GitAccount
332
- > = z.object({
333
- provider: ResponseBodyProvider$outboundSchema,
334
- namespaceId: z.nullable(z.union([z.string(), z.number()])),
335
- });
336
-
337
- /**
338
- * @internal
339
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
340
- */
341
- export namespace GitAccount$ {
342
- /** @deprecated use `GitAccount$inboundSchema` instead. */
343
- export const inboundSchema = GitAccount$inboundSchema;
344
- /** @deprecated use `GitAccount$outboundSchema` instead. */
345
- export const outboundSchema = GitAccount$outboundSchema;
346
- /** @deprecated use `GitAccount$Outbound` instead. */
347
- export type Outbound = GitAccount$Outbound;
348
- }
349
-
350
- export function gitAccountToJSON(gitAccount: GitAccount): string {
351
- return JSON.stringify(GitAccount$outboundSchema.parse(gitAccount));
352
- }
353
-
354
- export function gitAccountFromJSON(
355
- jsonString: string,
356
- ): SafeParseResult<GitAccount, SDKValidationError> {
357
- return safeParse(
358
- jsonString,
359
- (x) => GitAccount$inboundSchema.parse(JSON.parse(x)),
360
- `Failed to parse 'GitAccount' from JSON`,
361
- );
362
- }
363
-
364
- /** @internal */
365
- export const ResponseBodyId$inboundSchema: z.ZodType<
366
- ResponseBodyId,
367
- z.ZodTypeDef,
368
- unknown
369
- > = z.union([z.string(), z.number()]);
370
-
371
- /** @internal */
372
- export type ResponseBodyId$Outbound = string | number;
373
-
374
- /** @internal */
375
- export const ResponseBodyId$outboundSchema: z.ZodType<
376
- ResponseBodyId$Outbound,
377
- z.ZodTypeDef,
378
- ResponseBodyId
379
- > = z.union([z.string(), z.number()]);
380
-
381
- /**
382
- * @internal
383
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
384
- */
385
- export namespace ResponseBodyId$ {
386
- /** @deprecated use `ResponseBodyId$inboundSchema` instead. */
387
- export const inboundSchema = ResponseBodyId$inboundSchema;
388
- /** @deprecated use `ResponseBodyId$outboundSchema` instead. */
389
- export const outboundSchema = ResponseBodyId$outboundSchema;
390
- /** @deprecated use `ResponseBodyId$Outbound` instead. */
391
- export type Outbound = ResponseBodyId$Outbound;
392
- }
393
-
394
- export function responseBodyIdToJSON(responseBodyId: ResponseBodyId): string {
395
- return JSON.stringify(ResponseBodyId$outboundSchema.parse(responseBodyId));
396
- }
397
-
398
- export function responseBodyIdFromJSON(
399
- jsonString: string,
400
- ): SafeParseResult<ResponseBodyId, SDKValidationError> {
401
- return safeParse(
402
- jsonString,
403
- (x) => ResponseBodyId$inboundSchema.parse(JSON.parse(x)),
404
- `Failed to parse 'ResponseBodyId' from JSON`,
405
- );
406
- }
407
-
408
- /** @internal */
409
- export const SearchRepoResponseBodyProvider$inboundSchema: z.ZodNativeEnum<
410
- typeof SearchRepoResponseBodyProvider
411
- > = z.nativeEnum(SearchRepoResponseBodyProvider);
412
-
413
- /** @internal */
414
- export const SearchRepoResponseBodyProvider$outboundSchema: z.ZodNativeEnum<
415
- typeof SearchRepoResponseBodyProvider
416
- > = SearchRepoResponseBodyProvider$inboundSchema;
417
-
418
- /**
419
- * @internal
420
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
421
- */
422
- export namespace SearchRepoResponseBodyProvider$ {
423
- /** @deprecated use `SearchRepoResponseBodyProvider$inboundSchema` instead. */
424
- export const inboundSchema = SearchRepoResponseBodyProvider$inboundSchema;
425
- /** @deprecated use `SearchRepoResponseBodyProvider$outboundSchema` instead. */
426
- export const outboundSchema = SearchRepoResponseBodyProvider$outboundSchema;
427
- }
428
-
429
- /** @internal */
430
- export const SearchRepoResponseBodyId$inboundSchema: z.ZodType<
431
- SearchRepoResponseBodyId,
432
- z.ZodTypeDef,
433
- unknown
434
- > = z.union([z.string(), z.number()]);
435
-
436
- /** @internal */
437
- export type SearchRepoResponseBodyId$Outbound = string | number;
438
-
439
- /** @internal */
440
- export const SearchRepoResponseBodyId$outboundSchema: z.ZodType<
441
- SearchRepoResponseBodyId$Outbound,
442
- z.ZodTypeDef,
443
- SearchRepoResponseBodyId
444
- > = z.union([z.string(), z.number()]);
445
-
446
- /**
447
- * @internal
448
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
449
- */
450
- export namespace SearchRepoResponseBodyId$ {
451
- /** @deprecated use `SearchRepoResponseBodyId$inboundSchema` instead. */
452
- export const inboundSchema = SearchRepoResponseBodyId$inboundSchema;
453
- /** @deprecated use `SearchRepoResponseBodyId$outboundSchema` instead. */
454
- export const outboundSchema = SearchRepoResponseBodyId$outboundSchema;
455
- /** @deprecated use `SearchRepoResponseBodyId$Outbound` instead. */
456
- export type Outbound = SearchRepoResponseBodyId$Outbound;
457
- }
458
-
459
- export function searchRepoResponseBodyIdToJSON(
460
- searchRepoResponseBodyId: SearchRepoResponseBodyId,
461
- ): string {
462
- return JSON.stringify(
463
- SearchRepoResponseBodyId$outboundSchema.parse(searchRepoResponseBodyId),
464
- );
465
- }
466
-
467
- export function searchRepoResponseBodyIdFromJSON(
468
- jsonString: string,
469
- ): SafeParseResult<SearchRepoResponseBodyId, SDKValidationError> {
470
- return safeParse(
471
- jsonString,
472
- (x) => SearchRepoResponseBodyId$inboundSchema.parse(JSON.parse(x)),
473
- `Failed to parse 'SearchRepoResponseBodyId' from JSON`,
474
- );
475
- }
476
-
477
- /** @internal */
478
- export const Owner$inboundSchema: z.ZodType<Owner, z.ZodTypeDef, unknown> = z
479
- .object({
480
- id: z.union([z.string(), z.number()]),
481
- name: z.string(),
482
- });
483
-
484
- /** @internal */
485
- export type Owner$Outbound = {
486
- id: string | number;
487
- name: string;
488
- };
489
-
490
- /** @internal */
491
- export const Owner$outboundSchema: z.ZodType<
492
- Owner$Outbound,
493
- z.ZodTypeDef,
494
- Owner
495
- > = z.object({
496
- id: z.union([z.string(), z.number()]),
497
- name: z.string(),
498
- });
499
-
500
- /**
501
- * @internal
502
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
503
- */
504
- export namespace Owner$ {
505
- /** @deprecated use `Owner$inboundSchema` instead. */
506
- export const inboundSchema = Owner$inboundSchema;
507
- /** @deprecated use `Owner$outboundSchema` instead. */
508
- export const outboundSchema = Owner$outboundSchema;
509
- /** @deprecated use `Owner$Outbound` instead. */
510
- export type Outbound = Owner$Outbound;
511
- }
512
-
513
- export function ownerToJSON(owner: Owner): string {
514
- return JSON.stringify(Owner$outboundSchema.parse(owner));
515
- }
516
-
517
- export function ownerFromJSON(
518
- jsonString: string,
519
- ): SafeParseResult<Owner, SDKValidationError> {
520
- return safeParse(
521
- jsonString,
522
- (x) => Owner$inboundSchema.parse(JSON.parse(x)),
523
- `Failed to parse 'Owner' from JSON`,
524
- );
525
- }
526
-
527
- /** @internal */
528
- export const ResponseBodyOwnerType$inboundSchema: z.ZodNativeEnum<
529
- typeof ResponseBodyOwnerType
530
- > = z.nativeEnum(ResponseBodyOwnerType);
531
-
532
- /** @internal */
533
- export const ResponseBodyOwnerType$outboundSchema: z.ZodNativeEnum<
534
- typeof ResponseBodyOwnerType
535
- > = ResponseBodyOwnerType$inboundSchema;
536
-
537
- /**
538
- * @internal
539
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
540
- */
541
- export namespace ResponseBodyOwnerType$ {
542
- /** @deprecated use `ResponseBodyOwnerType$inboundSchema` instead. */
543
- export const inboundSchema = ResponseBodyOwnerType$inboundSchema;
544
- /** @deprecated use `ResponseBodyOwnerType$outboundSchema` instead. */
545
- export const outboundSchema = ResponseBodyOwnerType$outboundSchema;
546
- }
547
-
548
- /** @internal */
549
- export const Repos$inboundSchema: z.ZodType<Repos, z.ZodTypeDef, unknown> = z
550
- .object({
551
- id: z.union([z.string(), z.number()]),
552
- provider: SearchRepoResponseBodyProvider$inboundSchema,
553
- url: z.string(),
554
- name: z.string(),
555
- slug: z.string(),
556
- namespace: z.string(),
557
- owner: z.lazy(() => Owner$inboundSchema),
558
- ownerType: ResponseBodyOwnerType$inboundSchema,
559
- private: z.boolean(),
560
- defaultBranch: z.string(),
561
- updatedAt: z.number(),
562
- });
563
-
564
- /** @internal */
565
- export type Repos$Outbound = {
566
- id: string | number;
567
- provider: string;
568
- url: string;
569
- name: string;
570
- slug: string;
571
- namespace: string;
572
- owner: Owner$Outbound;
573
- ownerType: string;
574
- private: boolean;
575
- defaultBranch: string;
576
- updatedAt: number;
577
- };
578
-
579
- /** @internal */
580
- export const Repos$outboundSchema: z.ZodType<
581
- Repos$Outbound,
582
- z.ZodTypeDef,
583
- Repos
584
- > = z.object({
585
- id: z.union([z.string(), z.number()]),
586
- provider: SearchRepoResponseBodyProvider$outboundSchema,
587
- url: z.string(),
588
- name: z.string(),
589
- slug: z.string(),
590
- namespace: z.string(),
591
- owner: z.lazy(() => Owner$outboundSchema),
592
- ownerType: ResponseBodyOwnerType$outboundSchema,
593
- private: z.boolean(),
594
- defaultBranch: z.string(),
595
- updatedAt: z.number(),
596
- });
597
-
598
- /**
599
- * @internal
600
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
601
- */
602
- export namespace Repos$ {
603
- /** @deprecated use `Repos$inboundSchema` instead. */
604
- export const inboundSchema = Repos$inboundSchema;
605
- /** @deprecated use `Repos$outboundSchema` instead. */
606
- export const outboundSchema = Repos$outboundSchema;
607
- /** @deprecated use `Repos$Outbound` instead. */
608
- export type Outbound = Repos$Outbound;
609
- }
610
-
611
- export function reposToJSON(repos: Repos): string {
612
- return JSON.stringify(Repos$outboundSchema.parse(repos));
613
- }
614
-
615
- export function reposFromJSON(
616
- jsonString: string,
617
- ): SafeParseResult<Repos, SDKValidationError> {
618
- return safeParse(
619
- jsonString,
620
- (x) => Repos$inboundSchema.parse(JSON.parse(x)),
621
- `Failed to parse 'Repos' from JSON`,
622
- );
623
- }
624
-
625
- /** @internal */
626
- export const SearchRepoResponseBody2$inboundSchema: z.ZodType<
627
- SearchRepoResponseBody2,
628
- z.ZodTypeDef,
629
- unknown
630
- > = z.object({
631
- gitAccount: z.lazy(() => GitAccount$inboundSchema),
632
- repos: z.array(z.lazy(() => Repos$inboundSchema)),
633
- });
634
-
635
- /** @internal */
636
- export type SearchRepoResponseBody2$Outbound = {
637
- gitAccount: GitAccount$Outbound;
638
- repos: Array<Repos$Outbound>;
639
- };
640
-
641
- /** @internal */
642
- export const SearchRepoResponseBody2$outboundSchema: z.ZodType<
643
- SearchRepoResponseBody2$Outbound,
644
- z.ZodTypeDef,
645
- SearchRepoResponseBody2
646
- > = z.object({
647
- gitAccount: z.lazy(() => GitAccount$outboundSchema),
648
- repos: z.array(z.lazy(() => Repos$outboundSchema)),
649
- });
650
-
651
- /**
652
- * @internal
653
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
654
- */
655
- export namespace SearchRepoResponseBody2$ {
656
- /** @deprecated use `SearchRepoResponseBody2$inboundSchema` instead. */
657
- export const inboundSchema = SearchRepoResponseBody2$inboundSchema;
658
- /** @deprecated use `SearchRepoResponseBody2$outboundSchema` instead. */
659
- export const outboundSchema = SearchRepoResponseBody2$outboundSchema;
660
- /** @deprecated use `SearchRepoResponseBody2$Outbound` instead. */
661
- export type Outbound = SearchRepoResponseBody2$Outbound;
662
- }
663
-
664
- export function searchRepoResponseBody2ToJSON(
665
- searchRepoResponseBody2: SearchRepoResponseBody2,
666
- ): string {
667
- return JSON.stringify(
668
- SearchRepoResponseBody2$outboundSchema.parse(searchRepoResponseBody2),
669
- );
670
- }
671
-
672
- export function searchRepoResponseBody2FromJSON(
673
- jsonString: string,
674
- ): SafeParseResult<SearchRepoResponseBody2, SDKValidationError> {
675
- return safeParse(
676
- jsonString,
677
- (x) => SearchRepoResponseBody2$inboundSchema.parse(JSON.parse(x)),
678
- `Failed to parse 'SearchRepoResponseBody2' from JSON`,
679
- );
680
- }
681
-
682
- /** @internal */
683
- export const SearchRepoResponseBody1$inboundSchema: z.ZodType<
684
- SearchRepoResponseBody1,
685
- z.ZodTypeDef,
686
- unknown
687
- > = z.object({});
688
-
689
- /** @internal */
690
- export type SearchRepoResponseBody1$Outbound = {};
691
-
692
- /** @internal */
693
- export const SearchRepoResponseBody1$outboundSchema: z.ZodType<
694
- SearchRepoResponseBody1$Outbound,
695
- z.ZodTypeDef,
696
- SearchRepoResponseBody1
697
- > = z.object({});
698
-
699
- /**
700
- * @internal
701
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
702
- */
703
- export namespace SearchRepoResponseBody1$ {
704
- /** @deprecated use `SearchRepoResponseBody1$inboundSchema` instead. */
705
- export const inboundSchema = SearchRepoResponseBody1$inboundSchema;
706
- /** @deprecated use `SearchRepoResponseBody1$outboundSchema` instead. */
707
- export const outboundSchema = SearchRepoResponseBody1$outboundSchema;
708
- /** @deprecated use `SearchRepoResponseBody1$Outbound` instead. */
709
- export type Outbound = SearchRepoResponseBody1$Outbound;
710
- }
711
-
712
- export function searchRepoResponseBody1ToJSON(
713
- searchRepoResponseBody1: SearchRepoResponseBody1,
714
- ): string {
715
- return JSON.stringify(
716
- SearchRepoResponseBody1$outboundSchema.parse(searchRepoResponseBody1),
717
- );
718
- }
719
-
720
- export function searchRepoResponseBody1FromJSON(
721
- jsonString: string,
722
- ): SafeParseResult<SearchRepoResponseBody1, SDKValidationError> {
723
- return safeParse(
724
- jsonString,
725
- (x) => SearchRepoResponseBody1$inboundSchema.parse(JSON.parse(x)),
726
- `Failed to parse 'SearchRepoResponseBody1' from JSON`,
727
- );
728
- }
729
-
730
- /** @internal */
731
- export const SearchRepoResponseBody$inboundSchema: z.ZodType<
732
- SearchRepoResponseBody,
733
- z.ZodTypeDef,
734
- unknown
735
- > = z.union([
736
- z.lazy(() => SearchRepoResponseBody1$inboundSchema),
737
- z.lazy(() => SearchRepoResponseBody2$inboundSchema),
738
- ]);
739
-
740
- /** @internal */
741
- export type SearchRepoResponseBody$Outbound =
742
- | SearchRepoResponseBody1$Outbound
743
- | SearchRepoResponseBody2$Outbound;
744
-
745
- /** @internal */
746
- export const SearchRepoResponseBody$outboundSchema: z.ZodType<
747
- SearchRepoResponseBody$Outbound,
748
- z.ZodTypeDef,
749
- SearchRepoResponseBody
750
- > = z.union([
751
- z.lazy(() => SearchRepoResponseBody1$outboundSchema),
752
- z.lazy(() => SearchRepoResponseBody2$outboundSchema),
753
- ]);
754
-
755
- /**
756
- * @internal
757
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
758
- */
759
- export namespace SearchRepoResponseBody$ {
760
- /** @deprecated use `SearchRepoResponseBody$inboundSchema` instead. */
761
- export const inboundSchema = SearchRepoResponseBody$inboundSchema;
762
- /** @deprecated use `SearchRepoResponseBody$outboundSchema` instead. */
763
- export const outboundSchema = SearchRepoResponseBody$outboundSchema;
764
- /** @deprecated use `SearchRepoResponseBody$Outbound` instead. */
765
- export type Outbound = SearchRepoResponseBody$Outbound;
766
- }
767
-
768
- export function searchRepoResponseBodyToJSON(
769
- searchRepoResponseBody: SearchRepoResponseBody,
770
- ): string {
771
- return JSON.stringify(
772
- SearchRepoResponseBody$outboundSchema.parse(searchRepoResponseBody),
773
- );
774
- }
775
-
776
- export function searchRepoResponseBodyFromJSON(
777
- jsonString: string,
778
- ): SafeParseResult<SearchRepoResponseBody, SDKValidationError> {
779
- return safeParse(
780
- jsonString,
781
- (x) => SearchRepoResponseBody$inboundSchema.parse(JSON.parse(x)),
782
- `Failed to parse 'SearchRepoResponseBody' from JSON`,
783
- );
784
- }