@fern-api/fdr-sdk 1.2.53-df48a7112c → 1.2.54-228fd283a3

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/dist/client/docs-types/latest.d.ts +9 -9
  2. package/dist/client/docs-types/latest.d.ts.map +1 -1
  3. package/dist/client/docs-types/latest.js +1 -1
  4. package/dist/client/docs-types/latest.js.map +1 -1
  5. package/dist/js/client/FdrClient.js +1455 -1495
  6. package/dist/js/client/FdrClient.js.map +1 -1
  7. package/dist/js/client/FdrClient.mjs +1455 -1495
  8. package/dist/js/client/FdrClient.mjs.map +1 -1
  9. package/dist/js/client/types.js +1 -1
  10. package/dist/js/client/types.js.map +1 -1
  11. package/dist/js/client/types.mjs +1 -1
  12. package/dist/js/client/types.mjs.map +1 -1
  13. package/dist/js/converters/index.js +303 -301
  14. package/dist/js/converters/index.js.map +1 -1
  15. package/dist/js/converters/index.mjs +303 -301
  16. package/dist/js/converters/index.mjs.map +1 -1
  17. package/dist/js/docs/index.js +1 -1
  18. package/dist/js/docs/index.js.map +1 -1
  19. package/dist/js/docs/index.mjs +1 -1
  20. package/dist/js/docs/index.mjs.map +1 -1
  21. package/dist/js/index.js +1784 -1824
  22. package/dist/js/index.js.map +1 -1
  23. package/dist/js/index.mjs +1783 -1823
  24. package/dist/js/index.mjs.map +1 -1
  25. package/dist/js/navigation/index.js +303 -301
  26. package/dist/js/navigation/index.js.map +1 -1
  27. package/dist/js/navigation/index.mjs +303 -301
  28. package/dist/js/navigation/index.mjs.map +1 -1
  29. package/dist/js/orpc-client.js +1506 -1507
  30. package/dist/js/orpc-client.js.map +1 -1
  31. package/dist/js/orpc-client.mjs +1514 -1515
  32. package/dist/js/orpc-client.mjs.map +1 -1
  33. package/dist/orpc-client/docs/client.d.ts +0 -2
  34. package/dist/orpc-client/docs/client.d.ts.map +1 -1
  35. package/dist/orpc-client/docs/client.js +1 -3
  36. package/dist/orpc-client/docs/client.js.map +1 -1
  37. package/dist/orpc-client/docs/v2/write/contract.d.ts +6 -6
  38. package/dist/orpc-client/docs/v2/write/contract.d.ts.map +1 -1
  39. package/dist/tsconfig.tsbuildinfo +1 -1
  40. package/dist/types/client/docs-types/latest.d.ts +9 -9
  41. package/dist/types/client/docs-types/latest.d.ts.map +1 -1
  42. package/dist/types/orpc-client/docs/client.d.ts +0 -2
  43. package/dist/types/orpc-client/docs/client.d.ts.map +1 -1
  44. package/dist/types/orpc-client/docs/v2/write/contract.d.ts +6 -6
  45. package/dist/types/orpc-client/docs/v2/write/contract.d.ts.map +1 -1
  46. package/package.json +1 -1
@@ -2949,225 +2949,440 @@ function createDocsV1ReadClient(options) {
2949
2949
  return createORPCClient3(link);
2950
2950
  }
2951
2951
 
2952
- // src/orpc-client/docs/v1/write/client.ts
2952
+ // src/orpc-client/docs/v2/library-docs/client.ts
2953
2953
  import { createORPCClient as createORPCClient4 } from "@orpc/client";
2954
2954
  import { OpenAPILink as OpenAPILink4 } from "@orpc/openapi-client/fetch";
2955
2955
 
2956
- // src/orpc-client/docs/v1/write/contract.ts
2956
+ // src/orpc-client/docs/v2/library-docs/contract.ts
2957
2957
  import { oc as oc5 } from "@orpc/contract";
2958
+ import * as z14 from "zod";
2959
+ var ALLOWED_HOSTNAMES = /* @__PURE__ */ new Set(["github.com", "gitlab.com"]);
2960
+ var GithubUrlSchema = z14.string().url().describe(
2961
+ "HTTPS URL of a GitHub or GitLab repository. Currently only github.com and gitlab.com are supported. Must match the pattern https://github.com/<owner>/<repo> or https://gitlab.com/<owner>/<repo>."
2962
+ ).refine(
2963
+ (url) => {
2964
+ try {
2965
+ const parsed = new URL(url);
2966
+ if (parsed.protocol !== "https:") {
2967
+ return false;
2968
+ }
2969
+ if (!ALLOWED_HOSTNAMES.has(parsed.hostname)) {
2970
+ return false;
2971
+ }
2972
+ if (parsed.username || parsed.password) {
2973
+ return false;
2974
+ }
2975
+ return /^\/[\w.-]+\/[\w.-]+(?:\.git)?\/?$/.test(parsed.pathname);
2976
+ } catch {
2977
+ return false;
2978
+ }
2979
+ },
2980
+ { message: "Must be a valid https://github.com/<owner>/<repo> or https://gitlab.com/<owner>/<repo> URL" }
2981
+ );
2982
+ var SafeBranchSchema = z14.string().regex(/^[a-zA-Z0-9._/-]+$/, "Invalid branch name").nullish();
2983
+ var SafePackagePathSchema = z14.string().refine((p) => !p.includes("..") && !p.startsWith("/"), {
2984
+ message: "packagePath must not contain path traversal sequences"
2985
+ }).nullish();
2986
+ var LibraryDocsBaseConfigSchema = z14.object({
2987
+ branch: SafeBranchSchema,
2988
+ packagePath: SafePackagePathSchema,
2989
+ title: z14.string().nullish(),
2990
+ slug: z14.string().nullish()
2991
+ });
2992
+ var PythonLibraryDocsConfigSchema = LibraryDocsBaseConfigSchema;
2993
+ var CppLibraryDocsConfigSchema = LibraryDocsBaseConfigSchema.extend({
2994
+ doxyfileContent: z14.string().nullish()
2995
+ });
2996
+ var StartLibraryDocsGenerationInputSchema = z14.discriminatedUnion("language", [
2997
+ z14.object({
2998
+ orgId: z14.string(),
2999
+ githubUrl: GithubUrlSchema,
3000
+ language: z14.literal("PYTHON"),
3001
+ config: PythonLibraryDocsConfigSchema.nullish()
3002
+ }),
3003
+ z14.object({
3004
+ orgId: z14.string(),
3005
+ githubUrl: GithubUrlSchema,
3006
+ language: z14.literal("CPP"),
3007
+ config: CppLibraryDocsConfigSchema.nullish()
3008
+ })
3009
+ ]);
3010
+ var StartLibraryDocsGenerationResponseSchema = z14.object({
3011
+ jobId: z14.string()
3012
+ });
3013
+ var GetLibraryDocsStatusInputSchema = z14.object({
3014
+ jobId: z14.string()
3015
+ });
3016
+ var LibraryDocsResultSchema = z14.object({
3017
+ jobId: z14.string(),
3018
+ resultUrl: z14.string()
3019
+ });
3020
+ var LibraryDocsGenerationStatusSchema = z14.object({
3021
+ jobId: z14.string(),
3022
+ status: z14.string(),
3023
+ progress: z14.string(),
3024
+ error: z14.object({
3025
+ code: z14.string(),
3026
+ message: z14.string()
3027
+ }).optional(),
3028
+ createdAt: z14.string(),
3029
+ updatedAt: z14.string()
3030
+ });
3031
+ var libraryDocsContract = {
3032
+ startLibraryDocsGeneration: oc5.route({ method: "POST", path: "/library-docs/generate" }).input(StartLibraryDocsGenerationInputSchema).output(StartLibraryDocsGenerationResponseSchema),
3033
+ getLibraryDocsGenerationStatus: oc5.route({ method: "GET", path: "/library-docs/status/{jobId}" }).input(GetLibraryDocsStatusInputSchema).output(LibraryDocsGenerationStatusSchema),
3034
+ getLibraryDocsResult: oc5.route({ method: "GET", path: "/library-docs/result/{jobId}" }).input(GetLibraryDocsStatusInputSchema).output(LibraryDocsResultSchema)
3035
+ };
3036
+
3037
+ // src/orpc-client/docs/v2/library-docs/client.ts
3038
+ function createLibraryDocsClient(options) {
3039
+ const link = new OpenAPILink4(libraryDocsContract, {
3040
+ url: `${options.baseUrl}/v2/registry/docs`,
3041
+ headers: () => ({
3042
+ Authorization: `Bearer ${options.token}`,
3043
+ ...options.headers
3044
+ }),
3045
+ ...options.fetch != null ? { fetch: options.fetch } : {}
3046
+ });
3047
+ return createORPCClient4(link);
3048
+ }
3049
+
3050
+ // src/orpc-client/docs/v2/organization/client.ts
3051
+ import { createORPCClient as createORPCClient5 } from "@orpc/client";
3052
+ import { OpenAPILink as OpenAPILink5 } from "@orpc/openapi-client/fetch";
3053
+
3054
+ // src/orpc-client/docs/v2/organization/contract.ts
3055
+ import { oc as oc6 } from "@orpc/contract";
3056
+ import * as z15 from "zod";
3057
+ var GetOrganizationForUrlInputSchema = z15.object({
3058
+ url: z15.string()
3059
+ });
3060
+ var organizationContract = {
3061
+ getOrganizationForUrl: oc6.route({ method: "POST", path: "/organization-for-url" }).input(GetOrganizationForUrlInputSchema).output(z15.string())
3062
+ };
3063
+
3064
+ // src/orpc-client/docs/v2/organization/client.ts
3065
+ function createOrganizationClient(options) {
3066
+ const link = new OpenAPILink5(organizationContract, {
3067
+ url: `${options.baseUrl}/v2/registry/docs`,
3068
+ headers: () => ({
3069
+ Authorization: `Bearer ${options.token}`,
3070
+ ...options.headers
3071
+ }),
3072
+ ...options.fetch != null ? { fetch: options.fetch } : {}
3073
+ });
3074
+ return createORPCClient5(link);
3075
+ }
3076
+
3077
+ // src/orpc-client/docs/v2/read/client.ts
3078
+ import { createORPCClient as createORPCClient6 } from "@orpc/client";
3079
+ import { OpenAPILink as OpenAPILink6 } from "@orpc/openapi-client/fetch";
3080
+
3081
+ // src/orpc-client/docs/v2/read/contract.ts
3082
+ import { oc as oc7 } from "@orpc/contract";
2958
3083
  import * as z16 from "zod";
3084
+ var GetDocsUrlMetadataInputSchema = z16.object({
3085
+ url: z16.string()
3086
+ });
3087
+ var GetDocsUrlMetadataResponseSchema = z16.object({
3088
+ isPreviewUrl: z16.boolean(),
3089
+ org: z16.string(),
3090
+ url: z16.string(),
3091
+ gitUrl: z16.string().nullish(),
3092
+ enableAlgoliaOnPreview: z16.boolean().nullish()
3093
+ });
3094
+ var GetDocsForUrlInputSchema = z16.object({
3095
+ url: z16.string(),
3096
+ excludeApis: z16.boolean().nullish()
3097
+ });
3098
+ var GetPrivateDocsForUrlInputSchema = z16.object({
3099
+ url: z16.string()
3100
+ });
3101
+ var ListAllDocsUrlsInputSchema = z16.object({
3102
+ limit: z16.number().nullish(),
3103
+ page: z16.number().nullish(),
3104
+ custom: z16.boolean().nullish(),
3105
+ preview: z16.boolean().nullish()
3106
+ });
3107
+ var GetDocsConfigByIdInputSchema = z16.object({
3108
+ docsConfigId: z16.string()
3109
+ });
3110
+ var DocsDefinitionField = {
3111
+ BaseUrl: "BASE_URL",
3112
+ FilesV2: "FILES_V2",
3113
+ ApisV2: "APIS_V2",
3114
+ Apis: "APIS",
3115
+ Pages: "PAGES",
3116
+ JsFiles: "JS_FILES",
3117
+ Config: "CONFIG",
3118
+ Root: "ROOT"
3119
+ };
3120
+ var GetDocsConfigByIdResponseSchema = z16.object({
3121
+ docsConfig: DocsConfigSchema,
3122
+ apis: z16.record(z16.string(), z16.unknown())
3123
+ });
3124
+ var DocsDomainItemSchema = z16.object({
3125
+ domain: z16.string(),
3126
+ basePath: z16.string().optional(),
3127
+ organizationId: z16.string(),
3128
+ updatedAt: z16.string()
3129
+ });
3130
+ var ListAllDocsUrlsResponseSchema = z16.object({
3131
+ urls: z16.array(DocsDomainItemSchema)
3132
+ });
3133
+ var getDocsForUrl;
3134
+ ((getDocsForUrl2) => {
3135
+ let Error;
3136
+ ((Error2) => {
3137
+ function _unknown(fetcherError) {
3138
+ return { error: void 0, content: fetcherError };
3139
+ }
3140
+ Error2._unknown = _unknown;
3141
+ })(Error = getDocsForUrl2.Error || (getDocsForUrl2.Error = {}));
3142
+ })(getDocsForUrl || (getDocsForUrl = {}));
3143
+ var docsV2ReadContract = {
3144
+ getDocsUrlMetadata: oc7.route({ method: "POST", path: "/metadata-for-url" }).input(GetDocsUrlMetadataInputSchema).output(GetDocsUrlMetadataResponseSchema),
3145
+ getDocsForUrl: oc7.route({ method: "POST", path: "/load-with-url" }).input(GetDocsForUrlInputSchema).output(LoadDocsForUrlResponseSchema),
3146
+ getPrivateDocsForUrl: oc7.route({ method: "POST", path: "/private/load-with-url" }).input(GetPrivateDocsForUrlInputSchema).output(LoadDocsForUrlResponseSchema),
3147
+ listAllDocsUrls: oc7.route({ method: "GET", path: "/urls/list" }).input(ListAllDocsUrlsInputSchema).output(ListAllDocsUrlsResponseSchema),
3148
+ getDocsConfigById: oc7.route({ method: "GET", path: "/{docsConfigId}" }).input(GetDocsConfigByIdInputSchema).output(GetDocsConfigByIdResponseSchema),
3149
+ prepopulateFdrReadS3Bucket: oc7.route({ method: "POST", path: "/prepopulate-s3-bucket" }).output(z16.void()),
3150
+ ensureDocsInS3: oc7.route({ method: "POST", path: "/ensure-docs-in-s3" }).output(z16.void()),
3151
+ getDocsFields: oc7.route({ method: "POST", path: "/load-fields" }).output(z16.void())
3152
+ };
3153
+
3154
+ // src/orpc-client/docs/v2/read/client.ts
3155
+ function createDocsV2ReadClient(options) {
3156
+ const link = new OpenAPILink6(docsV2ReadContract, {
3157
+ url: `${options.baseUrl}/v2/registry/docs`,
3158
+ headers: () => ({
3159
+ Authorization: `Bearer ${options.token}`,
3160
+ ...options.headers
3161
+ }),
3162
+ ...options.fetch != null ? { fetch: options.fetch } : {}
3163
+ });
3164
+ return createORPCClient6(link);
3165
+ }
3166
+
3167
+ // src/orpc-client/docs/v2/write/client.ts
3168
+ import { createORPCClient as createORPCClient7 } from "@orpc/client";
3169
+ import { OpenAPILink as OpenAPILink7 } from "@orpc/openapi-client/fetch";
3170
+
3171
+ // src/orpc-client/docs/v2/write/contract.ts
3172
+ import { oc as oc8 } from "@orpc/contract";
3173
+ import * as z19 from "zod";
2959
3174
 
2960
3175
  // src/client/docs-types/write.ts
2961
- import * as z15 from "zod";
3176
+ import * as z18 from "zod";
2962
3177
 
2963
3178
  // src/client/docs-types/write-commons.ts
2964
- import * as z14 from "zod";
2965
- var OrgIdSchema2 = z14.string();
3179
+ import * as z17 from "zod";
3180
+ var OrgIdSchema2 = z17.string();
2966
3181
 
2967
3182
  // src/client/docs-types/write.ts
2968
- var FilePathSchema = z15.string();
2969
- var DocsRegistrationIdSchema = z15.string();
2970
- var HeightSchema2 = z15.number();
2971
- var FileS3UploadUrlSchema = z15.object({
2972
- uploadUrl: z15.string(),
3183
+ var FilePathSchema = z18.string();
3184
+ var DocsRegistrationIdSchema = z18.string();
3185
+ var HeightSchema2 = z18.number();
3186
+ var FileS3UploadUrlSchema = z18.object({
3187
+ uploadUrl: z18.string(),
2973
3188
  fileId: FileIdSchema2
2974
3189
  });
2975
- var StartDocsRegisterResponseSchema = z15.object({
3190
+ var StartDocsRegisterResponseSchema = z18.object({
2976
3191
  docsRegistrationId: DocsRegistrationIdSchema,
2977
- uploadUrls: z15.record(FilePathSchema, FileS3UploadUrlSchema),
2978
- skippedFiles: z15.array(FilePathSchema)
3192
+ uploadUrls: z18.record(FilePathSchema, FileS3UploadUrlSchema),
3193
+ skippedFiles: z18.array(FilePathSchema)
2979
3194
  });
2980
- var PageContentSchema2 = z15.object({
2981
- markdown: z15.string(),
3195
+ var PageContentSchema2 = z18.object({
3196
+ markdown: z18.string(),
2982
3197
  editThisPageUrl: UrlSchema2.optional(),
2983
3198
  editThisPageLaunch: EditThisPageLaunchSchema.optional(),
2984
- rawMarkdown: z15.string().optional()
3199
+ rawMarkdown: z18.string().optional()
2985
3200
  });
2986
- var NavigationNodeMetadataSchema2 = z15.object({
2987
- icon: z15.string().optional(),
2988
- hidden: z15.boolean().optional(),
2989
- urlSlugOverride: z15.string().optional(),
2990
- fullSlug: z15.array(z15.string()).optional()
3201
+ var NavigationNodeMetadataSchema2 = z18.object({
3202
+ icon: z18.string().optional(),
3203
+ hidden: z18.boolean().optional(),
3204
+ urlSlugOverride: z18.string().optional(),
3205
+ fullSlug: z18.array(z18.string()).optional()
2991
3206
  });
2992
- var PageMetadataSchema2 = z15.object({
3207
+ var PageMetadataSchema2 = z18.object({
2993
3208
  ...NavigationNodeMetadataSchema2.shape,
2994
3209
  id: PageIdSchema2,
2995
- title: z15.string()
3210
+ title: z18.string()
2996
3211
  });
2997
- var LinkMetadataSchema2 = z15.object({
2998
- title: z15.string(),
2999
- icon: z15.string().optional(),
3212
+ var LinkMetadataSchema2 = z18.object({
3213
+ title: z18.string(),
3214
+ icon: z18.string().optional(),
3000
3215
  url: UrlSchema2,
3001
3216
  target: LinkTargetSchema.optional()
3002
3217
  });
3003
- var ChangelogItemSchema2 = z15.object({
3004
- date: z15.string(),
3218
+ var ChangelogItemSchema2 = z18.object({
3219
+ date: z18.string(),
3005
3220
  pageId: PageIdSchema2,
3006
- hidden: z15.boolean().optional(),
3007
- tags: z15.array(z15.string()).optional()
3008
- });
3009
- var ChangelogSectionSchema2 = z15.object({
3010
- title: z15.string().optional(),
3011
- icon: z15.string().optional(),
3012
- hidden: z15.boolean().optional(),
3013
- description: z15.string().optional(),
3221
+ hidden: z18.boolean().optional(),
3222
+ tags: z18.array(z18.string()).optional()
3223
+ });
3224
+ var ChangelogSectionSchema2 = z18.object({
3225
+ title: z18.string().optional(),
3226
+ icon: z18.string().optional(),
3227
+ hidden: z18.boolean().optional(),
3228
+ description: z18.string().optional(),
3014
3229
  pageId: PageIdSchema2.optional(),
3015
- items: z15.array(ChangelogItemSchema2),
3016
- urlSlug: z15.string(),
3017
- fullSlug: z15.array(z15.string()).optional()
3230
+ items: z18.array(ChangelogItemSchema2),
3231
+ urlSlug: z18.string(),
3232
+ fullSlug: z18.array(z18.string()).optional()
3018
3233
  });
3019
- var ChangelogSectionV2Schema = z15.object({
3234
+ var ChangelogSectionV2Schema = z18.object({
3020
3235
  ...NavigationNodeMetadataSchema2.shape,
3021
- title: z15.string().optional(),
3022
- description: z15.string().optional(),
3236
+ title: z18.string().optional(),
3237
+ description: z18.string().optional(),
3023
3238
  pageId: PageIdSchema2.optional(),
3024
- items: z15.array(ChangelogItemSchema2)
3239
+ items: z18.array(ChangelogItemSchema2)
3025
3240
  });
3026
- var ChangelogSectionV3Schema2 = z15.object({
3027
- node: z15.unknown()
3241
+ var ChangelogSectionV3Schema2 = z18.object({
3242
+ node: z18.unknown()
3028
3243
  });
3029
- var NavigationTabLinkSchema2 = z15.object({
3030
- title: z15.string(),
3031
- icon: z15.string().optional(),
3244
+ var NavigationTabLinkSchema2 = z18.object({
3245
+ title: z18.string(),
3246
+ icon: z18.string().optional(),
3032
3247
  url: UrlSchema2,
3033
3248
  target: LinkTargetSchema.optional()
3034
3249
  });
3035
- var ApiNavigationConfigItemSchema3 = z15.lazy(
3036
- () => z15.discriminatedUnion("type", [
3037
- z15.object({
3038
- type: z15.literal("subpackage"),
3250
+ var ApiNavigationConfigItemSchema3 = z18.lazy(
3251
+ () => z18.discriminatedUnion("type", [
3252
+ z18.object({
3253
+ type: z18.literal("subpackage"),
3039
3254
  summaryPageId: PageIdSchema2.optional(),
3040
3255
  subpackageId: SubpackageIdSchema2,
3041
- items: z15.array(ApiNavigationConfigItemSchema3)
3256
+ items: z18.array(ApiNavigationConfigItemSchema3)
3042
3257
  }),
3043
- z15.object({ type: z15.literal("endpointId"), value: EndpointIdSchema2 }),
3044
- z15.object({ type: z15.literal("websocketId"), value: WebSocketIdSchema2 }),
3045
- z15.object({ type: z15.literal("webhookId"), value: WebhookIdSchema2 }),
3046
- z15.object({ type: z15.literal("page"), ...PageMetadataSchema2.shape })
3258
+ z18.object({ type: z18.literal("endpointId"), value: EndpointIdSchema2 }),
3259
+ z18.object({ type: z18.literal("websocketId"), value: WebSocketIdSchema2 }),
3260
+ z18.object({ type: z18.literal("webhookId"), value: WebhookIdSchema2 }),
3261
+ z18.object({ type: z18.literal("page"), ...PageMetadataSchema2.shape })
3047
3262
  ])
3048
3263
  );
3049
- var ApiNavigationConfigSubpackageSchema = z15.object({
3264
+ var ApiNavigationConfigSubpackageSchema = z18.object({
3050
3265
  summaryPageId: PageIdSchema2.optional(),
3051
3266
  subpackageId: SubpackageIdSchema2,
3052
- items: z15.array(ApiNavigationConfigItemSchema3)
3267
+ items: z18.array(ApiNavigationConfigItemSchema3)
3053
3268
  });
3054
- var ApiNavigationConfigRootSchema4 = z15.object({
3269
+ var ApiNavigationConfigRootSchema4 = z18.object({
3055
3270
  summaryPageId: PageIdSchema2.optional(),
3056
- items: z15.array(ApiNavigationConfigItemSchema3)
3271
+ items: z18.array(ApiNavigationConfigItemSchema3)
3057
3272
  });
3058
- var ApiSectionSchema2 = z15.object({
3273
+ var ApiSectionSchema2 = z18.object({
3059
3274
  ...NavigationNodeMetadataSchema2.shape,
3060
- title: z15.string(),
3275
+ title: z18.string(),
3061
3276
  api: ApiDefinitionIdSchema2,
3062
- artifacts: z15.object({
3063
- sdks: z15.array(
3064
- z15.discriminatedUnion("type", [
3065
- z15.object({
3066
- type: z15.literal("npm"),
3067
- packageName: z15.string(),
3068
- githubRepoName: z15.string(),
3069
- version: z15.string()
3277
+ artifacts: z18.object({
3278
+ sdks: z18.array(
3279
+ z18.discriminatedUnion("type", [
3280
+ z18.object({
3281
+ type: z18.literal("npm"),
3282
+ packageName: z18.string(),
3283
+ githubRepoName: z18.string(),
3284
+ version: z18.string()
3070
3285
  }),
3071
- z15.object({
3072
- type: z15.literal("maven"),
3073
- coordinate: z15.string(),
3074
- githubRepoName: z15.string(),
3075
- version: z15.string()
3286
+ z18.object({
3287
+ type: z18.literal("maven"),
3288
+ coordinate: z18.string(),
3289
+ githubRepoName: z18.string(),
3290
+ version: z18.string()
3076
3291
  }),
3077
- z15.object({
3078
- type: z15.literal("pypi"),
3079
- packageName: z15.string(),
3080
- githubRepoName: z15.string(),
3081
- version: z15.string()
3292
+ z18.object({
3293
+ type: z18.literal("pypi"),
3294
+ packageName: z18.string(),
3295
+ githubRepoName: z18.string(),
3296
+ version: z18.string()
3082
3297
  })
3083
3298
  ])
3084
3299
  ),
3085
- postman: z15.object({
3300
+ postman: z18.object({
3086
3301
  url: UrlSchema2,
3087
- githubRepoName: z15.string().optional()
3302
+ githubRepoName: z18.string().optional()
3088
3303
  }).optional()
3089
3304
  }).optional(),
3090
- skipUrlSlug: z15.boolean().optional(),
3091
- showErrors: z15.boolean().optional(),
3305
+ skipUrlSlug: z18.boolean().optional(),
3306
+ showErrors: z18.boolean().optional(),
3092
3307
  changelog: ChangelogSectionSchema2.optional(),
3093
3308
  changelogV2: ChangelogSectionV2Schema.optional(),
3094
3309
  navigation: ApiNavigationConfigRootSchema4.optional(),
3095
- longScrolling: z15.boolean().optional(),
3096
- flattened: z15.boolean().optional()
3310
+ longScrolling: z18.boolean().optional(),
3311
+ flattened: z18.boolean().optional()
3097
3312
  });
3098
- var ApiSectionV2Schema2 = z15.object({
3099
- node: z15.unknown()
3313
+ var ApiSectionV2Schema2 = z18.object({
3314
+ node: z18.unknown()
3100
3315
  });
3101
- var DocsSectionSchema2 = z15.lazy(
3102
- () => z15.object({
3316
+ var DocsSectionSchema2 = z18.lazy(
3317
+ () => z18.object({
3103
3318
  ...NavigationNodeMetadataSchema2.shape,
3104
- title: z15.string(),
3105
- items: z15.array(NavigationItemSchema2),
3106
- collapsed: z15.union([z15.boolean(), z15.literal("open-by-default")]).optional(),
3107
- collapsible: z15.boolean().optional(),
3108
- collapsedByDefault: z15.boolean().optional(),
3109
- skipUrlSlug: z15.boolean().optional(),
3319
+ title: z18.string(),
3320
+ items: z18.array(NavigationItemSchema2),
3321
+ collapsed: z18.union([z18.boolean(), z18.literal("open-by-default")]).optional(),
3322
+ collapsible: z18.boolean().optional(),
3323
+ collapsedByDefault: z18.boolean().optional(),
3324
+ skipUrlSlug: z18.boolean().optional(),
3110
3325
  overviewPageId: PageIdSchema2.optional()
3111
3326
  })
3112
3327
  );
3113
- var NavigationItemSchema2 = z15.lazy(
3114
- () => z15.discriminatedUnion("type", [
3115
- z15.object({ type: z15.literal("page"), ...PageMetadataSchema2.shape }),
3116
- z15.object({ type: z15.literal("api"), ...ApiSectionSchema2.shape }),
3117
- z15.object({ type: z15.literal("apiV2"), ...ApiSectionV2Schema2.shape }),
3118
- z15.object({
3119
- type: z15.literal("section"),
3328
+ var NavigationItemSchema2 = z18.lazy(
3329
+ () => z18.discriminatedUnion("type", [
3330
+ z18.object({ type: z18.literal("page"), ...PageMetadataSchema2.shape }),
3331
+ z18.object({ type: z18.literal("api"), ...ApiSectionSchema2.shape }),
3332
+ z18.object({ type: z18.literal("apiV2"), ...ApiSectionV2Schema2.shape }),
3333
+ z18.object({
3334
+ type: z18.literal("section"),
3120
3335
  ...NavigationNodeMetadataSchema2.shape,
3121
- title: z15.string(),
3122
- items: z15.array(NavigationItemSchema2),
3123
- collapsed: z15.union([z15.boolean(), z15.literal("open-by-default")]).optional(),
3124
- collapsible: z15.boolean().optional(),
3125
- collapsedByDefault: z15.boolean().optional(),
3126
- skipUrlSlug: z15.boolean().optional(),
3336
+ title: z18.string(),
3337
+ items: z18.array(NavigationItemSchema2),
3338
+ collapsed: z18.union([z18.boolean(), z18.literal("open-by-default")]).optional(),
3339
+ collapsible: z18.boolean().optional(),
3340
+ collapsedByDefault: z18.boolean().optional(),
3341
+ skipUrlSlug: z18.boolean().optional(),
3127
3342
  overviewPageId: PageIdSchema2.optional()
3128
3343
  }),
3129
- z15.object({ type: z15.literal("link"), ...LinkMetadataSchema2.shape }),
3130
- z15.object({ type: z15.literal("changelog"), ...ChangelogSectionV2Schema.shape }),
3131
- z15.object({ type: z15.literal("changelogV3"), ...ChangelogSectionV3Schema2.shape })
3344
+ z18.object({ type: z18.literal("link"), ...LinkMetadataSchema2.shape }),
3345
+ z18.object({ type: z18.literal("changelog"), ...ChangelogSectionV2Schema.shape }),
3346
+ z18.object({ type: z18.literal("changelogV3"), ...ChangelogSectionV3Schema2.shape })
3132
3347
  ])
3133
3348
  );
3134
- var NavigationTabGroupSchema2 = z15.object({
3349
+ var NavigationTabGroupSchema2 = z18.object({
3135
3350
  ...NavigationNodeMetadataSchema2.shape,
3136
- title: z15.string(),
3137
- items: z15.array(NavigationItemSchema2),
3138
- skipUrlSlug: z15.boolean().optional()
3139
- });
3140
- var NavigationTabSchema2 = z15.union([NavigationTabGroupSchema2, NavigationTabLinkSchema2]);
3141
- var NavigationTabV2Schema = z15.discriminatedUnion("type", [
3142
- z15.object({ type: z15.literal("group"), ...NavigationTabGroupSchema2.shape }),
3143
- z15.object({ type: z15.literal("link"), ...NavigationTabLinkSchema2.shape }),
3144
- z15.object({ type: z15.literal("changelog"), ...ChangelogSectionV2Schema.shape }),
3145
- z15.object({ type: z15.literal("changelogV3"), ...ChangelogSectionV3Schema2.shape })
3351
+ title: z18.string(),
3352
+ items: z18.array(NavigationItemSchema2),
3353
+ skipUrlSlug: z18.boolean().optional()
3354
+ });
3355
+ var NavigationTabSchema2 = z18.union([NavigationTabGroupSchema2, NavigationTabLinkSchema2]);
3356
+ var NavigationTabV2Schema = z18.discriminatedUnion("type", [
3357
+ z18.object({ type: z18.literal("group"), ...NavigationTabGroupSchema2.shape }),
3358
+ z18.object({ type: z18.literal("link"), ...NavigationTabLinkSchema2.shape }),
3359
+ z18.object({ type: z18.literal("changelog"), ...ChangelogSectionV2Schema.shape }),
3360
+ z18.object({ type: z18.literal("changelogV3"), ...ChangelogSectionV3Schema2.shape })
3146
3361
  ]);
3147
- var UnversionedTabbedNavigationConfigSchema2 = z15.object({
3148
- tabs: z15.array(NavigationTabSchema2).optional(),
3149
- tabsV2: z15.array(NavigationTabV2Schema).optional(),
3362
+ var UnversionedTabbedNavigationConfigSchema2 = z18.object({
3363
+ tabs: z18.array(NavigationTabSchema2).optional(),
3364
+ tabsV2: z18.array(NavigationTabV2Schema).optional(),
3150
3365
  landingPage: PageMetadataSchema2.optional()
3151
3366
  });
3152
- var UnversionedUntabbedNavigationConfigSchema2 = z15.object({
3153
- items: z15.array(NavigationItemSchema2),
3367
+ var UnversionedUntabbedNavigationConfigSchema2 = z18.object({
3368
+ items: z18.array(NavigationItemSchema2),
3154
3369
  landingPage: PageMetadataSchema2.optional()
3155
3370
  });
3156
- var UnversionedNavigationConfigSchema2 = z15.union([
3371
+ var UnversionedNavigationConfigSchema2 = z18.union([
3157
3372
  UnversionedTabbedNavigationConfigSchema2,
3158
3373
  UnversionedUntabbedNavigationConfigSchema2
3159
3374
  ]);
3160
- var VersionedNavigationConfigDataSchema2 = z15.object({
3375
+ var VersionedNavigationConfigDataSchema2 = z18.object({
3161
3376
  version: VersionIdSchema2,
3162
- urlSlugOverride: z15.string().optional(),
3377
+ urlSlugOverride: z18.string().optional(),
3163
3378
  availability: AvailabilitySchema2.optional(),
3164
3379
  config: UnversionedNavigationConfigSchema2
3165
3380
  });
3166
- var VersionedNavigationConfigSchema2 = z15.object({
3167
- versions: z15.array(VersionedNavigationConfigDataSchema2)
3381
+ var VersionedNavigationConfigSchema2 = z18.object({
3382
+ versions: z18.array(VersionedNavigationConfigDataSchema2)
3168
3383
  });
3169
- var NavigationConfigSchema2 = z15.union([UnversionedNavigationConfigSchema2, VersionedNavigationConfigSchema2]);
3170
- var ThemeConfigSchema2 = z15.object({
3384
+ var NavigationConfigSchema2 = z18.union([UnversionedNavigationConfigSchema2, VersionedNavigationConfigSchema2]);
3385
+ var ThemeConfigSchema2 = z18.object({
3171
3386
  logo: FileIdSchema2.optional(),
3172
3387
  backgroundImage: FileIdSchema2.optional(),
3173
3388
  accentPrimary: RgbaColorSchema,
@@ -3189,37 +3404,37 @@ var ThemeConfigSchema2 = z15.object({
3189
3404
  accent11: RgbaColorSchema.optional(),
3190
3405
  accent12: RgbaColorSchema.optional()
3191
3406
  });
3192
- var DarkAndLightModeConfigSchema2 = z15.object({
3407
+ var DarkAndLightModeConfigSchema2 = z18.object({
3193
3408
  dark: ThemeConfigSchema2,
3194
3409
  light: ThemeConfigSchema2
3195
3410
  });
3196
- var ColorsConfigV3Schema2 = z15.discriminatedUnion("type", [
3197
- z15.object({ type: z15.literal("dark"), ...ThemeConfigSchema2.shape }),
3198
- z15.object({ type: z15.literal("light"), ...ThemeConfigSchema2.shape }),
3199
- z15.object({ type: z15.literal("darkAndLight"), ...DarkAndLightModeConfigSchema2.shape })
3411
+ var ColorsConfigV3Schema2 = z18.discriminatedUnion("type", [
3412
+ z18.object({ type: z18.literal("dark"), ...ThemeConfigSchema2.shape }),
3413
+ z18.object({ type: z18.literal("light"), ...ThemeConfigSchema2.shape }),
3414
+ z18.object({ type: z18.literal("darkAndLight"), ...DarkAndLightModeConfigSchema2.shape })
3200
3415
  ]);
3201
- var DocsConfigSchema2 = z15.object({
3202
- title: z15.string().optional(),
3416
+ var DocsConfigSchema2 = z18.object({
3417
+ title: z18.string().optional(),
3203
3418
  defaultLanguage: ProgrammingLanguageSchema.optional(),
3204
- languages: z15.array(LanguageSchema).optional(),
3419
+ languages: z18.array(LanguageSchema).optional(),
3205
3420
  translations: DocsTranslationsConfigSchema.optional(),
3206
- announcement: z15.object({ text: z15.string() }).optional(),
3421
+ announcement: z18.object({ text: z18.string() }).optional(),
3207
3422
  navigation: NavigationConfigSchema2.optional(),
3208
- root: z15.custom().optional(),
3209
- navbarLinks: z15.array(NavbarLinkSchema).optional(),
3210
- footerLinks: z15.array(FooterLinkSchema).optional(),
3211
- hideNavLinks: z15.boolean().optional(),
3423
+ root: z18.custom().optional(),
3424
+ navbarLinks: z18.array(NavbarLinkSchema).optional(),
3425
+ footerLinks: z18.array(FooterLinkSchema).optional(),
3426
+ hideNavLinks: z18.boolean().optional(),
3212
3427
  logoHeight: HeightSchema2.optional(),
3213
3428
  logoHref: UrlSchema2.optional(),
3214
- logoRightText: z15.string().optional(),
3429
+ logoRightText: z18.string().optional(),
3215
3430
  favicon: FileIdSchema2.optional(),
3216
3431
  agents: AgentsConfigSchema.optional(),
3217
3432
  metadata: MetadataConfigSchema.optional(),
3218
- redirects: z15.array(RedirectConfigSchema).optional(),
3433
+ redirects: z18.array(RedirectConfigSchema).optional(),
3219
3434
  colorsV3: ColorsConfigV3Schema2.optional(),
3220
3435
  layout: DocsLayoutConfigSchema.optional(),
3221
3436
  theme: DocsThemeConfigSchema.optional(),
3222
- globalTheme: z15.string().optional(),
3437
+ globalTheme: z18.string().optional(),
3223
3438
  settings: DocsSettingsConfigSchema.optional(),
3224
3439
  typographyV2: DocsTypographyConfigV2Schema.optional(),
3225
3440
  analyticsConfig: AnalyticsConfigSchema.optional(),
@@ -3229,419 +3444,165 @@ var DocsConfigSchema2 = z15.object({
3229
3444
  aiChatConfig: AIChatConfigSchema.optional(),
3230
3445
  pageActions: PageActionsConfigSchema.optional(),
3231
3446
  editThisPageLaunch: EditThisPageLaunchSchema.optional(),
3232
- header: z15.string().optional(),
3233
- footer: z15.string().optional(),
3447
+ header: z18.string().optional(),
3448
+ footer: z18.string().optional(),
3234
3449
  backgroundImage: FileIdSchema2.optional(),
3235
- logoV2: ThemedFileIdSchema.optional(),
3236
- logo: FileIdSchema2.optional(),
3237
- colors: ColorsConfigSchema.optional(),
3238
- colorsV2: ColorsConfigV2Schema.optional(),
3239
- typography: DocsTypographyConfigSchema.optional()
3240
- });
3241
- var DocsDefinitionSchema2 = z15.object({
3242
- pages: z15.record(PageIdSchema2, PageContentSchema2),
3243
- config: DocsConfigSchema2,
3244
- jsFiles: z15.record(z15.string(), z15.string()).optional()
3245
- });
3246
- var NpmPackageSchema2 = z15.object({
3247
- packageName: z15.string(),
3248
- githubRepoName: z15.string(),
3249
- version: z15.string()
3250
- });
3251
- var MavenPackageSchema2 = z15.object({
3252
- coordinate: z15.string(),
3253
- githubRepoName: z15.string(),
3254
- version: z15.string()
3255
- });
3256
- var PypiPackageSchema2 = z15.object({
3257
- packageName: z15.string(),
3258
- githubRepoName: z15.string(),
3259
- version: z15.string()
3260
- });
3261
- var PublishedSdkSchema2 = z15.discriminatedUnion("type", [
3262
- z15.object({ type: z15.literal("npm"), ...NpmPackageSchema2.shape }),
3263
- z15.object({ type: z15.literal("maven"), ...MavenPackageSchema2.shape }),
3264
- z15.object({ type: z15.literal("pypi"), ...PypiPackageSchema2.shape })
3265
- ]);
3266
- var PublishedPostmanCollectionSchema2 = z15.object({
3267
- url: UrlSchema2,
3268
- githubRepoName: z15.string().optional()
3269
- });
3270
- var ApiArtifactsSchema2 = z15.object({
3271
- sdks: z15.array(PublishedSdkSchema2),
3272
- postman: PublishedPostmanCollectionSchema2.optional()
3273
- });
3274
- var InvalidCustomDomainErrorBodySchema = z15.object({
3275
- overlappingDomains: z15.array(z15.array(z15.string()))
3276
- });
3277
- var OverlappingCustomDomainsSchema = z15.array(z15.string());
3278
-
3279
- // src/orpc-client/docs/v1/write/contract.ts
3280
- var StartDocsRegisterV1InputSchema = z16.object({
3281
- orgId: z16.string(),
3282
- domain: z16.string(),
3283
- filepaths: z16.array(z16.string())
3284
- });
3285
- var StartDocsRegisterV1ResponseSchema = z16.object({
3286
- docsRegistrationId: z16.string(),
3287
- uploadUrls: z16.record(z16.string(), FileS3UploadUrlSchema),
3288
- skippedFiles: z16.array(z16.string())
3289
- });
3290
- var FinishDocsRegisterV1InputSchema = z16.object({
3291
- docsRegistrationId: z16.string(),
3292
- docsDefinition: z16.unknown()
3293
- });
3294
- var docsV1WriteContract = {
3295
- startDocsRegister: oc5.route({ method: "POST", path: "/init" }).input(StartDocsRegisterV1InputSchema).output(StartDocsRegisterV1ResponseSchema),
3296
- finishDocsRegister: oc5.route({ method: "POST", path: "/register/{docsRegistrationId}" }).input(FinishDocsRegisterV1InputSchema).output(z16.void())
3297
- };
3298
-
3299
- // src/orpc-client/docs/v1/write/client.ts
3300
- function createDocsV1WriteClient(options) {
3301
- const link = new OpenAPILink4(docsV1WriteContract, {
3302
- url: `${options.baseUrl}/registry/docs`,
3303
- headers: () => ({
3304
- Authorization: `Bearer ${options.token}`,
3305
- ...options.headers
3306
- }),
3307
- ...options.fetch != null ? { fetch: options.fetch } : {}
3308
- });
3309
- return createORPCClient4(link);
3310
- }
3311
-
3312
- // src/orpc-client/docs/v2/library-docs/client.ts
3313
- import { createORPCClient as createORPCClient5 } from "@orpc/client";
3314
- import { OpenAPILink as OpenAPILink5 } from "@orpc/openapi-client/fetch";
3315
-
3316
- // src/orpc-client/docs/v2/library-docs/contract.ts
3317
- import { oc as oc6 } from "@orpc/contract";
3318
- import * as z17 from "zod";
3319
- var ALLOWED_HOSTNAMES = /* @__PURE__ */ new Set(["github.com", "gitlab.com"]);
3320
- var GithubUrlSchema = z17.string().url().describe(
3321
- "HTTPS URL of a GitHub or GitLab repository. Currently only github.com and gitlab.com are supported. Must match the pattern https://github.com/<owner>/<repo> or https://gitlab.com/<owner>/<repo>."
3322
- ).refine(
3323
- (url) => {
3324
- try {
3325
- const parsed = new URL(url);
3326
- if (parsed.protocol !== "https:") {
3327
- return false;
3328
- }
3329
- if (!ALLOWED_HOSTNAMES.has(parsed.hostname)) {
3330
- return false;
3331
- }
3332
- if (parsed.username || parsed.password) {
3333
- return false;
3334
- }
3335
- return /^\/[\w.-]+\/[\w.-]+(?:\.git)?\/?$/.test(parsed.pathname);
3336
- } catch {
3337
- return false;
3338
- }
3339
- },
3340
- { message: "Must be a valid https://github.com/<owner>/<repo> or https://gitlab.com/<owner>/<repo> URL" }
3341
- );
3342
- var SafeBranchSchema = z17.string().regex(/^[a-zA-Z0-9._/-]+$/, "Invalid branch name").nullish();
3343
- var SafePackagePathSchema = z17.string().refine((p) => !p.includes("..") && !p.startsWith("/"), {
3344
- message: "packagePath must not contain path traversal sequences"
3345
- }).nullish();
3346
- var LibraryDocsBaseConfigSchema = z17.object({
3347
- branch: SafeBranchSchema,
3348
- packagePath: SafePackagePathSchema,
3349
- title: z17.string().nullish(),
3350
- slug: z17.string().nullish()
3351
- });
3352
- var PythonLibraryDocsConfigSchema = LibraryDocsBaseConfigSchema;
3353
- var CppLibraryDocsConfigSchema = LibraryDocsBaseConfigSchema.extend({
3354
- doxyfileContent: z17.string().nullish()
3355
- });
3356
- var StartLibraryDocsGenerationInputSchema = z17.discriminatedUnion("language", [
3357
- z17.object({
3358
- orgId: z17.string(),
3359
- githubUrl: GithubUrlSchema,
3360
- language: z17.literal("PYTHON"),
3361
- config: PythonLibraryDocsConfigSchema.nullish()
3362
- }),
3363
- z17.object({
3364
- orgId: z17.string(),
3365
- githubUrl: GithubUrlSchema,
3366
- language: z17.literal("CPP"),
3367
- config: CppLibraryDocsConfigSchema.nullish()
3368
- })
3369
- ]);
3370
- var StartLibraryDocsGenerationResponseSchema = z17.object({
3371
- jobId: z17.string()
3372
- });
3373
- var GetLibraryDocsStatusInputSchema = z17.object({
3374
- jobId: z17.string()
3375
- });
3376
- var LibraryDocsResultSchema = z17.object({
3377
- jobId: z17.string(),
3378
- resultUrl: z17.string()
3379
- });
3380
- var LibraryDocsGenerationStatusSchema = z17.object({
3381
- jobId: z17.string(),
3382
- status: z17.string(),
3383
- progress: z17.string(),
3384
- error: z17.object({
3385
- code: z17.string(),
3386
- message: z17.string()
3387
- }).optional(),
3388
- createdAt: z17.string(),
3389
- updatedAt: z17.string()
3390
- });
3391
- var libraryDocsContract = {
3392
- startLibraryDocsGeneration: oc6.route({ method: "POST", path: "/library-docs/generate" }).input(StartLibraryDocsGenerationInputSchema).output(StartLibraryDocsGenerationResponseSchema),
3393
- getLibraryDocsGenerationStatus: oc6.route({ method: "GET", path: "/library-docs/status/{jobId}" }).input(GetLibraryDocsStatusInputSchema).output(LibraryDocsGenerationStatusSchema),
3394
- getLibraryDocsResult: oc6.route({ method: "GET", path: "/library-docs/result/{jobId}" }).input(GetLibraryDocsStatusInputSchema).output(LibraryDocsResultSchema)
3395
- };
3396
-
3397
- // src/orpc-client/docs/v2/library-docs/client.ts
3398
- function createLibraryDocsClient(options) {
3399
- const link = new OpenAPILink5(libraryDocsContract, {
3400
- url: `${options.baseUrl}/v2/registry/docs`,
3401
- headers: () => ({
3402
- Authorization: `Bearer ${options.token}`,
3403
- ...options.headers
3404
- }),
3405
- ...options.fetch != null ? { fetch: options.fetch } : {}
3406
- });
3407
- return createORPCClient5(link);
3408
- }
3409
-
3410
- // src/orpc-client/docs/v2/organization/client.ts
3411
- import { createORPCClient as createORPCClient6 } from "@orpc/client";
3412
- import { OpenAPILink as OpenAPILink6 } from "@orpc/openapi-client/fetch";
3413
-
3414
- // src/orpc-client/docs/v2/organization/contract.ts
3415
- import { oc as oc7 } from "@orpc/contract";
3416
- import * as z18 from "zod";
3417
- var GetOrganizationForUrlInputSchema = z18.object({
3418
- url: z18.string()
3419
- });
3420
- var organizationContract = {
3421
- getOrganizationForUrl: oc7.route({ method: "POST", path: "/organization-for-url" }).input(GetOrganizationForUrlInputSchema).output(z18.string())
3422
- };
3423
-
3424
- // src/orpc-client/docs/v2/organization/client.ts
3425
- function createOrganizationClient(options) {
3426
- const link = new OpenAPILink6(organizationContract, {
3427
- url: `${options.baseUrl}/v2/registry/docs`,
3428
- headers: () => ({
3429
- Authorization: `Bearer ${options.token}`,
3430
- ...options.headers
3431
- }),
3432
- ...options.fetch != null ? { fetch: options.fetch } : {}
3433
- });
3434
- return createORPCClient6(link);
3435
- }
3436
-
3437
- // src/orpc-client/docs/v2/read/client.ts
3438
- import { createORPCClient as createORPCClient7 } from "@orpc/client";
3439
- import { OpenAPILink as OpenAPILink7 } from "@orpc/openapi-client/fetch";
3440
-
3441
- // src/orpc-client/docs/v2/read/contract.ts
3442
- import { oc as oc8 } from "@orpc/contract";
3443
- import * as z19 from "zod";
3444
- var GetDocsUrlMetadataInputSchema = z19.object({
3445
- url: z19.string()
3446
- });
3447
- var GetDocsUrlMetadataResponseSchema = z19.object({
3448
- isPreviewUrl: z19.boolean(),
3449
- org: z19.string(),
3450
- url: z19.string(),
3451
- gitUrl: z19.string().nullish(),
3452
- enableAlgoliaOnPreview: z19.boolean().nullish()
3453
- });
3454
- var GetDocsForUrlInputSchema = z19.object({
3455
- url: z19.string(),
3456
- excludeApis: z19.boolean().nullish()
3457
- });
3458
- var GetPrivateDocsForUrlInputSchema = z19.object({
3459
- url: z19.string()
3460
- });
3461
- var ListAllDocsUrlsInputSchema = z19.object({
3462
- limit: z19.number().nullish(),
3463
- page: z19.number().nullish(),
3464
- custom: z19.boolean().nullish(),
3465
- preview: z19.boolean().nullish()
3466
- });
3467
- var GetDocsConfigByIdInputSchema = z19.object({
3468
- docsConfigId: z19.string()
3469
- });
3470
- var DocsDefinitionField = {
3471
- BaseUrl: "BASE_URL",
3472
- FilesV2: "FILES_V2",
3473
- ApisV2: "APIS_V2",
3474
- Apis: "APIS",
3475
- Pages: "PAGES",
3476
- JsFiles: "JS_FILES",
3477
- Config: "CONFIG",
3478
- Root: "ROOT"
3479
- };
3480
- var GetDocsConfigByIdResponseSchema = z19.object({
3481
- docsConfig: DocsConfigSchema,
3482
- apis: z19.record(z19.string(), z19.unknown())
3450
+ logoV2: ThemedFileIdSchema.optional(),
3451
+ logo: FileIdSchema2.optional(),
3452
+ colors: ColorsConfigSchema.optional(),
3453
+ colorsV2: ColorsConfigV2Schema.optional(),
3454
+ typography: DocsTypographyConfigSchema.optional()
3483
3455
  });
3484
- var DocsDomainItemSchema = z19.object({
3485
- domain: z19.string(),
3486
- basePath: z19.string().optional(),
3487
- organizationId: z19.string(),
3488
- updatedAt: z19.string()
3456
+ var DocsDefinitionSchema2 = z18.object({
3457
+ pages: z18.record(PageIdSchema2, PageContentSchema2),
3458
+ config: DocsConfigSchema2,
3459
+ jsFiles: z18.record(z18.string(), z18.string()).optional()
3460
+ });
3461
+ var NpmPackageSchema2 = z18.object({
3462
+ packageName: z18.string(),
3463
+ githubRepoName: z18.string(),
3464
+ version: z18.string()
3465
+ });
3466
+ var MavenPackageSchema2 = z18.object({
3467
+ coordinate: z18.string(),
3468
+ githubRepoName: z18.string(),
3469
+ version: z18.string()
3470
+ });
3471
+ var PypiPackageSchema2 = z18.object({
3472
+ packageName: z18.string(),
3473
+ githubRepoName: z18.string(),
3474
+ version: z18.string()
3475
+ });
3476
+ var PublishedSdkSchema2 = z18.discriminatedUnion("type", [
3477
+ z18.object({ type: z18.literal("npm"), ...NpmPackageSchema2.shape }),
3478
+ z18.object({ type: z18.literal("maven"), ...MavenPackageSchema2.shape }),
3479
+ z18.object({ type: z18.literal("pypi"), ...PypiPackageSchema2.shape })
3480
+ ]);
3481
+ var PublishedPostmanCollectionSchema2 = z18.object({
3482
+ url: UrlSchema2,
3483
+ githubRepoName: z18.string().optional()
3489
3484
  });
3490
- var ListAllDocsUrlsResponseSchema = z19.object({
3491
- urls: z19.array(DocsDomainItemSchema)
3485
+ var ApiArtifactsSchema2 = z18.object({
3486
+ sdks: z18.array(PublishedSdkSchema2),
3487
+ postman: PublishedPostmanCollectionSchema2.optional()
3492
3488
  });
3493
- var getDocsForUrl;
3494
- ((getDocsForUrl2) => {
3495
- let Error;
3496
- ((Error2) => {
3497
- function _unknown(fetcherError) {
3498
- return { error: void 0, content: fetcherError };
3499
- }
3500
- Error2._unknown = _unknown;
3501
- })(Error = getDocsForUrl2.Error || (getDocsForUrl2.Error = {}));
3502
- })(getDocsForUrl || (getDocsForUrl = {}));
3503
- var docsV2ReadContract = {
3504
- getDocsUrlMetadata: oc8.route({ method: "POST", path: "/metadata-for-url" }).input(GetDocsUrlMetadataInputSchema).output(GetDocsUrlMetadataResponseSchema),
3505
- getDocsForUrl: oc8.route({ method: "POST", path: "/load-with-url" }).input(GetDocsForUrlInputSchema).output(LoadDocsForUrlResponseSchema),
3506
- getPrivateDocsForUrl: oc8.route({ method: "POST", path: "/private/load-with-url" }).input(GetPrivateDocsForUrlInputSchema).output(LoadDocsForUrlResponseSchema),
3507
- listAllDocsUrls: oc8.route({ method: "GET", path: "/urls/list" }).input(ListAllDocsUrlsInputSchema).output(ListAllDocsUrlsResponseSchema),
3508
- getDocsConfigById: oc8.route({ method: "GET", path: "/{docsConfigId}" }).input(GetDocsConfigByIdInputSchema).output(GetDocsConfigByIdResponseSchema),
3509
- prepopulateFdrReadS3Bucket: oc8.route({ method: "POST", path: "/prepopulate-s3-bucket" }).output(z19.void()),
3510
- ensureDocsInS3: oc8.route({ method: "POST", path: "/ensure-docs-in-s3" }).output(z19.void()),
3511
- getDocsFields: oc8.route({ method: "POST", path: "/load-fields" }).output(z19.void())
3512
- };
3513
-
3514
- // src/orpc-client/docs/v2/read/client.ts
3515
- function createDocsV2ReadClient(options) {
3516
- const link = new OpenAPILink7(docsV2ReadContract, {
3517
- url: `${options.baseUrl}/v2/registry/docs`,
3518
- headers: () => ({
3519
- Authorization: `Bearer ${options.token}`,
3520
- ...options.headers
3521
- }),
3522
- ...options.fetch != null ? { fetch: options.fetch } : {}
3523
- });
3524
- return createORPCClient7(link);
3525
- }
3526
-
3527
- // src/orpc-client/docs/v2/write/client.ts
3528
- import { createORPCClient as createORPCClient8 } from "@orpc/client";
3529
- import { OpenAPILink as OpenAPILink8 } from "@orpc/openapi-client/fetch";
3489
+ var InvalidCustomDomainErrorBodySchema = z18.object({
3490
+ overlappingDomains: z18.array(z18.array(z18.string()))
3491
+ });
3492
+ var OverlappingCustomDomainsSchema = z18.array(z18.string());
3530
3493
 
3531
3494
  // src/orpc-client/docs/v2/write/contract.ts
3532
- import { oc as oc9 } from "@orpc/contract";
3533
- import * as z20 from "zod";
3534
- var FilePathSchema2 = z20.string();
3495
+ var FilePathSchema2 = z19.string();
3535
3496
  function FilePath(value) {
3536
3497
  return value;
3537
3498
  }
3538
- var FilePathInputSchema = z20.union([
3499
+ var FilePathInputSchema = z19.union([
3539
3500
  FilePathSchema2,
3540
- z20.object({ path: FilePathSchema2, fileHash: z20.string().nullish() })
3501
+ z19.object({ path: FilePathSchema2, fileHash: z19.string().nullish() })
3541
3502
  ]);
3542
- var ImageFilePathSchema = z20.object({
3503
+ var ImageFilePathSchema = z19.object({
3543
3504
  filePath: FilePathSchema2,
3544
- width: z20.number(),
3545
- height: z20.number(),
3546
- blurDataUrl: z20.string().nullish(),
3547
- alt: z20.string().nullish(),
3548
- fileHash: z20.string().nullish()
3549
- });
3550
- var AuthConfigSchema = z20.object({
3551
- type: z20.string()
3552
- });
3553
- var StartDocsRegisterV2InputSchema = z20.object({
3554
- orgId: z20.string(),
3555
- domain: z20.string(),
3556
- customDomains: z20.array(z20.string()),
3557
- filepaths: z20.array(FilePathInputSchema),
3558
- images: z20.array(ImageFilePathSchema).nullish(),
3559
- authConfig: AuthConfigSchema.nullish()
3505
+ width: z19.number(),
3506
+ height: z19.number(),
3507
+ blurDataUrl: z19.string().nullish(),
3508
+ alt: z19.string().nullish(),
3509
+ fileHash: z19.string().nullish()
3560
3510
  });
3561
- var StartDocsRegisterV2ResponseSchema = z20.object({
3562
- docsRegistrationId: z20.string(),
3563
- uploadUrls: z20.record(z20.string(), FileS3UploadUrlSchema),
3564
- skippedFiles: z20.array(z20.string())
3565
- });
3566
- var StartDocsPreviewRegisterInputSchema = z20.object({
3567
- orgId: z20.string(),
3568
- filepaths: z20.array(FilePathInputSchema),
3569
- basePath: z20.string().nullish(),
3570
- images: z20.array(ImageFilePathSchema).nullish(),
3571
- authConfig: AuthConfigSchema.nullish(),
3572
- previewId: z20.string().nullish()
3511
+ var AuthConfigSchema = z19.object({
3512
+ type: z19.string()
3573
3513
  });
3574
- var StartDocsPreviewRegisterResponseSchema = z20.object({
3575
- docsRegistrationId: z20.string(),
3576
- uploadUrls: z20.record(z20.string(), FileS3UploadUrlSchema),
3577
- skippedFiles: z20.array(z20.string()),
3578
- previewUrl: z20.string()
3514
+ var StartDocsRegisterV2InputSchema = z19.object({
3515
+ orgId: z19.string(),
3516
+ domain: z19.string(),
3517
+ customDomains: z19.array(z19.string()),
3518
+ filepaths: z19.array(FilePathInputSchema),
3519
+ images: z19.array(ImageFilePathSchema).nullish(),
3520
+ authConfig: AuthConfigSchema.nullish()
3579
3521
  });
3580
- var FinishDocsRegisterV2InputSchema = z20.object({
3581
- docsRegistrationId: z20.string(),
3582
- docsDefinition: z20.unknown(),
3583
- libraryDocs: z20.unknown().nullish(),
3584
- excludeApis: z20.boolean().nullish(),
3585
- basepathAware: z20.boolean().nullish()
3522
+ var StartDocsRegisterV2ResponseSchema = z19.object({
3523
+ docsRegistrationId: z19.string(),
3524
+ uploadUrls: z19.record(z19.string(), FileS3UploadUrlSchema),
3525
+ skippedFiles: z19.array(z19.string())
3586
3526
  });
3587
- var TransferOwnershipInputSchema = z20.object({
3588
- domain: z20.string(),
3589
- toOrgId: z20.string()
3527
+ var StartDocsPreviewRegisterInputSchema = z19.object({
3528
+ orgId: z19.string(),
3529
+ filepaths: z19.array(FilePathInputSchema),
3530
+ basePath: z19.string().nullish(),
3531
+ images: z19.array(ImageFilePathSchema).nullish(),
3532
+ authConfig: AuthConfigSchema.nullish(),
3533
+ previewId: z19.string().nullish()
3534
+ });
3535
+ var StartDocsPreviewRegisterResponseSchema = z19.object({
3536
+ docsRegistrationId: z19.string(),
3537
+ uploadUrls: z19.record(z19.string(), FileS3UploadUrlSchema),
3538
+ skippedFiles: z19.array(z19.string()),
3539
+ previewUrl: z19.string()
3540
+ });
3541
+ var FinishDocsRegisterV2InputSchema = z19.object({
3542
+ docsRegistrationId: z19.string(),
3543
+ docsDefinition: z19.unknown(),
3544
+ libraryDocs: z19.unknown().nullish(),
3545
+ excludeApis: z19.boolean().nullish(),
3546
+ basepathAware: z19.boolean().nullish()
3547
+ });
3548
+ var TransferOwnershipInputSchema = z19.object({
3549
+ domain: z19.string(),
3550
+ toOrgId: z19.string()
3590
3551
  });
3591
- var SetIsArchivedInputSchema = z20.object({
3592
- url: z20.string(),
3593
- isArchived: z20.boolean()
3552
+ var SetIsArchivedInputSchema = z19.object({
3553
+ url: z19.string(),
3554
+ isArchived: z19.boolean()
3594
3555
  });
3595
- var SetDocsUrlMetadataInputSchema = z20.object({
3596
- url: z20.string(),
3597
- githubUrl: z20.string().nullish()
3556
+ var SetDocsUrlMetadataInputSchema = z19.object({
3557
+ url: z19.string(),
3558
+ githubUrl: z19.string().nullish()
3598
3559
  });
3599
- var AlgoliaDomainInputSchema = z20.object({
3600
- domain: z20.string()
3560
+ var AlgoliaDomainInputSchema = z19.object({
3561
+ domain: z19.string()
3601
3562
  });
3602
- var ListAlgoliaPreviewWhitelistResponseSchema = z20.object({
3603
- domains: z20.array(z20.string())
3563
+ var ListAlgoliaPreviewWhitelistResponseSchema = z19.object({
3564
+ domains: z19.array(z19.string())
3604
3565
  });
3605
- var DeleteDocsSiteInputSchema = z20.object({
3606
- url: z20.string()
3566
+ var DeleteDocsSiteInputSchema = z19.object({
3567
+ url: z19.string()
3607
3568
  });
3608
- var RemoveCustomDomainAliasInputSchema = z20.object({
3569
+ var RemoveCustomDomainAliasInputSchema = z19.object({
3609
3570
  /** The custom-domain URL to remove (e.g. `docs.example.com` or `docs.example.com/api`). */
3610
- url: z20.string()
3571
+ url: z19.string()
3611
3572
  });
3612
- var Bcp47LocaleSchema2 = z20.string().regex(
3573
+ var Bcp47LocaleSchema2 = z19.string().regex(
3613
3574
  /^[a-zA-Z]{2,8}(-[a-zA-Z0-9]{1,8})*$/,
3614
3575
  "Locale must be a valid BCP 47 language tag (e.g. 'en', 'fr', 'pt-BR', 'zh-Hans-CN')"
3615
3576
  );
3616
- var RegisterTranslationInputSchema = z20.object({
3617
- domain: z20.string(),
3577
+ var RegisterTranslationInputSchema = z19.object({
3578
+ domain: z19.string(),
3618
3579
  /**
3619
3580
  * Custom domains that share the docs registration with `domain`. The translation
3620
3581
  * blob is written to S3 once per URL (fern URL + each custom domain), mirroring
3621
3582
  * the fan-out shape of `finishDocsRegister`. Without this, requests to a custom
3622
3583
  * domain hit the translation S3 path under the fern URL prefix and 404.
3623
3584
  */
3624
- customDomains: z20.array(z20.string()).optional().default([]),
3625
- orgId: z20.string(),
3585
+ customDomains: z19.array(z19.string()).optional().default([]),
3586
+ orgId: z19.string(),
3626
3587
  /** BCP 47 language tag identifying the locale for this translation. */
3627
3588
  locale: Bcp47LocaleSchema2,
3628
3589
  /** The full docs definition for this locale, same structure as finishDocsRegister. */
3629
- docsDefinition: z20.unknown()
3590
+ docsDefinition: z19.unknown()
3630
3591
  });
3631
- var RegisterTranslationResponseSchema = z20.object({
3632
- locale: z20.string()
3592
+ var RegisterTranslationResponseSchema = z19.object({
3593
+ locale: z19.string()
3633
3594
  });
3634
3595
  var docsV2WriteContract = {
3635
- startDocsRegister: oc9.route({ method: "POST", path: "/v2/init" }).input(StartDocsRegisterV2InputSchema).output(StartDocsRegisterV2ResponseSchema),
3636
- startDocsPreviewRegister: oc9.route({ method: "POST", path: "/preview/init" }).input(StartDocsPreviewRegisterInputSchema).output(StartDocsPreviewRegisterResponseSchema),
3637
- finishDocsRegister: oc9.route({ method: "POST", path: "/register/{docsRegistrationId}" }).input(FinishDocsRegisterV2InputSchema).output(z20.void()),
3638
- transferOwnershipOfDomain: oc9.route({ method: "POST", path: "/transfer-ownership" }).input(TransferOwnershipInputSchema).output(z20.void()),
3639
- setIsArchived: oc9.route({ method: "POST", path: "/set-is-archived" }).input(SetIsArchivedInputSchema).output(z20.void()),
3640
- setDocsUrlMetadata: oc9.route({ method: "POST", path: "/set-metadata-for-url" }).input(SetDocsUrlMetadataInputSchema).output(z20.void()),
3641
- addAlgoliaPreviewWhitelistEntry: oc9.route({ method: "POST", path: "/algolia-preview-whitelist/add" }).input(AlgoliaDomainInputSchema).output(z20.void()),
3642
- removeAlgoliaPreviewWhitelistEntry: oc9.route({ method: "POST", path: "/algolia-preview-whitelist/remove" }).input(AlgoliaDomainInputSchema).output(z20.void()),
3643
- listAlgoliaPreviewWhitelist: oc9.route({ method: "GET", path: "/algolia-preview-whitelist/list" }).output(ListAlgoliaPreviewWhitelistResponseSchema),
3644
- deleteDocsSite: oc9.route({ method: "POST", path: "/delete" }).input(DeleteDocsSiteInputSchema).output(z20.void()),
3596
+ startDocsRegister: oc8.route({ method: "POST", path: "/v2/init" }).input(StartDocsRegisterV2InputSchema).output(StartDocsRegisterV2ResponseSchema),
3597
+ startDocsPreviewRegister: oc8.route({ method: "POST", path: "/preview/init" }).input(StartDocsPreviewRegisterInputSchema).output(StartDocsPreviewRegisterResponseSchema),
3598
+ finishDocsRegister: oc8.route({ method: "POST", path: "/register/{docsRegistrationId}" }).input(FinishDocsRegisterV2InputSchema).output(z19.void()),
3599
+ transferOwnershipOfDomain: oc8.route({ method: "POST", path: "/transfer-ownership" }).input(TransferOwnershipInputSchema).output(z19.void()),
3600
+ setIsArchived: oc8.route({ method: "POST", path: "/set-is-archived" }).input(SetIsArchivedInputSchema).output(z19.void()),
3601
+ setDocsUrlMetadata: oc8.route({ method: "POST", path: "/set-metadata-for-url" }).input(SetDocsUrlMetadataInputSchema).output(z19.void()),
3602
+ addAlgoliaPreviewWhitelistEntry: oc8.route({ method: "POST", path: "/algolia-preview-whitelist/add" }).input(AlgoliaDomainInputSchema).output(z19.void()),
3603
+ removeAlgoliaPreviewWhitelistEntry: oc8.route({ method: "POST", path: "/algolia-preview-whitelist/remove" }).input(AlgoliaDomainInputSchema).output(z19.void()),
3604
+ listAlgoliaPreviewWhitelist: oc8.route({ method: "GET", path: "/algolia-preview-whitelist/list" }).output(ListAlgoliaPreviewWhitelistResponseSchema),
3605
+ deleteDocsSite: oc8.route({ method: "POST", path: "/delete" }).input(DeleteDocsSiteInputSchema).output(z19.void()),
3645
3606
  /**
3646
3607
  * Removes a single custom-domain alias from a docs site, leaving the
3647
3608
  * Fern-URL sibling intact. Use this when un-binding a custom domain
@@ -3650,13 +3611,13 @@ var docsV2WriteContract = {
3650
3611
  *
3651
3612
  * Idempotent: succeeds with no-op if the URL is not registered.
3652
3613
  */
3653
- removeCustomDomainAlias: oc9.route({ method: "POST", path: "/remove-custom-domain-alias" }).input(RemoveCustomDomainAliasInputSchema).output(z20.void()),
3654
- registerTranslation: oc9.route({ method: "POST", path: "/translations/register" }).input(RegisterTranslationInputSchema).output(RegisterTranslationResponseSchema)
3614
+ removeCustomDomainAlias: oc8.route({ method: "POST", path: "/remove-custom-domain-alias" }).input(RemoveCustomDomainAliasInputSchema).output(z19.void()),
3615
+ registerTranslation: oc8.route({ method: "POST", path: "/translations/register" }).input(RegisterTranslationInputSchema).output(RegisterTranslationResponseSchema)
3655
3616
  };
3656
3617
 
3657
3618
  // src/orpc-client/docs/v2/write/client.ts
3658
3619
  function createDocsV2WriteClient(options) {
3659
- const link = new OpenAPILink8(docsV2WriteContract, {
3620
+ const link = new OpenAPILink7(docsV2WriteContract, {
3660
3621
  url: `${options.baseUrl}/v2/registry/docs`,
3661
3622
  headers: () => ({
3662
3623
  Authorization: `Bearer ${options.token}`,
@@ -3664,15 +3625,14 @@ function createDocsV2WriteClient(options) {
3664
3625
  }),
3665
3626
  ...options.fetch != null ? { fetch: options.fetch } : {}
3666
3627
  });
3667
- return createORPCClient8(link);
3628
+ return createORPCClient7(link);
3668
3629
  }
3669
3630
 
3670
3631
  // src/orpc-client/docs/client.ts
3671
3632
  function createDocsClient(options) {
3672
3633
  return {
3673
3634
  v1: {
3674
- read: createDocsV1ReadClient(options),
3675
- write: createDocsV1WriteClient(options)
3635
+ read: createDocsV1ReadClient(options)
3676
3636
  },
3677
3637
  v2: {
3678
3638
  read: createDocsV2ReadClient(options),
@@ -3684,22 +3644,22 @@ function createDocsClient(options) {
3684
3644
  }
3685
3645
 
3686
3646
  // src/orpc-client/docs-cache/client.ts
3687
- import { createORPCClient as createORPCClient9 } from "@orpc/client";
3688
- import { OpenAPILink as OpenAPILink9 } from "@orpc/openapi-client/fetch";
3647
+ import { createORPCClient as createORPCClient8 } from "@orpc/client";
3648
+ import { OpenAPILink as OpenAPILink8 } from "@orpc/openapi-client/fetch";
3689
3649
 
3690
3650
  // src/orpc-client/docs-cache/contract.ts
3691
- import { oc as oc10 } from "@orpc/contract";
3692
- import * as z21 from "zod";
3693
- var InvalidateCachedDocsInputSchema = z21.object({
3694
- url: z21.string()
3651
+ import { oc as oc9 } from "@orpc/contract";
3652
+ import * as z20 from "zod";
3653
+ var InvalidateCachedDocsInputSchema = z20.object({
3654
+ url: z20.string()
3695
3655
  });
3696
3656
  var docsCacheContract = {
3697
- invalidate: oc10.route({ method: "POST", path: "/invalidate" }).input(InvalidateCachedDocsInputSchema).output(z21.void())
3657
+ invalidate: oc9.route({ method: "POST", path: "/invalidate" }).input(InvalidateCachedDocsInputSchema).output(z20.void())
3698
3658
  };
3699
3659
 
3700
3660
  // src/orpc-client/docs-cache/client.ts
3701
3661
  function createDocsCacheClient(options) {
3702
- const link = new OpenAPILink9(docsCacheContract, {
3662
+ const link = new OpenAPILink8(docsCacheContract, {
3703
3663
  url: `${options.baseUrl}/docs-cache`,
3704
3664
  headers: () => ({
3705
3665
  Authorization: `Bearer ${options.token}`,
@@ -3707,14 +3667,14 @@ function createDocsCacheClient(options) {
3707
3667
  }),
3708
3668
  ...options.fetch != null ? { fetch: options.fetch } : {}
3709
3669
  });
3710
- return createORPCClient9(link);
3670
+ return createORPCClient8(link);
3711
3671
  }
3712
3672
 
3713
3673
  // src/orpc-client/docs-deployment/client.ts
3714
- import { createORPCClient as createORPCClient10 } from "@orpc/client";
3715
- import { OpenAPILink as OpenAPILink10 } from "@orpc/openapi-client/fetch";
3674
+ import { createORPCClient as createORPCClient9 } from "@orpc/client";
3675
+ import { OpenAPILink as OpenAPILink9 } from "@orpc/openapi-client/fetch";
3716
3676
  function createDocsDeploymentClient(options) {
3717
- const link = new OpenAPILink10(docsDeploymentContract, {
3677
+ const link = new OpenAPILink9(docsDeploymentContract, {
3718
3678
  url: `${options.baseUrl}/docs-deployment`,
3719
3679
  headers: () => ({
3720
3680
  Authorization: `Bearer ${options.token}`,
@@ -3722,58 +3682,58 @@ function createDocsDeploymentClient(options) {
3722
3682
  }),
3723
3683
  ...options.fetch != null ? { fetch: options.fetch } : {}
3724
3684
  });
3725
- return createORPCClient10(link);
3685
+ return createORPCClient9(link);
3726
3686
  }
3727
3687
 
3728
3688
  // src/orpc-client/docs-ledger/client.ts
3729
- import { createORPCClient as createORPCClient11 } from "@orpc/client";
3730
- import { OpenAPILink as OpenAPILink11 } from "@orpc/openapi-client/fetch";
3689
+ import { createORPCClient as createORPCClient10 } from "@orpc/client";
3690
+ import { OpenAPILink as OpenAPILink10 } from "@orpc/openapi-client/fetch";
3731
3691
 
3732
3692
  // src/orpc-client/docs-ledger/contract.ts
3733
- import { oc as oc11 } from "@orpc/contract";
3734
- import * as z22 from "zod";
3735
- var MissingContentSchema = z22.object({
3736
- hash: z22.string(),
3737
- uploadUrl: z22.string()
3693
+ import { oc as oc10 } from "@orpc/contract";
3694
+ import * as z21 from "zod";
3695
+ var MissingContentSchema = z21.object({
3696
+ hash: z21.string(),
3697
+ uploadUrl: z21.string()
3738
3698
  });
3739
- var RegisterResponseSchema = z22.object({
3740
- deploymentHash: z22.string(),
3741
- missingContent: z22.array(MissingContentSchema)
3699
+ var RegisterResponseSchema = z21.object({
3700
+ deploymentHash: z21.string(),
3701
+ missingContent: z21.array(MissingContentSchema)
3742
3702
  });
3743
- var FinishResponseSchema = z22.object({
3744
- deploymentId: z22.string(),
3703
+ var FinishResponseSchema = z21.object({
3704
+ deploymentId: z21.string(),
3745
3705
  /** ID of the canonical (fern URL) site row. */
3746
- siteId: z22.string(),
3706
+ siteId: z21.string(),
3747
3707
  /**
3748
3708
  * IDs of any additional site rows created for `customDomains` URLs
3749
3709
  * (ADR 0010). Empty when the publish has no `customDomains`. One ID
3750
3710
  * per parsed customDomain, in the same order as the input.
3751
3711
  */
3752
- additionalSiteIds: z22.array(z22.string()).default([]),
3753
- deploymentHash: z22.string(),
3754
- reusedDeployment: z22.boolean(),
3712
+ additionalSiteIds: z21.array(z21.string()).default([]),
3713
+ deploymentHash: z21.string(),
3714
+ reusedDeployment: z21.boolean(),
3755
3715
  /**
3756
3716
  * Per-locale segment counts when `translations[]` was supplied on the
3757
3717
  * finish input. Absent when no translations were included.
3758
3718
  */
3759
- translationsProcessed: z22.array(z22.object({ locale: z22.string(), segmentsAdded: z22.number() })).optional()
3719
+ translationsProcessed: z21.array(z21.object({ locale: z21.string(), segmentsAdded: z21.number() })).optional()
3760
3720
  });
3761
- var ArchiveSiteInputSchema = z22.object({
3762
- siteId: z22.string()
3721
+ var ArchiveSiteInputSchema = z21.object({
3722
+ siteId: z21.string()
3763
3723
  });
3764
- var ArchiveSiteResponseSchema = z22.object({
3765
- status: z22.enum(["archived", "already_archived", "not_found"])
3724
+ var ArchiveSiteResponseSchema = z21.object({
3725
+ status: z21.enum(["archived", "already_archived", "not_found"])
3766
3726
  });
3767
- var BlobRefSchema = z22.object({
3768
- hash: z22.string(),
3769
- contentType: z22.string(),
3770
- contentLength: z22.number()
3727
+ var BlobRefSchema = z21.object({
3728
+ hash: z21.string(),
3729
+ contentType: z21.string(),
3730
+ contentLength: z21.number()
3771
3731
  });
3772
- var PageBlobRefSchema = z22.object({
3732
+ var PageBlobRefSchema = z21.object({
3773
3733
  /** SHA-256 hex of the page content bytes. */
3774
- hash: z22.string(),
3775
- contentType: z22.string().default("text/markdown"),
3776
- contentLength: z22.number(),
3734
+ hash: z21.string(),
3735
+ contentType: z21.string().default("text/markdown"),
3736
+ contentLength: z21.number(),
3777
3737
  /**
3778
3738
  * Bare `fullPath`s of the file/image artifacts this page's rendered
3779
3739
  * markdown references (the `<fullPath>` of each `file:<fullPath>` token).
@@ -3783,35 +3743,35 @@ var PageBlobRefSchema = z22.object({
3783
3743
  * (ADR 0016, "File metadata on the render path"). Optional — older CLIs
3784
3744
  * omit it and the page simply contributes no shard-side file identities.
3785
3745
  */
3786
- referencedFiles: z22.array(z22.string()).optional()
3746
+ referencedFiles: z21.array(z21.string()).optional()
3787
3747
  });
3788
- var FileManifestEntrySchema = z22.object({
3748
+ var FileManifestEntrySchema = z21.object({
3789
3749
  /** SHA-256 hex of the file bytes (= CAS content hash). */
3790
- hash: z22.string(),
3791
- contentType: z22.string(),
3792
- contentLength: z22.number(),
3750
+ hash: z21.string(),
3751
+ contentType: z21.string(),
3752
+ contentLength: z21.number(),
3793
3753
  /** Original filename (e.g. "logo.png"). Used for Content-Disposition and URL cosmetics. */
3794
- filename: z22.string(),
3754
+ filename: z21.string(),
3795
3755
  /** Image width in pixels (images only). */
3796
- width: z22.number().optional(),
3756
+ width: z21.number().optional(),
3797
3757
  /** Image height in pixels (images only). */
3798
- height: z22.number().optional(),
3758
+ height: z21.number().optional(),
3799
3759
  /** Base64-encoded blur placeholder (images only). */
3800
- blurDataURL: z22.string().optional()
3760
+ blurDataURL: z21.string().optional()
3801
3761
  });
3802
- var ImageRefSchema = z22.object({
3803
- path: z22.string(),
3804
- width: z22.number(),
3805
- height: z22.number()
3762
+ var ImageRefSchema = z21.object({
3763
+ path: z21.string(),
3764
+ width: z21.number(),
3765
+ height: z21.number()
3806
3766
  });
3807
- var PathOrUrlSchema = z22.discriminatedUnion("type", [
3808
- z22.object({ type: z22.literal("path"), value: z22.string() }),
3809
- z22.object({ type: z22.literal("url"), value: z22.string() })
3767
+ var PathOrUrlSchema = z21.discriminatedUnion("type", [
3768
+ z21.object({ type: z21.literal("path"), value: z21.string() }),
3769
+ z21.object({ type: z21.literal("url"), value: z21.string() })
3810
3770
  ]);
3811
- var RgbaSchema = z22.object({ r: z22.number(), g: z22.number(), b: z22.number(), a: z22.number().optional() });
3812
- var BackgroundColorSchema = z22.discriminatedUnion("type", [
3813
- z22.object({ type: z22.literal("solid"), ...RgbaSchema.shape }),
3814
- z22.object({ type: z22.literal("gradient") })
3771
+ var RgbaSchema = z21.object({ r: z21.number(), g: z21.number(), b: z21.number(), a: z21.number().optional() });
3772
+ var BackgroundColorSchema = z21.discriminatedUnion("type", [
3773
+ z21.object({ type: z21.literal("solid"), ...RgbaSchema.shape }),
3774
+ z21.object({ type: z21.literal("gradient") })
3815
3775
  ]);
3816
3776
  var ACCENT_SCALE_KEYS = [
3817
3777
  "accent1",
@@ -3828,9 +3788,9 @@ var ACCENT_SCALE_KEYS = [
3828
3788
  "accent12"
3829
3789
  ];
3830
3790
  var accentScaleShape = Object.fromEntries(ACCENT_SCALE_KEYS.map((key) => [key, RgbaSchema.optional()]));
3831
- var LedgerThemeConfigSchema = z22.object({
3791
+ var LedgerThemeConfigSchema = z21.object({
3832
3792
  logo: ImageRefSchema.optional(),
3833
- backgroundImage: z22.string().optional(),
3793
+ backgroundImage: z21.string().optional(),
3834
3794
  accentPrimary: RgbaSchema,
3835
3795
  background: BackgroundColorSchema.optional(),
3836
3796
  border: RgbaSchema.optional(),
@@ -3839,51 +3799,51 @@ var LedgerThemeConfigSchema = z22.object({
3839
3799
  cardBackground: RgbaSchema.optional(),
3840
3800
  ...accentScaleShape
3841
3801
  });
3842
- var LedgerColorsConfigSchema = z22.discriminatedUnion("type", [
3843
- z22.object({ type: z22.literal("dark"), ...LedgerThemeConfigSchema.shape }),
3844
- z22.object({ type: z22.literal("light"), ...LedgerThemeConfigSchema.shape }),
3845
- z22.object({
3846
- type: z22.literal("darkAndLight"),
3802
+ var LedgerColorsConfigSchema = z21.discriminatedUnion("type", [
3803
+ z21.object({ type: z21.literal("dark"), ...LedgerThemeConfigSchema.shape }),
3804
+ z21.object({ type: z21.literal("light"), ...LedgerThemeConfigSchema.shape }),
3805
+ z21.object({
3806
+ type: z21.literal("darkAndLight"),
3847
3807
  dark: LedgerThemeConfigSchema,
3848
3808
  light: LedgerThemeConfigSchema
3849
3809
  })
3850
3810
  ]);
3851
- var LedgerFontVariantSchema = z22.object({
3852
- fontFile: z22.string(),
3853
- weight: z22.array(z22.string()).optional(),
3854
- style: z22.array(z22.enum(["normal", "italic"])).optional()
3855
- });
3856
- var LedgerFontConfigSchema = z22.discriminatedUnion("type", [
3857
- z22.object({
3858
- type: z22.literal("custom"),
3859
- name: z22.string(),
3860
- variants: z22.array(LedgerFontVariantSchema),
3861
- display: z22.enum(["auto", "block", "swap", "fallback", "optional"]).optional(),
3862
- fallback: z22.array(z22.string()).optional(),
3863
- fontVariationSettings: z22.string().optional()
3811
+ var LedgerFontVariantSchema = z21.object({
3812
+ fontFile: z21.string(),
3813
+ weight: z21.array(z21.string()).optional(),
3814
+ style: z21.array(z21.enum(["normal", "italic"])).optional()
3815
+ });
3816
+ var LedgerFontConfigSchema = z21.discriminatedUnion("type", [
3817
+ z21.object({
3818
+ type: z21.literal("custom"),
3819
+ name: z21.string(),
3820
+ variants: z21.array(LedgerFontVariantSchema),
3821
+ display: z21.enum(["auto", "block", "swap", "fallback", "optional"]).optional(),
3822
+ fallback: z21.array(z21.string()).optional(),
3823
+ fontVariationSettings: z21.string().optional()
3864
3824
  })
3865
3825
  ]);
3866
- var LedgerTypographySchema = z22.object({
3826
+ var LedgerTypographySchema = z21.object({
3867
3827
  headingsFont: LedgerFontConfigSchema.optional(),
3868
3828
  bodyFont: LedgerFontConfigSchema.optional(),
3869
3829
  codeFont: LedgerFontConfigSchema.optional()
3870
3830
  });
3871
- var LedgerJsFileSchema = z22.object({
3872
- path: z22.string(),
3873
- strategy: z22.enum(["beforeInteractive", "afterInteractive", "lazyOnload"]).optional()
3831
+ var LedgerJsFileSchema = z21.object({
3832
+ path: z21.string(),
3833
+ strategy: z21.enum(["beforeInteractive", "afterInteractive", "lazyOnload"]).optional()
3874
3834
  });
3875
- var LedgerJsConfigSchema = z22.object({
3876
- remote: z22.array(
3877
- z22.object({
3878
- url: z22.string(),
3879
- strategy: z22.enum(["beforeInteractive", "afterInteractive", "lazyOnload"]).optional()
3835
+ var LedgerJsConfigSchema = z21.object({
3836
+ remote: z21.array(
3837
+ z21.object({
3838
+ url: z21.string(),
3839
+ strategy: z21.enum(["beforeInteractive", "afterInteractive", "lazyOnload"]).optional()
3880
3840
  })
3881
3841
  ).optional(),
3882
- files: z22.array(LedgerJsFileSchema).optional(),
3883
- inline: z22.array(z22.string()).optional()
3842
+ files: z21.array(LedgerJsFileSchema).optional(),
3843
+ inline: z21.array(z21.string()).optional()
3884
3844
  });
3885
- var LedgerMetadataConfigSchema = z22.record(z22.string(), z22.unknown()).and(
3886
- z22.object({
3845
+ var LedgerMetadataConfigSchema = z21.record(z21.string(), z21.unknown()).and(
3846
+ z21.object({
3887
3847
  "og:image": PathOrUrlSchema.optional(),
3888
3848
  "og:logo": PathOrUrlSchema.optional(),
3889
3849
  "twitter:image": PathOrUrlSchema.optional(),
@@ -3891,83 +3851,83 @@ var LedgerMetadataConfigSchema = z22.record(z22.string(), z22.unknown()).and(
3891
3851
  "og:dynamic:background-image": PathOrUrlSchema.optional()
3892
3852
  })
3893
3853
  );
3894
- var NavbarLinksFieldSchema = z22.array(NavbarLinkSchema);
3895
- var FooterLinksFieldSchema = z22.array(FooterLinkSchema);
3854
+ var NavbarLinksFieldSchema = z21.array(NavbarLinkSchema);
3855
+ var FooterLinksFieldSchema = z21.array(FooterLinkSchema);
3896
3856
  var LayoutFieldSchema = DocsLayoutConfigSchema;
3897
3857
  var ThemeFieldSchema = DocsThemeConfigSchema;
3898
3858
  var SettingsFieldSchema = DocsSettingsConfigSchema;
3899
3859
  var AnalyticsFieldSchema = AnalyticsConfigSchema;
3900
3860
  var AIChatFieldSchema = AIChatConfigSchema;
3901
3861
  var PageActionsFieldSchema = PageActionsConfigSchema;
3902
- var LedgerAgentsConfigSchema = z22.object({
3903
- pageDirective: z22.string().optional(),
3904
- pageDescriptionSource: z22.enum(["description", "subtitle"]).optional(),
3905
- siteDescription: z22.string().optional()
3906
- });
3907
- var LedgerConfigSchema = z22.object({
3908
- title: z22.string().optional(),
3909
- rootSlug: z22.string().optional(),
3910
- defaultLanguage: z22.string().optional(),
3911
- translations: z22.object({
3912
- defaultLocale: z22.string(),
3913
- translations: z22.array(z22.string()).optional()
3862
+ var LedgerAgentsConfigSchema = z21.object({
3863
+ pageDirective: z21.string().optional(),
3864
+ pageDescriptionSource: z21.enum(["description", "subtitle"]).optional(),
3865
+ siteDescription: z21.string().optional()
3866
+ });
3867
+ var LedgerConfigSchema = z21.object({
3868
+ title: z21.string().optional(),
3869
+ rootSlug: z21.string().optional(),
3870
+ defaultLanguage: z21.string().optional(),
3871
+ translations: z21.object({
3872
+ defaultLocale: z21.string(),
3873
+ translations: z21.array(z21.string()).optional()
3914
3874
  }).optional(),
3915
- announcement: z22.object({ text: z22.string() }).optional(),
3875
+ announcement: z21.object({ text: z21.string() }).optional(),
3916
3876
  navbarLinks: NavbarLinksFieldSchema.optional(),
3917
3877
  footerLinks: FooterLinksFieldSchema.optional(),
3918
- logoHeight: z22.number().optional(),
3919
- logoHref: z22.string().optional(),
3920
- logoRightText: z22.string().optional(),
3878
+ logoHeight: z21.number().optional(),
3879
+ logoHref: z21.string().optional(),
3880
+ logoRightText: z21.string().optional(),
3921
3881
  /** fullPath of the favicon file artifact (any extension: .svg/.png/.ico). */
3922
- favicon: z22.string().nullish(),
3882
+ favicon: z21.string().nullish(),
3923
3883
  agents: LedgerAgentsConfigSchema.optional(),
3924
3884
  metadata: LedgerMetadataConfigSchema.optional(),
3925
- redirects: z22.array(z22.object({ source: z22.string(), destination: z22.string(), permanent: z22.boolean().optional() })).optional(),
3885
+ redirects: z21.array(z21.object({ source: z21.string(), destination: z21.string(), permanent: z21.boolean().optional() })).optional(),
3926
3886
  colorsV3: LedgerColorsConfigSchema.optional(),
3927
3887
  layout: LayoutFieldSchema.optional(),
3928
3888
  theme: ThemeFieldSchema.optional(),
3929
3889
  settings: SettingsFieldSchema.optional(),
3930
3890
  typographyV2: LedgerTypographySchema.optional(),
3931
3891
  analyticsConfig: AnalyticsFieldSchema.optional(),
3932
- integrations: z22.object({
3933
- intercom: z22.string().optional()
3892
+ integrations: z21.object({
3893
+ intercom: z21.string().optional()
3934
3894
  }).optional(),
3935
- css: z22.object({ inline: z22.array(z22.string()).optional() }).optional(),
3895
+ css: z21.object({ inline: z21.array(z21.string()).optional() }).optional(),
3936
3896
  js: LedgerJsConfigSchema.optional(),
3937
3897
  aiChatConfig: AIChatFieldSchema.optional(),
3938
3898
  pageActions: PageActionsFieldSchema.optional(),
3939
- editThisPageLaunch: z22.enum(["github", "dashboard"]).optional(),
3899
+ editThisPageLaunch: z21.enum(["github", "dashboard"]).optional(),
3940
3900
  /**
3941
3901
  * Explicit edit-this-page GitHub config from docs.yml (ADR 0012 parity).
3942
3902
  * When present, the loader synthesises `editThisPageUrl` from these fields
3943
3903
  * instead of relying on deployment-scoped git provenance. This matches the
3944
3904
  * v2 behaviour where the CLI derives the URL from the declared config.
3945
3905
  */
3946
- editThisPageGithub: z22.object({
3947
- owner: z22.string(),
3948
- repo: z22.string(),
3949
- branch: z22.string().default("main"),
3950
- host: z22.string().default("https://github.com")
3906
+ editThisPageGithub: z21.object({
3907
+ owner: z21.string(),
3908
+ repo: z21.string(),
3909
+ branch: z21.string().default("main"),
3910
+ host: z21.string().default("https://github.com")
3951
3911
  }).optional(),
3952
- header: z22.string().optional(),
3953
- footer: z22.string().optional()
3954
- });
3955
- var MetadataStringArraySchema = z22.array(z22.string());
3956
- var FeatureFlagMetadataSchema = z22.array(
3957
- z22.union([
3958
- z22.string(),
3959
- z22.object({
3960
- flag: z22.string(),
3961
- fallbackValue: z22.unknown().optional(),
3962
- match: z22.unknown().optional()
3912
+ header: z21.string().optional(),
3913
+ footer: z21.string().optional()
3914
+ });
3915
+ var MetadataStringArraySchema = z21.array(z21.string());
3916
+ var FeatureFlagMetadataSchema = z21.array(
3917
+ z21.union([
3918
+ z21.string(),
3919
+ z21.object({
3920
+ flag: z21.string(),
3921
+ fallbackValue: z21.unknown().optional(),
3922
+ match: z21.unknown().optional()
3963
3923
  })
3964
3924
  ])
3965
3925
  );
3966
- var LinkTargetSchema2 = z22.enum(["_blank", "_self", "_parent", "_top"]);
3967
- var CollapsedSchema = z22.union([z22.boolean(), z22.literal("open-by-default")]);
3968
- var LedgerAvailabilitySchema = z22.union([
3926
+ var LinkTargetSchema2 = z21.enum(["_blank", "_self", "_parent", "_top"]);
3927
+ var CollapsedSchema = z21.union([z21.boolean(), z21.literal("open-by-default")]);
3928
+ var LedgerAvailabilitySchema = z21.union([
3969
3929
  AvailabilitySchema,
3970
- z22.enum([
3930
+ z21.enum([
3971
3931
  "alpha",
3972
3932
  "stable",
3973
3933
  "generally-available",
@@ -3979,7 +3939,7 @@ var LedgerAvailabilitySchema = z22.union([
3979
3939
  "legacy"
3980
3940
  ])
3981
3941
  ]);
3982
- var LedgerArtifactTypeSchema = z22.enum([
3942
+ var LedgerArtifactTypeSchema = z21.enum([
3983
3943
  "markdown",
3984
3944
  "page",
3985
3945
  "rest",
@@ -3993,170 +3953,170 @@ var LedgerArtifactTypeSchema = z22.enum([
3993
3953
  "image",
3994
3954
  "redirect"
3995
3955
  ]);
3996
- var LedgerMetadataBaseSchema = z22.object({}).passthrough();
3956
+ var LedgerMetadataBaseSchema = z21.object({}).passthrough();
3997
3957
  var NodeMetadataFields = {
3998
- title: z22.string().optional(),
3999
- slug: z22.string().optional(),
4000
- icon: z22.string().optional(),
4001
- authed: z22.boolean().optional(),
3958
+ title: z21.string().optional(),
3959
+ slug: z21.string().optional(),
3960
+ icon: z21.string().optional(),
3961
+ authed: z21.boolean().optional(),
4002
3962
  viewers: MetadataStringArraySchema.optional(),
4003
- orphaned: z22.boolean().optional(),
3963
+ orphaned: z21.boolean().optional(),
4004
3964
  featureFlags: FeatureFlagMetadataSchema.optional()
4005
3965
  };
4006
3966
  var ApiNodeMetadataFields = {
4007
3967
  ...NodeMetadataFields,
4008
- apiDefinitionId: z22.string(),
3968
+ apiDefinitionId: z21.string(),
4009
3969
  availability: LedgerAvailabilitySchema.optional()
4010
3970
  };
4011
3971
  var LedgerSegmentDetailMetadataObjectSchema = LedgerMetadataBaseSchema.extend({
4012
- slug: z22.string().optional(),
4013
- default: z22.boolean().optional(),
4014
- subtitle: z22.string().optional(),
4015
- href: z22.string().optional(),
4016
- url: z22.string().optional(),
3972
+ slug: z21.string().optional(),
3973
+ default: z21.boolean().optional(),
3974
+ subtitle: z21.string().optional(),
3975
+ href: z21.string().optional(),
3976
+ url: z21.string().optional(),
4017
3977
  target: LinkTargetSchema2.optional(),
4018
- image: z22.string().optional(),
4019
- pointsTo: z22.string().optional(),
3978
+ image: z21.string().optional(),
3979
+ pointsTo: z21.string().optional(),
4020
3980
  availability: LedgerAvailabilitySchema.optional(),
4021
- tab_type: z22.enum(["tab", "link", "changelog"]).optional()
3981
+ tab_type: z21.enum(["tab", "link", "changelog"]).optional()
4022
3982
  });
4023
3983
  var LedgerSegmentDetailMetadataSchema = LedgerSegmentDetailMetadataObjectSchema.nullable();
4024
- var LedgerSegmentMetadataObjectSchema = z22.discriminatedUnion("type", [
3984
+ var LedgerSegmentMetadataObjectSchema = z21.discriminatedUnion("type", [
4025
3985
  LedgerMetadataBaseSchema.extend({
4026
- type: z22.literal("tabRoot")
3986
+ type: z21.literal("tabRoot")
4027
3987
  }),
4028
3988
  LedgerMetadataBaseSchema.extend({
4029
- type: z22.literal("section"),
4030
- title: z22.string().optional(),
4031
- icon: z22.string().optional(),
4032
- authed: z22.boolean().optional(),
3989
+ type: z21.literal("section"),
3990
+ title: z21.string().optional(),
3991
+ icon: z21.string().optional(),
3992
+ authed: z21.boolean().optional(),
4033
3993
  collapsed: CollapsedSchema.optional(),
4034
- collapsible: z22.boolean().optional(),
4035
- collapsedByDefault: z22.boolean().optional(),
3994
+ collapsible: z21.boolean().optional(),
3995
+ collapsedByDefault: z21.boolean().optional(),
4036
3996
  availability: LedgerAvailabilitySchema.optional(),
4037
- overviewPageId: z22.string().optional(),
4038
- noindex: z22.boolean().optional(),
4039
- pointsTo: z22.string().optional(),
3997
+ overviewPageId: z21.string().optional(),
3998
+ noindex: z21.boolean().optional(),
3999
+ pointsTo: z21.string().optional(),
4040
4000
  viewers: MetadataStringArraySchema.optional(),
4041
- orphaned: z22.boolean().optional(),
4001
+ orphaned: z21.boolean().optional(),
4042
4002
  featureFlags: FeatureFlagMetadataSchema.optional()
4043
4003
  }),
4044
4004
  LedgerMetadataBaseSchema.extend({
4045
- type: z22.literal("apiReference"),
4046
- title: z22.string().optional(),
4047
- icon: z22.string().optional(),
4048
- authed: z22.boolean().optional(),
4049
- apiDefinitionId: z22.string().optional(),
4050
- overviewPageId: z22.string().optional(),
4051
- noindex: z22.boolean().optional(),
4005
+ type: z21.literal("apiReference"),
4006
+ title: z21.string().optional(),
4007
+ icon: z21.string().optional(),
4008
+ authed: z21.boolean().optional(),
4009
+ apiDefinitionId: z21.string().optional(),
4010
+ overviewPageId: z21.string().optional(),
4011
+ noindex: z21.boolean().optional(),
4052
4012
  availability: LedgerAvailabilitySchema.optional(),
4053
- pointsTo: z22.string().optional(),
4054
- paginated: z22.boolean().optional(),
4055
- showErrors: z22.boolean().optional(),
4056
- hideTitle: z22.boolean().optional(),
4013
+ pointsTo: z21.string().optional(),
4014
+ paginated: z21.boolean().optional(),
4015
+ showErrors: z21.boolean().optional(),
4016
+ hideTitle: z21.boolean().optional(),
4057
4017
  viewers: MetadataStringArraySchema.optional(),
4058
- orphaned: z22.boolean().optional(),
4018
+ orphaned: z21.boolean().optional(),
4059
4019
  featureFlags: FeatureFlagMetadataSchema.optional()
4060
4020
  }),
4061
4021
  LedgerMetadataBaseSchema.extend({
4062
- type: z22.literal("apiPackage"),
4063
- title: z22.string().optional(),
4064
- icon: z22.string().optional(),
4065
- authed: z22.boolean().optional(),
4066
- apiDefinitionId: z22.string().optional(),
4067
- overviewPageId: z22.string().optional(),
4068
- noindex: z22.boolean().optional(),
4022
+ type: z21.literal("apiPackage"),
4023
+ title: z21.string().optional(),
4024
+ icon: z21.string().optional(),
4025
+ authed: z21.boolean().optional(),
4026
+ apiDefinitionId: z21.string().optional(),
4027
+ overviewPageId: z21.string().optional(),
4028
+ noindex: z21.boolean().optional(),
4069
4029
  availability: LedgerAvailabilitySchema.optional(),
4070
- pointsTo: z22.string().optional(),
4030
+ pointsTo: z21.string().optional(),
4071
4031
  viewers: MetadataStringArraySchema.optional(),
4072
- orphaned: z22.boolean().optional(),
4032
+ orphaned: z21.boolean().optional(),
4073
4033
  featureFlags: FeatureFlagMetadataSchema.optional()
4074
4034
  }),
4075
4035
  LedgerMetadataBaseSchema.extend({
4076
- type: z22.literal("changelog"),
4077
- title: z22.string().optional(),
4078
- icon: z22.string().optional(),
4079
- overviewPageId: z22.string().optional(),
4080
- apiDefinitionId: z22.string().optional(),
4081
- noindex: z22.boolean().optional(),
4082
- authed: z22.boolean().optional(),
4036
+ type: z21.literal("changelog"),
4037
+ title: z21.string().optional(),
4038
+ icon: z21.string().optional(),
4039
+ overviewPageId: z21.string().optional(),
4040
+ apiDefinitionId: z21.string().optional(),
4041
+ noindex: z21.boolean().optional(),
4042
+ authed: z21.boolean().optional(),
4083
4043
  viewers: MetadataStringArraySchema.optional(),
4084
- orphaned: z22.boolean().optional(),
4044
+ orphaned: z21.boolean().optional(),
4085
4045
  featureFlags: FeatureFlagMetadataSchema.optional()
4086
4046
  }),
4087
4047
  LedgerMetadataBaseSchema.extend({
4088
- type: z22.literal("files")
4048
+ type: z21.literal("files")
4089
4049
  }),
4090
4050
  LedgerMetadataBaseSchema.extend({
4091
- type: z22.literal("redirects")
4051
+ type: z21.literal("redirects")
4092
4052
  }),
4093
4053
  LedgerMetadataBaseSchema.extend({
4094
- type: z22.literal("productLink")
4054
+ type: z21.literal("productLink")
4095
4055
  }),
4096
4056
  LedgerMetadataBaseSchema.extend({
4097
- type: z22.literal("tabLink")
4057
+ type: z21.literal("tabLink")
4098
4058
  })
4099
4059
  ]);
4100
4060
  var LedgerSegmentMetadataSchema = LedgerSegmentMetadataObjectSchema;
4101
4061
  var LedgerMarkdownMetadataSchema = LedgerMetadataBaseSchema.extend({
4102
4062
  ...NodeMetadataFields,
4103
- pageId: z22.string().optional(),
4104
- isOverview: z22.boolean().optional(),
4105
- noindex: z22.boolean().optional()
4063
+ pageId: z21.string().optional(),
4064
+ isOverview: z21.boolean().optional(),
4065
+ noindex: z21.boolean().optional()
4106
4066
  });
4107
4067
  var LedgerRestMetadataSchema = LedgerMetadataBaseSchema.extend({
4108
4068
  ...ApiNodeMetadataFields,
4109
- endpointId: z22.string(),
4069
+ endpointId: z21.string(),
4110
4070
  method: HttpMethodSchema,
4111
- isResponseStream: z22.boolean().optional(),
4112
- endpointPairKey: z22.string().optional()
4071
+ isResponseStream: z21.boolean().optional(),
4072
+ endpointPairKey: z21.string().optional()
4113
4073
  });
4114
4074
  var LedgerWebSocketMetadataSchema = LedgerMetadataBaseSchema.extend({
4115
4075
  ...ApiNodeMetadataFields,
4116
- webSocketId: z22.string()
4076
+ webSocketId: z21.string()
4117
4077
  });
4118
4078
  var LedgerWebhookMetadataSchema = LedgerMetadataBaseSchema.extend({
4119
4079
  ...ApiNodeMetadataFields,
4120
- webhookId: z22.string(),
4080
+ webhookId: z21.string(),
4121
4081
  // V1.WebhookNode carries the full HttpMethod union, so the read model must accept it too.
4122
4082
  method: HttpMethodSchema
4123
4083
  });
4124
4084
  var LedgerGrpcMetadataSchema = LedgerMetadataBaseSchema.extend({
4125
4085
  ...ApiNodeMetadataFields,
4126
- grpcId: z22.string(),
4086
+ grpcId: z21.string(),
4127
4087
  method: GrpcMethodSchema
4128
4088
  });
4129
4089
  var LedgerGraphQlMetadataSchema = LedgerMetadataBaseSchema.extend({
4130
4090
  ...ApiNodeMetadataFields,
4131
- graphqlOperationId: z22.string(),
4091
+ graphqlOperationId: z21.string(),
4132
4092
  operationType: GraphQlOperationTypeSchema
4133
4093
  });
4134
4094
  var LedgerChangelogEntryMetadataSchema = LedgerMetadataBaseSchema.extend({
4135
4095
  ...NodeMetadataFields,
4136
- pageId: z22.string(),
4137
- noindex: z22.boolean().optional(),
4138
- date: z22.string().optional(),
4096
+ pageId: z21.string(),
4097
+ noindex: z21.boolean().optional(),
4098
+ date: z21.string().optional(),
4139
4099
  tags: MetadataStringArraySchema.optional()
4140
4100
  });
4141
4101
  var LedgerLinkMetadataSchema = LedgerMetadataBaseSchema.extend({
4142
- title: z22.string().optional(),
4143
- slug: z22.string().optional(),
4144
- icon: z22.string().optional(),
4145
- url: z22.string(),
4102
+ title: z21.string().optional(),
4103
+ slug: z21.string().optional(),
4104
+ icon: z21.string().optional(),
4105
+ url: z21.string(),
4146
4106
  target: LinkTargetSchema2.optional()
4147
4107
  });
4148
4108
  var LedgerFileArtifactMetadataSchema = LedgerMetadataBaseSchema.extend({
4149
- contentType: z22.string(),
4150
- contentLength: z22.number().optional(),
4151
- filename: z22.string(),
4152
- width: z22.number().optional(),
4153
- height: z22.number().optional(),
4154
- blurDataURL: z22.string().optional()
4109
+ contentType: z21.string(),
4110
+ contentLength: z21.number().optional(),
4111
+ filename: z21.string(),
4112
+ width: z21.number().optional(),
4113
+ height: z21.number().optional(),
4114
+ blurDataURL: z21.string().optional()
4155
4115
  });
4156
4116
  var LedgerRedirectMetadataSchema = LedgerMetadataBaseSchema.extend({
4157
- href: z22.string().optional()
4117
+ href: z21.string().optional()
4158
4118
  });
4159
- var LedgerArtifactMetadataSchema = z22.union([
4119
+ var LedgerArtifactMetadataSchema = z21.union([
4160
4120
  LedgerMarkdownMetadataSchema,
4161
4121
  LedgerRestMetadataSchema,
4162
4122
  LedgerWebSocketMetadataSchema,
@@ -4184,23 +4144,23 @@ var LEDGER_ARTIFACT_METADATA_SCHEMAS = {
4184
4144
  };
4185
4145
  function artifactTypeVariant(base, type) {
4186
4146
  return base.extend({
4187
- artifactType: z22.literal(type),
4147
+ artifactType: z21.literal(type),
4188
4148
  artifactMetadata: LEDGER_ARTIFACT_METADATA_SCHEMAS[type]
4189
4149
  });
4190
4150
  }
4191
- var NavRouteBaseSchema = z22.object({
4192
- fullPath: z22.string().nullable(),
4193
- artifactId: z22.string(),
4194
- hidden: z22.boolean(),
4195
- displaySortOrder: z22.number().nullable().optional()
4151
+ var NavRouteBaseSchema = z21.object({
4152
+ fullPath: z21.string().nullable(),
4153
+ artifactId: z21.string(),
4154
+ hidden: z21.boolean(),
4155
+ displaySortOrder: z21.number().nullable().optional()
4196
4156
  });
4197
4157
  function navRouteVariant(type) {
4198
4158
  return NavRouteBaseSchema.extend({
4199
- type: z22.literal(type),
4159
+ type: z21.literal(type),
4200
4160
  metadata: LEDGER_ARTIFACT_METADATA_SCHEMAS[type]
4201
4161
  });
4202
4162
  }
4203
- var LedgerNavRouteSchema = z22.discriminatedUnion("type", [
4163
+ var LedgerNavRouteSchema = z21.discriminatedUnion("type", [
4204
4164
  navRouteVariant("markdown"),
4205
4165
  navRouteVariant("page"),
4206
4166
  navRouteVariant("rest"),
@@ -4214,35 +4174,35 @@ var LedgerNavRouteSchema = z22.discriminatedUnion("type", [
4214
4174
  navRouteVariant("image"),
4215
4175
  navRouteVariant("redirect")
4216
4176
  ]);
4217
- var DocsPublishGitInputSchema = z22.object({
4177
+ var DocsPublishGitInputSchema = z21.object({
4218
4178
  /** Full HTTPS URL of the repo (e.g. `https://github.com/acme/docs`). */
4219
- repoUrl: z22.string(),
4179
+ repoUrl: z21.string(),
4220
4180
  /** Branch the publish ran from. Used to build the edit-this-page URL. */
4221
- branch: z22.string(),
4181
+ branch: z21.string(),
4222
4182
  /**
4223
4183
  * Optional commit SHA captured when the CLI knows it. Currently surfaced
4224
4184
  * on `versionMetadata` for diagnostics but not used in URL synthesis.
4225
4185
  */
4226
- commitSha: z22.string().optional()
4186
+ commitSha: z21.string().optional()
4227
4187
  });
4228
- var DocsContentFieldsSchema = z22.object({
4229
- root: z22.unknown(),
4230
- pages: z22.record(z22.string(), PageBlobRefSchema),
4188
+ var DocsContentFieldsSchema = z21.object({
4189
+ root: z21.unknown(),
4190
+ pages: z21.record(z21.string(), PageBlobRefSchema),
4231
4191
  apiManifest: BlobRefSchema.nullish(),
4232
4192
  config: LedgerConfigSchema.optional(),
4233
4193
  /**
4234
4194
  * Content-addressable file manifest: maps fullPath → file metadata + CAS blob ref.
4235
4195
  * Each entry becomes a file/image artifact in the ledger with nav routing by fullPath.
4236
4196
  */
4237
- fileManifest: z22.record(z22.string(), FileManifestEntrySchema).optional(),
4197
+ fileManifest: z21.record(z21.string(), FileManifestEntrySchema).optional(),
4238
4198
  // TODO: jsFiles is a single blob containing all custom React component bundles.
4239
4199
  // These should eventually be individual artifacts so they can be loaded/cached
4240
4200
  // independently rather than as a monolithic bundle.
4241
4201
  jsFiles: BlobRefSchema.nullish(),
4242
4202
  redirects: BlobRefSchema.nullish(),
4243
- locale: z22.string().default("en"),
4244
- version: z22.string().nullish(),
4245
- repo: z22.string().nullish(),
4203
+ locale: z21.string().default("en"),
4204
+ version: z21.string().nullish(),
4205
+ repo: z21.string().nullish(),
4246
4206
  /**
4247
4207
  * Git provenance for the deployment (ADR 0012 / FER-10489). Optional —
4248
4208
  * older CLI versions don't send it and the columns stay NULL. When
@@ -4253,14 +4213,14 @@ var DocsContentFieldsSchema = z22.object({
4253
4213
  });
4254
4214
  var LocaleEntrySchemaInternal = DocsContentFieldsSchema.extend({
4255
4215
  /** Locale identifier (e.g. "en", "es", "ja"). Required — no default. */
4256
- locale: z22.string()
4216
+ locale: z21.string()
4257
4217
  });
4258
4218
  var LocaleEntrySchema = LocaleEntrySchemaInternal;
4259
- var DocsPublishInputSchemaInternal = z22.object({
4260
- orgId: z22.string(),
4261
- domain: z22.string(),
4262
- basepath: z22.string().default(""),
4263
- basepathAware: z22.boolean().nullish(),
4219
+ var DocsPublishInputSchemaInternal = z21.object({
4220
+ orgId: z21.string(),
4221
+ domain: z21.string(),
4222
+ basepath: z21.string().default(""),
4223
+ basepathAware: z21.boolean().nullish(),
4264
4224
  /**
4265
4225
  * Additional URLs the deployment should be served from (e.g. a customer's
4266
4226
  * vanity hostname `docs.example.com` alongside the canonical fern URL).
@@ -4271,22 +4231,22 @@ var DocsPublishInputSchemaInternal = z22.object({
4271
4231
  *
4272
4232
  * See ADR 0010.
4273
4233
  */
4274
- customDomains: z22.array(z22.string()).default([]),
4275
- previewId: z22.string().nullish(),
4234
+ customDomains: z21.array(z21.string()).default([]),
4235
+ previewId: z21.string().nullish(),
4276
4236
  /** The primary/fallback locale for this deployment (e.g. "en"). */
4277
- defaultLocale: z22.string().default("en"),
4237
+ defaultLocale: z21.string().default("en"),
4278
4238
  /**
4279
4239
  * All locales for this deployment. Each locale goes through the same
4280
4240
  * transform → upload → verify → persist pipeline.
4281
4241
  */
4282
- locales: z22.array(LocaleEntrySchema).min(1)
4242
+ locales: z21.array(LocaleEntrySchema).min(1)
4283
4243
  }).refine((data) => data.locales.some((l) => l.locale === data.defaultLocale), {
4284
4244
  message: "defaultLocale must match one of the locales in the locales array",
4285
4245
  path: ["defaultLocale"]
4286
4246
  });
4287
4247
  var DocsPublishInputSchema = DocsPublishInputSchemaInternal;
4288
4248
  var LedgerPreviewRegisterInputSchemaInternal = DocsContentFieldsSchema.partial().extend({
4289
- orgId: z22.string(),
4249
+ orgId: z21.string(),
4290
4250
  /**
4291
4251
  * Optional caller-supplied identifier for the preview hostname. Sanitized
4292
4252
  * server-side (`[a-z0-9-]+`, no leading/trailing dashes). When absent,
@@ -4294,25 +4254,25 @@ var LedgerPreviewRegisterInputSchemaInternal = DocsContentFieldsSchema.partial()
4294
4254
  * defeats the round-trip use case where the CLI prints the predicted
4295
4255
  * URL before the publish completes. CLIs should always send this.
4296
4256
  */
4297
- previewId: z22.string().nullish(),
4257
+ previewId: z21.string().nullish(),
4298
4258
  /**
4299
4259
  * Optional path segment appended after the server-generated host.
4300
4260
  * Mirrors V2's `basePath` — most preview publishes leave this empty,
4301
4261
  * but explicit subpath previews (`/v2`) are supported.
4302
4262
  */
4303
- basePath: z22.string().default(""),
4263
+ basePath: z21.string().default(""),
4304
4264
  /** The primary/fallback locale for this preview deployment. */
4305
- defaultLocale: z22.string().optional(),
4265
+ defaultLocale: z21.string().optional(),
4306
4266
  /**
4307
4267
  * All locales for this preview deployment. Preferred over the legacy
4308
4268
  * single-locale content fields above.
4309
4269
  */
4310
- locales: z22.array(LocaleEntrySchema).min(1).optional()
4270
+ locales: z21.array(LocaleEntrySchema).min(1).optional()
4311
4271
  }).superRefine((data, ctx) => {
4312
4272
  if (data.locales == null) {
4313
4273
  if (data.root == null || data.pages == null) {
4314
4274
  ctx.addIssue({
4315
- code: z22.ZodIssueCode.custom,
4275
+ code: z21.ZodIssueCode.custom,
4316
4276
  message: "Either locales or legacy single-locale content fields must be provided",
4317
4277
  path: ["locales"]
4318
4278
  });
@@ -4322,75 +4282,75 @@ var LedgerPreviewRegisterInputSchemaInternal = DocsContentFieldsSchema.partial()
4322
4282
  const defaultLocale = data.defaultLocale ?? data.locales[0]?.locale;
4323
4283
  if (defaultLocale == null || !data.locales.some((locale) => locale.locale === defaultLocale)) {
4324
4284
  ctx.addIssue({
4325
- code: z22.ZodIssueCode.custom,
4285
+ code: z21.ZodIssueCode.custom,
4326
4286
  message: "defaultLocale must match one of the locales in the locales array",
4327
4287
  path: ["defaultLocale"]
4328
4288
  });
4329
4289
  }
4330
4290
  });
4331
4291
  var LedgerPreviewRegisterInputSchema = LedgerPreviewRegisterInputSchemaInternal;
4332
- var LedgerPreviewRegisterResponseSchema = z22.object({
4333
- deploymentHash: z22.string(),
4334
- missingContent: z22.array(MissingContentSchema),
4292
+ var LedgerPreviewRegisterResponseSchema = z21.object({
4293
+ deploymentHash: z21.string(),
4294
+ missingContent: z21.array(MissingContentSchema),
4335
4295
  /** Canonical preview URL, e.g. `https://acme-preview-feature-x.docs.buildwithfern.com`. */
4336
- previewUrl: z22.string(),
4296
+ previewUrl: z21.string(),
4337
4297
  /** Server-generated host portion of `previewUrl` (no scheme, no basepath). */
4338
- domain: z22.string(),
4298
+ domain: z21.string(),
4339
4299
  /** Echoed `basePath` (normalised — empty string when absent). */
4340
- basepath: z22.string(),
4300
+ basepath: z21.string(),
4341
4301
  /** Sanitized identifier the server actually used to compose the host. */
4342
- previewId: z22.string()
4302
+ previewId: z21.string()
4343
4303
  });
4344
4304
  var docsLedgerContract = {
4345
- register: oc11.route({ method: "POST", path: "/register" }).input(DocsPublishInputSchema).output(RegisterResponseSchema),
4346
- previewRegister: oc11.route({ method: "POST", path: "/preview/init" }).input(LedgerPreviewRegisterInputSchema).output(LedgerPreviewRegisterResponseSchema),
4347
- finish: oc11.route({ method: "POST", path: "/register/finish" }).input(DocsPublishInputSchema).output(FinishResponseSchema),
4348
- archiveSite: oc11.route({ method: "POST", path: "/archive" }).input(ArchiveSiteInputSchema).output(ArchiveSiteResponseSchema)
4305
+ register: oc10.route({ method: "POST", path: "/register" }).input(DocsPublishInputSchema).output(RegisterResponseSchema),
4306
+ previewRegister: oc10.route({ method: "POST", path: "/preview/init" }).input(LedgerPreviewRegisterInputSchema).output(LedgerPreviewRegisterResponseSchema),
4307
+ finish: oc10.route({ method: "POST", path: "/register/finish" }).input(DocsPublishInputSchema).output(FinishResponseSchema),
4308
+ archiveSite: oc10.route({ method: "POST", path: "/archive" }).input(ArchiveSiteInputSchema).output(ArchiveSiteResponseSchema)
4349
4309
  };
4350
- var CurrentVersionInputSchema = z22.object({
4351
- domain: z22.string(),
4352
- basepath: z22.string().default("")
4310
+ var CurrentVersionInputSchema = z21.object({
4311
+ domain: z21.string(),
4312
+ basepath: z21.string().default("")
4353
4313
  });
4354
4314
  var CurrentPreviewInputSchema = CurrentVersionInputSchema.extend({
4355
- previewId: z22.string()
4315
+ previewId: z21.string()
4316
+ });
4317
+ var CurrentVersionResponseSchema = z21.object({
4318
+ orgId: z21.string(),
4319
+ domain: z21.string(),
4320
+ basepath: z21.string(),
4321
+ deploymentId: z21.string(),
4322
+ deploymentHash: z21.string(),
4323
+ siteId: z21.string(),
4324
+ assignedAt: z21.string(),
4325
+ assignedBy: z21.string().nullable()
4326
+ });
4327
+ var ContentRefSchema = z21.object({
4328
+ hash: z21.string(),
4329
+ s3Key: z21.string(),
4330
+ contentType: z21.string(),
4331
+ url: z21.string()
4356
4332
  });
4357
- var CurrentVersionResponseSchema = z22.object({
4358
- orgId: z22.string(),
4359
- domain: z22.string(),
4360
- basepath: z22.string(),
4361
- deploymentId: z22.string(),
4362
- deploymentHash: z22.string(),
4363
- siteId: z22.string(),
4364
- assignedAt: z22.string(),
4365
- assignedBy: z22.string().nullable()
4366
- });
4367
- var ContentRefSchema = z22.object({
4368
- hash: z22.string(),
4369
- s3Key: z22.string(),
4370
- contentType: z22.string(),
4371
- url: z22.string()
4372
- });
4373
- var SegmentDetailSchema = z22.object({
4374
- id: z22.string(),
4375
- displayName: z22.string(),
4376
- icon: z22.string().nullable(),
4377
- sortOrder: z22.number(),
4378
- hidden: z22.boolean(),
4379
- viewers: z22.array(z22.string()),
4380
- orphaned: z22.boolean(),
4381
- featureFlags: z22.array(z22.string()),
4333
+ var SegmentDetailSchema = z21.object({
4334
+ id: z21.string(),
4335
+ displayName: z21.string(),
4336
+ icon: z21.string().nullable(),
4337
+ sortOrder: z21.number(),
4338
+ hidden: z21.boolean(),
4339
+ viewers: z21.array(z21.string()),
4340
+ orphaned: z21.boolean(),
4341
+ featureFlags: z21.array(z21.string()),
4382
4342
  /** Type-specific fields: slug, default, subtitle, href, target, image, availability, pointsTo, tab_type. */
4383
4343
  metadata: LedgerSegmentDetailMetadataSchema
4384
4344
  });
4385
- var SegmentSchema = z22.object({
4386
- segmentId: z22.string(),
4387
- segmentHash: z22.string(),
4388
- section: z22.string(),
4389
- locale: z22.string(),
4345
+ var SegmentSchema = z21.object({
4346
+ segmentId: z21.string(),
4347
+ segmentHash: z21.string(),
4348
+ section: z21.string(),
4349
+ locale: z21.string(),
4390
4350
  /** Sidebar order across segments (docs_ledger_deployment_segments.sort_order). */
4391
- sortOrder: z22.number(),
4351
+ sortOrder: z21.number(),
4392
4352
  /** Whether the segment is hidden from the sidebar. */
4393
- hidden: z22.boolean(),
4353
+ hidden: z21.boolean(),
4394
4354
  /** Segment type descriptor (seg.metadata): { type, title, icon, apiDefinitionId, overviewPageId, pointsTo, ... }. */
4395
4355
  metadata: LedgerSegmentMetadataSchema,
4396
4356
  /** Full product/version/variant/tab detail metadata, or null when the dimension is absent. */
@@ -4400,26 +4360,26 @@ var SegmentSchema = z22.object({
4400
4360
  tab: SegmentDetailSchema.nullable(),
4401
4361
  // ── Flat name/icon retained for back-compat (derivable from the
4402
4362
  // detail objects above). ──
4403
- productId: z22.string().nullable(),
4404
- productName: z22.string().nullable(),
4405
- productIcon: z22.string().nullable(),
4406
- versionId: z22.string().nullable(),
4407
- versionName: z22.string().nullable(),
4408
- versionIcon: z22.string().nullable(),
4409
- variantId: z22.string().nullable(),
4410
- variantName: z22.string().nullable(),
4411
- variantIcon: z22.string().nullable(),
4412
- tabId: z22.string().nullable(),
4413
- tabName: z22.string().nullable(),
4414
- tabIcon: z22.string().nullable()
4415
- });
4416
- var VersionMetadataInputSchema = z22.object({
4417
- deploymentId: z22.string(),
4418
- locale: z22.string().optional()
4419
- });
4420
- var VersionMetadataResponseSchema = z22.object({
4421
- deploymentId: z22.string(),
4422
- version: z22.string().nullable(),
4363
+ productId: z21.string().nullable(),
4364
+ productName: z21.string().nullable(),
4365
+ productIcon: z21.string().nullable(),
4366
+ versionId: z21.string().nullable(),
4367
+ versionName: z21.string().nullable(),
4368
+ versionIcon: z21.string().nullable(),
4369
+ variantId: z21.string().nullable(),
4370
+ variantName: z21.string().nullable(),
4371
+ variantIcon: z21.string().nullable(),
4372
+ tabId: z21.string().nullable(),
4373
+ tabName: z21.string().nullable(),
4374
+ tabIcon: z21.string().nullable()
4375
+ });
4376
+ var VersionMetadataInputSchema = z21.object({
4377
+ deploymentId: z21.string(),
4378
+ locale: z21.string().optional()
4379
+ });
4380
+ var VersionMetadataResponseSchema = z21.object({
4381
+ deploymentId: z21.string(),
4382
+ version: z21.string().nullable(),
4423
4383
  /**
4424
4384
  * Inline structural config (ADR 0009). Contains everything from
4425
4385
  * {@link LedgerConfigSchema} except `header`, `footer`, `css.inline`,
@@ -4438,76 +4398,76 @@ var VersionMetadataResponseSchema = z22.object({
4438
4398
  /** CAS ref for the joined `config.js.inline` blob (`\n`-separated JS). */
4439
4399
  jsInline: ContentRefSchema.nullable(),
4440
4400
  jsFiles: ContentRefSchema.nullable(),
4441
- segments: z22.array(SegmentSchema),
4401
+ segments: z21.array(SegmentSchema),
4442
4402
  /** Mapping from human-readable API name slug to API definition UUID. */
4443
- apiNameToId: z22.record(z22.string(), z22.string()),
4403
+ apiNameToId: z21.record(z21.string(), z21.string()),
4444
4404
  /**
4445
4405
  * Git provenance for the deployment (ADR 0012 / FER-10489). Optional —
4446
4406
  * nullable on CLIs that don't send `git` on the publish input. When
4447
4407
  * present, the docs loader synthesises `editThisPageUrl` from `repoUrl`,
4448
4408
  * `branch`, and the page `filename` server-side.
4449
4409
  */
4450
- git: z22.object({
4451
- repoUrl: z22.string(),
4452
- branch: z22.string(),
4453
- commitSha: z22.string().nullable().optional()
4410
+ git: z21.object({
4411
+ repoUrl: z21.string(),
4412
+ branch: z21.string(),
4413
+ commitSha: z21.string().nullable().optional()
4454
4414
  }).optional(),
4455
4415
  /**
4456
4416
  * Docs deployment status from the legacy `docs_sites` table, resolved
4457
4417
  * via Kysely join in the DAO. Null when no matching row exists.
4458
4418
  */
4459
- docsStatus: z22.enum(["PUBLISHING", "LIVE", "UNPUBLISHED", "ERROR"]).nullable().optional()
4460
- });
4461
- var PageContentInputSchema = z22.object({
4462
- deploymentId: z22.string(),
4463
- fullPath: z22.string().optional(),
4464
- pageId: z22.string().optional(),
4465
- locale: z22.string().optional()
4466
- });
4467
- var PageContentResponseSchema = z22.object({
4468
- s3Key: z22.string(),
4469
- segmentHash: z22.string(),
4470
- url: z22.string(),
4471
- pageId: z22.string().optional()
4472
- });
4473
- var BatchPageContentInputSchema = z22.object({
4474
- deploymentId: z22.string(),
4475
- pageIds: z22.array(z22.string()).min(1).max(2e3),
4476
- locale: z22.string().optional()
4477
- });
4478
- var BatchPageContentItemSchema = z22.object({
4479
- pageId: z22.string(),
4480
- s3Key: z22.string(),
4481
- url: z22.string()
4482
- });
4483
- var BatchPageContentResponseSchema = z22.object({
4484
- items: z22.array(BatchPageContentItemSchema)
4485
- });
4486
- var NavInputSchema = z22.object({
4487
- segmentHash: z22.string()
4488
- });
4489
- var NavResponseSchema = z22.object({
4490
- routes: z22.array(LedgerNavRouteSchema)
4491
- });
4492
- var RouteContextInputSchema = z22.object({
4493
- deploymentId: z22.string(),
4494
- fullPath: z22.string(),
4495
- locale: z22.string().optional()
4496
- });
4497
- var RouteContextResponseBaseSchema = z22.object({
4498
- artifactId: z22.string(),
4419
+ docsStatus: z21.enum(["PUBLISHING", "LIVE", "UNPUBLISHED", "ERROR"]).nullable().optional()
4420
+ });
4421
+ var PageContentInputSchema = z21.object({
4422
+ deploymentId: z21.string(),
4423
+ fullPath: z21.string().optional(),
4424
+ pageId: z21.string().optional(),
4425
+ locale: z21.string().optional()
4426
+ });
4427
+ var PageContentResponseSchema = z21.object({
4428
+ s3Key: z21.string(),
4429
+ segmentHash: z21.string(),
4430
+ url: z21.string(),
4431
+ pageId: z21.string().optional()
4432
+ });
4433
+ var BatchPageContentInputSchema = z21.object({
4434
+ deploymentId: z21.string(),
4435
+ pageIds: z21.array(z21.string()).min(1).max(2e3),
4436
+ locale: z21.string().optional()
4437
+ });
4438
+ var BatchPageContentItemSchema = z21.object({
4439
+ pageId: z21.string(),
4440
+ s3Key: z21.string(),
4441
+ url: z21.string()
4442
+ });
4443
+ var BatchPageContentResponseSchema = z21.object({
4444
+ items: z21.array(BatchPageContentItemSchema)
4445
+ });
4446
+ var NavInputSchema = z21.object({
4447
+ segmentHash: z21.string()
4448
+ });
4449
+ var NavResponseSchema = z21.object({
4450
+ routes: z21.array(LedgerNavRouteSchema)
4451
+ });
4452
+ var RouteContextInputSchema = z21.object({
4453
+ deploymentId: z21.string(),
4454
+ fullPath: z21.string(),
4455
+ locale: z21.string().optional()
4456
+ });
4457
+ var RouteContextResponseBaseSchema = z21.object({
4458
+ artifactId: z21.string(),
4499
4459
  /** Hash of the segment that owns the matched route — feed to `nav`. */
4500
- segmentHash: z22.string(),
4460
+ segmentHash: z21.string(),
4501
4461
  /** Section path of the owning segment (e.g. "models/command"). */
4502
- section: z22.string(),
4503
- locale: z22.string(),
4462
+ section: z21.string(),
4463
+ locale: z21.string(),
4504
4464
  /**
4505
4465
  * Page content reference, or null for non-page artifacts (links/redirects)
4506
4466
  * and route-only aliases that carry no content blob.
4507
4467
  */
4508
- page: z22.object({
4509
- s3Key: z22.string(),
4510
- url: z22.string()
4468
+ page: z21.object({
4469
+ s3Key: z21.string(),
4470
+ url: z21.string()
4511
4471
  }).nullable(),
4512
4472
  /** Identity of the owning segment, for switchers + breadcrumbs. */
4513
4473
  product: SegmentDetailSchema.nullable(),
@@ -4515,7 +4475,7 @@ var RouteContextResponseBaseSchema = z22.object({
4515
4475
  variant: SegmentDetailSchema.nullable(),
4516
4476
  tab: SegmentDetailSchema.nullable()
4517
4477
  });
4518
- var RouteContextResponseSchema = z22.discriminatedUnion("artifactType", [
4478
+ var RouteContextResponseSchema = z21.discriminatedUnion("artifactType", [
4519
4479
  artifactTypeVariant(RouteContextResponseBaseSchema, "markdown"),
4520
4480
  artifactTypeVariant(RouteContextResponseBaseSchema, "page"),
4521
4481
  artifactTypeVariant(RouteContextResponseBaseSchema, "rest"),
@@ -4529,116 +4489,116 @@ var RouteContextResponseSchema = z22.discriminatedUnion("artifactType", [
4529
4489
  artifactTypeVariant(RouteContextResponseBaseSchema, "image"),
4530
4490
  artifactTypeVariant(RouteContextResponseBaseSchema, "redirect")
4531
4491
  ]);
4532
- var TopLevelNavigationInputSchema = z22.object({
4533
- deploymentId: z22.string(),
4534
- locale: z22.string().optional()
4535
- });
4536
- var TopLevelNavigationResponseSchema = z22.object({
4537
- products: z22.array(SegmentDetailSchema),
4538
- versions: z22.array(SegmentDetailSchema),
4539
- variants: z22.array(SegmentDetailSchema),
4540
- tabs: z22.array(SegmentDetailSchema)
4541
- });
4542
- var VersionSwitchTargetsInputSchema = z22.object({
4543
- deploymentId: z22.string(),
4544
- fullPath: z22.string(),
4545
- locale: z22.string().optional()
4546
- });
4547
- var VersionSwitchTargetSchema = z22.object({
4492
+ var TopLevelNavigationInputSchema = z21.object({
4493
+ deploymentId: z21.string(),
4494
+ locale: z21.string().optional()
4495
+ });
4496
+ var TopLevelNavigationResponseSchema = z21.object({
4497
+ products: z21.array(SegmentDetailSchema),
4498
+ versions: z21.array(SegmentDetailSchema),
4499
+ variants: z21.array(SegmentDetailSchema),
4500
+ tabs: z21.array(SegmentDetailSchema)
4501
+ });
4502
+ var VersionSwitchTargetsInputSchema = z21.object({
4503
+ deploymentId: z21.string(),
4504
+ fullPath: z21.string(),
4505
+ locale: z21.string().optional()
4506
+ });
4507
+ var VersionSwitchTargetSchema = z21.object({
4548
4508
  /** The version detail id (matches a `SegmentDetail.id` from `versionMetadata`). */
4549
- versionId: z22.string(),
4509
+ versionId: z21.string(),
4550
4510
  /**
4551
4511
  * Slug to navigate to when switching to this version — the equivalent
4552
4512
  * route in the target version, or that version's landing/root slug when
4553
4513
  * no equivalent exists. The current version maps to `fullPath` itself.
4554
4514
  */
4555
- targetSlug: z22.string()
4515
+ targetSlug: z21.string()
4556
4516
  });
4557
- var VersionSwitchTargetsResponseSchema = z22.object({
4558
- targets: z22.array(VersionSwitchTargetSchema)
4517
+ var VersionSwitchTargetsResponseSchema = z21.object({
4518
+ targets: z21.array(VersionSwitchTargetSchema)
4559
4519
  });
4560
- var ApiDefinitionInputSchema = z22.object({
4561
- deploymentId: z22.string(),
4562
- apiDefinitionId: z22.string()
4520
+ var ApiDefinitionInputSchema = z21.object({
4521
+ deploymentId: z21.string(),
4522
+ apiDefinitionId: z21.string()
4563
4523
  });
4564
- var ApiDefinitionResponseSchema = z22.object({
4565
- s3Key: z22.string(),
4566
- contentType: z22.string(),
4567
- url: z22.string()
4524
+ var ApiDefinitionResponseSchema = z21.object({
4525
+ s3Key: z21.string(),
4526
+ contentType: z21.string(),
4527
+ url: z21.string()
4568
4528
  });
4569
- var PrunedApiDefinitionInputSchema = z22.object({
4570
- deploymentId: z22.string(),
4571
- apiDefinitionId: z22.string(),
4529
+ var PrunedApiDefinitionInputSchema = z21.object({
4530
+ deploymentId: z21.string(),
4531
+ apiDefinitionId: z21.string(),
4572
4532
  /** Discriminator matching PruningNodeType.type → artifact metadata field. */
4573
- nodeType: z22.enum(["endpoint", "webSocket", "webhook", "grpc", "graphql"]),
4533
+ nodeType: z21.enum(["endpoint", "webSocket", "webhook", "grpc", "graphql"]),
4574
4534
  /** The node ID value (endpointId, webSocketId, etc.). */
4575
- nodeId: z22.string()
4576
- });
4577
- var PrunedApiDefinitionResponseSchema = z22.object({
4578
- s3Key: z22.string(),
4579
- contentType: z22.string(),
4580
- url: z22.string()
4581
- });
4582
- var FileArtifactInputSchema = z22.object({
4583
- deploymentId: z22.string(),
4584
- fullPath: z22.string()
4585
- });
4586
- var FileArtifactResponseSchema = z22.object({
4587
- fullPath: z22.string(),
4588
- type: z22.enum(["file", "image"]),
4589
- contentType: z22.string(),
4590
- contentLength: z22.number().optional(),
4591
- filename: z22.string(),
4592
- url: z22.string(),
4593
- width: z22.number().optional(),
4594
- height: z22.number().optional(),
4595
- blurDataURL: z22.string().optional()
4596
- });
4597
- var PresignedFileDownloadInputSchema = z22.object({
4535
+ nodeId: z21.string()
4536
+ });
4537
+ var PrunedApiDefinitionResponseSchema = z21.object({
4538
+ s3Key: z21.string(),
4539
+ contentType: z21.string(),
4540
+ url: z21.string()
4541
+ });
4542
+ var FileArtifactInputSchema = z21.object({
4543
+ deploymentId: z21.string(),
4544
+ fullPath: z21.string()
4545
+ });
4546
+ var FileArtifactResponseSchema = z21.object({
4547
+ fullPath: z21.string(),
4548
+ type: z21.enum(["file", "image"]),
4549
+ contentType: z21.string(),
4550
+ contentLength: z21.number().optional(),
4551
+ filename: z21.string(),
4552
+ url: z21.string(),
4553
+ width: z21.number().optional(),
4554
+ height: z21.number().optional(),
4555
+ blurDataURL: z21.string().optional()
4556
+ });
4557
+ var PresignedFileDownloadInputSchema = z21.object({
4598
4558
  /** S3 object key in the public docs bucket (format: `{domain}/{hash}/{path}`). */
4599
- s3Key: z22.string().regex(/^[a-zA-Z0-9._-]+(?:\/[^/]+){2,}$/)
4559
+ s3Key: z21.string().regex(/^[a-zA-Z0-9._-]+(?:\/[^/]+){2,}$/)
4600
4560
  });
4601
- var PresignedFileDownloadResponseSchema = z22.object({
4561
+ var PresignedFileDownloadResponseSchema = z21.object({
4602
4562
  /** Presigned S3 GET URL with long expiry (7 days). */
4603
- url: z22.string()
4563
+ url: z21.string()
4604
4564
  });
4605
- var FileMetadataInputSchema = z22.object({
4606
- deploymentId: z22.string(),
4607
- fullPath: z22.string()
4565
+ var FileMetadataInputSchema = z21.object({
4566
+ deploymentId: z21.string(),
4567
+ fullPath: z21.string()
4608
4568
  });
4609
- var FileMetadataResponseSchema = z22.object({
4569
+ var FileMetadataResponseSchema = z21.object({
4610
4570
  /** Content hash — used by the loader to construct CDN URLs. */
4611
- hash: z22.string(),
4571
+ hash: z21.string(),
4612
4572
  /** Domain under which the file bytes were uploaded in the docs files bucket. */
4613
- domain: z22.string(),
4614
- contentType: z22.string(),
4615
- contentLength: z22.number().optional(),
4616
- filename: z22.string().optional(),
4617
- width: z22.number().optional(),
4618
- height: z22.number().optional(),
4619
- blurDataURL: z22.string().optional()
4573
+ domain: z21.string(),
4574
+ contentType: z21.string(),
4575
+ contentLength: z21.number().optional(),
4576
+ filename: z21.string().optional(),
4577
+ width: z21.number().optional(),
4578
+ height: z21.number().optional(),
4579
+ blurDataURL: z21.string().optional()
4620
4580
  });
4621
4581
  var docsLedgerReadContract = {
4622
- currentVersion: oc11.route({ method: "GET", path: "/current-version" }).input(CurrentVersionInputSchema).output(CurrentVersionResponseSchema),
4623
- currentPreview: oc11.route({ method: "GET", path: "/current-preview" }).input(CurrentPreviewInputSchema).output(CurrentVersionResponseSchema),
4624
- versionMetadata: oc11.route({ method: "GET", path: "/version-metadata/{deploymentId}" }).input(VersionMetadataInputSchema).output(VersionMetadataResponseSchema),
4625
- pageContent: oc11.route({ method: "GET", path: "/page-content/{deploymentId}" }).input(PageContentInputSchema).output(PageContentResponseSchema),
4626
- batchPageContent: oc11.route({ method: "POST", path: "/batch-page-content/{deploymentId}" }).input(BatchPageContentInputSchema).output(BatchPageContentResponseSchema),
4627
- nav: oc11.route({ method: "GET", path: "/nav/{segmentHash}" }).input(NavInputSchema).output(NavResponseSchema),
4628
- routeContext: oc11.route({ method: "GET", path: "/route-context/{deploymentId}" }).input(RouteContextInputSchema).output(RouteContextResponseSchema),
4629
- topLevelNavigation: oc11.route({ method: "GET", path: "/top-level-navigation/{deploymentId}" }).input(TopLevelNavigationInputSchema).output(TopLevelNavigationResponseSchema),
4630
- versionSwitchTargets: oc11.route({ method: "GET", path: "/version-switch-targets/{deploymentId}" }).input(VersionSwitchTargetsInputSchema).output(VersionSwitchTargetsResponseSchema),
4631
- apiDefinition: oc11.route({ method: "GET", path: "/api-definition/{deploymentId}/{apiDefinitionId}" }).input(ApiDefinitionInputSchema).output(ApiDefinitionResponseSchema),
4632
- prunedApiDefinition: oc11.route({ method: "GET", path: "/pruned-api/{deploymentId}/{apiDefinitionId}" }).input(PrunedApiDefinitionInputSchema).output(PrunedApiDefinitionResponseSchema),
4633
- fileArtifact: oc11.route({ method: "GET", path: "/file/{deploymentId}" }).input(FileArtifactInputSchema).output(FileArtifactResponseSchema),
4634
- fileMetadata: oc11.route({ method: "GET", path: "/file-metadata/{deploymentId}" }).input(FileMetadataInputSchema).output(FileMetadataResponseSchema),
4635
- presignedFileDownload: oc11.route({ method: "POST", path: "/presigned-file-download" }).input(PresignedFileDownloadInputSchema).output(PresignedFileDownloadResponseSchema)
4582
+ currentVersion: oc10.route({ method: "GET", path: "/current-version" }).input(CurrentVersionInputSchema).output(CurrentVersionResponseSchema),
4583
+ currentPreview: oc10.route({ method: "GET", path: "/current-preview" }).input(CurrentPreviewInputSchema).output(CurrentVersionResponseSchema),
4584
+ versionMetadata: oc10.route({ method: "GET", path: "/version-metadata/{deploymentId}" }).input(VersionMetadataInputSchema).output(VersionMetadataResponseSchema),
4585
+ pageContent: oc10.route({ method: "GET", path: "/page-content/{deploymentId}" }).input(PageContentInputSchema).output(PageContentResponseSchema),
4586
+ batchPageContent: oc10.route({ method: "POST", path: "/batch-page-content/{deploymentId}" }).input(BatchPageContentInputSchema).output(BatchPageContentResponseSchema),
4587
+ nav: oc10.route({ method: "GET", path: "/nav/{segmentHash}" }).input(NavInputSchema).output(NavResponseSchema),
4588
+ routeContext: oc10.route({ method: "GET", path: "/route-context/{deploymentId}" }).input(RouteContextInputSchema).output(RouteContextResponseSchema),
4589
+ topLevelNavigation: oc10.route({ method: "GET", path: "/top-level-navigation/{deploymentId}" }).input(TopLevelNavigationInputSchema).output(TopLevelNavigationResponseSchema),
4590
+ versionSwitchTargets: oc10.route({ method: "GET", path: "/version-switch-targets/{deploymentId}" }).input(VersionSwitchTargetsInputSchema).output(VersionSwitchTargetsResponseSchema),
4591
+ apiDefinition: oc10.route({ method: "GET", path: "/api-definition/{deploymentId}/{apiDefinitionId}" }).input(ApiDefinitionInputSchema).output(ApiDefinitionResponseSchema),
4592
+ prunedApiDefinition: oc10.route({ method: "GET", path: "/pruned-api/{deploymentId}/{apiDefinitionId}" }).input(PrunedApiDefinitionInputSchema).output(PrunedApiDefinitionResponseSchema),
4593
+ fileArtifact: oc10.route({ method: "GET", path: "/file/{deploymentId}" }).input(FileArtifactInputSchema).output(FileArtifactResponseSchema),
4594
+ fileMetadata: oc10.route({ method: "GET", path: "/file-metadata/{deploymentId}" }).input(FileMetadataInputSchema).output(FileMetadataResponseSchema),
4595
+ presignedFileDownload: oc10.route({ method: "POST", path: "/presigned-file-download" }).input(PresignedFileDownloadInputSchema).output(PresignedFileDownloadResponseSchema)
4636
4596
  };
4637
4597
 
4638
4598
  // src/orpc-client/docs-ledger/client.ts
4639
4599
  function createDocsLedgerClient(options) {
4640
4600
  const baseUrl = options.baseUrl.replace(/\/+$/, "");
4641
- const link = new OpenAPILink11(docsLedgerContract, {
4601
+ const link = new OpenAPILink10(docsLedgerContract, {
4642
4602
  url: `${baseUrl}/docs-ledger`,
4643
4603
  headers: () => ({
4644
4604
  Authorization: `Bearer ${options.token}`,
@@ -4646,53 +4606,53 @@ function createDocsLedgerClient(options) {
4646
4606
  }),
4647
4607
  ...options.fetch != null ? { fetch: options.fetch } : {}
4648
4608
  });
4649
- return createORPCClient11(link);
4609
+ return createORPCClient10(link);
4650
4610
  }
4651
4611
 
4652
4612
  // src/orpc-client/editor-snapshot/client.ts
4653
- import { createORPCClient as createORPCClient12 } from "@orpc/client";
4654
- import { OpenAPILink as OpenAPILink12 } from "@orpc/openapi-client/fetch";
4613
+ import { createORPCClient as createORPCClient11 } from "@orpc/client";
4614
+ import { OpenAPILink as OpenAPILink11 } from "@orpc/openapi-client/fetch";
4655
4615
 
4656
4616
  // src/orpc-client/editor-snapshot/contract.ts
4657
- import { oc as oc12 } from "@orpc/contract";
4658
- import * as z23 from "zod";
4659
- var GetSnapshotInputSchema = z23.object({
4660
- domain: z23.string(),
4661
- branchName: z23.string()
4617
+ import { oc as oc11 } from "@orpc/contract";
4618
+ import * as z22 from "zod";
4619
+ var GetSnapshotInputSchema = z22.object({
4620
+ domain: z22.string(),
4621
+ branchName: z22.string()
4662
4622
  });
4663
- var SetSnapshotInputSchema = z23.object({
4664
- domain: z23.string(),
4665
- branchName: z23.string(),
4666
- data: z23.unknown()
4623
+ var SetSnapshotInputSchema = z22.object({
4624
+ domain: z22.string(),
4625
+ branchName: z22.string(),
4626
+ data: z22.unknown()
4667
4627
  });
4668
- var GetDocumentsForBranchesInputSchema = z23.object({
4669
- domain: z23.string(),
4670
- branchNames: z23.array(z23.string())
4628
+ var GetDocumentsForBranchesInputSchema = z22.object({
4629
+ domain: z22.string(),
4630
+ branchNames: z22.array(z22.string())
4671
4631
  });
4672
- var EditorDocumentSchema = z23.object({
4673
- id: z23.string(),
4674
- domain: z23.string(),
4675
- branchName: z23.string(),
4676
- data: z23.unknown(),
4677
- createdAt: z23.string(),
4678
- updatedAt: z23.string(),
4679
- expiresAt: z23.string().optional()
4632
+ var EditorDocumentSchema = z22.object({
4633
+ id: z22.string(),
4634
+ domain: z22.string(),
4635
+ branchName: z22.string(),
4636
+ data: z22.unknown(),
4637
+ createdAt: z22.string(),
4638
+ updatedAt: z22.string(),
4639
+ expiresAt: z22.string().optional()
4680
4640
  });
4681
- var GetSnapshotResponseSchema = z23.object({
4682
- data: z23.unknown().nullable()
4641
+ var GetSnapshotResponseSchema = z22.object({
4642
+ data: z22.unknown().nullable()
4683
4643
  });
4684
- var GetDocumentsForBranchesResponseSchema = z23.object({
4685
- documents: z23.array(EditorDocumentSchema)
4644
+ var GetDocumentsForBranchesResponseSchema = z22.object({
4645
+ documents: z22.array(EditorDocumentSchema)
4686
4646
  });
4687
4647
  var editorSnapshotContract = {
4688
- getSnapshot: oc12.route({ method: "POST", path: "/get" }).input(GetSnapshotInputSchema).output(GetSnapshotResponseSchema),
4689
- setSnapshot: oc12.route({ method: "POST", path: "/set" }).input(SetSnapshotInputSchema).output(z23.object({})),
4690
- getDocumentsForBranches: oc12.route({ method: "POST", path: "/branches" }).input(GetDocumentsForBranchesInputSchema).output(GetDocumentsForBranchesResponseSchema)
4648
+ getSnapshot: oc11.route({ method: "POST", path: "/get" }).input(GetSnapshotInputSchema).output(GetSnapshotResponseSchema),
4649
+ setSnapshot: oc11.route({ method: "POST", path: "/set" }).input(SetSnapshotInputSchema).output(z22.object({})),
4650
+ getDocumentsForBranches: oc11.route({ method: "POST", path: "/branches" }).input(GetDocumentsForBranchesInputSchema).output(GetDocumentsForBranchesResponseSchema)
4691
4651
  };
4692
4652
 
4693
4653
  // src/orpc-client/editor-snapshot/client.ts
4694
4654
  function createEditorSnapshotClient(options) {
4695
- const link = new OpenAPILink12(editorSnapshotContract, {
4655
+ const link = new OpenAPILink11(editorSnapshotContract, {
4696
4656
  url: `${options.baseUrl.replace(/\/+$/, "")}/editor-snapshot`,
4697
4657
  headers: () => ({
4698
4658
  Authorization: `Bearer ${options.token}`,
@@ -4700,16 +4660,16 @@ function createEditorSnapshotClient(options) {
4700
4660
  }),
4701
4661
  ...options.fetch != null ? { fetch: options.fetch } : {}
4702
4662
  });
4703
- return createORPCClient12(link);
4663
+ return createORPCClient11(link);
4704
4664
  }
4705
4665
 
4706
4666
  // src/orpc-client/generators/cli/client.ts
4707
- import { createORPCClient as createORPCClient13 } from "@orpc/client";
4708
- import { OpenAPILink as OpenAPILink13 } from "@orpc/openapi-client/fetch";
4667
+ import { createORPCClient as createORPCClient12 } from "@orpc/client";
4668
+ import { OpenAPILink as OpenAPILink12 } from "@orpc/openapi-client/fetch";
4709
4669
 
4710
4670
  // src/orpc-client/generators/contract.ts
4711
- import { oc as oc13 } from "@orpc/contract";
4712
- import * as z24 from "zod";
4671
+ import { oc as oc12 } from "@orpc/contract";
4672
+ import * as z23 from "zod";
4713
4673
  function GeneratorId(value) {
4714
4674
  return value;
4715
4675
  }
@@ -4728,7 +4688,7 @@ var ReleaseType = {
4728
4688
  Ga: "GA",
4729
4689
  Rc: "RC"
4730
4690
  };
4731
- var GeneratorLanguageSchema = z24.enum([
4691
+ var GeneratorLanguageSchema = z23.enum([
4732
4692
  "python",
4733
4693
  "go",
4734
4694
  "java",
@@ -4739,182 +4699,182 @@ var GeneratorLanguageSchema = z24.enum([
4739
4699
  "swift",
4740
4700
  "rust"
4741
4701
  ]);
4742
- var ScriptSchema = z24.object({
4743
- steps: z24.array(z24.string())
4702
+ var ScriptSchema = z23.object({
4703
+ steps: z23.array(z23.string())
4744
4704
  });
4745
- var GeneratorScriptsSchema = z24.object({
4705
+ var GeneratorScriptsSchema = z23.object({
4746
4706
  preInstallScript: ScriptSchema.nullish(),
4747
4707
  installScript: ScriptSchema.nullish(),
4748
4708
  compileScript: ScriptSchema.nullish(),
4749
4709
  testScript: ScriptSchema.nullish()
4750
4710
  });
4751
- var GeneratorTypeSchema = z24.discriminatedUnion("type", [
4752
- z24.object({ type: z24.literal("sdk") }),
4753
- z24.object({ type: z24.literal("model") }),
4754
- z24.object({ type: z24.literal("server") }),
4755
- z24.object({ type: z24.literal("other") })
4711
+ var GeneratorTypeSchema = z23.discriminatedUnion("type", [
4712
+ z23.object({ type: z23.literal("sdk") }),
4713
+ z23.object({ type: z23.literal("model") }),
4714
+ z23.object({ type: z23.literal("server") }),
4715
+ z23.object({ type: z23.literal("other") })
4756
4716
  ]);
4757
- var ChangelogEntryTypeSchema = z24.enum(["fix", "feat", "chore", "break", "internal"]);
4758
- var ChangelogEntrySchema = z24.object({
4717
+ var ChangelogEntryTypeSchema = z23.enum(["fix", "feat", "chore", "break", "internal"]);
4718
+ var ChangelogEntrySchema = z23.object({
4759
4719
  type: ChangelogEntryTypeSchema,
4760
- summary: z24.string(),
4761
- links: z24.array(z24.string()).nullish(),
4762
- upgradeNotes: z24.string().nullish(),
4763
- added: z24.array(z24.string()).nullish(),
4764
- changed: z24.array(z24.string()).nullish(),
4765
- deprecated: z24.array(z24.string()).nullish(),
4766
- removed: z24.array(z24.string()).nullish(),
4767
- fixed: z24.array(z24.string()).nullish()
4768
- });
4769
- var YankSchema = z24.object({
4770
- remediationVerision: z24.string().nullish()
4771
- });
4772
- var ReleaseTypeSchema = z24.enum(["GA", "RC"]);
4773
- var VersionRangeSchema = z24.discriminatedUnion("type", [
4774
- z24.object({ type: z24.literal("inclusive"), value: z24.string() }),
4775
- z24.object({ type: z24.literal("exclusive"), value: z24.string() })
4720
+ summary: z23.string(),
4721
+ links: z23.array(z23.string()).nullish(),
4722
+ upgradeNotes: z23.string().nullish(),
4723
+ added: z23.array(z23.string()).nullish(),
4724
+ changed: z23.array(z23.string()).nullish(),
4725
+ deprecated: z23.array(z23.string()).nullish(),
4726
+ removed: z23.array(z23.string()).nullish(),
4727
+ fixed: z23.array(z23.string()).nullish()
4728
+ });
4729
+ var YankSchema = z23.object({
4730
+ remediationVerision: z23.string().nullish()
4731
+ });
4732
+ var ReleaseTypeSchema = z23.enum(["GA", "RC"]);
4733
+ var VersionRangeSchema = z23.discriminatedUnion("type", [
4734
+ z23.object({ type: z23.literal("inclusive"), value: z23.string() }),
4735
+ z23.object({ type: z23.literal("exclusive"), value: z23.string() })
4776
4736
  ]);
4777
- var GeneratorSchema = z24.object({
4778
- id: z24.string(),
4779
- displayName: z24.string(),
4737
+ var GeneratorSchema = z23.object({
4738
+ id: z23.string(),
4739
+ displayName: z23.string(),
4780
4740
  generatorType: GeneratorTypeSchema,
4781
4741
  generatorLanguage: GeneratorLanguageSchema.nullish(),
4782
- dockerImage: z24.string(),
4742
+ dockerImage: z23.string(),
4783
4743
  scripts: GeneratorScriptsSchema.nullish()
4784
4744
  });
4785
- var GeneratorOutputSchema = z24.object({
4786
- id: z24.string(),
4787
- displayName: z24.string(),
4745
+ var GeneratorOutputSchema = z23.object({
4746
+ id: z23.string(),
4747
+ displayName: z23.string(),
4788
4748
  generatorType: GeneratorTypeSchema,
4789
4749
  generatorLanguage: GeneratorLanguageSchema.nullish(),
4790
- dockerImage: z24.string(),
4750
+ dockerImage: z23.string(),
4791
4751
  scripts: GeneratorScriptsSchema.nullish()
4792
4752
  });
4793
- var GetGeneratorByImageInputSchema = z24.object({
4794
- dockerImage: z24.string()
4753
+ var GetGeneratorByImageInputSchema = z23.object({
4754
+ dockerImage: z23.string()
4795
4755
  });
4796
- var GetGeneratorInputSchema = z24.object({
4797
- generatorId: z24.string()
4756
+ var GetGeneratorInputSchema = z23.object({
4757
+ generatorId: z23.string()
4798
4758
  });
4799
- var GeneratorReleaseSchema = z24.object({
4800
- version: z24.string(),
4801
- createdAt: z24.string().nullish(),
4759
+ var GeneratorReleaseSchema = z23.object({
4760
+ version: z23.string(),
4761
+ createdAt: z23.string().nullish(),
4802
4762
  isYanked: YankSchema.nullish(),
4803
- changelogEntry: z24.array(ChangelogEntrySchema).nullish(),
4763
+ changelogEntry: z23.array(ChangelogEntrySchema).nullish(),
4804
4764
  releaseType: ReleaseTypeSchema,
4805
- majorVersion: z24.number(),
4806
- generatorId: z24.string(),
4807
- irVersion: z24.number(),
4808
- migration: z24.string().nullish(),
4809
- customConfigSchema: z24.string().nullish(),
4810
- tags: z24.array(z24.string()).nullish()
4811
- });
4812
- var GeneratorReleaseRequestSchema = z24.object({
4813
- version: z24.string(),
4814
- createdAt: z24.string().nullish(),
4765
+ majorVersion: z23.number(),
4766
+ generatorId: z23.string(),
4767
+ irVersion: z23.number(),
4768
+ migration: z23.string().nullish(),
4769
+ customConfigSchema: z23.string().nullish(),
4770
+ tags: z23.array(z23.string()).nullish()
4771
+ });
4772
+ var GeneratorReleaseRequestSchema = z23.object({
4773
+ version: z23.string(),
4774
+ createdAt: z23.string().nullish(),
4815
4775
  isYanked: YankSchema.nullish(),
4816
- changelogEntry: z24.array(ChangelogEntrySchema).nullish(),
4817
- generatorId: z24.string(),
4818
- irVersion: z24.number(),
4819
- migration: z24.string().nullish(),
4820
- customConfigSchema: z24.string().nullish(),
4821
- tags: z24.array(z24.string()).nullish()
4822
- });
4823
- var GetLatestGeneratorReleaseInputSchema = z24.object({
4824
- generator: z24.string(),
4825
- cliVersion: z24.string().nullish(),
4826
- irVersion: z24.number().nullish(),
4827
- generatorMajorVersion: z24.number().nullish(),
4828
- releaseTypes: z24.array(ReleaseTypeSchema).nullish()
4829
- });
4830
- var GetGeneratorChangelogInputSchema = z24.object({
4831
- generator: z24.string(),
4776
+ changelogEntry: z23.array(ChangelogEntrySchema).nullish(),
4777
+ generatorId: z23.string(),
4778
+ irVersion: z23.number(),
4779
+ migration: z23.string().nullish(),
4780
+ customConfigSchema: z23.string().nullish(),
4781
+ tags: z23.array(z23.string()).nullish()
4782
+ });
4783
+ var GetLatestGeneratorReleaseInputSchema = z23.object({
4784
+ generator: z23.string(),
4785
+ cliVersion: z23.string().nullish(),
4786
+ irVersion: z23.number().nullish(),
4787
+ generatorMajorVersion: z23.number().nullish(),
4788
+ releaseTypes: z23.array(ReleaseTypeSchema).nullish()
4789
+ });
4790
+ var GetGeneratorChangelogInputSchema = z23.object({
4791
+ generator: z23.string(),
4832
4792
  fromVersion: VersionRangeSchema,
4833
4793
  toVersion: VersionRangeSchema
4834
4794
  });
4835
- var ChangelogResponseSchema = z24.object({
4836
- version: z24.string(),
4837
- changelogEntry: z24.array(ChangelogEntrySchema)
4795
+ var ChangelogResponseSchema = z23.object({
4796
+ version: z23.string(),
4797
+ changelogEntry: z23.array(ChangelogEntrySchema)
4838
4798
  });
4839
- var GetChangelogResponseSchema = z24.object({
4840
- entries: z24.array(ChangelogResponseSchema)
4799
+ var GetChangelogResponseSchema = z23.object({
4800
+ entries: z23.array(ChangelogResponseSchema)
4841
4801
  });
4842
- var GetGeneratorReleaseInputSchema = z24.object({
4843
- generator: z24.string(),
4844
- version: z24.string()
4802
+ var GetGeneratorReleaseInputSchema = z23.object({
4803
+ generator: z23.string(),
4804
+ version: z23.string()
4845
4805
  });
4846
- var ListGeneratorReleasesInputSchema = z24.object({
4847
- generator: z24.string(),
4848
- page: z24.coerce.number().nullish(),
4849
- pageSize: z24.coerce.number().nullish()
4806
+ var ListGeneratorReleasesInputSchema = z23.object({
4807
+ generator: z23.string(),
4808
+ page: z23.coerce.number().nullish(),
4809
+ pageSize: z23.coerce.number().nullish()
4850
4810
  });
4851
- var ListGeneratorReleasesResponseSchema = z24.object({
4852
- generatorReleases: z24.array(GeneratorReleaseSchema)
4811
+ var ListGeneratorReleasesResponseSchema = z23.object({
4812
+ generatorReleases: z23.array(GeneratorReleaseSchema)
4853
4813
  });
4854
- var CliReleaseSchema = z24.object({
4855
- version: z24.string(),
4856
- createdAt: z24.string().nullish(),
4814
+ var CliReleaseSchema = z23.object({
4815
+ version: z23.string(),
4816
+ createdAt: z23.string().nullish(),
4857
4817
  isYanked: YankSchema.nullish(),
4858
- changelogEntry: z24.array(ChangelogEntrySchema).nullish(),
4818
+ changelogEntry: z23.array(ChangelogEntrySchema).nullish(),
4859
4819
  releaseType: ReleaseTypeSchema,
4860
- majorVersion: z24.number(),
4861
- irVersion: z24.number(),
4862
- tags: z24.array(z24.string()).nullish()
4820
+ majorVersion: z23.number(),
4821
+ irVersion: z23.number(),
4822
+ tags: z23.array(z23.string()).nullish()
4863
4823
  });
4864
- var GetLatestCliReleaseInputSchema = z24.object({
4865
- releaseTypes: z24.array(ReleaseTypeSchema).nullish(),
4866
- irVersion: z24.number().nullish()
4824
+ var GetLatestCliReleaseInputSchema = z23.object({
4825
+ releaseTypes: z23.array(ReleaseTypeSchema).nullish(),
4826
+ irVersion: z23.number().nullish()
4867
4827
  });
4868
- var GetCliChangelogInputSchema = z24.object({
4828
+ var GetCliChangelogInputSchema = z23.object({
4869
4829
  fromVersion: VersionRangeSchema,
4870
4830
  toVersion: VersionRangeSchema
4871
4831
  });
4872
- var GetMinCliForIrInputSchema = z24.object({
4873
- irVersion: z24.coerce.number()
4832
+ var GetMinCliForIrInputSchema = z23.object({
4833
+ irVersion: z23.coerce.number()
4874
4834
  });
4875
- var UpsertCliReleaseInputSchema = z24.object({
4876
- version: z24.string(),
4877
- createdAt: z24.string().nullish(),
4835
+ var UpsertCliReleaseInputSchema = z23.object({
4836
+ version: z23.string(),
4837
+ createdAt: z23.string().nullish(),
4878
4838
  isYanked: YankSchema.nullish(),
4879
- changelogEntry: z24.array(ChangelogEntrySchema).nullish(),
4880
- irVersion: z24.number(),
4881
- tags: z24.array(z24.string()).nullish()
4839
+ changelogEntry: z23.array(ChangelogEntrySchema).nullish(),
4840
+ irVersion: z23.number(),
4841
+ tags: z23.array(z23.string()).nullish()
4882
4842
  });
4883
- var GetCliReleaseInputSchema = z24.object({
4884
- cliVersion: z24.string()
4843
+ var GetCliReleaseInputSchema = z23.object({
4844
+ cliVersion: z23.string()
4885
4845
  });
4886
- var ListCliReleasesInputSchema = z24.object({
4887
- page: z24.coerce.number().nullish(),
4888
- pageSize: z24.coerce.number().nullish()
4846
+ var ListCliReleasesInputSchema = z23.object({
4847
+ page: z23.coerce.number().nullish(),
4848
+ pageSize: z23.coerce.number().nullish()
4889
4849
  });
4890
- var ListCliReleasesResponseSchema = z24.object({
4891
- cliReleases: z24.array(CliReleaseSchema)
4850
+ var ListCliReleasesResponseSchema = z23.object({
4851
+ cliReleases: z23.array(CliReleaseSchema)
4892
4852
  });
4893
4853
  var generatorsContract = {
4894
- upsertGenerator: oc13.route({ method: "PUT", path: "/" }).input(GeneratorSchema).output(z24.void()),
4895
- getGeneratorByImage: oc13.route({ method: "POST", path: "/by-image" }).input(GetGeneratorByImageInputSchema).output(GeneratorOutputSchema.nullish()),
4896
- getGenerator: oc13.route({ method: "GET", path: "/{generatorId}" }).input(GetGeneratorInputSchema).output(GeneratorOutputSchema.nullish()),
4897
- listGenerators: oc13.route({ method: "GET", path: "/" }).input(z24.object({})).output(z24.array(GeneratorOutputSchema))
4854
+ upsertGenerator: oc12.route({ method: "PUT", path: "/" }).input(GeneratorSchema).output(z23.void()),
4855
+ getGeneratorByImage: oc12.route({ method: "POST", path: "/by-image" }).input(GetGeneratorByImageInputSchema).output(GeneratorOutputSchema.nullish()),
4856
+ getGenerator: oc12.route({ method: "GET", path: "/{generatorId}" }).input(GetGeneratorInputSchema).output(GeneratorOutputSchema.nullish()),
4857
+ listGenerators: oc12.route({ method: "GET", path: "/" }).input(z23.object({})).output(z23.array(GeneratorOutputSchema))
4898
4858
  };
4899
4859
  var generatorVersionsContract = {
4900
- getLatestGeneratorRelease: oc13.route({ method: "POST", path: "/latest" }).input(GetLatestGeneratorReleaseInputSchema).output(GeneratorReleaseSchema),
4901
- getChangelog: oc13.route({ method: "POST", path: "/{generator}/changelog" }).input(GetGeneratorChangelogInputSchema).output(GetChangelogResponseSchema),
4902
- upsertGeneratorRelease: oc13.route({ method: "PUT", path: "/" }).input(GeneratorReleaseRequestSchema).output(z24.void()),
4903
- getGeneratorRelease: oc13.route({ method: "GET", path: "/{generator}/{version}" }).input(GetGeneratorReleaseInputSchema).output(GeneratorReleaseSchema),
4904
- listGeneratorReleases: oc13.route({ method: "GET", path: "/{generator}" }).input(ListGeneratorReleasesInputSchema).output(ListGeneratorReleasesResponseSchema)
4860
+ getLatestGeneratorRelease: oc12.route({ method: "POST", path: "/latest" }).input(GetLatestGeneratorReleaseInputSchema).output(GeneratorReleaseSchema),
4861
+ getChangelog: oc12.route({ method: "POST", path: "/{generator}/changelog" }).input(GetGeneratorChangelogInputSchema).output(GetChangelogResponseSchema),
4862
+ upsertGeneratorRelease: oc12.route({ method: "PUT", path: "/" }).input(GeneratorReleaseRequestSchema).output(z23.void()),
4863
+ getGeneratorRelease: oc12.route({ method: "GET", path: "/{generator}/{version}" }).input(GetGeneratorReleaseInputSchema).output(GeneratorReleaseSchema),
4864
+ listGeneratorReleases: oc12.route({ method: "GET", path: "/{generator}" }).input(ListGeneratorReleasesInputSchema).output(ListGeneratorReleasesResponseSchema)
4905
4865
  };
4906
4866
  var generatorCliContract = {
4907
- getLatestCliRelease: oc13.route({ method: "POST", path: "/latest" }).input(GetLatestCliReleaseInputSchema).output(CliReleaseSchema),
4908
- getChangelog: oc13.route({ method: "POST", path: "/changelog" }).input(GetCliChangelogInputSchema).output(GetChangelogResponseSchema),
4909
- getMinCliForIr: oc13.route({ method: "GET", path: "/for-ir/{irVersion}" }).input(GetMinCliForIrInputSchema).output(CliReleaseSchema),
4910
- upsertCliRelease: oc13.route({ method: "PUT", path: "/" }).input(UpsertCliReleaseInputSchema).output(z24.void()),
4911
- getCliRelease: oc13.route({ method: "GET", path: "/{cliVersion}" }).input(GetCliReleaseInputSchema).output(CliReleaseSchema),
4912
- listCliReleases: oc13.route({ method: "GET", path: "/" }).input(ListCliReleasesInputSchema).output(ListCliReleasesResponseSchema)
4867
+ getLatestCliRelease: oc12.route({ method: "POST", path: "/latest" }).input(GetLatestCliReleaseInputSchema).output(CliReleaseSchema),
4868
+ getChangelog: oc12.route({ method: "POST", path: "/changelog" }).input(GetCliChangelogInputSchema).output(GetChangelogResponseSchema),
4869
+ getMinCliForIr: oc12.route({ method: "GET", path: "/for-ir/{irVersion}" }).input(GetMinCliForIrInputSchema).output(CliReleaseSchema),
4870
+ upsertCliRelease: oc12.route({ method: "PUT", path: "/" }).input(UpsertCliReleaseInputSchema).output(z23.void()),
4871
+ getCliRelease: oc12.route({ method: "GET", path: "/{cliVersion}" }).input(GetCliReleaseInputSchema).output(CliReleaseSchema),
4872
+ listCliReleases: oc12.route({ method: "GET", path: "/" }).input(ListCliReleasesInputSchema).output(ListCliReleasesResponseSchema)
4913
4873
  };
4914
4874
 
4915
4875
  // src/orpc-client/generators/cli/client.ts
4916
4876
  function createGeneratorCliClient(options) {
4917
- const link = new OpenAPILink13(generatorCliContract, {
4877
+ const link = new OpenAPILink12(generatorCliContract, {
4918
4878
  url: `${options.baseUrl}/generators/cli`,
4919
4879
  headers: () => ({
4920
4880
  Authorization: `Bearer ${options.token}`,
@@ -4922,14 +4882,14 @@ function createGeneratorCliClient(options) {
4922
4882
  }),
4923
4883
  ...options.fetch != null ? { fetch: options.fetch } : {}
4924
4884
  });
4925
- return createORPCClient13(link);
4885
+ return createORPCClient12(link);
4926
4886
  }
4927
4887
 
4928
4888
  // src/orpc-client/generators/client.ts
4929
- import { createORPCClient as createORPCClient14 } from "@orpc/client";
4930
- import { OpenAPILink as OpenAPILink14 } from "@orpc/openapi-client/fetch";
4889
+ import { createORPCClient as createORPCClient13 } from "@orpc/client";
4890
+ import { OpenAPILink as OpenAPILink13 } from "@orpc/openapi-client/fetch";
4931
4891
  function createGeneratorsRootClient(options) {
4932
- const link = new OpenAPILink14(generatorsContract, {
4892
+ const link = new OpenAPILink13(generatorsContract, {
4933
4893
  url: `${options.baseUrl}/generators`,
4934
4894
  headers: () => ({
4935
4895
  Authorization: `Bearer ${options.token}`,
@@ -4937,14 +4897,14 @@ function createGeneratorsRootClient(options) {
4937
4897
  }),
4938
4898
  ...options.fetch != null ? { fetch: options.fetch } : {}
4939
4899
  });
4940
- return createORPCClient14(link);
4900
+ return createORPCClient13(link);
4941
4901
  }
4942
4902
 
4943
4903
  // src/orpc-client/generators/versions/client.ts
4944
- import { createORPCClient as createORPCClient15 } from "@orpc/client";
4945
- import { OpenAPILink as OpenAPILink15 } from "@orpc/openapi-client/fetch";
4904
+ import { createORPCClient as createORPCClient14 } from "@orpc/client";
4905
+ import { OpenAPILink as OpenAPILink14 } from "@orpc/openapi-client/fetch";
4946
4906
  function createGeneratorVersionsClient(options) {
4947
- const link = new OpenAPILink15(generatorVersionsContract, {
4907
+ const link = new OpenAPILink14(generatorVersionsContract, {
4948
4908
  url: `${options.baseUrl}/generators/versions`,
4949
4909
  headers: () => ({
4950
4910
  Authorization: `Bearer ${options.token}`,
@@ -4952,135 +4912,135 @@ function createGeneratorVersionsClient(options) {
4952
4912
  }),
4953
4913
  ...options.fetch != null ? { fetch: options.fetch } : {}
4954
4914
  });
4955
- return createORPCClient15(link);
4915
+ return createORPCClient14(link);
4956
4916
  }
4957
4917
 
4958
4918
  // src/orpc-client/git/client.ts
4959
- import { createORPCClient as createORPCClient16 } from "@orpc/client";
4960
- import { OpenAPILink as OpenAPILink16 } from "@orpc/openapi-client/fetch";
4919
+ import { createORPCClient as createORPCClient15 } from "@orpc/client";
4920
+ import { OpenAPILink as OpenAPILink15 } from "@orpc/openapi-client/fetch";
4961
4921
 
4962
4922
  // src/orpc-client/git/contract.ts
4963
- import { oc as oc14 } from "@orpc/contract";
4964
- import * as z25 from "zod";
4965
- var CheckRunSchema = z25.object({
4966
- checkId: z25.string(),
4967
- repositoryOwner: z25.string(),
4968
- repositoryName: z25.string(),
4969
- ref: z25.string(),
4970
- name: z25.string(),
4971
- status: z25.string(),
4972
- conclusion: z25.string(),
4973
- checkRunUrl: z25.string(),
4974
- createdAt: z25.string(),
4975
- completedAt: z25.string().nullish(),
4976
- rawCheckRun: z25.unknown()
4977
- });
4978
- var GithubRepositoryIdSchema = z25.object({
4979
- id: z25.string()
4980
- });
4981
- var RepositoryIdSchema = z25.discriminatedUnion("type", [
4982
- z25.object({ type: z25.literal("github") }).merge(GithubRepositoryIdSchema)
4923
+ import { oc as oc13 } from "@orpc/contract";
4924
+ import * as z24 from "zod";
4925
+ var CheckRunSchema = z24.object({
4926
+ checkId: z24.string(),
4927
+ repositoryOwner: z24.string(),
4928
+ repositoryName: z24.string(),
4929
+ ref: z24.string(),
4930
+ name: z24.string(),
4931
+ status: z24.string(),
4932
+ conclusion: z24.string(),
4933
+ checkRunUrl: z24.string(),
4934
+ createdAt: z24.string(),
4935
+ completedAt: z24.string().nullish(),
4936
+ rawCheckRun: z24.unknown()
4937
+ });
4938
+ var GithubRepositoryIdSchema = z24.object({
4939
+ id: z24.string()
4940
+ });
4941
+ var RepositoryIdSchema = z24.discriminatedUnion("type", [
4942
+ z24.object({ type: z24.literal("github") }).merge(GithubRepositoryIdSchema)
4983
4943
  ]);
4984
- var BaseRepositorySchema = z25.object({
4944
+ var BaseRepositorySchema = z24.object({
4985
4945
  id: RepositoryIdSchema,
4986
- name: z25.string(),
4987
- owner: z25.string(),
4988
- fullName: z25.string(),
4989
- url: z25.string(),
4990
- repositoryOwnerOrganizationId: z25.string(),
4991
- defaultBranchChecks: z25.array(CheckRunSchema)
4946
+ name: z24.string(),
4947
+ owner: z24.string(),
4948
+ fullName: z24.string(),
4949
+ url: z24.string(),
4950
+ repositoryOwnerOrganizationId: z24.string(),
4951
+ defaultBranchChecks: z24.array(CheckRunSchema)
4992
4952
  });
4993
4953
  var SdkRepositorySchema = BaseRepositorySchema.extend({
4994
- type: z25.literal("sdk"),
4995
- sdkLanguage: z25.string()
4954
+ type: z24.literal("sdk"),
4955
+ sdkLanguage: z24.string()
4996
4956
  });
4997
4957
  var FernConfigRepositorySchema = BaseRepositorySchema.extend({
4998
- type: z25.literal("config")
4958
+ type: z24.literal("config")
4999
4959
  });
5000
- var FernRepositorySchema = z25.discriminatedUnion("type", [SdkRepositorySchema, FernConfigRepositorySchema]);
5001
- var GithubUserSchema = z25.object({
5002
- name: z25.string().nullish(),
5003
- email: z25.string().nullish(),
5004
- username: z25.string()
4960
+ var FernRepositorySchema = z24.discriminatedUnion("type", [SdkRepositorySchema, FernConfigRepositorySchema]);
4961
+ var GithubUserSchema = z24.object({
4962
+ name: z24.string().nullish(),
4963
+ email: z24.string().nullish(),
4964
+ username: z24.string()
5005
4965
  });
5006
- var GithubTeamSchema = z25.object({
5007
- name: z25.string(),
5008
- teamId: z25.string()
4966
+ var GithubTeamSchema = z24.object({
4967
+ name: z24.string(),
4968
+ teamId: z24.string()
5009
4969
  });
5010
- var PullRequestReviewerSchema = z25.discriminatedUnion("type", [
5011
- z25.object({ type: z25.literal("user") }).merge(GithubUserSchema),
5012
- z25.object({ type: z25.literal("team") }).merge(GithubTeamSchema)
4970
+ var PullRequestReviewerSchema = z24.discriminatedUnion("type", [
4971
+ z24.object({ type: z24.literal("user") }).merge(GithubUserSchema),
4972
+ z24.object({ type: z24.literal("team") }).merge(GithubTeamSchema)
5013
4973
  ]);
5014
- var PullRequestStateSchema = z25.enum(["open", "closed", "merged"]);
4974
+ var PullRequestStateSchema = z24.enum(["open", "closed", "merged"]);
5015
4975
  var PullRequestState = {
5016
4976
  Open: "open",
5017
4977
  Closed: "closed",
5018
4978
  Merged: "merged"
5019
4979
  };
5020
- var PullRequestSchema = z25.object({
5021
- pullRequestNumber: z25.number().int(),
5022
- repositoryName: z25.string(),
5023
- repositoryOwner: z25.string(),
4980
+ var PullRequestSchema = z24.object({
4981
+ pullRequestNumber: z24.number().int(),
4982
+ repositoryName: z24.string(),
4983
+ repositoryOwner: z24.string(),
5024
4984
  author: GithubUserSchema.nullish(),
5025
- reviewers: z25.array(PullRequestReviewerSchema),
5026
- title: z25.string(),
5027
- url: z25.string(),
5028
- checks: z25.array(CheckRunSchema),
4985
+ reviewers: z24.array(PullRequestReviewerSchema),
4986
+ title: z24.string(),
4987
+ url: z24.string(),
4988
+ checks: z24.array(CheckRunSchema),
5029
4989
  state: PullRequestStateSchema,
5030
- createdAt: z25.string(),
5031
- updatedAt: z25.string().nullish(),
5032
- mergedAt: z25.string().nullish(),
5033
- closedAt: z25.string().nullish()
5034
- });
5035
- var ListRepositoriesResponseSchema = z25.object({
5036
- repositories: z25.array(FernRepositorySchema)
5037
- });
5038
- var ListPullRequestsResponseSchema = z25.object({
5039
- pullRequests: z25.array(PullRequestSchema)
5040
- });
5041
- var GetRepositoryInputSchema = z25.object({
5042
- repositoryOwner: z25.string(),
5043
- repositoryName: z25.string()
5044
- });
5045
- var ListRepositoriesInputSchema = z25.object({
5046
- page: z25.number().int().nullish(),
5047
- pageSize: z25.number().int().nullish(),
5048
- organizationId: z25.string().nullish(),
5049
- repositoryName: z25.string().nullish(),
5050
- repositoryOwner: z25.string().nullish()
5051
- });
5052
- var DeleteRepositoryInputSchema = z25.object({
5053
- repositoryOwner: z25.string(),
5054
- repositoryName: z25.string()
5055
- });
5056
- var GetPullRequestInputSchema = z25.object({
5057
- repositoryOwner: z25.string(),
5058
- repositoryName: z25.string(),
5059
- pullRequestNumber: z25.coerce.number().int()
5060
- });
5061
- var ListPullRequestsInputSchema = z25.object({
5062
- page: z25.number().int().nullish(),
5063
- pageSize: z25.number().int().nullish(),
5064
- repositoryName: z25.string().nullish(),
5065
- repositoryOwner: z25.string().nullish(),
5066
- organizationId: z25.string().nullish(),
5067
- state: z25.array(PullRequestStateSchema).nullish(),
5068
- author: z25.array(z25.string()).nullish()
5069
- });
5070
- var DeletePullRequestInputSchema = z25.object({
5071
- repositoryOwner: z25.string(),
5072
- repositoryName: z25.string(),
5073
- pullRequestNumber: z25.coerce.number().int()
4990
+ createdAt: z24.string(),
4991
+ updatedAt: z24.string().nullish(),
4992
+ mergedAt: z24.string().nullish(),
4993
+ closedAt: z24.string().nullish()
4994
+ });
4995
+ var ListRepositoriesResponseSchema = z24.object({
4996
+ repositories: z24.array(FernRepositorySchema)
4997
+ });
4998
+ var ListPullRequestsResponseSchema = z24.object({
4999
+ pullRequests: z24.array(PullRequestSchema)
5000
+ });
5001
+ var GetRepositoryInputSchema = z24.object({
5002
+ repositoryOwner: z24.string(),
5003
+ repositoryName: z24.string()
5004
+ });
5005
+ var ListRepositoriesInputSchema = z24.object({
5006
+ page: z24.number().int().nullish(),
5007
+ pageSize: z24.number().int().nullish(),
5008
+ organizationId: z24.string().nullish(),
5009
+ repositoryName: z24.string().nullish(),
5010
+ repositoryOwner: z24.string().nullish()
5011
+ });
5012
+ var DeleteRepositoryInputSchema = z24.object({
5013
+ repositoryOwner: z24.string(),
5014
+ repositoryName: z24.string()
5015
+ });
5016
+ var GetPullRequestInputSchema = z24.object({
5017
+ repositoryOwner: z24.string(),
5018
+ repositoryName: z24.string(),
5019
+ pullRequestNumber: z24.coerce.number().int()
5020
+ });
5021
+ var ListPullRequestsInputSchema = z24.object({
5022
+ page: z24.number().int().nullish(),
5023
+ pageSize: z24.number().int().nullish(),
5024
+ repositoryName: z24.string().nullish(),
5025
+ repositoryOwner: z24.string().nullish(),
5026
+ organizationId: z24.string().nullish(),
5027
+ state: z24.array(PullRequestStateSchema).nullish(),
5028
+ author: z24.array(z24.string()).nullish()
5029
+ });
5030
+ var DeletePullRequestInputSchema = z24.object({
5031
+ repositoryOwner: z24.string(),
5032
+ repositoryName: z24.string(),
5033
+ pullRequestNumber: z24.coerce.number().int()
5074
5034
  });
5075
5035
  var gitContract = {
5076
- getRepository: oc14.route({ method: "GET", path: "/repository/{repositoryOwner}/{repositoryName}" }).input(GetRepositoryInputSchema).output(FernRepositorySchema),
5077
- listRepositories: oc14.route({ method: "POST", path: "/repository/list" }).input(ListRepositoriesInputSchema).output(ListRepositoriesResponseSchema),
5078
- upsertRepository: oc14.route({ method: "PUT", path: "/repository/upsert" }).input(FernRepositorySchema),
5079
- deleteRepository: oc14.route({ method: "DELETE", path: "/repository/{repositoryOwner}/{repositoryName}/delete" }).input(DeleteRepositoryInputSchema),
5080
- getPullRequest: oc14.route({ method: "GET", path: "/pull-request/{repositoryOwner}/{repositoryName}/{pullRequestNumber}" }).input(GetPullRequestInputSchema).output(PullRequestSchema),
5081
- listPullRequests: oc14.route({ method: "POST", path: "/pull-request/list" }).input(ListPullRequestsInputSchema).output(ListPullRequestsResponseSchema),
5082
- upsertPullRequest: oc14.route({ method: "PUT", path: "/pull-request/upsert" }).input(PullRequestSchema),
5083
- deletePullRequest: oc14.route({
5036
+ getRepository: oc13.route({ method: "GET", path: "/repository/{repositoryOwner}/{repositoryName}" }).input(GetRepositoryInputSchema).output(FernRepositorySchema),
5037
+ listRepositories: oc13.route({ method: "POST", path: "/repository/list" }).input(ListRepositoriesInputSchema).output(ListRepositoriesResponseSchema),
5038
+ upsertRepository: oc13.route({ method: "PUT", path: "/repository/upsert" }).input(FernRepositorySchema),
5039
+ deleteRepository: oc13.route({ method: "DELETE", path: "/repository/{repositoryOwner}/{repositoryName}/delete" }).input(DeleteRepositoryInputSchema),
5040
+ getPullRequest: oc13.route({ method: "GET", path: "/pull-request/{repositoryOwner}/{repositoryName}/{pullRequestNumber}" }).input(GetPullRequestInputSchema).output(PullRequestSchema),
5041
+ listPullRequests: oc13.route({ method: "POST", path: "/pull-request/list" }).input(ListPullRequestsInputSchema).output(ListPullRequestsResponseSchema),
5042
+ upsertPullRequest: oc13.route({ method: "PUT", path: "/pull-request/upsert" }).input(PullRequestSchema),
5043
+ deletePullRequest: oc13.route({
5084
5044
  method: "DELETE",
5085
5045
  path: "/pull-request/{repositoryOwner}/{repositoryName}/{pullRequestNumber}/delete"
5086
5046
  }).input(DeletePullRequestInputSchema)
@@ -5088,7 +5048,7 @@ var gitContract = {
5088
5048
 
5089
5049
  // src/orpc-client/git/client.ts
5090
5050
  function createGitClient(options) {
5091
- const link = new OpenAPILink16(gitContract, {
5051
+ const link = new OpenAPILink15(gitContract, {
5092
5052
  url: `${options.baseUrl}/generators/github`,
5093
5053
  headers: () => ({
5094
5054
  Authorization: `Bearer ${options.token}`,
@@ -5096,106 +5056,106 @@ function createGitClient(options) {
5096
5056
  }),
5097
5057
  ...options.fetch != null ? { fetch: options.fetch } : {}
5098
5058
  });
5099
- return createORPCClient16(link);
5059
+ return createORPCClient15(link);
5100
5060
  }
5101
5061
 
5102
5062
  // src/orpc-client/pdf-export/client.ts
5103
- import { createORPCClient as createORPCClient17 } from "@orpc/client";
5104
- import { OpenAPILink as OpenAPILink17 } from "@orpc/openapi-client/fetch";
5063
+ import { createORPCClient as createORPCClient16 } from "@orpc/client";
5064
+ import { OpenAPILink as OpenAPILink16 } from "@orpc/openapi-client/fetch";
5105
5065
 
5106
5066
  // src/orpc-client/pdf-export/contract.ts
5107
- import { oc as oc15 } from "@orpc/contract";
5108
- import * as z26 from "zod";
5109
- var PdfExportScopeSchema = z26.object({
5110
- pageSlugs: z26.array(z26.string())
5111
- });
5112
- var PdfExportOptionsV1Schema = z26.object({
5113
- coverTitle: z26.string().nullish(),
5114
- coverSubtitle: z26.string().nullish(),
5115
- hideCoverFooter: z26.boolean().nullish(),
5116
- headerLeftTemplate: z26.string().nullish(),
5117
- headerRightTemplate: z26.string().nullish(),
5118
- footerLeftTemplate: z26.string().nullish(),
5119
- footerRightTemplate: z26.string().nullish(),
5067
+ import { oc as oc14 } from "@orpc/contract";
5068
+ import * as z25 from "zod";
5069
+ var PdfExportScopeSchema = z25.object({
5070
+ pageSlugs: z25.array(z25.string())
5071
+ });
5072
+ var PdfExportOptionsV1Schema = z25.object({
5073
+ coverTitle: z25.string().nullish(),
5074
+ coverSubtitle: z25.string().nullish(),
5075
+ hideCoverFooter: z25.boolean().nullish(),
5076
+ headerLeftTemplate: z25.string().nullish(),
5077
+ headerRightTemplate: z25.string().nullish(),
5078
+ footerLeftTemplate: z25.string().nullish(),
5079
+ footerRightTemplate: z25.string().nullish(),
5120
5080
  scope: PdfExportScopeSchema.nullish(),
5121
- hideCover: z26.boolean().nullish(),
5122
- hideToc: z26.boolean().nullish()
5081
+ hideCover: z25.boolean().nullish(),
5082
+ hideToc: z25.boolean().nullish()
5123
5083
  });
5124
- var PdfExportOptionsSchema = z26.discriminatedUnion("version", [
5125
- z26.object({ version: z26.literal("v1") }).merge(PdfExportOptionsV1Schema)
5084
+ var PdfExportOptionsSchema = z25.discriminatedUnion("version", [
5085
+ z25.object({ version: z25.literal("v1") }).merge(PdfExportOptionsV1Schema)
5126
5086
  ]);
5127
- var PdfExportTaskStatusSchema = z26.enum(["PENDING", "RUNNING", "COMPLETED", "FAILED"]);
5128
- var PdfExportTaskSchema = z26.object({
5129
- id: z26.string(),
5130
- orgId: z26.string(),
5131
- docsUrl: z26.string(),
5132
- productId: z26.string().nullish(),
5133
- versionId: z26.string().nullish(),
5134
- requesterName: z26.string().nullish(),
5135
- notifyEmails: z26.array(z26.string()).nullish(),
5087
+ var PdfExportTaskStatusSchema = z25.enum(["PENDING", "RUNNING", "COMPLETED", "FAILED"]);
5088
+ var PdfExportTaskSchema = z25.object({
5089
+ id: z25.string(),
5090
+ orgId: z25.string(),
5091
+ docsUrl: z25.string(),
5092
+ productId: z25.string().nullish(),
5093
+ versionId: z25.string().nullish(),
5094
+ requesterName: z25.string().nullish(),
5095
+ notifyEmails: z25.array(z25.string()).nullish(),
5136
5096
  status: PdfExportTaskStatusSchema,
5137
5097
  options: PdfExportOptionsSchema.nullish(),
5138
- createdAt: z26.string(),
5139
- startedAt: z26.string().nullish(),
5140
- completedAt: z26.string().nullish(),
5141
- fileName: z26.string().nullish(),
5142
- sizeBytes: z26.number().nullish(),
5143
- errorMessage: z26.string().nullish()
5144
- });
5145
- var ListPdfExportTasksResponseSchema = z26.object({
5146
- tasks: z26.array(PdfExportTaskSchema)
5147
- });
5148
- var PdfExportDownloadResponseSchema = z26.object({
5149
- downloadUrl: z26.string(),
5150
- fileName: z26.string(),
5151
- sizeBytes: z26.number()
5152
- });
5153
- var CreatePdfExportTaskInputSchema = z26.object({
5154
- orgId: z26.string(),
5155
- docsUrl: z26.string(),
5156
- productId: z26.string().nullish(),
5157
- versionId: z26.string().nullish(),
5158
- requesterName: z26.string().nullish(),
5098
+ createdAt: z25.string(),
5099
+ startedAt: z25.string().nullish(),
5100
+ completedAt: z25.string().nullish(),
5101
+ fileName: z25.string().nullish(),
5102
+ sizeBytes: z25.number().nullish(),
5103
+ errorMessage: z25.string().nullish()
5104
+ });
5105
+ var ListPdfExportTasksResponseSchema = z25.object({
5106
+ tasks: z25.array(PdfExportTaskSchema)
5107
+ });
5108
+ var PdfExportDownloadResponseSchema = z25.object({
5109
+ downloadUrl: z25.string(),
5110
+ fileName: z25.string(),
5111
+ sizeBytes: z25.number()
5112
+ });
5113
+ var CreatePdfExportTaskInputSchema = z25.object({
5114
+ orgId: z25.string(),
5115
+ docsUrl: z25.string(),
5116
+ productId: z25.string().nullish(),
5117
+ versionId: z25.string().nullish(),
5118
+ requesterName: z25.string().nullish(),
5159
5119
  options: PdfExportOptionsSchema.nullish()
5160
5120
  });
5161
- var ListPdfExportTasksInputSchema = z26.object({
5162
- orgId: z26.string(),
5163
- docsUrl: z26.string(),
5164
- limit: z26.coerce.number().nullish()
5121
+ var ListPdfExportTasksInputSchema = z25.object({
5122
+ orgId: z25.string(),
5123
+ docsUrl: z25.string(),
5124
+ limit: z25.coerce.number().nullish()
5165
5125
  });
5166
- var GetPdfExportTaskInputSchema = z26.object({
5167
- taskId: z26.string()
5126
+ var GetPdfExportTaskInputSchema = z25.object({
5127
+ taskId: z25.string()
5168
5128
  });
5169
- var UpdatePdfExportTaskInputSchema = z26.object({
5170
- taskId: z26.string(),
5129
+ var UpdatePdfExportTaskInputSchema = z25.object({
5130
+ taskId: z25.string(),
5171
5131
  status: PdfExportTaskStatusSchema,
5172
- startedAt: z26.string().nullish(),
5173
- completedAt: z26.string().nullish(),
5174
- s3Key: z26.string().nullish(),
5175
- fileName: z26.string().nullish(),
5176
- sizeBytes: z26.number().nullish(),
5177
- errorMessage: z26.string().nullish()
5132
+ startedAt: z25.string().nullish(),
5133
+ completedAt: z25.string().nullish(),
5134
+ s3Key: z25.string().nullish(),
5135
+ fileName: z25.string().nullish(),
5136
+ sizeBytes: z25.number().nullish(),
5137
+ errorMessage: z25.string().nullish()
5178
5138
  });
5179
- var GetPdfExportDownloadUrlInputSchema = z26.object({
5180
- taskId: z26.string()
5139
+ var GetPdfExportDownloadUrlInputSchema = z25.object({
5140
+ taskId: z25.string()
5181
5141
  });
5182
- var CleanupPdfExportsResponseSchema = z26.object({
5183
- expiredTasksDeleted: z26.number(),
5184
- s3ObjectsDeleted: z26.number(),
5185
- timedOutTasksFailed: z26.number()
5142
+ var CleanupPdfExportsResponseSchema = z25.object({
5143
+ expiredTasksDeleted: z25.number(),
5144
+ s3ObjectsDeleted: z25.number(),
5145
+ timedOutTasksFailed: z25.number()
5186
5146
  });
5187
5147
  var pdfExportContract = {
5188
- createTask: oc15.route({ method: "POST", path: "/task" }).input(CreatePdfExportTaskInputSchema).output(PdfExportTaskSchema),
5189
- listTasks: oc15.route({ method: "GET", path: "/tasks" }).input(ListPdfExportTasksInputSchema).output(ListPdfExportTasksResponseSchema),
5190
- getTask: oc15.route({ method: "GET", path: "/task/{taskId}" }).input(GetPdfExportTaskInputSchema).output(PdfExportTaskSchema),
5191
- updateTask: oc15.route({ method: "POST", path: "/task/{taskId}" }).input(UpdatePdfExportTaskInputSchema).output(PdfExportTaskSchema),
5192
- getDownloadUrl: oc15.route({ method: "GET", path: "/task/{taskId}/download-url" }).input(GetPdfExportDownloadUrlInputSchema).output(PdfExportDownloadResponseSchema),
5193
- cleanup: oc15.route({ method: "POST", path: "/cleanup" }).output(CleanupPdfExportsResponseSchema)
5148
+ createTask: oc14.route({ method: "POST", path: "/task" }).input(CreatePdfExportTaskInputSchema).output(PdfExportTaskSchema),
5149
+ listTasks: oc14.route({ method: "GET", path: "/tasks" }).input(ListPdfExportTasksInputSchema).output(ListPdfExportTasksResponseSchema),
5150
+ getTask: oc14.route({ method: "GET", path: "/task/{taskId}" }).input(GetPdfExportTaskInputSchema).output(PdfExportTaskSchema),
5151
+ updateTask: oc14.route({ method: "POST", path: "/task/{taskId}" }).input(UpdatePdfExportTaskInputSchema).output(PdfExportTaskSchema),
5152
+ getDownloadUrl: oc14.route({ method: "GET", path: "/task/{taskId}/download-url" }).input(GetPdfExportDownloadUrlInputSchema).output(PdfExportDownloadResponseSchema),
5153
+ cleanup: oc14.route({ method: "POST", path: "/cleanup" }).output(CleanupPdfExportsResponseSchema)
5194
5154
  };
5195
5155
 
5196
5156
  // src/orpc-client/pdf-export/client.ts
5197
5157
  function createPdfExportClient(options) {
5198
- const link = new OpenAPILink17(pdfExportContract, {
5158
+ const link = new OpenAPILink16(pdfExportContract, {
5199
5159
  url: `${options.baseUrl}/pdf-export`,
5200
5160
  headers: () => ({
5201
5161
  Authorization: `Bearer ${options.token}`,
@@ -5203,17 +5163,17 @@ function createPdfExportClient(options) {
5203
5163
  }),
5204
5164
  ...options.fetch != null ? { fetch: options.fetch } : {}
5205
5165
  });
5206
- return createORPCClient17(link);
5166
+ return createORPCClient16(link);
5207
5167
  }
5208
5168
 
5209
5169
  // src/orpc-client/sdks/client.ts
5210
- import { createORPCClient as createORPCClient18 } from "@orpc/client";
5211
- import { OpenAPILink as OpenAPILink18 } from "@orpc/openapi-client/fetch";
5170
+ import { createORPCClient as createORPCClient17 } from "@orpc/client";
5171
+ import { OpenAPILink as OpenAPILink17 } from "@orpc/openapi-client/fetch";
5212
5172
 
5213
5173
  // src/orpc-client/sdks/contract.ts
5214
- import { oc as oc16 } from "@orpc/contract";
5215
- import * as z27 from "zod";
5216
- var LanguageEnumSchema = z27.enum([
5174
+ import { oc as oc15 } from "@orpc/contract";
5175
+ import * as z26 from "zod";
5176
+ var LanguageEnumSchema = z26.enum([
5217
5177
  "Go",
5218
5178
  "TypeScript",
5219
5179
  "Java",
@@ -5224,23 +5184,23 @@ var LanguageEnumSchema = z27.enum([
5224
5184
  "Swift",
5225
5185
  "Rust"
5226
5186
  ]);
5227
- var VersionBumpEnumSchema = z27.enum(["MAJOR", "MINOR", "PATCH"]);
5228
- var ComputeSemanticVersionInputSchema = z27.object({
5229
- package: z27.string(),
5187
+ var VersionBumpEnumSchema = z26.enum(["MAJOR", "MINOR", "PATCH"]);
5188
+ var ComputeSemanticVersionInputSchema = z26.object({
5189
+ package: z26.string(),
5230
5190
  language: LanguageEnumSchema,
5231
- githubRepository: z27.string().nullish()
5191
+ githubRepository: z26.string().nullish()
5232
5192
  });
5233
- var ComputeSemanticVersionOutputSchema = z27.object({
5234
- version: z27.string(),
5193
+ var ComputeSemanticVersionOutputSchema = z26.object({
5194
+ version: z26.string(),
5235
5195
  bump: VersionBumpEnumSchema
5236
5196
  });
5237
5197
  var sdksContract = {
5238
- computeSemanticVersion: oc16.route({ method: "POST", path: "/semantic-version/compute" }).input(ComputeSemanticVersionInputSchema).output(ComputeSemanticVersionOutputSchema)
5198
+ computeSemanticVersion: oc15.route({ method: "POST", path: "/semantic-version/compute" }).input(ComputeSemanticVersionInputSchema).output(ComputeSemanticVersionOutputSchema)
5239
5199
  };
5240
5200
 
5241
5201
  // src/orpc-client/sdks/client.ts
5242
5202
  function createSdksClient(options) {
5243
- const link = new OpenAPILink18(sdksContract, {
5203
+ const link = new OpenAPILink17(sdksContract, {
5244
5204
  url: `${options.baseUrl}/sdks`,
5245
5205
  headers: () => ({
5246
5206
  Authorization: `Bearer ${options.token}`,
@@ -5248,50 +5208,50 @@ function createSdksClient(options) {
5248
5208
  }),
5249
5209
  ...options.fetch != null ? { fetch: options.fetch } : {}
5250
5210
  });
5251
- return createORPCClient18(link);
5211
+ return createORPCClient17(link);
5252
5212
  }
5253
5213
 
5254
5214
  // src/orpc-client/slugs/client.ts
5255
- import { createORPCClient as createORPCClient19 } from "@orpc/client";
5256
- import { OpenAPILink as OpenAPILink19 } from "@orpc/openapi-client/fetch";
5215
+ import { createORPCClient as createORPCClient18 } from "@orpc/client";
5216
+ import { OpenAPILink as OpenAPILink18 } from "@orpc/openapi-client/fetch";
5257
5217
 
5258
5218
  // src/orpc-client/slugs/contract.ts
5259
- import { oc as oc17 } from "@orpc/contract";
5260
- import * as z28 from "zod";
5261
- var SlugsInputSchema = z28.object({
5262
- domain: z28.string(),
5263
- basepath: z28.string().optional().default("")
5264
- });
5265
- var SlugEntrySchema = z28.object({
5266
- orgId: z28.string(),
5267
- domain: z28.string(),
5268
- basepath: z28.string(),
5269
- slug: z28.string(),
5270
- lastUpdated: z28.string()
5271
- });
5272
- var MarkdownEntrySchema = z28.object({
5273
- orgId: z28.string(),
5274
- domain: z28.string(),
5275
- basepath: z28.string(),
5276
- pageId: z28.string(),
5277
- slug: z28.string(),
5278
- hash: z28.string(),
5279
- lastUpdated: z28.string()
5280
- });
5281
- var GetSlugEntriesResponseSchema = z28.object({
5282
- entries: z28.array(SlugEntrySchema)
5283
- });
5284
- var GetMarkdownEntriesResponseSchema = z28.object({
5285
- entries: z28.array(MarkdownEntrySchema)
5219
+ import { oc as oc16 } from "@orpc/contract";
5220
+ import * as z27 from "zod";
5221
+ var SlugsInputSchema = z27.object({
5222
+ domain: z27.string(),
5223
+ basepath: z27.string().optional().default("")
5224
+ });
5225
+ var SlugEntrySchema = z27.object({
5226
+ orgId: z27.string(),
5227
+ domain: z27.string(),
5228
+ basepath: z27.string(),
5229
+ slug: z27.string(),
5230
+ lastUpdated: z27.string()
5231
+ });
5232
+ var MarkdownEntrySchema = z27.object({
5233
+ orgId: z27.string(),
5234
+ domain: z27.string(),
5235
+ basepath: z27.string(),
5236
+ pageId: z27.string(),
5237
+ slug: z27.string(),
5238
+ hash: z27.string(),
5239
+ lastUpdated: z27.string()
5240
+ });
5241
+ var GetSlugEntriesResponseSchema = z27.object({
5242
+ entries: z27.array(SlugEntrySchema)
5243
+ });
5244
+ var GetMarkdownEntriesResponseSchema = z27.object({
5245
+ entries: z27.array(MarkdownEntrySchema)
5286
5246
  });
5287
5247
  var slugsContract = {
5288
- getSlugEntries: oc17.route({ method: "POST", path: "/slugs" }).input(SlugsInputSchema).output(GetSlugEntriesResponseSchema),
5289
- getMarkdownEntries: oc17.route({ method: "POST", path: "/markdowns" }).input(SlugsInputSchema).output(GetMarkdownEntriesResponseSchema)
5248
+ getSlugEntries: oc16.route({ method: "POST", path: "/slugs" }).input(SlugsInputSchema).output(GetSlugEntriesResponseSchema),
5249
+ getMarkdownEntries: oc16.route({ method: "POST", path: "/markdowns" }).input(SlugsInputSchema).output(GetMarkdownEntriesResponseSchema)
5290
5250
  };
5291
5251
 
5292
5252
  // src/orpc-client/slugs/client.ts
5293
5253
  function createSlugsClient(options) {
5294
- const link = new OpenAPILink19(slugsContract, {
5254
+ const link = new OpenAPILink18(slugsContract, {
5295
5255
  url: `${options.baseUrl.replace(/\/+$/, "")}/slugs`,
5296
5256
  headers: () => ({
5297
5257
  Authorization: `Bearer ${options.token}`,
@@ -5299,118 +5259,118 @@ function createSlugsClient(options) {
5299
5259
  }),
5300
5260
  ...options.fetch != null ? { fetch: options.fetch } : {}
5301
5261
  });
5302
- return createORPCClient19(link);
5262
+ return createORPCClient18(link);
5303
5263
  }
5304
5264
 
5305
5265
  // src/orpc-client/snippets/client.ts
5306
- import { createORPCClient as createORPCClient20 } from "@orpc/client";
5307
- import { OpenAPILink as OpenAPILink20 } from "@orpc/openapi-client/fetch";
5266
+ import { createORPCClient as createORPCClient19 } from "@orpc/client";
5267
+ import { OpenAPILink as OpenAPILink19 } from "@orpc/openapi-client/fetch";
5308
5268
 
5309
5269
  // src/orpc-client/snippets/contract.ts
5310
- import { oc as oc18 } from "@orpc/contract";
5311
- import * as z29 from "zod";
5312
- var TypeScriptSdkSchema = z29.object({ package: z29.string(), version: z29.string() });
5313
- var PythonSdkSchema = z29.object({ package: z29.string(), version: z29.string() });
5314
- var GoSdkSchema = z29.object({ githubRepo: z29.string(), version: z29.string() });
5315
- var RubySdkSchema = z29.object({ gem: z29.string(), version: z29.string() });
5316
- var JavaSdkSchema = z29.object({ group: z29.string(), artifact: z29.string(), version: z29.string() });
5317
- var CsharpSdkSchema = z29.object({ package: z29.string(), version: z29.string() });
5318
- var BaseSnippetCreateSchema = z29.object({
5270
+ import { oc as oc17 } from "@orpc/contract";
5271
+ import * as z28 from "zod";
5272
+ var TypeScriptSdkSchema = z28.object({ package: z28.string(), version: z28.string() });
5273
+ var PythonSdkSchema = z28.object({ package: z28.string(), version: z28.string() });
5274
+ var GoSdkSchema = z28.object({ githubRepo: z28.string(), version: z28.string() });
5275
+ var RubySdkSchema = z28.object({ gem: z28.string(), version: z28.string() });
5276
+ var JavaSdkSchema = z28.object({ group: z28.string(), artifact: z28.string(), version: z28.string() });
5277
+ var CsharpSdkSchema = z28.object({ package: z28.string(), version: z28.string() });
5278
+ var BaseSnippetCreateSchema = z28.object({
5319
5279
  endpoint: EndpointIdentifierSchema,
5320
- exampleIdentifier: z29.string().nullish()
5280
+ exampleIdentifier: z28.string().nullish()
5321
5281
  });
5322
- var SdkSnippetsCreateSchema = z29.discriminatedUnion("type", [
5323
- z29.object({
5324
- type: z29.literal("typescript"),
5282
+ var SdkSnippetsCreateSchema = z28.discriminatedUnion("type", [
5283
+ z28.object({
5284
+ type: z28.literal("typescript"),
5325
5285
  sdk: TypeScriptSdkSchema,
5326
- snippets: z29.array(BaseSnippetCreateSchema.extend({ snippet: z29.object({ client: z29.string() }) }))
5286
+ snippets: z28.array(BaseSnippetCreateSchema.extend({ snippet: z28.object({ client: z28.string() }) }))
5327
5287
  }),
5328
- z29.object({
5329
- type: z29.literal("python"),
5288
+ z28.object({
5289
+ type: z28.literal("python"),
5330
5290
  sdk: PythonSdkSchema,
5331
- snippets: z29.array(
5291
+ snippets: z28.array(
5332
5292
  BaseSnippetCreateSchema.extend({
5333
- snippet: z29.object({ async_client: z29.string(), sync_client: z29.string() })
5293
+ snippet: z28.object({ async_client: z28.string(), sync_client: z28.string() })
5334
5294
  })
5335
5295
  )
5336
5296
  }),
5337
- z29.object({
5338
- type: z29.literal("go"),
5297
+ z28.object({
5298
+ type: z28.literal("go"),
5339
5299
  sdk: GoSdkSchema,
5340
- snippets: z29.array(BaseSnippetCreateSchema.extend({ snippet: z29.object({ client: z29.string() }) }))
5300
+ snippets: z28.array(BaseSnippetCreateSchema.extend({ snippet: z28.object({ client: z28.string() }) }))
5341
5301
  }),
5342
- z29.object({
5343
- type: z29.literal("java"),
5302
+ z28.object({
5303
+ type: z28.literal("java"),
5344
5304
  sdk: JavaSdkSchema,
5345
- snippets: z29.array(
5305
+ snippets: z28.array(
5346
5306
  BaseSnippetCreateSchema.extend({
5347
- snippet: z29.object({ async_client: z29.string(), sync_client: z29.string() })
5307
+ snippet: z28.object({ async_client: z28.string(), sync_client: z28.string() })
5348
5308
  })
5349
5309
  )
5350
5310
  }),
5351
- z29.object({
5352
- type: z29.literal("ruby"),
5311
+ z28.object({
5312
+ type: z28.literal("ruby"),
5353
5313
  sdk: RubySdkSchema,
5354
- snippets: z29.array(BaseSnippetCreateSchema.extend({ snippet: z29.object({ client: z29.string() }) }))
5314
+ snippets: z28.array(BaseSnippetCreateSchema.extend({ snippet: z28.object({ client: z28.string() }) }))
5355
5315
  }),
5356
- z29.object({
5357
- type: z29.literal("csharp"),
5316
+ z28.object({
5317
+ type: z28.literal("csharp"),
5358
5318
  sdk: CsharpSdkSchema,
5359
- snippets: z29.array(BaseSnippetCreateSchema.extend({ snippet: z29.object({ client: z29.string() }) }))
5319
+ snippets: z28.array(BaseSnippetCreateSchema.extend({ snippet: z28.object({ client: z28.string() }) }))
5360
5320
  })
5361
5321
  ]);
5362
5322
  var snippetsFactoryContract = {
5363
- createSnippetsForSdk: oc18.route({ method: "POST", path: "/create" }).input(
5364
- z29.object({
5365
- orgId: z29.string(),
5366
- apiId: z29.string(),
5323
+ createSnippetsForSdk: oc17.route({ method: "POST", path: "/create" }).input(
5324
+ z28.object({
5325
+ orgId: z28.string(),
5326
+ apiId: z28.string(),
5367
5327
  snippets: SdkSnippetsCreateSchema
5368
5328
  })
5369
5329
  )
5370
5330
  };
5371
- var ParameterPayloadSchema = z29.object({
5372
- name: z29.string(),
5373
- value: z29.unknown()
5331
+ var ParameterPayloadSchema = z28.object({
5332
+ name: z28.string(),
5333
+ value: z28.unknown()
5374
5334
  });
5375
- var AuthPayloadSchema = z29.discriminatedUnion("type", [
5376
- z29.object({ type: z29.literal("bearer"), token: z29.string() }),
5377
- z29.object({ type: z29.literal("basic"), username: z29.string(), password: z29.string() })
5335
+ var AuthPayloadSchema = z28.discriminatedUnion("type", [
5336
+ z28.object({ type: z28.literal("bearer"), token: z28.string() }),
5337
+ z28.object({ type: z28.literal("basic"), username: z28.string(), password: z28.string() })
5378
5338
  ]);
5379
- var CustomSnippetPayloadSchema = z29.object({
5380
- headers: z29.array(ParameterPayloadSchema).nullish(),
5381
- pathParameters: z29.array(ParameterPayloadSchema).nullish(),
5382
- queryParameters: z29.array(ParameterPayloadSchema).nullish(),
5383
- requestBody: z29.unknown().nullish(),
5339
+ var CustomSnippetPayloadSchema = z28.object({
5340
+ headers: z28.array(ParameterPayloadSchema).nullish(),
5341
+ pathParameters: z28.array(ParameterPayloadSchema).nullish(),
5342
+ queryParameters: z28.array(ParameterPayloadSchema).nullish(),
5343
+ requestBody: z28.unknown().nullish(),
5384
5344
  auth: AuthPayloadSchema.nullish()
5385
5345
  });
5386
5346
  var snippetsContract = {
5387
- get: oc18.route({ method: "POST", path: "/" }).input(
5388
- z29.object({
5389
- orgId: z29.string().nullish(),
5390
- apiId: z29.string().nullish(),
5391
- sdks: z29.array(SdkRequestSchema).nullish(),
5347
+ get: oc17.route({ method: "POST", path: "/" }).input(
5348
+ z28.object({
5349
+ orgId: z28.string().nullish(),
5350
+ apiId: z28.string().nullish(),
5351
+ sdks: z28.array(SdkRequestSchema).nullish(),
5392
5352
  endpoint: EndpointIdentifierSchema,
5393
- exampleIdentifier: z29.string().nullish(),
5353
+ exampleIdentifier: z28.string().nullish(),
5394
5354
  payload: CustomSnippetPayloadSchema.nullish()
5395
5355
  })
5396
- ).output(z29.array(z29.unknown())),
5397
- load: oc18.route({ method: "POST", path: "/load" }).input(
5398
- z29.object({
5399
- orgId: z29.string().nullish(),
5400
- apiId: z29.string().nullish(),
5401
- sdks: z29.array(SdkRequestSchema).nullish()
5356
+ ).output(z28.array(z28.unknown())),
5357
+ load: oc17.route({ method: "POST", path: "/load" }).input(
5358
+ z28.object({
5359
+ orgId: z28.string().nullish(),
5360
+ apiId: z28.string().nullish(),
5361
+ sdks: z28.array(SdkRequestSchema).nullish()
5402
5362
  })
5403
5363
  ).output(
5404
- z29.object({
5405
- next: z29.number().nullish(),
5406
- snippets: z29.record(z29.string(), z29.unknown())
5364
+ z28.object({
5365
+ next: z28.number().nullish(),
5366
+ snippets: z28.record(z28.string(), z28.unknown())
5407
5367
  })
5408
5368
  )
5409
5369
  };
5410
5370
 
5411
5371
  // src/orpc-client/snippets/client.ts
5412
5372
  function createSnippetsFactoryClient(options) {
5413
- const link = new OpenAPILink20(snippetsFactoryContract, {
5373
+ const link = new OpenAPILink19(snippetsFactoryContract, {
5414
5374
  url: `${options.baseUrl}/snippets`,
5415
5375
  headers: () => ({
5416
5376
  Authorization: `Bearer ${options.token}`,
@@ -5418,10 +5378,10 @@ function createSnippetsFactoryClient(options) {
5418
5378
  }),
5419
5379
  ...options.fetch != null ? { fetch: options.fetch } : {}
5420
5380
  });
5421
- return createORPCClient20(link);
5381
+ return createORPCClient19(link);
5422
5382
  }
5423
5383
  function createSnippetsClient(options) {
5424
- const link = new OpenAPILink20(snippetsContract, {
5384
+ const link = new OpenAPILink19(snippetsContract, {
5425
5385
  url: `${options.baseUrl}/snippets`,
5426
5386
  headers: () => ({
5427
5387
  Authorization: `Bearer ${options.token}`,
@@ -5429,63 +5389,63 @@ function createSnippetsClient(options) {
5429
5389
  }),
5430
5390
  ...options.fetch != null ? { fetch: options.fetch } : {}
5431
5391
  });
5432
- return createORPCClient20(link);
5392
+ return createORPCClient19(link);
5433
5393
  }
5434
5394
 
5435
5395
  // src/orpc-client/templates/client.ts
5436
- import { createORPCClient as createORPCClient21 } from "@orpc/client";
5437
- import { OpenAPILink as OpenAPILink21 } from "@orpc/openapi-client/fetch";
5396
+ import { createORPCClient as createORPCClient20 } from "@orpc/client";
5397
+ import { OpenAPILink as OpenAPILink20 } from "@orpc/openapi-client/fetch";
5438
5398
 
5439
5399
  // src/orpc-client/templates/contract.ts
5440
- import { oc as oc19 } from "@orpc/contract";
5441
- import * as z30 from "zod";
5442
- var SnippetRegistryEntrySchema = z30.object({
5400
+ import { oc as oc18 } from "@orpc/contract";
5401
+ import * as z29 from "zod";
5402
+ var SnippetRegistryEntrySchema = z29.object({
5443
5403
  sdk: SdkSchema,
5444
- endpointId: z30.object({
5445
- path: z30.string(),
5404
+ endpointId: z29.object({
5405
+ path: z29.string(),
5446
5406
  method: HttpMethodSchema,
5447
- identifierOverride: z30.string().nullish()
5407
+ identifierOverride: z29.string().nullish()
5448
5408
  }),
5449
- snippetTemplate: z30.object({
5450
- type: z30.literal("v1"),
5451
- functionInvocation: z30.unknown(),
5452
- clientInstantiation: z30.string()
5409
+ snippetTemplate: z29.object({
5410
+ type: z29.literal("v1"),
5411
+ functionInvocation: z29.unknown(),
5412
+ clientInstantiation: z29.string()
5453
5413
  }),
5454
- additionalTemplates: z30.record(z30.string(), z30.unknown()).nullish()
5414
+ additionalTemplates: z29.record(z29.string(), z29.unknown()).nullish()
5455
5415
  });
5456
- var RegisterInputSchema = z30.object({
5457
- orgId: z30.string(),
5458
- apiId: z30.string(),
5459
- apiDefinitionId: z30.string(),
5416
+ var RegisterInputSchema = z29.object({
5417
+ orgId: z29.string(),
5418
+ apiId: z29.string(),
5419
+ apiDefinitionId: z29.string(),
5460
5420
  snippet: SnippetRegistryEntrySchema
5461
5421
  });
5462
- var RegisterBatchInputSchema = z30.object({
5463
- orgId: z30.string(),
5464
- apiId: z30.string(),
5465
- apiDefinitionId: z30.string(),
5466
- snippets: z30.array(SnippetRegistryEntrySchema)
5422
+ var RegisterBatchInputSchema = z29.object({
5423
+ orgId: z29.string(),
5424
+ apiId: z29.string(),
5425
+ apiDefinitionId: z29.string(),
5426
+ snippets: z29.array(SnippetRegistryEntrySchema)
5467
5427
  });
5468
- var GetInputSchema = z30.object({
5469
- orgId: z30.string(),
5470
- apiId: z30.string(),
5428
+ var GetInputSchema = z29.object({
5429
+ orgId: z29.string(),
5430
+ apiId: z29.string(),
5471
5431
  sdk: SdkSchema,
5472
- endpointId: z30.object({
5473
- path: z30.string(),
5432
+ endpointId: z29.object({
5433
+ path: z29.string(),
5474
5434
  method: HttpMethodSchema,
5475
- identifierOverride: z30.string().nullish()
5435
+ identifierOverride: z29.string().nullish()
5476
5436
  })
5477
5437
  });
5478
- var EndpointSnippetTemplateSchema = z30.record(z30.string(), z30.unknown());
5438
+ var EndpointSnippetTemplateSchema = z29.record(z29.string(), z29.unknown());
5479
5439
  var templatesContract = {
5480
- register: oc19.route({ method: "POST", path: "/register" }).input(RegisterInputSchema),
5481
- registerBatch: oc19.route({ method: "POST", path: "/register/batch" }).input(RegisterBatchInputSchema),
5482
- get: oc19.route({ method: "POST", path: "/get" }).input(GetInputSchema).output(EndpointSnippetTemplateSchema)
5440
+ register: oc18.route({ method: "POST", path: "/register" }).input(RegisterInputSchema),
5441
+ registerBatch: oc18.route({ method: "POST", path: "/register/batch" }).input(RegisterBatchInputSchema),
5442
+ get: oc18.route({ method: "POST", path: "/get" }).input(GetInputSchema).output(EndpointSnippetTemplateSchema)
5483
5443
  };
5484
5444
 
5485
5445
  // src/orpc-client/templates/client.ts
5486
5446
  function createTemplatesClient(options) {
5487
5447
  const baseUrl = options.baseUrl.replace(/\/+$/, "");
5488
- const link = new OpenAPILink21(templatesContract, {
5448
+ const link = new OpenAPILink20(templatesContract, {
5489
5449
  url: `${baseUrl}/snippet-template`,
5490
5450
  headers: () => ({
5491
5451
  Authorization: `Bearer ${options.token}`,
@@ -5493,36 +5453,36 @@ function createTemplatesClient(options) {
5493
5453
  }),
5494
5454
  ...options.fetch != null ? { fetch: options.fetch } : {}
5495
5455
  });
5496
- return createORPCClient21(link);
5456
+ return createORPCClient20(link);
5497
5457
  }
5498
5458
 
5499
5459
  // src/orpc-client/tokens/client.ts
5500
- import { createORPCClient as createORPCClient22 } from "@orpc/client";
5501
- import { OpenAPILink as OpenAPILink22 } from "@orpc/openapi-client/fetch";
5460
+ import { createORPCClient as createORPCClient21 } from "@orpc/client";
5461
+ import { OpenAPILink as OpenAPILink21 } from "@orpc/openapi-client/fetch";
5502
5462
 
5503
5463
  // src/orpc-client/tokens/contract.ts
5504
- import { oc as oc20 } from "@orpc/contract";
5505
- import * as z31 from "zod";
5506
- var GenerateTokenInputSchema = z31.object({
5507
- orgId: z31.string(),
5508
- scope: z31.string()
5464
+ import { oc as oc19 } from "@orpc/contract";
5465
+ import * as z30 from "zod";
5466
+ var GenerateTokenInputSchema = z30.object({
5467
+ orgId: z30.string(),
5468
+ scope: z30.string()
5509
5469
  });
5510
- var RevokeTokenInputSchema = z31.object({
5511
- orgId: z31.string(),
5512
- tokenId: z31.string()
5470
+ var RevokeTokenInputSchema = z30.object({
5471
+ orgId: z30.string(),
5472
+ tokenId: z30.string()
5513
5473
  });
5514
- var GenerateTokenOutputSchema = z31.object({
5515
- token: z31.string(),
5516
- id: z31.string()
5474
+ var GenerateTokenOutputSchema = z30.object({
5475
+ token: z30.string(),
5476
+ id: z30.string()
5517
5477
  });
5518
5478
  var tokensContract = {
5519
- generate: oc20.route({ method: "POST", path: "/generate" }).input(GenerateTokenInputSchema).output(GenerateTokenOutputSchema),
5520
- revoke: oc20.route({ method: "POST", path: "/revoke" }).input(RevokeTokenInputSchema)
5479
+ generate: oc19.route({ method: "POST", path: "/generate" }).input(GenerateTokenInputSchema).output(GenerateTokenOutputSchema),
5480
+ revoke: oc19.route({ method: "POST", path: "/revoke" }).input(RevokeTokenInputSchema)
5521
5481
  };
5522
5482
 
5523
5483
  // src/orpc-client/tokens/client.ts
5524
5484
  function createTokensClient(options) {
5525
- const link = new OpenAPILink22(tokensContract, {
5485
+ const link = new OpenAPILink21(tokensContract, {
5526
5486
  url: `${options.baseUrl}/tokens`,
5527
5487
  headers: () => ({
5528
5488
  Authorization: `Bearer ${options.token}`,
@@ -5530,7 +5490,7 @@ function createTokensClient(options) {
5530
5490
  }),
5531
5491
  ...options.fetch != null ? { fetch: options.fetch } : {}
5532
5492
  });
5533
- return createORPCClient22(link);
5493
+ return createORPCClient21(link);
5534
5494
  }
5535
5495
 
5536
5496
  // src/orpc-client/client.ts
@@ -5563,6 +5523,45 @@ function createFdrORPCClient(options) {
5563
5523
  };
5564
5524
  }
5565
5525
 
5526
+ // src/orpc-client/docs/v1/write/client.ts
5527
+ import { createORPCClient as createORPCClient22 } from "@orpc/client";
5528
+ import { OpenAPILink as OpenAPILink22 } from "@orpc/openapi-client/fetch";
5529
+
5530
+ // src/orpc-client/docs/v1/write/contract.ts
5531
+ import { oc as oc20 } from "@orpc/contract";
5532
+ import * as z31 from "zod";
5533
+ var StartDocsRegisterV1InputSchema = z31.object({
5534
+ orgId: z31.string(),
5535
+ domain: z31.string(),
5536
+ filepaths: z31.array(z31.string())
5537
+ });
5538
+ var StartDocsRegisterV1ResponseSchema = z31.object({
5539
+ docsRegistrationId: z31.string(),
5540
+ uploadUrls: z31.record(z31.string(), FileS3UploadUrlSchema),
5541
+ skippedFiles: z31.array(z31.string())
5542
+ });
5543
+ var FinishDocsRegisterV1InputSchema = z31.object({
5544
+ docsRegistrationId: z31.string(),
5545
+ docsDefinition: z31.unknown()
5546
+ });
5547
+ var docsV1WriteContract = {
5548
+ startDocsRegister: oc20.route({ method: "POST", path: "/init" }).input(StartDocsRegisterV1InputSchema).output(StartDocsRegisterV1ResponseSchema),
5549
+ finishDocsRegister: oc20.route({ method: "POST", path: "/register/{docsRegistrationId}" }).input(FinishDocsRegisterV1InputSchema).output(z31.void())
5550
+ };
5551
+
5552
+ // src/orpc-client/docs/v1/write/client.ts
5553
+ function createDocsV1WriteClient(options) {
5554
+ const link = new OpenAPILink22(docsV1WriteContract, {
5555
+ url: `${options.baseUrl}/registry/docs`,
5556
+ headers: () => ({
5557
+ Authorization: `Bearer ${options.token}`,
5558
+ ...options.headers
5559
+ }),
5560
+ ...options.fetch != null ? { fetch: options.fetch } : {}
5561
+ });
5562
+ return createORPCClient22(link);
5563
+ }
5564
+
5566
5565
  // src/orpc-client/docs-ledger/config-files.ts
5567
5566
  import * as z32 from "zod";
5568
5567
  var PATH_OR_URL_METADATA_KEYS = [