@fern-api/fdr-sdk 1.2.53-d8c526632f → 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.
- package/dist/client/docs-types/db.d.ts +61 -0
- package/dist/client/docs-types/db.d.ts.map +1 -1
- package/dist/client/docs-types/latest.d.ts +9 -9
- package/dist/client/docs-types/latest.d.ts.map +1 -1
- package/dist/client/docs-types/latest.js +1 -1
- package/dist/client/docs-types/latest.js.map +1 -1
- package/dist/client/docs-types/read.d.ts +27 -0
- package/dist/client/docs-types/read.d.ts.map +1 -1
- package/dist/client/docs-types/shared.d.ts +8 -0
- package/dist/client/docs-types/shared.d.ts.map +1 -1
- package/dist/client/docs-types/shared.js +1 -0
- package/dist/client/docs-types/shared.js.map +1 -1
- package/dist/client/docs-types/write.d.ts +16 -0
- package/dist/client/docs-types/write.d.ts.map +1 -1
- package/dist/js/client/FdrClient.js +1456 -1495
- package/dist/js/client/FdrClient.js.map +1 -1
- package/dist/js/client/FdrClient.mjs +1456 -1495
- package/dist/js/client/FdrClient.mjs.map +1 -1
- package/dist/js/client/types.js +2 -1
- package/dist/js/client/types.js.map +1 -1
- package/dist/js/client/types.mjs +2 -1
- package/dist/js/client/types.mjs.map +1 -1
- package/dist/js/converters/index.js +304 -301
- package/dist/js/converters/index.js.map +1 -1
- package/dist/js/converters/index.mjs +304 -301
- package/dist/js/converters/index.mjs.map +1 -1
- package/dist/js/docs/index.js +2 -1
- package/dist/js/docs/index.js.map +1 -1
- package/dist/js/docs/index.mjs +2 -1
- package/dist/js/docs/index.mjs.map +1 -1
- package/dist/js/index.js +1785 -1824
- package/dist/js/index.js.map +1 -1
- package/dist/js/index.mjs +1784 -1823
- package/dist/js/index.mjs.map +1 -1
- package/dist/js/navigation/index.js +304 -301
- package/dist/js/navigation/index.js.map +1 -1
- package/dist/js/navigation/index.mjs +304 -301
- package/dist/js/navigation/index.mjs.map +1 -1
- package/dist/js/orpc-client.js +1507 -1507
- package/dist/js/orpc-client.js.map +1 -1
- package/dist/js/orpc-client.mjs +1515 -1515
- package/dist/js/orpc-client.mjs.map +1 -1
- package/dist/orpc-client/docs/client.d.ts +0 -2
- package/dist/orpc-client/docs/client.d.ts.map +1 -1
- package/dist/orpc-client/docs/client.js +1 -3
- package/dist/orpc-client/docs/client.js.map +1 -1
- package/dist/orpc-client/docs/v1/read/contract.d.ts +18 -0
- package/dist/orpc-client/docs/v1/read/contract.d.ts.map +1 -1
- package/dist/orpc-client/docs/v1/write/contract.d.ts +4 -0
- package/dist/orpc-client/docs/v1/write/contract.d.ts.map +1 -1
- package/dist/orpc-client/docs/v2/read/contract.d.ts +40 -0
- package/dist/orpc-client/docs/v2/read/contract.d.ts.map +1 -1
- package/dist/orpc-client/docs/v2/write/contract.d.ts +14 -6
- package/dist/orpc-client/docs/v2/write/contract.d.ts.map +1 -1
- package/dist/orpc-client/docs-ledger/contract.d.ts +56 -0
- package/dist/orpc-client/docs-ledger/contract.d.ts.map +1 -1
- package/dist/orpc-client/docs-ledger/ledger-manifest.d.ts +14 -0
- package/dist/orpc-client/docs-ledger/ledger-manifest.d.ts.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/client/docs-types/db.d.ts +61 -0
- package/dist/types/client/docs-types/db.d.ts.map +1 -1
- package/dist/types/client/docs-types/latest.d.ts +9 -9
- package/dist/types/client/docs-types/latest.d.ts.map +1 -1
- package/dist/types/client/docs-types/read.d.ts +27 -0
- package/dist/types/client/docs-types/read.d.ts.map +1 -1
- package/dist/types/client/docs-types/shared.d.ts +8 -0
- package/dist/types/client/docs-types/shared.d.ts.map +1 -1
- package/dist/types/client/docs-types/write.d.ts +16 -0
- package/dist/types/client/docs-types/write.d.ts.map +1 -1
- package/dist/types/orpc-client/docs/client.d.ts +0 -2
- package/dist/types/orpc-client/docs/client.d.ts.map +1 -1
- package/dist/types/orpc-client/docs/v1/read/contract.d.ts +18 -0
- package/dist/types/orpc-client/docs/v1/read/contract.d.ts.map +1 -1
- package/dist/types/orpc-client/docs/v1/write/contract.d.ts +4 -0
- package/dist/types/orpc-client/docs/v1/write/contract.d.ts.map +1 -1
- package/dist/types/orpc-client/docs/v2/read/contract.d.ts +40 -0
- package/dist/types/orpc-client/docs/v2/read/contract.d.ts.map +1 -1
- package/dist/types/orpc-client/docs/v2/write/contract.d.ts +14 -6
- package/dist/types/orpc-client/docs/v2/write/contract.d.ts.map +1 -1
- package/dist/types/orpc-client/docs-ledger/contract.d.ts +56 -0
- package/dist/types/orpc-client/docs-ledger/contract.d.ts.map +1 -1
- package/dist/types/orpc-client/docs-ledger/ledger-manifest.d.ts +14 -0
- package/dist/types/orpc-client/docs-ledger/ledger-manifest.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/js/orpc-client.js
CHANGED
|
@@ -383,7 +383,7 @@ __export(orpc_client_exports, {
|
|
|
383
383
|
OAuthClientCredentialsReferencedEndpointSchema: () => OAuthClientCredentialsReferencedEndpointSchema,
|
|
384
384
|
OAuthClientCredentialsSchema: () => OAuthClientCredentialsSchema,
|
|
385
385
|
OAuthSchema: () => OAuthSchema,
|
|
386
|
-
ORPCError: () =>
|
|
386
|
+
ORPCError: () => import_client45.ORPCError,
|
|
387
387
|
ObjectPropertyAccessSchema: () => ObjectPropertyAccessSchema,
|
|
388
388
|
ObjectPropertySchema: () => ObjectPropertySchema,
|
|
389
389
|
ObjectTypeSchema: () => ObjectTypeSchema,
|
|
@@ -644,7 +644,7 @@ __export(orpc_client_exports, {
|
|
|
644
644
|
tokensContract: () => tokensContract
|
|
645
645
|
});
|
|
646
646
|
module.exports = __toCommonJS(orpc_client_exports);
|
|
647
|
-
var
|
|
647
|
+
var import_client45 = require("@orpc/client");
|
|
648
648
|
|
|
649
649
|
// src/orpc-client/api/client.ts
|
|
650
650
|
var import_client = require("@orpc/client");
|
|
@@ -3267,6 +3267,7 @@ var PageActionOptionsSchema = z10.object({
|
|
|
3267
3267
|
cursor: z10.boolean().optional(),
|
|
3268
3268
|
claudeCode: z10.boolean().optional(),
|
|
3269
3269
|
vscode: z10.boolean().optional(),
|
|
3270
|
+
mcp: z10.boolean().optional(),
|
|
3270
3271
|
custom: z10.array(CustomPageActionSchema).optional(),
|
|
3271
3272
|
skills: SkillsConfigSchema.optional()
|
|
3272
3273
|
});
|
|
@@ -3593,225 +3594,440 @@ function createDocsV1ReadClient(options) {
|
|
|
3593
3594
|
return (0, import_client3.createORPCClient)(link);
|
|
3594
3595
|
}
|
|
3595
3596
|
|
|
3596
|
-
// src/orpc-client/docs/
|
|
3597
|
+
// src/orpc-client/docs/v2/library-docs/client.ts
|
|
3597
3598
|
var import_client4 = require("@orpc/client");
|
|
3598
3599
|
var import_fetch4 = require("@orpc/openapi-client/fetch");
|
|
3599
3600
|
|
|
3600
|
-
// src/orpc-client/docs/
|
|
3601
|
+
// src/orpc-client/docs/v2/library-docs/contract.ts
|
|
3601
3602
|
var import_contract8 = require("@orpc/contract");
|
|
3603
|
+
var z14 = __toESM(require("zod"), 1);
|
|
3604
|
+
var ALLOWED_HOSTNAMES = /* @__PURE__ */ new Set(["github.com", "gitlab.com"]);
|
|
3605
|
+
var GithubUrlSchema = z14.string().url().describe(
|
|
3606
|
+
"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>."
|
|
3607
|
+
).refine(
|
|
3608
|
+
(url) => {
|
|
3609
|
+
try {
|
|
3610
|
+
const parsed = new URL(url);
|
|
3611
|
+
if (parsed.protocol !== "https:") {
|
|
3612
|
+
return false;
|
|
3613
|
+
}
|
|
3614
|
+
if (!ALLOWED_HOSTNAMES.has(parsed.hostname)) {
|
|
3615
|
+
return false;
|
|
3616
|
+
}
|
|
3617
|
+
if (parsed.username || parsed.password) {
|
|
3618
|
+
return false;
|
|
3619
|
+
}
|
|
3620
|
+
return /^\/[\w.-]+\/[\w.-]+(?:\.git)?\/?$/.test(parsed.pathname);
|
|
3621
|
+
} catch {
|
|
3622
|
+
return false;
|
|
3623
|
+
}
|
|
3624
|
+
},
|
|
3625
|
+
{ message: "Must be a valid https://github.com/<owner>/<repo> or https://gitlab.com/<owner>/<repo> URL" }
|
|
3626
|
+
);
|
|
3627
|
+
var SafeBranchSchema = z14.string().regex(/^[a-zA-Z0-9._/-]+$/, "Invalid branch name").nullish();
|
|
3628
|
+
var SafePackagePathSchema = z14.string().refine((p) => !p.includes("..") && !p.startsWith("/"), {
|
|
3629
|
+
message: "packagePath must not contain path traversal sequences"
|
|
3630
|
+
}).nullish();
|
|
3631
|
+
var LibraryDocsBaseConfigSchema = z14.object({
|
|
3632
|
+
branch: SafeBranchSchema,
|
|
3633
|
+
packagePath: SafePackagePathSchema,
|
|
3634
|
+
title: z14.string().nullish(),
|
|
3635
|
+
slug: z14.string().nullish()
|
|
3636
|
+
});
|
|
3637
|
+
var PythonLibraryDocsConfigSchema = LibraryDocsBaseConfigSchema;
|
|
3638
|
+
var CppLibraryDocsConfigSchema = LibraryDocsBaseConfigSchema.extend({
|
|
3639
|
+
doxyfileContent: z14.string().nullish()
|
|
3640
|
+
});
|
|
3641
|
+
var StartLibraryDocsGenerationInputSchema = z14.discriminatedUnion("language", [
|
|
3642
|
+
z14.object({
|
|
3643
|
+
orgId: z14.string(),
|
|
3644
|
+
githubUrl: GithubUrlSchema,
|
|
3645
|
+
language: z14.literal("PYTHON"),
|
|
3646
|
+
config: PythonLibraryDocsConfigSchema.nullish()
|
|
3647
|
+
}),
|
|
3648
|
+
z14.object({
|
|
3649
|
+
orgId: z14.string(),
|
|
3650
|
+
githubUrl: GithubUrlSchema,
|
|
3651
|
+
language: z14.literal("CPP"),
|
|
3652
|
+
config: CppLibraryDocsConfigSchema.nullish()
|
|
3653
|
+
})
|
|
3654
|
+
]);
|
|
3655
|
+
var StartLibraryDocsGenerationResponseSchema = z14.object({
|
|
3656
|
+
jobId: z14.string()
|
|
3657
|
+
});
|
|
3658
|
+
var GetLibraryDocsStatusInputSchema = z14.object({
|
|
3659
|
+
jobId: z14.string()
|
|
3660
|
+
});
|
|
3661
|
+
var LibraryDocsResultSchema = z14.object({
|
|
3662
|
+
jobId: z14.string(),
|
|
3663
|
+
resultUrl: z14.string()
|
|
3664
|
+
});
|
|
3665
|
+
var LibraryDocsGenerationStatusSchema = z14.object({
|
|
3666
|
+
jobId: z14.string(),
|
|
3667
|
+
status: z14.string(),
|
|
3668
|
+
progress: z14.string(),
|
|
3669
|
+
error: z14.object({
|
|
3670
|
+
code: z14.string(),
|
|
3671
|
+
message: z14.string()
|
|
3672
|
+
}).optional(),
|
|
3673
|
+
createdAt: z14.string(),
|
|
3674
|
+
updatedAt: z14.string()
|
|
3675
|
+
});
|
|
3676
|
+
var libraryDocsContract = {
|
|
3677
|
+
startLibraryDocsGeneration: import_contract8.oc.route({ method: "POST", path: "/library-docs/generate" }).input(StartLibraryDocsGenerationInputSchema).output(StartLibraryDocsGenerationResponseSchema),
|
|
3678
|
+
getLibraryDocsGenerationStatus: import_contract8.oc.route({ method: "GET", path: "/library-docs/status/{jobId}" }).input(GetLibraryDocsStatusInputSchema).output(LibraryDocsGenerationStatusSchema),
|
|
3679
|
+
getLibraryDocsResult: import_contract8.oc.route({ method: "GET", path: "/library-docs/result/{jobId}" }).input(GetLibraryDocsStatusInputSchema).output(LibraryDocsResultSchema)
|
|
3680
|
+
};
|
|
3681
|
+
|
|
3682
|
+
// src/orpc-client/docs/v2/library-docs/client.ts
|
|
3683
|
+
function createLibraryDocsClient(options) {
|
|
3684
|
+
const link = new import_fetch4.OpenAPILink(libraryDocsContract, {
|
|
3685
|
+
url: `${options.baseUrl}/v2/registry/docs`,
|
|
3686
|
+
headers: () => ({
|
|
3687
|
+
Authorization: `Bearer ${options.token}`,
|
|
3688
|
+
...options.headers
|
|
3689
|
+
}),
|
|
3690
|
+
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
3691
|
+
});
|
|
3692
|
+
return (0, import_client4.createORPCClient)(link);
|
|
3693
|
+
}
|
|
3694
|
+
|
|
3695
|
+
// src/orpc-client/docs/v2/organization/client.ts
|
|
3696
|
+
var import_client5 = require("@orpc/client");
|
|
3697
|
+
var import_fetch5 = require("@orpc/openapi-client/fetch");
|
|
3698
|
+
|
|
3699
|
+
// src/orpc-client/docs/v2/organization/contract.ts
|
|
3700
|
+
var import_contract10 = require("@orpc/contract");
|
|
3701
|
+
var z15 = __toESM(require("zod"), 1);
|
|
3702
|
+
var GetOrganizationForUrlInputSchema = z15.object({
|
|
3703
|
+
url: z15.string()
|
|
3704
|
+
});
|
|
3705
|
+
var organizationContract = {
|
|
3706
|
+
getOrganizationForUrl: import_contract10.oc.route({ method: "POST", path: "/organization-for-url" }).input(GetOrganizationForUrlInputSchema).output(z15.string())
|
|
3707
|
+
};
|
|
3708
|
+
|
|
3709
|
+
// src/orpc-client/docs/v2/organization/client.ts
|
|
3710
|
+
function createOrganizationClient(options) {
|
|
3711
|
+
const link = new import_fetch5.OpenAPILink(organizationContract, {
|
|
3712
|
+
url: `${options.baseUrl}/v2/registry/docs`,
|
|
3713
|
+
headers: () => ({
|
|
3714
|
+
Authorization: `Bearer ${options.token}`,
|
|
3715
|
+
...options.headers
|
|
3716
|
+
}),
|
|
3717
|
+
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
3718
|
+
});
|
|
3719
|
+
return (0, import_client5.createORPCClient)(link);
|
|
3720
|
+
}
|
|
3721
|
+
|
|
3722
|
+
// src/orpc-client/docs/v2/read/client.ts
|
|
3723
|
+
var import_client6 = require("@orpc/client");
|
|
3724
|
+
var import_fetch6 = require("@orpc/openapi-client/fetch");
|
|
3725
|
+
|
|
3726
|
+
// src/orpc-client/docs/v2/read/contract.ts
|
|
3727
|
+
var import_contract12 = require("@orpc/contract");
|
|
3602
3728
|
var z16 = __toESM(require("zod"), 1);
|
|
3729
|
+
var GetDocsUrlMetadataInputSchema = z16.object({
|
|
3730
|
+
url: z16.string()
|
|
3731
|
+
});
|
|
3732
|
+
var GetDocsUrlMetadataResponseSchema = z16.object({
|
|
3733
|
+
isPreviewUrl: z16.boolean(),
|
|
3734
|
+
org: z16.string(),
|
|
3735
|
+
url: z16.string(),
|
|
3736
|
+
gitUrl: z16.string().nullish(),
|
|
3737
|
+
enableAlgoliaOnPreview: z16.boolean().nullish()
|
|
3738
|
+
});
|
|
3739
|
+
var GetDocsForUrlInputSchema = z16.object({
|
|
3740
|
+
url: z16.string(),
|
|
3741
|
+
excludeApis: z16.boolean().nullish()
|
|
3742
|
+
});
|
|
3743
|
+
var GetPrivateDocsForUrlInputSchema = z16.object({
|
|
3744
|
+
url: z16.string()
|
|
3745
|
+
});
|
|
3746
|
+
var ListAllDocsUrlsInputSchema = z16.object({
|
|
3747
|
+
limit: z16.number().nullish(),
|
|
3748
|
+
page: z16.number().nullish(),
|
|
3749
|
+
custom: z16.boolean().nullish(),
|
|
3750
|
+
preview: z16.boolean().nullish()
|
|
3751
|
+
});
|
|
3752
|
+
var GetDocsConfigByIdInputSchema = z16.object({
|
|
3753
|
+
docsConfigId: z16.string()
|
|
3754
|
+
});
|
|
3755
|
+
var DocsDefinitionField = {
|
|
3756
|
+
BaseUrl: "BASE_URL",
|
|
3757
|
+
FilesV2: "FILES_V2",
|
|
3758
|
+
ApisV2: "APIS_V2",
|
|
3759
|
+
Apis: "APIS",
|
|
3760
|
+
Pages: "PAGES",
|
|
3761
|
+
JsFiles: "JS_FILES",
|
|
3762
|
+
Config: "CONFIG",
|
|
3763
|
+
Root: "ROOT"
|
|
3764
|
+
};
|
|
3765
|
+
var GetDocsConfigByIdResponseSchema = z16.object({
|
|
3766
|
+
docsConfig: DocsConfigSchema,
|
|
3767
|
+
apis: z16.record(z16.string(), z16.unknown())
|
|
3768
|
+
});
|
|
3769
|
+
var DocsDomainItemSchema = z16.object({
|
|
3770
|
+
domain: z16.string(),
|
|
3771
|
+
basePath: z16.string().optional(),
|
|
3772
|
+
organizationId: z16.string(),
|
|
3773
|
+
updatedAt: z16.string()
|
|
3774
|
+
});
|
|
3775
|
+
var ListAllDocsUrlsResponseSchema = z16.object({
|
|
3776
|
+
urls: z16.array(DocsDomainItemSchema)
|
|
3777
|
+
});
|
|
3778
|
+
var getDocsForUrl;
|
|
3779
|
+
((getDocsForUrl2) => {
|
|
3780
|
+
let Error2;
|
|
3781
|
+
((Error3) => {
|
|
3782
|
+
function _unknown(fetcherError) {
|
|
3783
|
+
return { error: void 0, content: fetcherError };
|
|
3784
|
+
}
|
|
3785
|
+
Error3._unknown = _unknown;
|
|
3786
|
+
})(Error2 = getDocsForUrl2.Error || (getDocsForUrl2.Error = {}));
|
|
3787
|
+
})(getDocsForUrl || (getDocsForUrl = {}));
|
|
3788
|
+
var docsV2ReadContract = {
|
|
3789
|
+
getDocsUrlMetadata: import_contract12.oc.route({ method: "POST", path: "/metadata-for-url" }).input(GetDocsUrlMetadataInputSchema).output(GetDocsUrlMetadataResponseSchema),
|
|
3790
|
+
getDocsForUrl: import_contract12.oc.route({ method: "POST", path: "/load-with-url" }).input(GetDocsForUrlInputSchema).output(LoadDocsForUrlResponseSchema),
|
|
3791
|
+
getPrivateDocsForUrl: import_contract12.oc.route({ method: "POST", path: "/private/load-with-url" }).input(GetPrivateDocsForUrlInputSchema).output(LoadDocsForUrlResponseSchema),
|
|
3792
|
+
listAllDocsUrls: import_contract12.oc.route({ method: "GET", path: "/urls/list" }).input(ListAllDocsUrlsInputSchema).output(ListAllDocsUrlsResponseSchema),
|
|
3793
|
+
getDocsConfigById: import_contract12.oc.route({ method: "GET", path: "/{docsConfigId}" }).input(GetDocsConfigByIdInputSchema).output(GetDocsConfigByIdResponseSchema),
|
|
3794
|
+
prepopulateFdrReadS3Bucket: import_contract12.oc.route({ method: "POST", path: "/prepopulate-s3-bucket" }).output(z16.void()),
|
|
3795
|
+
ensureDocsInS3: import_contract12.oc.route({ method: "POST", path: "/ensure-docs-in-s3" }).output(z16.void()),
|
|
3796
|
+
getDocsFields: import_contract12.oc.route({ method: "POST", path: "/load-fields" }).output(z16.void())
|
|
3797
|
+
};
|
|
3798
|
+
|
|
3799
|
+
// src/orpc-client/docs/v2/read/client.ts
|
|
3800
|
+
function createDocsV2ReadClient(options) {
|
|
3801
|
+
const link = new import_fetch6.OpenAPILink(docsV2ReadContract, {
|
|
3802
|
+
url: `${options.baseUrl}/v2/registry/docs`,
|
|
3803
|
+
headers: () => ({
|
|
3804
|
+
Authorization: `Bearer ${options.token}`,
|
|
3805
|
+
...options.headers
|
|
3806
|
+
}),
|
|
3807
|
+
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
3808
|
+
});
|
|
3809
|
+
return (0, import_client6.createORPCClient)(link);
|
|
3810
|
+
}
|
|
3811
|
+
|
|
3812
|
+
// src/orpc-client/docs/v2/write/client.ts
|
|
3813
|
+
var import_client7 = require("@orpc/client");
|
|
3814
|
+
var import_fetch7 = require("@orpc/openapi-client/fetch");
|
|
3815
|
+
|
|
3816
|
+
// src/orpc-client/docs/v2/write/contract.ts
|
|
3817
|
+
var import_contract14 = require("@orpc/contract");
|
|
3818
|
+
var z19 = __toESM(require("zod"), 1);
|
|
3603
3819
|
|
|
3604
3820
|
// src/client/docs-types/write.ts
|
|
3605
|
-
var
|
|
3821
|
+
var z18 = __toESM(require("zod"), 1);
|
|
3606
3822
|
|
|
3607
3823
|
// src/client/docs-types/write-commons.ts
|
|
3608
|
-
var
|
|
3609
|
-
var OrgIdSchema2 =
|
|
3824
|
+
var z17 = __toESM(require("zod"), 1);
|
|
3825
|
+
var OrgIdSchema2 = z17.string();
|
|
3610
3826
|
|
|
3611
3827
|
// src/client/docs-types/write.ts
|
|
3612
|
-
var FilePathSchema =
|
|
3613
|
-
var DocsRegistrationIdSchema =
|
|
3614
|
-
var HeightSchema2 =
|
|
3615
|
-
var FileS3UploadUrlSchema =
|
|
3616
|
-
uploadUrl:
|
|
3828
|
+
var FilePathSchema = z18.string();
|
|
3829
|
+
var DocsRegistrationIdSchema = z18.string();
|
|
3830
|
+
var HeightSchema2 = z18.number();
|
|
3831
|
+
var FileS3UploadUrlSchema = z18.object({
|
|
3832
|
+
uploadUrl: z18.string(),
|
|
3617
3833
|
fileId: FileIdSchema2
|
|
3618
3834
|
});
|
|
3619
|
-
var StartDocsRegisterResponseSchema =
|
|
3835
|
+
var StartDocsRegisterResponseSchema = z18.object({
|
|
3620
3836
|
docsRegistrationId: DocsRegistrationIdSchema,
|
|
3621
|
-
uploadUrls:
|
|
3622
|
-
skippedFiles:
|
|
3837
|
+
uploadUrls: z18.record(FilePathSchema, FileS3UploadUrlSchema),
|
|
3838
|
+
skippedFiles: z18.array(FilePathSchema)
|
|
3623
3839
|
});
|
|
3624
|
-
var PageContentSchema2 =
|
|
3625
|
-
markdown:
|
|
3840
|
+
var PageContentSchema2 = z18.object({
|
|
3841
|
+
markdown: z18.string(),
|
|
3626
3842
|
editThisPageUrl: UrlSchema2.optional(),
|
|
3627
3843
|
editThisPageLaunch: EditThisPageLaunchSchema.optional(),
|
|
3628
|
-
rawMarkdown:
|
|
3844
|
+
rawMarkdown: z18.string().optional()
|
|
3629
3845
|
});
|
|
3630
|
-
var NavigationNodeMetadataSchema2 =
|
|
3631
|
-
icon:
|
|
3632
|
-
hidden:
|
|
3633
|
-
urlSlugOverride:
|
|
3634
|
-
fullSlug:
|
|
3846
|
+
var NavigationNodeMetadataSchema2 = z18.object({
|
|
3847
|
+
icon: z18.string().optional(),
|
|
3848
|
+
hidden: z18.boolean().optional(),
|
|
3849
|
+
urlSlugOverride: z18.string().optional(),
|
|
3850
|
+
fullSlug: z18.array(z18.string()).optional()
|
|
3635
3851
|
});
|
|
3636
|
-
var PageMetadataSchema2 =
|
|
3852
|
+
var PageMetadataSchema2 = z18.object({
|
|
3637
3853
|
...NavigationNodeMetadataSchema2.shape,
|
|
3638
3854
|
id: PageIdSchema2,
|
|
3639
|
-
title:
|
|
3855
|
+
title: z18.string()
|
|
3640
3856
|
});
|
|
3641
|
-
var LinkMetadataSchema2 =
|
|
3642
|
-
title:
|
|
3643
|
-
icon:
|
|
3857
|
+
var LinkMetadataSchema2 = z18.object({
|
|
3858
|
+
title: z18.string(),
|
|
3859
|
+
icon: z18.string().optional(),
|
|
3644
3860
|
url: UrlSchema2,
|
|
3645
3861
|
target: LinkTargetSchema.optional()
|
|
3646
3862
|
});
|
|
3647
|
-
var ChangelogItemSchema2 =
|
|
3648
|
-
date:
|
|
3863
|
+
var ChangelogItemSchema2 = z18.object({
|
|
3864
|
+
date: z18.string(),
|
|
3649
3865
|
pageId: PageIdSchema2,
|
|
3650
|
-
hidden:
|
|
3651
|
-
tags:
|
|
3652
|
-
});
|
|
3653
|
-
var ChangelogSectionSchema2 =
|
|
3654
|
-
title:
|
|
3655
|
-
icon:
|
|
3656
|
-
hidden:
|
|
3657
|
-
description:
|
|
3866
|
+
hidden: z18.boolean().optional(),
|
|
3867
|
+
tags: z18.array(z18.string()).optional()
|
|
3868
|
+
});
|
|
3869
|
+
var ChangelogSectionSchema2 = z18.object({
|
|
3870
|
+
title: z18.string().optional(),
|
|
3871
|
+
icon: z18.string().optional(),
|
|
3872
|
+
hidden: z18.boolean().optional(),
|
|
3873
|
+
description: z18.string().optional(),
|
|
3658
3874
|
pageId: PageIdSchema2.optional(),
|
|
3659
|
-
items:
|
|
3660
|
-
urlSlug:
|
|
3661
|
-
fullSlug:
|
|
3875
|
+
items: z18.array(ChangelogItemSchema2),
|
|
3876
|
+
urlSlug: z18.string(),
|
|
3877
|
+
fullSlug: z18.array(z18.string()).optional()
|
|
3662
3878
|
});
|
|
3663
|
-
var ChangelogSectionV2Schema =
|
|
3879
|
+
var ChangelogSectionV2Schema = z18.object({
|
|
3664
3880
|
...NavigationNodeMetadataSchema2.shape,
|
|
3665
|
-
title:
|
|
3666
|
-
description:
|
|
3881
|
+
title: z18.string().optional(),
|
|
3882
|
+
description: z18.string().optional(),
|
|
3667
3883
|
pageId: PageIdSchema2.optional(),
|
|
3668
|
-
items:
|
|
3884
|
+
items: z18.array(ChangelogItemSchema2)
|
|
3669
3885
|
});
|
|
3670
|
-
var ChangelogSectionV3Schema2 =
|
|
3671
|
-
node:
|
|
3886
|
+
var ChangelogSectionV3Schema2 = z18.object({
|
|
3887
|
+
node: z18.unknown()
|
|
3672
3888
|
});
|
|
3673
|
-
var NavigationTabLinkSchema2 =
|
|
3674
|
-
title:
|
|
3675
|
-
icon:
|
|
3889
|
+
var NavigationTabLinkSchema2 = z18.object({
|
|
3890
|
+
title: z18.string(),
|
|
3891
|
+
icon: z18.string().optional(),
|
|
3676
3892
|
url: UrlSchema2,
|
|
3677
3893
|
target: LinkTargetSchema.optional()
|
|
3678
3894
|
});
|
|
3679
|
-
var ApiNavigationConfigItemSchema3 =
|
|
3680
|
-
() =>
|
|
3681
|
-
|
|
3682
|
-
type:
|
|
3895
|
+
var ApiNavigationConfigItemSchema3 = z18.lazy(
|
|
3896
|
+
() => z18.discriminatedUnion("type", [
|
|
3897
|
+
z18.object({
|
|
3898
|
+
type: z18.literal("subpackage"),
|
|
3683
3899
|
summaryPageId: PageIdSchema2.optional(),
|
|
3684
3900
|
subpackageId: SubpackageIdSchema2,
|
|
3685
|
-
items:
|
|
3901
|
+
items: z18.array(ApiNavigationConfigItemSchema3)
|
|
3686
3902
|
}),
|
|
3687
|
-
|
|
3688
|
-
|
|
3689
|
-
|
|
3690
|
-
|
|
3903
|
+
z18.object({ type: z18.literal("endpointId"), value: EndpointIdSchema2 }),
|
|
3904
|
+
z18.object({ type: z18.literal("websocketId"), value: WebSocketIdSchema2 }),
|
|
3905
|
+
z18.object({ type: z18.literal("webhookId"), value: WebhookIdSchema2 }),
|
|
3906
|
+
z18.object({ type: z18.literal("page"), ...PageMetadataSchema2.shape })
|
|
3691
3907
|
])
|
|
3692
3908
|
);
|
|
3693
|
-
var ApiNavigationConfigSubpackageSchema =
|
|
3909
|
+
var ApiNavigationConfigSubpackageSchema = z18.object({
|
|
3694
3910
|
summaryPageId: PageIdSchema2.optional(),
|
|
3695
3911
|
subpackageId: SubpackageIdSchema2,
|
|
3696
|
-
items:
|
|
3912
|
+
items: z18.array(ApiNavigationConfigItemSchema3)
|
|
3697
3913
|
});
|
|
3698
|
-
var ApiNavigationConfigRootSchema4 =
|
|
3914
|
+
var ApiNavigationConfigRootSchema4 = z18.object({
|
|
3699
3915
|
summaryPageId: PageIdSchema2.optional(),
|
|
3700
|
-
items:
|
|
3916
|
+
items: z18.array(ApiNavigationConfigItemSchema3)
|
|
3701
3917
|
});
|
|
3702
|
-
var ApiSectionSchema2 =
|
|
3918
|
+
var ApiSectionSchema2 = z18.object({
|
|
3703
3919
|
...NavigationNodeMetadataSchema2.shape,
|
|
3704
|
-
title:
|
|
3920
|
+
title: z18.string(),
|
|
3705
3921
|
api: ApiDefinitionIdSchema2,
|
|
3706
|
-
artifacts:
|
|
3707
|
-
sdks:
|
|
3708
|
-
|
|
3709
|
-
|
|
3710
|
-
type:
|
|
3711
|
-
packageName:
|
|
3712
|
-
githubRepoName:
|
|
3713
|
-
version:
|
|
3922
|
+
artifacts: z18.object({
|
|
3923
|
+
sdks: z18.array(
|
|
3924
|
+
z18.discriminatedUnion("type", [
|
|
3925
|
+
z18.object({
|
|
3926
|
+
type: z18.literal("npm"),
|
|
3927
|
+
packageName: z18.string(),
|
|
3928
|
+
githubRepoName: z18.string(),
|
|
3929
|
+
version: z18.string()
|
|
3714
3930
|
}),
|
|
3715
|
-
|
|
3716
|
-
type:
|
|
3717
|
-
coordinate:
|
|
3718
|
-
githubRepoName:
|
|
3719
|
-
version:
|
|
3931
|
+
z18.object({
|
|
3932
|
+
type: z18.literal("maven"),
|
|
3933
|
+
coordinate: z18.string(),
|
|
3934
|
+
githubRepoName: z18.string(),
|
|
3935
|
+
version: z18.string()
|
|
3720
3936
|
}),
|
|
3721
|
-
|
|
3722
|
-
type:
|
|
3723
|
-
packageName:
|
|
3724
|
-
githubRepoName:
|
|
3725
|
-
version:
|
|
3937
|
+
z18.object({
|
|
3938
|
+
type: z18.literal("pypi"),
|
|
3939
|
+
packageName: z18.string(),
|
|
3940
|
+
githubRepoName: z18.string(),
|
|
3941
|
+
version: z18.string()
|
|
3726
3942
|
})
|
|
3727
3943
|
])
|
|
3728
3944
|
),
|
|
3729
|
-
postman:
|
|
3945
|
+
postman: z18.object({
|
|
3730
3946
|
url: UrlSchema2,
|
|
3731
|
-
githubRepoName:
|
|
3947
|
+
githubRepoName: z18.string().optional()
|
|
3732
3948
|
}).optional()
|
|
3733
3949
|
}).optional(),
|
|
3734
|
-
skipUrlSlug:
|
|
3735
|
-
showErrors:
|
|
3950
|
+
skipUrlSlug: z18.boolean().optional(),
|
|
3951
|
+
showErrors: z18.boolean().optional(),
|
|
3736
3952
|
changelog: ChangelogSectionSchema2.optional(),
|
|
3737
3953
|
changelogV2: ChangelogSectionV2Schema.optional(),
|
|
3738
3954
|
navigation: ApiNavigationConfigRootSchema4.optional(),
|
|
3739
|
-
longScrolling:
|
|
3740
|
-
flattened:
|
|
3955
|
+
longScrolling: z18.boolean().optional(),
|
|
3956
|
+
flattened: z18.boolean().optional()
|
|
3741
3957
|
});
|
|
3742
|
-
var ApiSectionV2Schema2 =
|
|
3743
|
-
node:
|
|
3958
|
+
var ApiSectionV2Schema2 = z18.object({
|
|
3959
|
+
node: z18.unknown()
|
|
3744
3960
|
});
|
|
3745
|
-
var DocsSectionSchema2 =
|
|
3746
|
-
() =>
|
|
3961
|
+
var DocsSectionSchema2 = z18.lazy(
|
|
3962
|
+
() => z18.object({
|
|
3747
3963
|
...NavigationNodeMetadataSchema2.shape,
|
|
3748
|
-
title:
|
|
3749
|
-
items:
|
|
3750
|
-
collapsed:
|
|
3751
|
-
collapsible:
|
|
3752
|
-
collapsedByDefault:
|
|
3753
|
-
skipUrlSlug:
|
|
3964
|
+
title: z18.string(),
|
|
3965
|
+
items: z18.array(NavigationItemSchema2),
|
|
3966
|
+
collapsed: z18.union([z18.boolean(), z18.literal("open-by-default")]).optional(),
|
|
3967
|
+
collapsible: z18.boolean().optional(),
|
|
3968
|
+
collapsedByDefault: z18.boolean().optional(),
|
|
3969
|
+
skipUrlSlug: z18.boolean().optional(),
|
|
3754
3970
|
overviewPageId: PageIdSchema2.optional()
|
|
3755
3971
|
})
|
|
3756
3972
|
);
|
|
3757
|
-
var NavigationItemSchema2 =
|
|
3758
|
-
() =>
|
|
3759
|
-
|
|
3760
|
-
|
|
3761
|
-
|
|
3762
|
-
|
|
3763
|
-
type:
|
|
3973
|
+
var NavigationItemSchema2 = z18.lazy(
|
|
3974
|
+
() => z18.discriminatedUnion("type", [
|
|
3975
|
+
z18.object({ type: z18.literal("page"), ...PageMetadataSchema2.shape }),
|
|
3976
|
+
z18.object({ type: z18.literal("api"), ...ApiSectionSchema2.shape }),
|
|
3977
|
+
z18.object({ type: z18.literal("apiV2"), ...ApiSectionV2Schema2.shape }),
|
|
3978
|
+
z18.object({
|
|
3979
|
+
type: z18.literal("section"),
|
|
3764
3980
|
...NavigationNodeMetadataSchema2.shape,
|
|
3765
|
-
title:
|
|
3766
|
-
items:
|
|
3767
|
-
collapsed:
|
|
3768
|
-
collapsible:
|
|
3769
|
-
collapsedByDefault:
|
|
3770
|
-
skipUrlSlug:
|
|
3981
|
+
title: z18.string(),
|
|
3982
|
+
items: z18.array(NavigationItemSchema2),
|
|
3983
|
+
collapsed: z18.union([z18.boolean(), z18.literal("open-by-default")]).optional(),
|
|
3984
|
+
collapsible: z18.boolean().optional(),
|
|
3985
|
+
collapsedByDefault: z18.boolean().optional(),
|
|
3986
|
+
skipUrlSlug: z18.boolean().optional(),
|
|
3771
3987
|
overviewPageId: PageIdSchema2.optional()
|
|
3772
3988
|
}),
|
|
3773
|
-
|
|
3774
|
-
|
|
3775
|
-
|
|
3989
|
+
z18.object({ type: z18.literal("link"), ...LinkMetadataSchema2.shape }),
|
|
3990
|
+
z18.object({ type: z18.literal("changelog"), ...ChangelogSectionV2Schema.shape }),
|
|
3991
|
+
z18.object({ type: z18.literal("changelogV3"), ...ChangelogSectionV3Schema2.shape })
|
|
3776
3992
|
])
|
|
3777
3993
|
);
|
|
3778
|
-
var NavigationTabGroupSchema2 =
|
|
3994
|
+
var NavigationTabGroupSchema2 = z18.object({
|
|
3779
3995
|
...NavigationNodeMetadataSchema2.shape,
|
|
3780
|
-
title:
|
|
3781
|
-
items:
|
|
3782
|
-
skipUrlSlug:
|
|
3783
|
-
});
|
|
3784
|
-
var NavigationTabSchema2 =
|
|
3785
|
-
var NavigationTabV2Schema =
|
|
3786
|
-
|
|
3787
|
-
|
|
3788
|
-
|
|
3789
|
-
|
|
3996
|
+
title: z18.string(),
|
|
3997
|
+
items: z18.array(NavigationItemSchema2),
|
|
3998
|
+
skipUrlSlug: z18.boolean().optional()
|
|
3999
|
+
});
|
|
4000
|
+
var NavigationTabSchema2 = z18.union([NavigationTabGroupSchema2, NavigationTabLinkSchema2]);
|
|
4001
|
+
var NavigationTabV2Schema = z18.discriminatedUnion("type", [
|
|
4002
|
+
z18.object({ type: z18.literal("group"), ...NavigationTabGroupSchema2.shape }),
|
|
4003
|
+
z18.object({ type: z18.literal("link"), ...NavigationTabLinkSchema2.shape }),
|
|
4004
|
+
z18.object({ type: z18.literal("changelog"), ...ChangelogSectionV2Schema.shape }),
|
|
4005
|
+
z18.object({ type: z18.literal("changelogV3"), ...ChangelogSectionV3Schema2.shape })
|
|
3790
4006
|
]);
|
|
3791
|
-
var UnversionedTabbedNavigationConfigSchema2 =
|
|
3792
|
-
tabs:
|
|
3793
|
-
tabsV2:
|
|
4007
|
+
var UnversionedTabbedNavigationConfigSchema2 = z18.object({
|
|
4008
|
+
tabs: z18.array(NavigationTabSchema2).optional(),
|
|
4009
|
+
tabsV2: z18.array(NavigationTabV2Schema).optional(),
|
|
3794
4010
|
landingPage: PageMetadataSchema2.optional()
|
|
3795
4011
|
});
|
|
3796
|
-
var UnversionedUntabbedNavigationConfigSchema2 =
|
|
3797
|
-
items:
|
|
4012
|
+
var UnversionedUntabbedNavigationConfigSchema2 = z18.object({
|
|
4013
|
+
items: z18.array(NavigationItemSchema2),
|
|
3798
4014
|
landingPage: PageMetadataSchema2.optional()
|
|
3799
4015
|
});
|
|
3800
|
-
var UnversionedNavigationConfigSchema2 =
|
|
4016
|
+
var UnversionedNavigationConfigSchema2 = z18.union([
|
|
3801
4017
|
UnversionedTabbedNavigationConfigSchema2,
|
|
3802
4018
|
UnversionedUntabbedNavigationConfigSchema2
|
|
3803
4019
|
]);
|
|
3804
|
-
var VersionedNavigationConfigDataSchema2 =
|
|
4020
|
+
var VersionedNavigationConfigDataSchema2 = z18.object({
|
|
3805
4021
|
version: VersionIdSchema2,
|
|
3806
|
-
urlSlugOverride:
|
|
4022
|
+
urlSlugOverride: z18.string().optional(),
|
|
3807
4023
|
availability: AvailabilitySchema2.optional(),
|
|
3808
4024
|
config: UnversionedNavigationConfigSchema2
|
|
3809
4025
|
});
|
|
3810
|
-
var VersionedNavigationConfigSchema2 =
|
|
3811
|
-
versions:
|
|
4026
|
+
var VersionedNavigationConfigSchema2 = z18.object({
|
|
4027
|
+
versions: z18.array(VersionedNavigationConfigDataSchema2)
|
|
3812
4028
|
});
|
|
3813
|
-
var NavigationConfigSchema2 =
|
|
3814
|
-
var ThemeConfigSchema2 =
|
|
4029
|
+
var NavigationConfigSchema2 = z18.union([UnversionedNavigationConfigSchema2, VersionedNavigationConfigSchema2]);
|
|
4030
|
+
var ThemeConfigSchema2 = z18.object({
|
|
3815
4031
|
logo: FileIdSchema2.optional(),
|
|
3816
4032
|
backgroundImage: FileIdSchema2.optional(),
|
|
3817
4033
|
accentPrimary: RgbaColorSchema,
|
|
@@ -3833,37 +4049,37 @@ var ThemeConfigSchema2 = z15.object({
|
|
|
3833
4049
|
accent11: RgbaColorSchema.optional(),
|
|
3834
4050
|
accent12: RgbaColorSchema.optional()
|
|
3835
4051
|
});
|
|
3836
|
-
var DarkAndLightModeConfigSchema2 =
|
|
4052
|
+
var DarkAndLightModeConfigSchema2 = z18.object({
|
|
3837
4053
|
dark: ThemeConfigSchema2,
|
|
3838
4054
|
light: ThemeConfigSchema2
|
|
3839
4055
|
});
|
|
3840
|
-
var ColorsConfigV3Schema2 =
|
|
3841
|
-
|
|
3842
|
-
|
|
3843
|
-
|
|
4056
|
+
var ColorsConfigV3Schema2 = z18.discriminatedUnion("type", [
|
|
4057
|
+
z18.object({ type: z18.literal("dark"), ...ThemeConfigSchema2.shape }),
|
|
4058
|
+
z18.object({ type: z18.literal("light"), ...ThemeConfigSchema2.shape }),
|
|
4059
|
+
z18.object({ type: z18.literal("darkAndLight"), ...DarkAndLightModeConfigSchema2.shape })
|
|
3844
4060
|
]);
|
|
3845
|
-
var DocsConfigSchema2 =
|
|
3846
|
-
title:
|
|
4061
|
+
var DocsConfigSchema2 = z18.object({
|
|
4062
|
+
title: z18.string().optional(),
|
|
3847
4063
|
defaultLanguage: ProgrammingLanguageSchema.optional(),
|
|
3848
|
-
languages:
|
|
4064
|
+
languages: z18.array(LanguageSchema).optional(),
|
|
3849
4065
|
translations: DocsTranslationsConfigSchema.optional(),
|
|
3850
|
-
announcement:
|
|
4066
|
+
announcement: z18.object({ text: z18.string() }).optional(),
|
|
3851
4067
|
navigation: NavigationConfigSchema2.optional(),
|
|
3852
|
-
root:
|
|
3853
|
-
navbarLinks:
|
|
3854
|
-
footerLinks:
|
|
3855
|
-
hideNavLinks:
|
|
4068
|
+
root: z18.custom().optional(),
|
|
4069
|
+
navbarLinks: z18.array(NavbarLinkSchema).optional(),
|
|
4070
|
+
footerLinks: z18.array(FooterLinkSchema).optional(),
|
|
4071
|
+
hideNavLinks: z18.boolean().optional(),
|
|
3856
4072
|
logoHeight: HeightSchema2.optional(),
|
|
3857
4073
|
logoHref: UrlSchema2.optional(),
|
|
3858
|
-
logoRightText:
|
|
4074
|
+
logoRightText: z18.string().optional(),
|
|
3859
4075
|
favicon: FileIdSchema2.optional(),
|
|
3860
4076
|
agents: AgentsConfigSchema.optional(),
|
|
3861
4077
|
metadata: MetadataConfigSchema.optional(),
|
|
3862
|
-
redirects:
|
|
4078
|
+
redirects: z18.array(RedirectConfigSchema).optional(),
|
|
3863
4079
|
colorsV3: ColorsConfigV3Schema2.optional(),
|
|
3864
4080
|
layout: DocsLayoutConfigSchema.optional(),
|
|
3865
4081
|
theme: DocsThemeConfigSchema.optional(),
|
|
3866
|
-
globalTheme:
|
|
4082
|
+
globalTheme: z18.string().optional(),
|
|
3867
4083
|
settings: DocsSettingsConfigSchema.optional(),
|
|
3868
4084
|
typographyV2: DocsTypographyConfigV2Schema.optional(),
|
|
3869
4085
|
analyticsConfig: AnalyticsConfigSchema.optional(),
|
|
@@ -3873,8 +4089,8 @@ var DocsConfigSchema2 = z15.object({
|
|
|
3873
4089
|
aiChatConfig: AIChatConfigSchema.optional(),
|
|
3874
4090
|
pageActions: PageActionsConfigSchema.optional(),
|
|
3875
4091
|
editThisPageLaunch: EditThisPageLaunchSchema.optional(),
|
|
3876
|
-
header:
|
|
3877
|
-
footer:
|
|
4092
|
+
header: z18.string().optional(),
|
|
4093
|
+
footer: z18.string().optional(),
|
|
3878
4094
|
backgroundImage: FileIdSchema2.optional(),
|
|
3879
4095
|
logoV2: ThemedFileIdSchema.optional(),
|
|
3880
4096
|
logo: FileIdSchema2.optional(),
|
|
@@ -3882,410 +4098,156 @@ var DocsConfigSchema2 = z15.object({
|
|
|
3882
4098
|
colorsV2: ColorsConfigV2Schema.optional(),
|
|
3883
4099
|
typography: DocsTypographyConfigSchema.optional()
|
|
3884
4100
|
});
|
|
3885
|
-
var DocsDefinitionSchema2 =
|
|
3886
|
-
pages:
|
|
4101
|
+
var DocsDefinitionSchema2 = z18.object({
|
|
4102
|
+
pages: z18.record(PageIdSchema2, PageContentSchema2),
|
|
3887
4103
|
config: DocsConfigSchema2,
|
|
3888
|
-
jsFiles:
|
|
3889
|
-
});
|
|
3890
|
-
var NpmPackageSchema2 =
|
|
3891
|
-
packageName:
|
|
3892
|
-
githubRepoName:
|
|
3893
|
-
version:
|
|
3894
|
-
});
|
|
3895
|
-
var MavenPackageSchema2 =
|
|
3896
|
-
coordinate:
|
|
3897
|
-
githubRepoName:
|
|
3898
|
-
version:
|
|
3899
|
-
});
|
|
3900
|
-
var PypiPackageSchema2 =
|
|
3901
|
-
packageName:
|
|
3902
|
-
githubRepoName:
|
|
3903
|
-
version:
|
|
3904
|
-
});
|
|
3905
|
-
var PublishedSdkSchema2 =
|
|
3906
|
-
|
|
3907
|
-
|
|
3908
|
-
|
|
4104
|
+
jsFiles: z18.record(z18.string(), z18.string()).optional()
|
|
4105
|
+
});
|
|
4106
|
+
var NpmPackageSchema2 = z18.object({
|
|
4107
|
+
packageName: z18.string(),
|
|
4108
|
+
githubRepoName: z18.string(),
|
|
4109
|
+
version: z18.string()
|
|
4110
|
+
});
|
|
4111
|
+
var MavenPackageSchema2 = z18.object({
|
|
4112
|
+
coordinate: z18.string(),
|
|
4113
|
+
githubRepoName: z18.string(),
|
|
4114
|
+
version: z18.string()
|
|
4115
|
+
});
|
|
4116
|
+
var PypiPackageSchema2 = z18.object({
|
|
4117
|
+
packageName: z18.string(),
|
|
4118
|
+
githubRepoName: z18.string(),
|
|
4119
|
+
version: z18.string()
|
|
4120
|
+
});
|
|
4121
|
+
var PublishedSdkSchema2 = z18.discriminatedUnion("type", [
|
|
4122
|
+
z18.object({ type: z18.literal("npm"), ...NpmPackageSchema2.shape }),
|
|
4123
|
+
z18.object({ type: z18.literal("maven"), ...MavenPackageSchema2.shape }),
|
|
4124
|
+
z18.object({ type: z18.literal("pypi"), ...PypiPackageSchema2.shape })
|
|
3909
4125
|
]);
|
|
3910
|
-
var PublishedPostmanCollectionSchema2 =
|
|
4126
|
+
var PublishedPostmanCollectionSchema2 = z18.object({
|
|
3911
4127
|
url: UrlSchema2,
|
|
3912
|
-
githubRepoName:
|
|
4128
|
+
githubRepoName: z18.string().optional()
|
|
3913
4129
|
});
|
|
3914
|
-
var ApiArtifactsSchema2 =
|
|
3915
|
-
sdks:
|
|
4130
|
+
var ApiArtifactsSchema2 = z18.object({
|
|
4131
|
+
sdks: z18.array(PublishedSdkSchema2),
|
|
3916
4132
|
postman: PublishedPostmanCollectionSchema2.optional()
|
|
3917
4133
|
});
|
|
3918
|
-
var InvalidCustomDomainErrorBodySchema =
|
|
3919
|
-
overlappingDomains:
|
|
3920
|
-
});
|
|
3921
|
-
var OverlappingCustomDomainsSchema = z15.array(z15.string());
|
|
3922
|
-
|
|
3923
|
-
// src/orpc-client/docs/v1/write/contract.ts
|
|
3924
|
-
var StartDocsRegisterV1InputSchema = z16.object({
|
|
3925
|
-
orgId: z16.string(),
|
|
3926
|
-
domain: z16.string(),
|
|
3927
|
-
filepaths: z16.array(z16.string())
|
|
3928
|
-
});
|
|
3929
|
-
var StartDocsRegisterV1ResponseSchema = z16.object({
|
|
3930
|
-
docsRegistrationId: z16.string(),
|
|
3931
|
-
uploadUrls: z16.record(z16.string(), FileS3UploadUrlSchema),
|
|
3932
|
-
skippedFiles: z16.array(z16.string())
|
|
3933
|
-
});
|
|
3934
|
-
var FinishDocsRegisterV1InputSchema = z16.object({
|
|
3935
|
-
docsRegistrationId: z16.string(),
|
|
3936
|
-
docsDefinition: z16.unknown()
|
|
3937
|
-
});
|
|
3938
|
-
var docsV1WriteContract = {
|
|
3939
|
-
startDocsRegister: import_contract8.oc.route({ method: "POST", path: "/init" }).input(StartDocsRegisterV1InputSchema).output(StartDocsRegisterV1ResponseSchema),
|
|
3940
|
-
finishDocsRegister: import_contract8.oc.route({ method: "POST", path: "/register/{docsRegistrationId}" }).input(FinishDocsRegisterV1InputSchema).output(z16.void())
|
|
3941
|
-
};
|
|
3942
|
-
|
|
3943
|
-
// src/orpc-client/docs/v1/write/client.ts
|
|
3944
|
-
function createDocsV1WriteClient(options) {
|
|
3945
|
-
const link = new import_fetch4.OpenAPILink(docsV1WriteContract, {
|
|
3946
|
-
url: `${options.baseUrl}/registry/docs`,
|
|
3947
|
-
headers: () => ({
|
|
3948
|
-
Authorization: `Bearer ${options.token}`,
|
|
3949
|
-
...options.headers
|
|
3950
|
-
}),
|
|
3951
|
-
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
3952
|
-
});
|
|
3953
|
-
return (0, import_client4.createORPCClient)(link);
|
|
3954
|
-
}
|
|
3955
|
-
|
|
3956
|
-
// src/orpc-client/docs/v2/library-docs/client.ts
|
|
3957
|
-
var import_client5 = require("@orpc/client");
|
|
3958
|
-
var import_fetch5 = require("@orpc/openapi-client/fetch");
|
|
3959
|
-
|
|
3960
|
-
// src/orpc-client/docs/v2/library-docs/contract.ts
|
|
3961
|
-
var import_contract10 = require("@orpc/contract");
|
|
3962
|
-
var z17 = __toESM(require("zod"), 1);
|
|
3963
|
-
var ALLOWED_HOSTNAMES = /* @__PURE__ */ new Set(["github.com", "gitlab.com"]);
|
|
3964
|
-
var GithubUrlSchema = z17.string().url().describe(
|
|
3965
|
-
"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>."
|
|
3966
|
-
).refine(
|
|
3967
|
-
(url) => {
|
|
3968
|
-
try {
|
|
3969
|
-
const parsed = new URL(url);
|
|
3970
|
-
if (parsed.protocol !== "https:") {
|
|
3971
|
-
return false;
|
|
3972
|
-
}
|
|
3973
|
-
if (!ALLOWED_HOSTNAMES.has(parsed.hostname)) {
|
|
3974
|
-
return false;
|
|
3975
|
-
}
|
|
3976
|
-
if (parsed.username || parsed.password) {
|
|
3977
|
-
return false;
|
|
3978
|
-
}
|
|
3979
|
-
return /^\/[\w.-]+\/[\w.-]+(?:\.git)?\/?$/.test(parsed.pathname);
|
|
3980
|
-
} catch {
|
|
3981
|
-
return false;
|
|
3982
|
-
}
|
|
3983
|
-
},
|
|
3984
|
-
{ message: "Must be a valid https://github.com/<owner>/<repo> or https://gitlab.com/<owner>/<repo> URL" }
|
|
3985
|
-
);
|
|
3986
|
-
var SafeBranchSchema = z17.string().regex(/^[a-zA-Z0-9._/-]+$/, "Invalid branch name").nullish();
|
|
3987
|
-
var SafePackagePathSchema = z17.string().refine((p) => !p.includes("..") && !p.startsWith("/"), {
|
|
3988
|
-
message: "packagePath must not contain path traversal sequences"
|
|
3989
|
-
}).nullish();
|
|
3990
|
-
var LibraryDocsBaseConfigSchema = z17.object({
|
|
3991
|
-
branch: SafeBranchSchema,
|
|
3992
|
-
packagePath: SafePackagePathSchema,
|
|
3993
|
-
title: z17.string().nullish(),
|
|
3994
|
-
slug: z17.string().nullish()
|
|
3995
|
-
});
|
|
3996
|
-
var PythonLibraryDocsConfigSchema = LibraryDocsBaseConfigSchema;
|
|
3997
|
-
var CppLibraryDocsConfigSchema = LibraryDocsBaseConfigSchema.extend({
|
|
3998
|
-
doxyfileContent: z17.string().nullish()
|
|
3999
|
-
});
|
|
4000
|
-
var StartLibraryDocsGenerationInputSchema = z17.discriminatedUnion("language", [
|
|
4001
|
-
z17.object({
|
|
4002
|
-
orgId: z17.string(),
|
|
4003
|
-
githubUrl: GithubUrlSchema,
|
|
4004
|
-
language: z17.literal("PYTHON"),
|
|
4005
|
-
config: PythonLibraryDocsConfigSchema.nullish()
|
|
4006
|
-
}),
|
|
4007
|
-
z17.object({
|
|
4008
|
-
orgId: z17.string(),
|
|
4009
|
-
githubUrl: GithubUrlSchema,
|
|
4010
|
-
language: z17.literal("CPP"),
|
|
4011
|
-
config: CppLibraryDocsConfigSchema.nullish()
|
|
4012
|
-
})
|
|
4013
|
-
]);
|
|
4014
|
-
var StartLibraryDocsGenerationResponseSchema = z17.object({
|
|
4015
|
-
jobId: z17.string()
|
|
4016
|
-
});
|
|
4017
|
-
var GetLibraryDocsStatusInputSchema = z17.object({
|
|
4018
|
-
jobId: z17.string()
|
|
4019
|
-
});
|
|
4020
|
-
var LibraryDocsResultSchema = z17.object({
|
|
4021
|
-
jobId: z17.string(),
|
|
4022
|
-
resultUrl: z17.string()
|
|
4023
|
-
});
|
|
4024
|
-
var LibraryDocsGenerationStatusSchema = z17.object({
|
|
4025
|
-
jobId: z17.string(),
|
|
4026
|
-
status: z17.string(),
|
|
4027
|
-
progress: z17.string(),
|
|
4028
|
-
error: z17.object({
|
|
4029
|
-
code: z17.string(),
|
|
4030
|
-
message: z17.string()
|
|
4031
|
-
}).optional(),
|
|
4032
|
-
createdAt: z17.string(),
|
|
4033
|
-
updatedAt: z17.string()
|
|
4034
|
-
});
|
|
4035
|
-
var libraryDocsContract = {
|
|
4036
|
-
startLibraryDocsGeneration: import_contract10.oc.route({ method: "POST", path: "/library-docs/generate" }).input(StartLibraryDocsGenerationInputSchema).output(StartLibraryDocsGenerationResponseSchema),
|
|
4037
|
-
getLibraryDocsGenerationStatus: import_contract10.oc.route({ method: "GET", path: "/library-docs/status/{jobId}" }).input(GetLibraryDocsStatusInputSchema).output(LibraryDocsGenerationStatusSchema),
|
|
4038
|
-
getLibraryDocsResult: import_contract10.oc.route({ method: "GET", path: "/library-docs/result/{jobId}" }).input(GetLibraryDocsStatusInputSchema).output(LibraryDocsResultSchema)
|
|
4039
|
-
};
|
|
4040
|
-
|
|
4041
|
-
// src/orpc-client/docs/v2/library-docs/client.ts
|
|
4042
|
-
function createLibraryDocsClient(options) {
|
|
4043
|
-
const link = new import_fetch5.OpenAPILink(libraryDocsContract, {
|
|
4044
|
-
url: `${options.baseUrl}/v2/registry/docs`,
|
|
4045
|
-
headers: () => ({
|
|
4046
|
-
Authorization: `Bearer ${options.token}`,
|
|
4047
|
-
...options.headers
|
|
4048
|
-
}),
|
|
4049
|
-
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
4050
|
-
});
|
|
4051
|
-
return (0, import_client5.createORPCClient)(link);
|
|
4052
|
-
}
|
|
4053
|
-
|
|
4054
|
-
// src/orpc-client/docs/v2/organization/client.ts
|
|
4055
|
-
var import_client6 = require("@orpc/client");
|
|
4056
|
-
var import_fetch6 = require("@orpc/openapi-client/fetch");
|
|
4057
|
-
|
|
4058
|
-
// src/orpc-client/docs/v2/organization/contract.ts
|
|
4059
|
-
var import_contract12 = require("@orpc/contract");
|
|
4060
|
-
var z18 = __toESM(require("zod"), 1);
|
|
4061
|
-
var GetOrganizationForUrlInputSchema = z18.object({
|
|
4062
|
-
url: z18.string()
|
|
4134
|
+
var InvalidCustomDomainErrorBodySchema = z18.object({
|
|
4135
|
+
overlappingDomains: z18.array(z18.array(z18.string()))
|
|
4063
4136
|
});
|
|
4064
|
-
var
|
|
4065
|
-
getOrganizationForUrl: import_contract12.oc.route({ method: "POST", path: "/organization-for-url" }).input(GetOrganizationForUrlInputSchema).output(z18.string())
|
|
4066
|
-
};
|
|
4067
|
-
|
|
4068
|
-
// src/orpc-client/docs/v2/organization/client.ts
|
|
4069
|
-
function createOrganizationClient(options) {
|
|
4070
|
-
const link = new import_fetch6.OpenAPILink(organizationContract, {
|
|
4071
|
-
url: `${options.baseUrl}/v2/registry/docs`,
|
|
4072
|
-
headers: () => ({
|
|
4073
|
-
Authorization: `Bearer ${options.token}`,
|
|
4074
|
-
...options.headers
|
|
4075
|
-
}),
|
|
4076
|
-
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
4077
|
-
});
|
|
4078
|
-
return (0, import_client6.createORPCClient)(link);
|
|
4079
|
-
}
|
|
4080
|
-
|
|
4081
|
-
// src/orpc-client/docs/v2/read/client.ts
|
|
4082
|
-
var import_client7 = require("@orpc/client");
|
|
4083
|
-
var import_fetch7 = require("@orpc/openapi-client/fetch");
|
|
4084
|
-
|
|
4085
|
-
// src/orpc-client/docs/v2/read/contract.ts
|
|
4086
|
-
var import_contract14 = require("@orpc/contract");
|
|
4087
|
-
var z19 = __toESM(require("zod"), 1);
|
|
4088
|
-
var GetDocsUrlMetadataInputSchema = z19.object({
|
|
4089
|
-
url: z19.string()
|
|
4090
|
-
});
|
|
4091
|
-
var GetDocsUrlMetadataResponseSchema = z19.object({
|
|
4092
|
-
isPreviewUrl: z19.boolean(),
|
|
4093
|
-
org: z19.string(),
|
|
4094
|
-
url: z19.string(),
|
|
4095
|
-
gitUrl: z19.string().nullish(),
|
|
4096
|
-
enableAlgoliaOnPreview: z19.boolean().nullish()
|
|
4097
|
-
});
|
|
4098
|
-
var GetDocsForUrlInputSchema = z19.object({
|
|
4099
|
-
url: z19.string(),
|
|
4100
|
-
excludeApis: z19.boolean().nullish()
|
|
4101
|
-
});
|
|
4102
|
-
var GetPrivateDocsForUrlInputSchema = z19.object({
|
|
4103
|
-
url: z19.string()
|
|
4104
|
-
});
|
|
4105
|
-
var ListAllDocsUrlsInputSchema = z19.object({
|
|
4106
|
-
limit: z19.number().nullish(),
|
|
4107
|
-
page: z19.number().nullish(),
|
|
4108
|
-
custom: z19.boolean().nullish(),
|
|
4109
|
-
preview: z19.boolean().nullish()
|
|
4110
|
-
});
|
|
4111
|
-
var GetDocsConfigByIdInputSchema = z19.object({
|
|
4112
|
-
docsConfigId: z19.string()
|
|
4113
|
-
});
|
|
4114
|
-
var DocsDefinitionField = {
|
|
4115
|
-
BaseUrl: "BASE_URL",
|
|
4116
|
-
FilesV2: "FILES_V2",
|
|
4117
|
-
ApisV2: "APIS_V2",
|
|
4118
|
-
Apis: "APIS",
|
|
4119
|
-
Pages: "PAGES",
|
|
4120
|
-
JsFiles: "JS_FILES",
|
|
4121
|
-
Config: "CONFIG",
|
|
4122
|
-
Root: "ROOT"
|
|
4123
|
-
};
|
|
4124
|
-
var GetDocsConfigByIdResponseSchema = z19.object({
|
|
4125
|
-
docsConfig: DocsConfigSchema,
|
|
4126
|
-
apis: z19.record(z19.string(), z19.unknown())
|
|
4127
|
-
});
|
|
4128
|
-
var DocsDomainItemSchema = z19.object({
|
|
4129
|
-
domain: z19.string(),
|
|
4130
|
-
basePath: z19.string().optional(),
|
|
4131
|
-
organizationId: z19.string(),
|
|
4132
|
-
updatedAt: z19.string()
|
|
4133
|
-
});
|
|
4134
|
-
var ListAllDocsUrlsResponseSchema = z19.object({
|
|
4135
|
-
urls: z19.array(DocsDomainItemSchema)
|
|
4136
|
-
});
|
|
4137
|
-
var getDocsForUrl;
|
|
4138
|
-
((getDocsForUrl2) => {
|
|
4139
|
-
let Error2;
|
|
4140
|
-
((Error3) => {
|
|
4141
|
-
function _unknown(fetcherError) {
|
|
4142
|
-
return { error: void 0, content: fetcherError };
|
|
4143
|
-
}
|
|
4144
|
-
Error3._unknown = _unknown;
|
|
4145
|
-
})(Error2 = getDocsForUrl2.Error || (getDocsForUrl2.Error = {}));
|
|
4146
|
-
})(getDocsForUrl || (getDocsForUrl = {}));
|
|
4147
|
-
var docsV2ReadContract = {
|
|
4148
|
-
getDocsUrlMetadata: import_contract14.oc.route({ method: "POST", path: "/metadata-for-url" }).input(GetDocsUrlMetadataInputSchema).output(GetDocsUrlMetadataResponseSchema),
|
|
4149
|
-
getDocsForUrl: import_contract14.oc.route({ method: "POST", path: "/load-with-url" }).input(GetDocsForUrlInputSchema).output(LoadDocsForUrlResponseSchema),
|
|
4150
|
-
getPrivateDocsForUrl: import_contract14.oc.route({ method: "POST", path: "/private/load-with-url" }).input(GetPrivateDocsForUrlInputSchema).output(LoadDocsForUrlResponseSchema),
|
|
4151
|
-
listAllDocsUrls: import_contract14.oc.route({ method: "GET", path: "/urls/list" }).input(ListAllDocsUrlsInputSchema).output(ListAllDocsUrlsResponseSchema),
|
|
4152
|
-
getDocsConfigById: import_contract14.oc.route({ method: "GET", path: "/{docsConfigId}" }).input(GetDocsConfigByIdInputSchema).output(GetDocsConfigByIdResponseSchema),
|
|
4153
|
-
prepopulateFdrReadS3Bucket: import_contract14.oc.route({ method: "POST", path: "/prepopulate-s3-bucket" }).output(z19.void()),
|
|
4154
|
-
ensureDocsInS3: import_contract14.oc.route({ method: "POST", path: "/ensure-docs-in-s3" }).output(z19.void()),
|
|
4155
|
-
getDocsFields: import_contract14.oc.route({ method: "POST", path: "/load-fields" }).output(z19.void())
|
|
4156
|
-
};
|
|
4157
|
-
|
|
4158
|
-
// src/orpc-client/docs/v2/read/client.ts
|
|
4159
|
-
function createDocsV2ReadClient(options) {
|
|
4160
|
-
const link = new import_fetch7.OpenAPILink(docsV2ReadContract, {
|
|
4161
|
-
url: `${options.baseUrl}/v2/registry/docs`,
|
|
4162
|
-
headers: () => ({
|
|
4163
|
-
Authorization: `Bearer ${options.token}`,
|
|
4164
|
-
...options.headers
|
|
4165
|
-
}),
|
|
4166
|
-
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
4167
|
-
});
|
|
4168
|
-
return (0, import_client7.createORPCClient)(link);
|
|
4169
|
-
}
|
|
4170
|
-
|
|
4171
|
-
// src/orpc-client/docs/v2/write/client.ts
|
|
4172
|
-
var import_client8 = require("@orpc/client");
|
|
4173
|
-
var import_fetch8 = require("@orpc/openapi-client/fetch");
|
|
4137
|
+
var OverlappingCustomDomainsSchema = z18.array(z18.string());
|
|
4174
4138
|
|
|
4175
4139
|
// src/orpc-client/docs/v2/write/contract.ts
|
|
4176
|
-
var
|
|
4177
|
-
var z20 = __toESM(require("zod"), 1);
|
|
4178
|
-
var FilePathSchema2 = z20.string();
|
|
4140
|
+
var FilePathSchema2 = z19.string();
|
|
4179
4141
|
function FilePath(value) {
|
|
4180
4142
|
return value;
|
|
4181
4143
|
}
|
|
4182
|
-
var FilePathInputSchema =
|
|
4144
|
+
var FilePathInputSchema = z19.union([
|
|
4183
4145
|
FilePathSchema2,
|
|
4184
|
-
|
|
4146
|
+
z19.object({ path: FilePathSchema2, fileHash: z19.string().nullish() })
|
|
4185
4147
|
]);
|
|
4186
|
-
var ImageFilePathSchema =
|
|
4148
|
+
var ImageFilePathSchema = z19.object({
|
|
4187
4149
|
filePath: FilePathSchema2,
|
|
4188
|
-
width:
|
|
4189
|
-
height:
|
|
4190
|
-
blurDataUrl:
|
|
4191
|
-
alt:
|
|
4192
|
-
fileHash:
|
|
4193
|
-
});
|
|
4194
|
-
var AuthConfigSchema = z20.object({
|
|
4195
|
-
type: z20.string()
|
|
4196
|
-
});
|
|
4197
|
-
var StartDocsRegisterV2InputSchema = z20.object({
|
|
4198
|
-
orgId: z20.string(),
|
|
4199
|
-
domain: z20.string(),
|
|
4200
|
-
customDomains: z20.array(z20.string()),
|
|
4201
|
-
filepaths: z20.array(FilePathInputSchema),
|
|
4202
|
-
images: z20.array(ImageFilePathSchema).nullish(),
|
|
4203
|
-
authConfig: AuthConfigSchema.nullish()
|
|
4150
|
+
width: z19.number(),
|
|
4151
|
+
height: z19.number(),
|
|
4152
|
+
blurDataUrl: z19.string().nullish(),
|
|
4153
|
+
alt: z19.string().nullish(),
|
|
4154
|
+
fileHash: z19.string().nullish()
|
|
4204
4155
|
});
|
|
4205
|
-
var
|
|
4206
|
-
|
|
4207
|
-
uploadUrls: z20.record(z20.string(), FileS3UploadUrlSchema),
|
|
4208
|
-
skippedFiles: z20.array(z20.string())
|
|
4156
|
+
var AuthConfigSchema = z19.object({
|
|
4157
|
+
type: z19.string()
|
|
4209
4158
|
});
|
|
4210
|
-
var
|
|
4211
|
-
orgId:
|
|
4212
|
-
|
|
4213
|
-
|
|
4214
|
-
|
|
4215
|
-
|
|
4216
|
-
|
|
4217
|
-
});
|
|
4218
|
-
var StartDocsPreviewRegisterResponseSchema = z20.object({
|
|
4219
|
-
docsRegistrationId: z20.string(),
|
|
4220
|
-
uploadUrls: z20.record(z20.string(), FileS3UploadUrlSchema),
|
|
4221
|
-
skippedFiles: z20.array(z20.string()),
|
|
4222
|
-
previewUrl: z20.string()
|
|
4159
|
+
var StartDocsRegisterV2InputSchema = z19.object({
|
|
4160
|
+
orgId: z19.string(),
|
|
4161
|
+
domain: z19.string(),
|
|
4162
|
+
customDomains: z19.array(z19.string()),
|
|
4163
|
+
filepaths: z19.array(FilePathInputSchema),
|
|
4164
|
+
images: z19.array(ImageFilePathSchema).nullish(),
|
|
4165
|
+
authConfig: AuthConfigSchema.nullish()
|
|
4223
4166
|
});
|
|
4224
|
-
var
|
|
4225
|
-
docsRegistrationId:
|
|
4226
|
-
|
|
4227
|
-
|
|
4228
|
-
excludeApis: z20.boolean().nullish(),
|
|
4229
|
-
basepathAware: z20.boolean().nullish()
|
|
4167
|
+
var StartDocsRegisterV2ResponseSchema = z19.object({
|
|
4168
|
+
docsRegistrationId: z19.string(),
|
|
4169
|
+
uploadUrls: z19.record(z19.string(), FileS3UploadUrlSchema),
|
|
4170
|
+
skippedFiles: z19.array(z19.string())
|
|
4230
4171
|
});
|
|
4231
|
-
var
|
|
4232
|
-
|
|
4233
|
-
|
|
4172
|
+
var StartDocsPreviewRegisterInputSchema = z19.object({
|
|
4173
|
+
orgId: z19.string(),
|
|
4174
|
+
filepaths: z19.array(FilePathInputSchema),
|
|
4175
|
+
basePath: z19.string().nullish(),
|
|
4176
|
+
images: z19.array(ImageFilePathSchema).nullish(),
|
|
4177
|
+
authConfig: AuthConfigSchema.nullish(),
|
|
4178
|
+
previewId: z19.string().nullish()
|
|
4179
|
+
});
|
|
4180
|
+
var StartDocsPreviewRegisterResponseSchema = z19.object({
|
|
4181
|
+
docsRegistrationId: z19.string(),
|
|
4182
|
+
uploadUrls: z19.record(z19.string(), FileS3UploadUrlSchema),
|
|
4183
|
+
skippedFiles: z19.array(z19.string()),
|
|
4184
|
+
previewUrl: z19.string()
|
|
4185
|
+
});
|
|
4186
|
+
var FinishDocsRegisterV2InputSchema = z19.object({
|
|
4187
|
+
docsRegistrationId: z19.string(),
|
|
4188
|
+
docsDefinition: z19.unknown(),
|
|
4189
|
+
libraryDocs: z19.unknown().nullish(),
|
|
4190
|
+
excludeApis: z19.boolean().nullish(),
|
|
4191
|
+
basepathAware: z19.boolean().nullish()
|
|
4192
|
+
});
|
|
4193
|
+
var TransferOwnershipInputSchema = z19.object({
|
|
4194
|
+
domain: z19.string(),
|
|
4195
|
+
toOrgId: z19.string()
|
|
4234
4196
|
});
|
|
4235
|
-
var SetIsArchivedInputSchema =
|
|
4236
|
-
url:
|
|
4237
|
-
isArchived:
|
|
4197
|
+
var SetIsArchivedInputSchema = z19.object({
|
|
4198
|
+
url: z19.string(),
|
|
4199
|
+
isArchived: z19.boolean()
|
|
4238
4200
|
});
|
|
4239
|
-
var SetDocsUrlMetadataInputSchema =
|
|
4240
|
-
url:
|
|
4241
|
-
githubUrl:
|
|
4201
|
+
var SetDocsUrlMetadataInputSchema = z19.object({
|
|
4202
|
+
url: z19.string(),
|
|
4203
|
+
githubUrl: z19.string().nullish()
|
|
4242
4204
|
});
|
|
4243
|
-
var AlgoliaDomainInputSchema =
|
|
4244
|
-
domain:
|
|
4205
|
+
var AlgoliaDomainInputSchema = z19.object({
|
|
4206
|
+
domain: z19.string()
|
|
4245
4207
|
});
|
|
4246
|
-
var ListAlgoliaPreviewWhitelistResponseSchema =
|
|
4247
|
-
domains:
|
|
4208
|
+
var ListAlgoliaPreviewWhitelistResponseSchema = z19.object({
|
|
4209
|
+
domains: z19.array(z19.string())
|
|
4248
4210
|
});
|
|
4249
|
-
var DeleteDocsSiteInputSchema =
|
|
4250
|
-
url:
|
|
4211
|
+
var DeleteDocsSiteInputSchema = z19.object({
|
|
4212
|
+
url: z19.string()
|
|
4251
4213
|
});
|
|
4252
|
-
var RemoveCustomDomainAliasInputSchema =
|
|
4214
|
+
var RemoveCustomDomainAliasInputSchema = z19.object({
|
|
4253
4215
|
/** The custom-domain URL to remove (e.g. `docs.example.com` or `docs.example.com/api`). */
|
|
4254
|
-
url:
|
|
4216
|
+
url: z19.string()
|
|
4255
4217
|
});
|
|
4256
|
-
var Bcp47LocaleSchema2 =
|
|
4218
|
+
var Bcp47LocaleSchema2 = z19.string().regex(
|
|
4257
4219
|
/^[a-zA-Z]{2,8}(-[a-zA-Z0-9]{1,8})*$/,
|
|
4258
4220
|
"Locale must be a valid BCP 47 language tag (e.g. 'en', 'fr', 'pt-BR', 'zh-Hans-CN')"
|
|
4259
4221
|
);
|
|
4260
|
-
var RegisterTranslationInputSchema =
|
|
4261
|
-
domain:
|
|
4222
|
+
var RegisterTranslationInputSchema = z19.object({
|
|
4223
|
+
domain: z19.string(),
|
|
4262
4224
|
/**
|
|
4263
4225
|
* Custom domains that share the docs registration with `domain`. The translation
|
|
4264
4226
|
* blob is written to S3 once per URL (fern URL + each custom domain), mirroring
|
|
4265
4227
|
* the fan-out shape of `finishDocsRegister`. Without this, requests to a custom
|
|
4266
4228
|
* domain hit the translation S3 path under the fern URL prefix and 404.
|
|
4267
4229
|
*/
|
|
4268
|
-
customDomains:
|
|
4269
|
-
orgId:
|
|
4230
|
+
customDomains: z19.array(z19.string()).optional().default([]),
|
|
4231
|
+
orgId: z19.string(),
|
|
4270
4232
|
/** BCP 47 language tag identifying the locale for this translation. */
|
|
4271
4233
|
locale: Bcp47LocaleSchema2,
|
|
4272
4234
|
/** The full docs definition for this locale, same structure as finishDocsRegister. */
|
|
4273
|
-
docsDefinition:
|
|
4235
|
+
docsDefinition: z19.unknown()
|
|
4274
4236
|
});
|
|
4275
|
-
var RegisterTranslationResponseSchema =
|
|
4276
|
-
locale:
|
|
4237
|
+
var RegisterTranslationResponseSchema = z19.object({
|
|
4238
|
+
locale: z19.string()
|
|
4277
4239
|
});
|
|
4278
4240
|
var docsV2WriteContract = {
|
|
4279
|
-
startDocsRegister:
|
|
4280
|
-
startDocsPreviewRegister:
|
|
4281
|
-
finishDocsRegister:
|
|
4282
|
-
transferOwnershipOfDomain:
|
|
4283
|
-
setIsArchived:
|
|
4284
|
-
setDocsUrlMetadata:
|
|
4285
|
-
addAlgoliaPreviewWhitelistEntry:
|
|
4286
|
-
removeAlgoliaPreviewWhitelistEntry:
|
|
4287
|
-
listAlgoliaPreviewWhitelist:
|
|
4288
|
-
deleteDocsSite:
|
|
4241
|
+
startDocsRegister: import_contract14.oc.route({ method: "POST", path: "/v2/init" }).input(StartDocsRegisterV2InputSchema).output(StartDocsRegisterV2ResponseSchema),
|
|
4242
|
+
startDocsPreviewRegister: import_contract14.oc.route({ method: "POST", path: "/preview/init" }).input(StartDocsPreviewRegisterInputSchema).output(StartDocsPreviewRegisterResponseSchema),
|
|
4243
|
+
finishDocsRegister: import_contract14.oc.route({ method: "POST", path: "/register/{docsRegistrationId}" }).input(FinishDocsRegisterV2InputSchema).output(z19.void()),
|
|
4244
|
+
transferOwnershipOfDomain: import_contract14.oc.route({ method: "POST", path: "/transfer-ownership" }).input(TransferOwnershipInputSchema).output(z19.void()),
|
|
4245
|
+
setIsArchived: import_contract14.oc.route({ method: "POST", path: "/set-is-archived" }).input(SetIsArchivedInputSchema).output(z19.void()),
|
|
4246
|
+
setDocsUrlMetadata: import_contract14.oc.route({ method: "POST", path: "/set-metadata-for-url" }).input(SetDocsUrlMetadataInputSchema).output(z19.void()),
|
|
4247
|
+
addAlgoliaPreviewWhitelistEntry: import_contract14.oc.route({ method: "POST", path: "/algolia-preview-whitelist/add" }).input(AlgoliaDomainInputSchema).output(z19.void()),
|
|
4248
|
+
removeAlgoliaPreviewWhitelistEntry: import_contract14.oc.route({ method: "POST", path: "/algolia-preview-whitelist/remove" }).input(AlgoliaDomainInputSchema).output(z19.void()),
|
|
4249
|
+
listAlgoliaPreviewWhitelist: import_contract14.oc.route({ method: "GET", path: "/algolia-preview-whitelist/list" }).output(ListAlgoliaPreviewWhitelistResponseSchema),
|
|
4250
|
+
deleteDocsSite: import_contract14.oc.route({ method: "POST", path: "/delete" }).input(DeleteDocsSiteInputSchema).output(z19.void()),
|
|
4289
4251
|
/**
|
|
4290
4252
|
* Removes a single custom-domain alias from a docs site, leaving the
|
|
4291
4253
|
* Fern-URL sibling intact. Use this when un-binding a custom domain
|
|
@@ -4294,13 +4256,13 @@ var docsV2WriteContract = {
|
|
|
4294
4256
|
*
|
|
4295
4257
|
* Idempotent: succeeds with no-op if the URL is not registered.
|
|
4296
4258
|
*/
|
|
4297
|
-
removeCustomDomainAlias:
|
|
4298
|
-
registerTranslation:
|
|
4259
|
+
removeCustomDomainAlias: import_contract14.oc.route({ method: "POST", path: "/remove-custom-domain-alias" }).input(RemoveCustomDomainAliasInputSchema).output(z19.void()),
|
|
4260
|
+
registerTranslation: import_contract14.oc.route({ method: "POST", path: "/translations/register" }).input(RegisterTranslationInputSchema).output(RegisterTranslationResponseSchema)
|
|
4299
4261
|
};
|
|
4300
4262
|
|
|
4301
4263
|
// src/orpc-client/docs/v2/write/client.ts
|
|
4302
4264
|
function createDocsV2WriteClient(options) {
|
|
4303
|
-
const link = new
|
|
4265
|
+
const link = new import_fetch7.OpenAPILink(docsV2WriteContract, {
|
|
4304
4266
|
url: `${options.baseUrl}/v2/registry/docs`,
|
|
4305
4267
|
headers: () => ({
|
|
4306
4268
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -4308,15 +4270,14 @@ function createDocsV2WriteClient(options) {
|
|
|
4308
4270
|
}),
|
|
4309
4271
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
4310
4272
|
});
|
|
4311
|
-
return (0,
|
|
4273
|
+
return (0, import_client7.createORPCClient)(link);
|
|
4312
4274
|
}
|
|
4313
4275
|
|
|
4314
4276
|
// src/orpc-client/docs/client.ts
|
|
4315
4277
|
function createDocsClient(options) {
|
|
4316
4278
|
return {
|
|
4317
4279
|
v1: {
|
|
4318
|
-
read: createDocsV1ReadClient(options)
|
|
4319
|
-
write: createDocsV1WriteClient(options)
|
|
4280
|
+
read: createDocsV1ReadClient(options)
|
|
4320
4281
|
},
|
|
4321
4282
|
v2: {
|
|
4322
4283
|
read: createDocsV2ReadClient(options),
|
|
@@ -4328,22 +4289,22 @@ function createDocsClient(options) {
|
|
|
4328
4289
|
}
|
|
4329
4290
|
|
|
4330
4291
|
// src/orpc-client/docs-cache/client.ts
|
|
4331
|
-
var
|
|
4332
|
-
var
|
|
4292
|
+
var import_client13 = require("@orpc/client");
|
|
4293
|
+
var import_fetch8 = require("@orpc/openapi-client/fetch");
|
|
4333
4294
|
|
|
4334
4295
|
// src/orpc-client/docs-cache/contract.ts
|
|
4335
|
-
var
|
|
4336
|
-
var
|
|
4337
|
-
var InvalidateCachedDocsInputSchema =
|
|
4338
|
-
url:
|
|
4296
|
+
var import_contract16 = require("@orpc/contract");
|
|
4297
|
+
var z20 = __toESM(require("zod"), 1);
|
|
4298
|
+
var InvalidateCachedDocsInputSchema = z20.object({
|
|
4299
|
+
url: z20.string()
|
|
4339
4300
|
});
|
|
4340
4301
|
var docsCacheContract = {
|
|
4341
|
-
invalidate:
|
|
4302
|
+
invalidate: import_contract16.oc.route({ method: "POST", path: "/invalidate" }).input(InvalidateCachedDocsInputSchema).output(z20.void())
|
|
4342
4303
|
};
|
|
4343
4304
|
|
|
4344
4305
|
// src/orpc-client/docs-cache/client.ts
|
|
4345
4306
|
function createDocsCacheClient(options) {
|
|
4346
|
-
const link = new
|
|
4307
|
+
const link = new import_fetch8.OpenAPILink(docsCacheContract, {
|
|
4347
4308
|
url: `${options.baseUrl}/docs-cache`,
|
|
4348
4309
|
headers: () => ({
|
|
4349
4310
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -4351,14 +4312,14 @@ function createDocsCacheClient(options) {
|
|
|
4351
4312
|
}),
|
|
4352
4313
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
4353
4314
|
});
|
|
4354
|
-
return (0,
|
|
4315
|
+
return (0, import_client13.createORPCClient)(link);
|
|
4355
4316
|
}
|
|
4356
4317
|
|
|
4357
4318
|
// src/orpc-client/docs-deployment/client.ts
|
|
4358
|
-
var
|
|
4359
|
-
var
|
|
4319
|
+
var import_client14 = require("@orpc/client");
|
|
4320
|
+
var import_fetch9 = require("@orpc/openapi-client/fetch");
|
|
4360
4321
|
function createDocsDeploymentClient(options) {
|
|
4361
|
-
const link = new
|
|
4322
|
+
const link = new import_fetch9.OpenAPILink(docsDeploymentContract, {
|
|
4362
4323
|
url: `${options.baseUrl}/docs-deployment`,
|
|
4363
4324
|
headers: () => ({
|
|
4364
4325
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -4366,58 +4327,58 @@ function createDocsDeploymentClient(options) {
|
|
|
4366
4327
|
}),
|
|
4367
4328
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
4368
4329
|
});
|
|
4369
|
-
return (0,
|
|
4330
|
+
return (0, import_client14.createORPCClient)(link);
|
|
4370
4331
|
}
|
|
4371
4332
|
|
|
4372
4333
|
// src/orpc-client/docs-ledger/client.ts
|
|
4373
|
-
var
|
|
4374
|
-
var
|
|
4334
|
+
var import_client15 = require("@orpc/client");
|
|
4335
|
+
var import_fetch10 = require("@orpc/openapi-client/fetch");
|
|
4375
4336
|
|
|
4376
4337
|
// src/orpc-client/docs-ledger/contract.ts
|
|
4377
|
-
var
|
|
4378
|
-
var
|
|
4379
|
-
var MissingContentSchema =
|
|
4380
|
-
hash:
|
|
4381
|
-
uploadUrl:
|
|
4338
|
+
var import_contract19 = require("@orpc/contract");
|
|
4339
|
+
var z21 = __toESM(require("zod"), 1);
|
|
4340
|
+
var MissingContentSchema = z21.object({
|
|
4341
|
+
hash: z21.string(),
|
|
4342
|
+
uploadUrl: z21.string()
|
|
4382
4343
|
});
|
|
4383
|
-
var RegisterResponseSchema =
|
|
4384
|
-
deploymentHash:
|
|
4385
|
-
missingContent:
|
|
4344
|
+
var RegisterResponseSchema = z21.object({
|
|
4345
|
+
deploymentHash: z21.string(),
|
|
4346
|
+
missingContent: z21.array(MissingContentSchema)
|
|
4386
4347
|
});
|
|
4387
|
-
var FinishResponseSchema =
|
|
4388
|
-
deploymentId:
|
|
4348
|
+
var FinishResponseSchema = z21.object({
|
|
4349
|
+
deploymentId: z21.string(),
|
|
4389
4350
|
/** ID of the canonical (fern URL) site row. */
|
|
4390
|
-
siteId:
|
|
4351
|
+
siteId: z21.string(),
|
|
4391
4352
|
/**
|
|
4392
4353
|
* IDs of any additional site rows created for `customDomains` URLs
|
|
4393
4354
|
* (ADR 0010). Empty when the publish has no `customDomains`. One ID
|
|
4394
4355
|
* per parsed customDomain, in the same order as the input.
|
|
4395
4356
|
*/
|
|
4396
|
-
additionalSiteIds:
|
|
4397
|
-
deploymentHash:
|
|
4398
|
-
reusedDeployment:
|
|
4357
|
+
additionalSiteIds: z21.array(z21.string()).default([]),
|
|
4358
|
+
deploymentHash: z21.string(),
|
|
4359
|
+
reusedDeployment: z21.boolean(),
|
|
4399
4360
|
/**
|
|
4400
4361
|
* Per-locale segment counts when `translations[]` was supplied on the
|
|
4401
4362
|
* finish input. Absent when no translations were included.
|
|
4402
4363
|
*/
|
|
4403
|
-
translationsProcessed:
|
|
4364
|
+
translationsProcessed: z21.array(z21.object({ locale: z21.string(), segmentsAdded: z21.number() })).optional()
|
|
4404
4365
|
});
|
|
4405
|
-
var ArchiveSiteInputSchema =
|
|
4406
|
-
siteId:
|
|
4366
|
+
var ArchiveSiteInputSchema = z21.object({
|
|
4367
|
+
siteId: z21.string()
|
|
4407
4368
|
});
|
|
4408
|
-
var ArchiveSiteResponseSchema =
|
|
4409
|
-
status:
|
|
4369
|
+
var ArchiveSiteResponseSchema = z21.object({
|
|
4370
|
+
status: z21.enum(["archived", "already_archived", "not_found"])
|
|
4410
4371
|
});
|
|
4411
|
-
var BlobRefSchema =
|
|
4412
|
-
hash:
|
|
4413
|
-
contentType:
|
|
4414
|
-
contentLength:
|
|
4372
|
+
var BlobRefSchema = z21.object({
|
|
4373
|
+
hash: z21.string(),
|
|
4374
|
+
contentType: z21.string(),
|
|
4375
|
+
contentLength: z21.number()
|
|
4415
4376
|
});
|
|
4416
|
-
var PageBlobRefSchema =
|
|
4377
|
+
var PageBlobRefSchema = z21.object({
|
|
4417
4378
|
/** SHA-256 hex of the page content bytes. */
|
|
4418
|
-
hash:
|
|
4419
|
-
contentType:
|
|
4420
|
-
contentLength:
|
|
4379
|
+
hash: z21.string(),
|
|
4380
|
+
contentType: z21.string().default("text/markdown"),
|
|
4381
|
+
contentLength: z21.number(),
|
|
4421
4382
|
/**
|
|
4422
4383
|
* Bare `fullPath`s of the file/image artifacts this page's rendered
|
|
4423
4384
|
* markdown references (the `<fullPath>` of each `file:<fullPath>` token).
|
|
@@ -4427,35 +4388,35 @@ var PageBlobRefSchema = z22.object({
|
|
|
4427
4388
|
* (ADR 0016, "File metadata on the render path"). Optional — older CLIs
|
|
4428
4389
|
* omit it and the page simply contributes no shard-side file identities.
|
|
4429
4390
|
*/
|
|
4430
|
-
referencedFiles:
|
|
4391
|
+
referencedFiles: z21.array(z21.string()).optional()
|
|
4431
4392
|
});
|
|
4432
|
-
var FileManifestEntrySchema =
|
|
4393
|
+
var FileManifestEntrySchema = z21.object({
|
|
4433
4394
|
/** SHA-256 hex of the file bytes (= CAS content hash). */
|
|
4434
|
-
hash:
|
|
4435
|
-
contentType:
|
|
4436
|
-
contentLength:
|
|
4395
|
+
hash: z21.string(),
|
|
4396
|
+
contentType: z21.string(),
|
|
4397
|
+
contentLength: z21.number(),
|
|
4437
4398
|
/** Original filename (e.g. "logo.png"). Used for Content-Disposition and URL cosmetics. */
|
|
4438
|
-
filename:
|
|
4399
|
+
filename: z21.string(),
|
|
4439
4400
|
/** Image width in pixels (images only). */
|
|
4440
|
-
width:
|
|
4401
|
+
width: z21.number().optional(),
|
|
4441
4402
|
/** Image height in pixels (images only). */
|
|
4442
|
-
height:
|
|
4403
|
+
height: z21.number().optional(),
|
|
4443
4404
|
/** Base64-encoded blur placeholder (images only). */
|
|
4444
|
-
blurDataURL:
|
|
4405
|
+
blurDataURL: z21.string().optional()
|
|
4445
4406
|
});
|
|
4446
|
-
var ImageRefSchema =
|
|
4447
|
-
path:
|
|
4448
|
-
width:
|
|
4449
|
-
height:
|
|
4407
|
+
var ImageRefSchema = z21.object({
|
|
4408
|
+
path: z21.string(),
|
|
4409
|
+
width: z21.number(),
|
|
4410
|
+
height: z21.number()
|
|
4450
4411
|
});
|
|
4451
|
-
var PathOrUrlSchema =
|
|
4452
|
-
|
|
4453
|
-
|
|
4412
|
+
var PathOrUrlSchema = z21.discriminatedUnion("type", [
|
|
4413
|
+
z21.object({ type: z21.literal("path"), value: z21.string() }),
|
|
4414
|
+
z21.object({ type: z21.literal("url"), value: z21.string() })
|
|
4454
4415
|
]);
|
|
4455
|
-
var RgbaSchema =
|
|
4456
|
-
var BackgroundColorSchema =
|
|
4457
|
-
|
|
4458
|
-
|
|
4416
|
+
var RgbaSchema = z21.object({ r: z21.number(), g: z21.number(), b: z21.number(), a: z21.number().optional() });
|
|
4417
|
+
var BackgroundColorSchema = z21.discriminatedUnion("type", [
|
|
4418
|
+
z21.object({ type: z21.literal("solid"), ...RgbaSchema.shape }),
|
|
4419
|
+
z21.object({ type: z21.literal("gradient") })
|
|
4459
4420
|
]);
|
|
4460
4421
|
var ACCENT_SCALE_KEYS = [
|
|
4461
4422
|
"accent1",
|
|
@@ -4472,9 +4433,9 @@ var ACCENT_SCALE_KEYS = [
|
|
|
4472
4433
|
"accent12"
|
|
4473
4434
|
];
|
|
4474
4435
|
var accentScaleShape = Object.fromEntries(ACCENT_SCALE_KEYS.map((key) => [key, RgbaSchema.optional()]));
|
|
4475
|
-
var LedgerThemeConfigSchema =
|
|
4436
|
+
var LedgerThemeConfigSchema = z21.object({
|
|
4476
4437
|
logo: ImageRefSchema.optional(),
|
|
4477
|
-
backgroundImage:
|
|
4438
|
+
backgroundImage: z21.string().optional(),
|
|
4478
4439
|
accentPrimary: RgbaSchema,
|
|
4479
4440
|
background: BackgroundColorSchema.optional(),
|
|
4480
4441
|
border: RgbaSchema.optional(),
|
|
@@ -4483,51 +4444,51 @@ var LedgerThemeConfigSchema = z22.object({
|
|
|
4483
4444
|
cardBackground: RgbaSchema.optional(),
|
|
4484
4445
|
...accentScaleShape
|
|
4485
4446
|
});
|
|
4486
|
-
var LedgerColorsConfigSchema =
|
|
4487
|
-
|
|
4488
|
-
|
|
4489
|
-
|
|
4490
|
-
type:
|
|
4447
|
+
var LedgerColorsConfigSchema = z21.discriminatedUnion("type", [
|
|
4448
|
+
z21.object({ type: z21.literal("dark"), ...LedgerThemeConfigSchema.shape }),
|
|
4449
|
+
z21.object({ type: z21.literal("light"), ...LedgerThemeConfigSchema.shape }),
|
|
4450
|
+
z21.object({
|
|
4451
|
+
type: z21.literal("darkAndLight"),
|
|
4491
4452
|
dark: LedgerThemeConfigSchema,
|
|
4492
4453
|
light: LedgerThemeConfigSchema
|
|
4493
4454
|
})
|
|
4494
4455
|
]);
|
|
4495
|
-
var LedgerFontVariantSchema =
|
|
4496
|
-
fontFile:
|
|
4497
|
-
weight:
|
|
4498
|
-
style:
|
|
4499
|
-
});
|
|
4500
|
-
var LedgerFontConfigSchema =
|
|
4501
|
-
|
|
4502
|
-
type:
|
|
4503
|
-
name:
|
|
4504
|
-
variants:
|
|
4505
|
-
display:
|
|
4506
|
-
fallback:
|
|
4507
|
-
fontVariationSettings:
|
|
4456
|
+
var LedgerFontVariantSchema = z21.object({
|
|
4457
|
+
fontFile: z21.string(),
|
|
4458
|
+
weight: z21.array(z21.string()).optional(),
|
|
4459
|
+
style: z21.array(z21.enum(["normal", "italic"])).optional()
|
|
4460
|
+
});
|
|
4461
|
+
var LedgerFontConfigSchema = z21.discriminatedUnion("type", [
|
|
4462
|
+
z21.object({
|
|
4463
|
+
type: z21.literal("custom"),
|
|
4464
|
+
name: z21.string(),
|
|
4465
|
+
variants: z21.array(LedgerFontVariantSchema),
|
|
4466
|
+
display: z21.enum(["auto", "block", "swap", "fallback", "optional"]).optional(),
|
|
4467
|
+
fallback: z21.array(z21.string()).optional(),
|
|
4468
|
+
fontVariationSettings: z21.string().optional()
|
|
4508
4469
|
})
|
|
4509
4470
|
]);
|
|
4510
|
-
var LedgerTypographySchema =
|
|
4471
|
+
var LedgerTypographySchema = z21.object({
|
|
4511
4472
|
headingsFont: LedgerFontConfigSchema.optional(),
|
|
4512
4473
|
bodyFont: LedgerFontConfigSchema.optional(),
|
|
4513
4474
|
codeFont: LedgerFontConfigSchema.optional()
|
|
4514
4475
|
});
|
|
4515
|
-
var LedgerJsFileSchema =
|
|
4516
|
-
path:
|
|
4517
|
-
strategy:
|
|
4476
|
+
var LedgerJsFileSchema = z21.object({
|
|
4477
|
+
path: z21.string(),
|
|
4478
|
+
strategy: z21.enum(["beforeInteractive", "afterInteractive", "lazyOnload"]).optional()
|
|
4518
4479
|
});
|
|
4519
|
-
var LedgerJsConfigSchema =
|
|
4520
|
-
remote:
|
|
4521
|
-
|
|
4522
|
-
url:
|
|
4523
|
-
strategy:
|
|
4480
|
+
var LedgerJsConfigSchema = z21.object({
|
|
4481
|
+
remote: z21.array(
|
|
4482
|
+
z21.object({
|
|
4483
|
+
url: z21.string(),
|
|
4484
|
+
strategy: z21.enum(["beforeInteractive", "afterInteractive", "lazyOnload"]).optional()
|
|
4524
4485
|
})
|
|
4525
4486
|
).optional(),
|
|
4526
|
-
files:
|
|
4527
|
-
inline:
|
|
4487
|
+
files: z21.array(LedgerJsFileSchema).optional(),
|
|
4488
|
+
inline: z21.array(z21.string()).optional()
|
|
4528
4489
|
});
|
|
4529
|
-
var LedgerMetadataConfigSchema =
|
|
4530
|
-
|
|
4490
|
+
var LedgerMetadataConfigSchema = z21.record(z21.string(), z21.unknown()).and(
|
|
4491
|
+
z21.object({
|
|
4531
4492
|
"og:image": PathOrUrlSchema.optional(),
|
|
4532
4493
|
"og:logo": PathOrUrlSchema.optional(),
|
|
4533
4494
|
"twitter:image": PathOrUrlSchema.optional(),
|
|
@@ -4535,83 +4496,83 @@ var LedgerMetadataConfigSchema = z22.record(z22.string(), z22.unknown()).and(
|
|
|
4535
4496
|
"og:dynamic:background-image": PathOrUrlSchema.optional()
|
|
4536
4497
|
})
|
|
4537
4498
|
);
|
|
4538
|
-
var NavbarLinksFieldSchema =
|
|
4539
|
-
var FooterLinksFieldSchema =
|
|
4499
|
+
var NavbarLinksFieldSchema = z21.array(NavbarLinkSchema);
|
|
4500
|
+
var FooterLinksFieldSchema = z21.array(FooterLinkSchema);
|
|
4540
4501
|
var LayoutFieldSchema = DocsLayoutConfigSchema;
|
|
4541
4502
|
var ThemeFieldSchema = DocsThemeConfigSchema;
|
|
4542
4503
|
var SettingsFieldSchema = DocsSettingsConfigSchema;
|
|
4543
4504
|
var AnalyticsFieldSchema = AnalyticsConfigSchema;
|
|
4544
4505
|
var AIChatFieldSchema = AIChatConfigSchema;
|
|
4545
4506
|
var PageActionsFieldSchema = PageActionsConfigSchema;
|
|
4546
|
-
var LedgerAgentsConfigSchema =
|
|
4547
|
-
pageDirective:
|
|
4548
|
-
pageDescriptionSource:
|
|
4549
|
-
siteDescription:
|
|
4550
|
-
});
|
|
4551
|
-
var LedgerConfigSchema =
|
|
4552
|
-
title:
|
|
4553
|
-
rootSlug:
|
|
4554
|
-
defaultLanguage:
|
|
4555
|
-
translations:
|
|
4556
|
-
defaultLocale:
|
|
4557
|
-
translations:
|
|
4507
|
+
var LedgerAgentsConfigSchema = z21.object({
|
|
4508
|
+
pageDirective: z21.string().optional(),
|
|
4509
|
+
pageDescriptionSource: z21.enum(["description", "subtitle"]).optional(),
|
|
4510
|
+
siteDescription: z21.string().optional()
|
|
4511
|
+
});
|
|
4512
|
+
var LedgerConfigSchema = z21.object({
|
|
4513
|
+
title: z21.string().optional(),
|
|
4514
|
+
rootSlug: z21.string().optional(),
|
|
4515
|
+
defaultLanguage: z21.string().optional(),
|
|
4516
|
+
translations: z21.object({
|
|
4517
|
+
defaultLocale: z21.string(),
|
|
4518
|
+
translations: z21.array(z21.string()).optional()
|
|
4558
4519
|
}).optional(),
|
|
4559
|
-
announcement:
|
|
4520
|
+
announcement: z21.object({ text: z21.string() }).optional(),
|
|
4560
4521
|
navbarLinks: NavbarLinksFieldSchema.optional(),
|
|
4561
4522
|
footerLinks: FooterLinksFieldSchema.optional(),
|
|
4562
|
-
logoHeight:
|
|
4563
|
-
logoHref:
|
|
4564
|
-
logoRightText:
|
|
4523
|
+
logoHeight: z21.number().optional(),
|
|
4524
|
+
logoHref: z21.string().optional(),
|
|
4525
|
+
logoRightText: z21.string().optional(),
|
|
4565
4526
|
/** fullPath of the favicon file artifact (any extension: .svg/.png/.ico). */
|
|
4566
|
-
favicon:
|
|
4527
|
+
favicon: z21.string().nullish(),
|
|
4567
4528
|
agents: LedgerAgentsConfigSchema.optional(),
|
|
4568
4529
|
metadata: LedgerMetadataConfigSchema.optional(),
|
|
4569
|
-
redirects:
|
|
4530
|
+
redirects: z21.array(z21.object({ source: z21.string(), destination: z21.string(), permanent: z21.boolean().optional() })).optional(),
|
|
4570
4531
|
colorsV3: LedgerColorsConfigSchema.optional(),
|
|
4571
4532
|
layout: LayoutFieldSchema.optional(),
|
|
4572
4533
|
theme: ThemeFieldSchema.optional(),
|
|
4573
4534
|
settings: SettingsFieldSchema.optional(),
|
|
4574
4535
|
typographyV2: LedgerTypographySchema.optional(),
|
|
4575
4536
|
analyticsConfig: AnalyticsFieldSchema.optional(),
|
|
4576
|
-
integrations:
|
|
4577
|
-
intercom:
|
|
4537
|
+
integrations: z21.object({
|
|
4538
|
+
intercom: z21.string().optional()
|
|
4578
4539
|
}).optional(),
|
|
4579
|
-
css:
|
|
4540
|
+
css: z21.object({ inline: z21.array(z21.string()).optional() }).optional(),
|
|
4580
4541
|
js: LedgerJsConfigSchema.optional(),
|
|
4581
4542
|
aiChatConfig: AIChatFieldSchema.optional(),
|
|
4582
4543
|
pageActions: PageActionsFieldSchema.optional(),
|
|
4583
|
-
editThisPageLaunch:
|
|
4544
|
+
editThisPageLaunch: z21.enum(["github", "dashboard"]).optional(),
|
|
4584
4545
|
/**
|
|
4585
4546
|
* Explicit edit-this-page GitHub config from docs.yml (ADR 0012 parity).
|
|
4586
4547
|
* When present, the loader synthesises `editThisPageUrl` from these fields
|
|
4587
4548
|
* instead of relying on deployment-scoped git provenance. This matches the
|
|
4588
4549
|
* v2 behaviour where the CLI derives the URL from the declared config.
|
|
4589
4550
|
*/
|
|
4590
|
-
editThisPageGithub:
|
|
4591
|
-
owner:
|
|
4592
|
-
repo:
|
|
4593
|
-
branch:
|
|
4594
|
-
host:
|
|
4551
|
+
editThisPageGithub: z21.object({
|
|
4552
|
+
owner: z21.string(),
|
|
4553
|
+
repo: z21.string(),
|
|
4554
|
+
branch: z21.string().default("main"),
|
|
4555
|
+
host: z21.string().default("https://github.com")
|
|
4595
4556
|
}).optional(),
|
|
4596
|
-
header:
|
|
4597
|
-
footer:
|
|
4598
|
-
});
|
|
4599
|
-
var MetadataStringArraySchema =
|
|
4600
|
-
var FeatureFlagMetadataSchema =
|
|
4601
|
-
|
|
4602
|
-
|
|
4603
|
-
|
|
4604
|
-
flag:
|
|
4605
|
-
fallbackValue:
|
|
4606
|
-
match:
|
|
4557
|
+
header: z21.string().optional(),
|
|
4558
|
+
footer: z21.string().optional()
|
|
4559
|
+
});
|
|
4560
|
+
var MetadataStringArraySchema = z21.array(z21.string());
|
|
4561
|
+
var FeatureFlagMetadataSchema = z21.array(
|
|
4562
|
+
z21.union([
|
|
4563
|
+
z21.string(),
|
|
4564
|
+
z21.object({
|
|
4565
|
+
flag: z21.string(),
|
|
4566
|
+
fallbackValue: z21.unknown().optional(),
|
|
4567
|
+
match: z21.unknown().optional()
|
|
4607
4568
|
})
|
|
4608
4569
|
])
|
|
4609
4570
|
);
|
|
4610
|
-
var LinkTargetSchema2 =
|
|
4611
|
-
var CollapsedSchema =
|
|
4612
|
-
var LedgerAvailabilitySchema =
|
|
4571
|
+
var LinkTargetSchema2 = z21.enum(["_blank", "_self", "_parent", "_top"]);
|
|
4572
|
+
var CollapsedSchema = z21.union([z21.boolean(), z21.literal("open-by-default")]);
|
|
4573
|
+
var LedgerAvailabilitySchema = z21.union([
|
|
4613
4574
|
AvailabilitySchema,
|
|
4614
|
-
|
|
4575
|
+
z21.enum([
|
|
4615
4576
|
"alpha",
|
|
4616
4577
|
"stable",
|
|
4617
4578
|
"generally-available",
|
|
@@ -4623,7 +4584,7 @@ var LedgerAvailabilitySchema = z22.union([
|
|
|
4623
4584
|
"legacy"
|
|
4624
4585
|
])
|
|
4625
4586
|
]);
|
|
4626
|
-
var LedgerArtifactTypeSchema =
|
|
4587
|
+
var LedgerArtifactTypeSchema = z21.enum([
|
|
4627
4588
|
"markdown",
|
|
4628
4589
|
"page",
|
|
4629
4590
|
"rest",
|
|
@@ -4637,170 +4598,170 @@ var LedgerArtifactTypeSchema = z22.enum([
|
|
|
4637
4598
|
"image",
|
|
4638
4599
|
"redirect"
|
|
4639
4600
|
]);
|
|
4640
|
-
var LedgerMetadataBaseSchema =
|
|
4601
|
+
var LedgerMetadataBaseSchema = z21.object({}).passthrough();
|
|
4641
4602
|
var NodeMetadataFields = {
|
|
4642
|
-
title:
|
|
4643
|
-
slug:
|
|
4644
|
-
icon:
|
|
4645
|
-
authed:
|
|
4603
|
+
title: z21.string().optional(),
|
|
4604
|
+
slug: z21.string().optional(),
|
|
4605
|
+
icon: z21.string().optional(),
|
|
4606
|
+
authed: z21.boolean().optional(),
|
|
4646
4607
|
viewers: MetadataStringArraySchema.optional(),
|
|
4647
|
-
orphaned:
|
|
4608
|
+
orphaned: z21.boolean().optional(),
|
|
4648
4609
|
featureFlags: FeatureFlagMetadataSchema.optional()
|
|
4649
4610
|
};
|
|
4650
4611
|
var ApiNodeMetadataFields = {
|
|
4651
4612
|
...NodeMetadataFields,
|
|
4652
|
-
apiDefinitionId:
|
|
4613
|
+
apiDefinitionId: z21.string(),
|
|
4653
4614
|
availability: LedgerAvailabilitySchema.optional()
|
|
4654
4615
|
};
|
|
4655
4616
|
var LedgerSegmentDetailMetadataObjectSchema = LedgerMetadataBaseSchema.extend({
|
|
4656
|
-
slug:
|
|
4657
|
-
default:
|
|
4658
|
-
subtitle:
|
|
4659
|
-
href:
|
|
4660
|
-
url:
|
|
4617
|
+
slug: z21.string().optional(),
|
|
4618
|
+
default: z21.boolean().optional(),
|
|
4619
|
+
subtitle: z21.string().optional(),
|
|
4620
|
+
href: z21.string().optional(),
|
|
4621
|
+
url: z21.string().optional(),
|
|
4661
4622
|
target: LinkTargetSchema2.optional(),
|
|
4662
|
-
image:
|
|
4663
|
-
pointsTo:
|
|
4623
|
+
image: z21.string().optional(),
|
|
4624
|
+
pointsTo: z21.string().optional(),
|
|
4664
4625
|
availability: LedgerAvailabilitySchema.optional(),
|
|
4665
|
-
tab_type:
|
|
4626
|
+
tab_type: z21.enum(["tab", "link", "changelog"]).optional()
|
|
4666
4627
|
});
|
|
4667
4628
|
var LedgerSegmentDetailMetadataSchema = LedgerSegmentDetailMetadataObjectSchema.nullable();
|
|
4668
|
-
var LedgerSegmentMetadataObjectSchema =
|
|
4629
|
+
var LedgerSegmentMetadataObjectSchema = z21.discriminatedUnion("type", [
|
|
4669
4630
|
LedgerMetadataBaseSchema.extend({
|
|
4670
|
-
type:
|
|
4631
|
+
type: z21.literal("tabRoot")
|
|
4671
4632
|
}),
|
|
4672
4633
|
LedgerMetadataBaseSchema.extend({
|
|
4673
|
-
type:
|
|
4674
|
-
title:
|
|
4675
|
-
icon:
|
|
4676
|
-
authed:
|
|
4634
|
+
type: z21.literal("section"),
|
|
4635
|
+
title: z21.string().optional(),
|
|
4636
|
+
icon: z21.string().optional(),
|
|
4637
|
+
authed: z21.boolean().optional(),
|
|
4677
4638
|
collapsed: CollapsedSchema.optional(),
|
|
4678
|
-
collapsible:
|
|
4679
|
-
collapsedByDefault:
|
|
4639
|
+
collapsible: z21.boolean().optional(),
|
|
4640
|
+
collapsedByDefault: z21.boolean().optional(),
|
|
4680
4641
|
availability: LedgerAvailabilitySchema.optional(),
|
|
4681
|
-
overviewPageId:
|
|
4682
|
-
noindex:
|
|
4683
|
-
pointsTo:
|
|
4642
|
+
overviewPageId: z21.string().optional(),
|
|
4643
|
+
noindex: z21.boolean().optional(),
|
|
4644
|
+
pointsTo: z21.string().optional(),
|
|
4684
4645
|
viewers: MetadataStringArraySchema.optional(),
|
|
4685
|
-
orphaned:
|
|
4646
|
+
orphaned: z21.boolean().optional(),
|
|
4686
4647
|
featureFlags: FeatureFlagMetadataSchema.optional()
|
|
4687
4648
|
}),
|
|
4688
4649
|
LedgerMetadataBaseSchema.extend({
|
|
4689
|
-
type:
|
|
4690
|
-
title:
|
|
4691
|
-
icon:
|
|
4692
|
-
authed:
|
|
4693
|
-
apiDefinitionId:
|
|
4694
|
-
overviewPageId:
|
|
4695
|
-
noindex:
|
|
4650
|
+
type: z21.literal("apiReference"),
|
|
4651
|
+
title: z21.string().optional(),
|
|
4652
|
+
icon: z21.string().optional(),
|
|
4653
|
+
authed: z21.boolean().optional(),
|
|
4654
|
+
apiDefinitionId: z21.string().optional(),
|
|
4655
|
+
overviewPageId: z21.string().optional(),
|
|
4656
|
+
noindex: z21.boolean().optional(),
|
|
4696
4657
|
availability: LedgerAvailabilitySchema.optional(),
|
|
4697
|
-
pointsTo:
|
|
4698
|
-
paginated:
|
|
4699
|
-
showErrors:
|
|
4700
|
-
hideTitle:
|
|
4658
|
+
pointsTo: z21.string().optional(),
|
|
4659
|
+
paginated: z21.boolean().optional(),
|
|
4660
|
+
showErrors: z21.boolean().optional(),
|
|
4661
|
+
hideTitle: z21.boolean().optional(),
|
|
4701
4662
|
viewers: MetadataStringArraySchema.optional(),
|
|
4702
|
-
orphaned:
|
|
4663
|
+
orphaned: z21.boolean().optional(),
|
|
4703
4664
|
featureFlags: FeatureFlagMetadataSchema.optional()
|
|
4704
4665
|
}),
|
|
4705
4666
|
LedgerMetadataBaseSchema.extend({
|
|
4706
|
-
type:
|
|
4707
|
-
title:
|
|
4708
|
-
icon:
|
|
4709
|
-
authed:
|
|
4710
|
-
apiDefinitionId:
|
|
4711
|
-
overviewPageId:
|
|
4712
|
-
noindex:
|
|
4667
|
+
type: z21.literal("apiPackage"),
|
|
4668
|
+
title: z21.string().optional(),
|
|
4669
|
+
icon: z21.string().optional(),
|
|
4670
|
+
authed: z21.boolean().optional(),
|
|
4671
|
+
apiDefinitionId: z21.string().optional(),
|
|
4672
|
+
overviewPageId: z21.string().optional(),
|
|
4673
|
+
noindex: z21.boolean().optional(),
|
|
4713
4674
|
availability: LedgerAvailabilitySchema.optional(),
|
|
4714
|
-
pointsTo:
|
|
4675
|
+
pointsTo: z21.string().optional(),
|
|
4715
4676
|
viewers: MetadataStringArraySchema.optional(),
|
|
4716
|
-
orphaned:
|
|
4677
|
+
orphaned: z21.boolean().optional(),
|
|
4717
4678
|
featureFlags: FeatureFlagMetadataSchema.optional()
|
|
4718
4679
|
}),
|
|
4719
4680
|
LedgerMetadataBaseSchema.extend({
|
|
4720
|
-
type:
|
|
4721
|
-
title:
|
|
4722
|
-
icon:
|
|
4723
|
-
overviewPageId:
|
|
4724
|
-
apiDefinitionId:
|
|
4725
|
-
noindex:
|
|
4726
|
-
authed:
|
|
4681
|
+
type: z21.literal("changelog"),
|
|
4682
|
+
title: z21.string().optional(),
|
|
4683
|
+
icon: z21.string().optional(),
|
|
4684
|
+
overviewPageId: z21.string().optional(),
|
|
4685
|
+
apiDefinitionId: z21.string().optional(),
|
|
4686
|
+
noindex: z21.boolean().optional(),
|
|
4687
|
+
authed: z21.boolean().optional(),
|
|
4727
4688
|
viewers: MetadataStringArraySchema.optional(),
|
|
4728
|
-
orphaned:
|
|
4689
|
+
orphaned: z21.boolean().optional(),
|
|
4729
4690
|
featureFlags: FeatureFlagMetadataSchema.optional()
|
|
4730
4691
|
}),
|
|
4731
4692
|
LedgerMetadataBaseSchema.extend({
|
|
4732
|
-
type:
|
|
4693
|
+
type: z21.literal("files")
|
|
4733
4694
|
}),
|
|
4734
4695
|
LedgerMetadataBaseSchema.extend({
|
|
4735
|
-
type:
|
|
4696
|
+
type: z21.literal("redirects")
|
|
4736
4697
|
}),
|
|
4737
4698
|
LedgerMetadataBaseSchema.extend({
|
|
4738
|
-
type:
|
|
4699
|
+
type: z21.literal("productLink")
|
|
4739
4700
|
}),
|
|
4740
4701
|
LedgerMetadataBaseSchema.extend({
|
|
4741
|
-
type:
|
|
4702
|
+
type: z21.literal("tabLink")
|
|
4742
4703
|
})
|
|
4743
4704
|
]);
|
|
4744
4705
|
var LedgerSegmentMetadataSchema = LedgerSegmentMetadataObjectSchema;
|
|
4745
4706
|
var LedgerMarkdownMetadataSchema = LedgerMetadataBaseSchema.extend({
|
|
4746
4707
|
...NodeMetadataFields,
|
|
4747
|
-
pageId:
|
|
4748
|
-
isOverview:
|
|
4749
|
-
noindex:
|
|
4708
|
+
pageId: z21.string().optional(),
|
|
4709
|
+
isOverview: z21.boolean().optional(),
|
|
4710
|
+
noindex: z21.boolean().optional()
|
|
4750
4711
|
});
|
|
4751
4712
|
var LedgerRestMetadataSchema = LedgerMetadataBaseSchema.extend({
|
|
4752
4713
|
...ApiNodeMetadataFields,
|
|
4753
|
-
endpointId:
|
|
4714
|
+
endpointId: z21.string(),
|
|
4754
4715
|
method: HttpMethodSchema,
|
|
4755
|
-
isResponseStream:
|
|
4756
|
-
endpointPairKey:
|
|
4716
|
+
isResponseStream: z21.boolean().optional(),
|
|
4717
|
+
endpointPairKey: z21.string().optional()
|
|
4757
4718
|
});
|
|
4758
4719
|
var LedgerWebSocketMetadataSchema = LedgerMetadataBaseSchema.extend({
|
|
4759
4720
|
...ApiNodeMetadataFields,
|
|
4760
|
-
webSocketId:
|
|
4721
|
+
webSocketId: z21.string()
|
|
4761
4722
|
});
|
|
4762
4723
|
var LedgerWebhookMetadataSchema = LedgerMetadataBaseSchema.extend({
|
|
4763
4724
|
...ApiNodeMetadataFields,
|
|
4764
|
-
webhookId:
|
|
4725
|
+
webhookId: z21.string(),
|
|
4765
4726
|
// V1.WebhookNode carries the full HttpMethod union, so the read model must accept it too.
|
|
4766
4727
|
method: HttpMethodSchema
|
|
4767
4728
|
});
|
|
4768
4729
|
var LedgerGrpcMetadataSchema = LedgerMetadataBaseSchema.extend({
|
|
4769
4730
|
...ApiNodeMetadataFields,
|
|
4770
|
-
grpcId:
|
|
4731
|
+
grpcId: z21.string(),
|
|
4771
4732
|
method: GrpcMethodSchema
|
|
4772
4733
|
});
|
|
4773
4734
|
var LedgerGraphQlMetadataSchema = LedgerMetadataBaseSchema.extend({
|
|
4774
4735
|
...ApiNodeMetadataFields,
|
|
4775
|
-
graphqlOperationId:
|
|
4736
|
+
graphqlOperationId: z21.string(),
|
|
4776
4737
|
operationType: GraphQlOperationTypeSchema
|
|
4777
4738
|
});
|
|
4778
4739
|
var LedgerChangelogEntryMetadataSchema = LedgerMetadataBaseSchema.extend({
|
|
4779
4740
|
...NodeMetadataFields,
|
|
4780
|
-
pageId:
|
|
4781
|
-
noindex:
|
|
4782
|
-
date:
|
|
4741
|
+
pageId: z21.string(),
|
|
4742
|
+
noindex: z21.boolean().optional(),
|
|
4743
|
+
date: z21.string().optional(),
|
|
4783
4744
|
tags: MetadataStringArraySchema.optional()
|
|
4784
4745
|
});
|
|
4785
4746
|
var LedgerLinkMetadataSchema = LedgerMetadataBaseSchema.extend({
|
|
4786
|
-
title:
|
|
4787
|
-
slug:
|
|
4788
|
-
icon:
|
|
4789
|
-
url:
|
|
4747
|
+
title: z21.string().optional(),
|
|
4748
|
+
slug: z21.string().optional(),
|
|
4749
|
+
icon: z21.string().optional(),
|
|
4750
|
+
url: z21.string(),
|
|
4790
4751
|
target: LinkTargetSchema2.optional()
|
|
4791
4752
|
});
|
|
4792
4753
|
var LedgerFileArtifactMetadataSchema = LedgerMetadataBaseSchema.extend({
|
|
4793
|
-
contentType:
|
|
4794
|
-
contentLength:
|
|
4795
|
-
filename:
|
|
4796
|
-
width:
|
|
4797
|
-
height:
|
|
4798
|
-
blurDataURL:
|
|
4754
|
+
contentType: z21.string(),
|
|
4755
|
+
contentLength: z21.number().optional(),
|
|
4756
|
+
filename: z21.string(),
|
|
4757
|
+
width: z21.number().optional(),
|
|
4758
|
+
height: z21.number().optional(),
|
|
4759
|
+
blurDataURL: z21.string().optional()
|
|
4799
4760
|
});
|
|
4800
4761
|
var LedgerRedirectMetadataSchema = LedgerMetadataBaseSchema.extend({
|
|
4801
|
-
href:
|
|
4762
|
+
href: z21.string().optional()
|
|
4802
4763
|
});
|
|
4803
|
-
var LedgerArtifactMetadataSchema =
|
|
4764
|
+
var LedgerArtifactMetadataSchema = z21.union([
|
|
4804
4765
|
LedgerMarkdownMetadataSchema,
|
|
4805
4766
|
LedgerRestMetadataSchema,
|
|
4806
4767
|
LedgerWebSocketMetadataSchema,
|
|
@@ -4828,23 +4789,23 @@ var LEDGER_ARTIFACT_METADATA_SCHEMAS = {
|
|
|
4828
4789
|
};
|
|
4829
4790
|
function artifactTypeVariant(base, type) {
|
|
4830
4791
|
return base.extend({
|
|
4831
|
-
artifactType:
|
|
4792
|
+
artifactType: z21.literal(type),
|
|
4832
4793
|
artifactMetadata: LEDGER_ARTIFACT_METADATA_SCHEMAS[type]
|
|
4833
4794
|
});
|
|
4834
4795
|
}
|
|
4835
|
-
var NavRouteBaseSchema =
|
|
4836
|
-
fullPath:
|
|
4837
|
-
artifactId:
|
|
4838
|
-
hidden:
|
|
4839
|
-
displaySortOrder:
|
|
4796
|
+
var NavRouteBaseSchema = z21.object({
|
|
4797
|
+
fullPath: z21.string().nullable(),
|
|
4798
|
+
artifactId: z21.string(),
|
|
4799
|
+
hidden: z21.boolean(),
|
|
4800
|
+
displaySortOrder: z21.number().nullable().optional()
|
|
4840
4801
|
});
|
|
4841
4802
|
function navRouteVariant(type) {
|
|
4842
4803
|
return NavRouteBaseSchema.extend({
|
|
4843
|
-
type:
|
|
4804
|
+
type: z21.literal(type),
|
|
4844
4805
|
metadata: LEDGER_ARTIFACT_METADATA_SCHEMAS[type]
|
|
4845
4806
|
});
|
|
4846
4807
|
}
|
|
4847
|
-
var LedgerNavRouteSchema =
|
|
4808
|
+
var LedgerNavRouteSchema = z21.discriminatedUnion("type", [
|
|
4848
4809
|
navRouteVariant("markdown"),
|
|
4849
4810
|
navRouteVariant("page"),
|
|
4850
4811
|
navRouteVariant("rest"),
|
|
@@ -4858,35 +4819,35 @@ var LedgerNavRouteSchema = z22.discriminatedUnion("type", [
|
|
|
4858
4819
|
navRouteVariant("image"),
|
|
4859
4820
|
navRouteVariant("redirect")
|
|
4860
4821
|
]);
|
|
4861
|
-
var DocsPublishGitInputSchema =
|
|
4822
|
+
var DocsPublishGitInputSchema = z21.object({
|
|
4862
4823
|
/** Full HTTPS URL of the repo (e.g. `https://github.com/acme/docs`). */
|
|
4863
|
-
repoUrl:
|
|
4824
|
+
repoUrl: z21.string(),
|
|
4864
4825
|
/** Branch the publish ran from. Used to build the edit-this-page URL. */
|
|
4865
|
-
branch:
|
|
4826
|
+
branch: z21.string(),
|
|
4866
4827
|
/**
|
|
4867
4828
|
* Optional commit SHA captured when the CLI knows it. Currently surfaced
|
|
4868
4829
|
* on `versionMetadata` for diagnostics but not used in URL synthesis.
|
|
4869
4830
|
*/
|
|
4870
|
-
commitSha:
|
|
4831
|
+
commitSha: z21.string().optional()
|
|
4871
4832
|
});
|
|
4872
|
-
var DocsContentFieldsSchema =
|
|
4873
|
-
root:
|
|
4874
|
-
pages:
|
|
4833
|
+
var DocsContentFieldsSchema = z21.object({
|
|
4834
|
+
root: z21.unknown(),
|
|
4835
|
+
pages: z21.record(z21.string(), PageBlobRefSchema),
|
|
4875
4836
|
apiManifest: BlobRefSchema.nullish(),
|
|
4876
4837
|
config: LedgerConfigSchema.optional(),
|
|
4877
4838
|
/**
|
|
4878
4839
|
* Content-addressable file manifest: maps fullPath → file metadata + CAS blob ref.
|
|
4879
4840
|
* Each entry becomes a file/image artifact in the ledger with nav routing by fullPath.
|
|
4880
4841
|
*/
|
|
4881
|
-
fileManifest:
|
|
4842
|
+
fileManifest: z21.record(z21.string(), FileManifestEntrySchema).optional(),
|
|
4882
4843
|
// TODO: jsFiles is a single blob containing all custom React component bundles.
|
|
4883
4844
|
// These should eventually be individual artifacts so they can be loaded/cached
|
|
4884
4845
|
// independently rather than as a monolithic bundle.
|
|
4885
4846
|
jsFiles: BlobRefSchema.nullish(),
|
|
4886
4847
|
redirects: BlobRefSchema.nullish(),
|
|
4887
|
-
locale:
|
|
4888
|
-
version:
|
|
4889
|
-
repo:
|
|
4848
|
+
locale: z21.string().default("en"),
|
|
4849
|
+
version: z21.string().nullish(),
|
|
4850
|
+
repo: z21.string().nullish(),
|
|
4890
4851
|
/**
|
|
4891
4852
|
* Git provenance for the deployment (ADR 0012 / FER-10489). Optional —
|
|
4892
4853
|
* older CLI versions don't send it and the columns stay NULL. When
|
|
@@ -4897,14 +4858,14 @@ var DocsContentFieldsSchema = z22.object({
|
|
|
4897
4858
|
});
|
|
4898
4859
|
var LocaleEntrySchemaInternal = DocsContentFieldsSchema.extend({
|
|
4899
4860
|
/** Locale identifier (e.g. "en", "es", "ja"). Required — no default. */
|
|
4900
|
-
locale:
|
|
4861
|
+
locale: z21.string()
|
|
4901
4862
|
});
|
|
4902
4863
|
var LocaleEntrySchema = LocaleEntrySchemaInternal;
|
|
4903
|
-
var DocsPublishInputSchemaInternal =
|
|
4904
|
-
orgId:
|
|
4905
|
-
domain:
|
|
4906
|
-
basepath:
|
|
4907
|
-
basepathAware:
|
|
4864
|
+
var DocsPublishInputSchemaInternal = z21.object({
|
|
4865
|
+
orgId: z21.string(),
|
|
4866
|
+
domain: z21.string(),
|
|
4867
|
+
basepath: z21.string().default(""),
|
|
4868
|
+
basepathAware: z21.boolean().nullish(),
|
|
4908
4869
|
/**
|
|
4909
4870
|
* Additional URLs the deployment should be served from (e.g. a customer's
|
|
4910
4871
|
* vanity hostname `docs.example.com` alongside the canonical fern URL).
|
|
@@ -4915,22 +4876,22 @@ var DocsPublishInputSchemaInternal = z22.object({
|
|
|
4915
4876
|
*
|
|
4916
4877
|
* See ADR 0010.
|
|
4917
4878
|
*/
|
|
4918
|
-
customDomains:
|
|
4919
|
-
previewId:
|
|
4879
|
+
customDomains: z21.array(z21.string()).default([]),
|
|
4880
|
+
previewId: z21.string().nullish(),
|
|
4920
4881
|
/** The primary/fallback locale for this deployment (e.g. "en"). */
|
|
4921
|
-
defaultLocale:
|
|
4882
|
+
defaultLocale: z21.string().default("en"),
|
|
4922
4883
|
/**
|
|
4923
4884
|
* All locales for this deployment. Each locale goes through the same
|
|
4924
4885
|
* transform → upload → verify → persist pipeline.
|
|
4925
4886
|
*/
|
|
4926
|
-
locales:
|
|
4887
|
+
locales: z21.array(LocaleEntrySchema).min(1)
|
|
4927
4888
|
}).refine((data) => data.locales.some((l) => l.locale === data.defaultLocale), {
|
|
4928
4889
|
message: "defaultLocale must match one of the locales in the locales array",
|
|
4929
4890
|
path: ["defaultLocale"]
|
|
4930
4891
|
});
|
|
4931
4892
|
var DocsPublishInputSchema = DocsPublishInputSchemaInternal;
|
|
4932
4893
|
var LedgerPreviewRegisterInputSchemaInternal = DocsContentFieldsSchema.partial().extend({
|
|
4933
|
-
orgId:
|
|
4894
|
+
orgId: z21.string(),
|
|
4934
4895
|
/**
|
|
4935
4896
|
* Optional caller-supplied identifier for the preview hostname. Sanitized
|
|
4936
4897
|
* server-side (`[a-z0-9-]+`, no leading/trailing dashes). When absent,
|
|
@@ -4938,25 +4899,25 @@ var LedgerPreviewRegisterInputSchemaInternal = DocsContentFieldsSchema.partial()
|
|
|
4938
4899
|
* defeats the round-trip use case where the CLI prints the predicted
|
|
4939
4900
|
* URL before the publish completes. CLIs should always send this.
|
|
4940
4901
|
*/
|
|
4941
|
-
previewId:
|
|
4902
|
+
previewId: z21.string().nullish(),
|
|
4942
4903
|
/**
|
|
4943
4904
|
* Optional path segment appended after the server-generated host.
|
|
4944
4905
|
* Mirrors V2's `basePath` — most preview publishes leave this empty,
|
|
4945
4906
|
* but explicit subpath previews (`/v2`) are supported.
|
|
4946
4907
|
*/
|
|
4947
|
-
basePath:
|
|
4908
|
+
basePath: z21.string().default(""),
|
|
4948
4909
|
/** The primary/fallback locale for this preview deployment. */
|
|
4949
|
-
defaultLocale:
|
|
4910
|
+
defaultLocale: z21.string().optional(),
|
|
4950
4911
|
/**
|
|
4951
4912
|
* All locales for this preview deployment. Preferred over the legacy
|
|
4952
4913
|
* single-locale content fields above.
|
|
4953
4914
|
*/
|
|
4954
|
-
locales:
|
|
4915
|
+
locales: z21.array(LocaleEntrySchema).min(1).optional()
|
|
4955
4916
|
}).superRefine((data, ctx) => {
|
|
4956
4917
|
if (data.locales == null) {
|
|
4957
4918
|
if (data.root == null || data.pages == null) {
|
|
4958
4919
|
ctx.addIssue({
|
|
4959
|
-
code:
|
|
4920
|
+
code: z21.ZodIssueCode.custom,
|
|
4960
4921
|
message: "Either locales or legacy single-locale content fields must be provided",
|
|
4961
4922
|
path: ["locales"]
|
|
4962
4923
|
});
|
|
@@ -4966,75 +4927,75 @@ var LedgerPreviewRegisterInputSchemaInternal = DocsContentFieldsSchema.partial()
|
|
|
4966
4927
|
const defaultLocale = data.defaultLocale ?? data.locales[0]?.locale;
|
|
4967
4928
|
if (defaultLocale == null || !data.locales.some((locale) => locale.locale === defaultLocale)) {
|
|
4968
4929
|
ctx.addIssue({
|
|
4969
|
-
code:
|
|
4930
|
+
code: z21.ZodIssueCode.custom,
|
|
4970
4931
|
message: "defaultLocale must match one of the locales in the locales array",
|
|
4971
4932
|
path: ["defaultLocale"]
|
|
4972
4933
|
});
|
|
4973
4934
|
}
|
|
4974
4935
|
});
|
|
4975
4936
|
var LedgerPreviewRegisterInputSchema = LedgerPreviewRegisterInputSchemaInternal;
|
|
4976
|
-
var LedgerPreviewRegisterResponseSchema =
|
|
4977
|
-
deploymentHash:
|
|
4978
|
-
missingContent:
|
|
4937
|
+
var LedgerPreviewRegisterResponseSchema = z21.object({
|
|
4938
|
+
deploymentHash: z21.string(),
|
|
4939
|
+
missingContent: z21.array(MissingContentSchema),
|
|
4979
4940
|
/** Canonical preview URL, e.g. `https://acme-preview-feature-x.docs.buildwithfern.com`. */
|
|
4980
|
-
previewUrl:
|
|
4941
|
+
previewUrl: z21.string(),
|
|
4981
4942
|
/** Server-generated host portion of `previewUrl` (no scheme, no basepath). */
|
|
4982
|
-
domain:
|
|
4943
|
+
domain: z21.string(),
|
|
4983
4944
|
/** Echoed `basePath` (normalised — empty string when absent). */
|
|
4984
|
-
basepath:
|
|
4945
|
+
basepath: z21.string(),
|
|
4985
4946
|
/** Sanitized identifier the server actually used to compose the host. */
|
|
4986
|
-
previewId:
|
|
4947
|
+
previewId: z21.string()
|
|
4987
4948
|
});
|
|
4988
4949
|
var docsLedgerContract = {
|
|
4989
|
-
register:
|
|
4990
|
-
previewRegister:
|
|
4991
|
-
finish:
|
|
4992
|
-
archiveSite:
|
|
4950
|
+
register: import_contract19.oc.route({ method: "POST", path: "/register" }).input(DocsPublishInputSchema).output(RegisterResponseSchema),
|
|
4951
|
+
previewRegister: import_contract19.oc.route({ method: "POST", path: "/preview/init" }).input(LedgerPreviewRegisterInputSchema).output(LedgerPreviewRegisterResponseSchema),
|
|
4952
|
+
finish: import_contract19.oc.route({ method: "POST", path: "/register/finish" }).input(DocsPublishInputSchema).output(FinishResponseSchema),
|
|
4953
|
+
archiveSite: import_contract19.oc.route({ method: "POST", path: "/archive" }).input(ArchiveSiteInputSchema).output(ArchiveSiteResponseSchema)
|
|
4993
4954
|
};
|
|
4994
|
-
var CurrentVersionInputSchema =
|
|
4995
|
-
domain:
|
|
4996
|
-
basepath:
|
|
4955
|
+
var CurrentVersionInputSchema = z21.object({
|
|
4956
|
+
domain: z21.string(),
|
|
4957
|
+
basepath: z21.string().default("")
|
|
4997
4958
|
});
|
|
4998
4959
|
var CurrentPreviewInputSchema = CurrentVersionInputSchema.extend({
|
|
4999
|
-
previewId:
|
|
4960
|
+
previewId: z21.string()
|
|
4961
|
+
});
|
|
4962
|
+
var CurrentVersionResponseSchema = z21.object({
|
|
4963
|
+
orgId: z21.string(),
|
|
4964
|
+
domain: z21.string(),
|
|
4965
|
+
basepath: z21.string(),
|
|
4966
|
+
deploymentId: z21.string(),
|
|
4967
|
+
deploymentHash: z21.string(),
|
|
4968
|
+
siteId: z21.string(),
|
|
4969
|
+
assignedAt: z21.string(),
|
|
4970
|
+
assignedBy: z21.string().nullable()
|
|
4971
|
+
});
|
|
4972
|
+
var ContentRefSchema = z21.object({
|
|
4973
|
+
hash: z21.string(),
|
|
4974
|
+
s3Key: z21.string(),
|
|
4975
|
+
contentType: z21.string(),
|
|
4976
|
+
url: z21.string()
|
|
5000
4977
|
});
|
|
5001
|
-
var
|
|
5002
|
-
|
|
5003
|
-
|
|
5004
|
-
|
|
5005
|
-
|
|
5006
|
-
|
|
5007
|
-
|
|
5008
|
-
|
|
5009
|
-
|
|
5010
|
-
});
|
|
5011
|
-
var ContentRefSchema = z22.object({
|
|
5012
|
-
hash: z22.string(),
|
|
5013
|
-
s3Key: z22.string(),
|
|
5014
|
-
contentType: z22.string(),
|
|
5015
|
-
url: z22.string()
|
|
5016
|
-
});
|
|
5017
|
-
var SegmentDetailSchema = z22.object({
|
|
5018
|
-
id: z22.string(),
|
|
5019
|
-
displayName: z22.string(),
|
|
5020
|
-
icon: z22.string().nullable(),
|
|
5021
|
-
sortOrder: z22.number(),
|
|
5022
|
-
hidden: z22.boolean(),
|
|
5023
|
-
viewers: z22.array(z22.string()),
|
|
5024
|
-
orphaned: z22.boolean(),
|
|
5025
|
-
featureFlags: z22.array(z22.string()),
|
|
4978
|
+
var SegmentDetailSchema = z21.object({
|
|
4979
|
+
id: z21.string(),
|
|
4980
|
+
displayName: z21.string(),
|
|
4981
|
+
icon: z21.string().nullable(),
|
|
4982
|
+
sortOrder: z21.number(),
|
|
4983
|
+
hidden: z21.boolean(),
|
|
4984
|
+
viewers: z21.array(z21.string()),
|
|
4985
|
+
orphaned: z21.boolean(),
|
|
4986
|
+
featureFlags: z21.array(z21.string()),
|
|
5026
4987
|
/** Type-specific fields: slug, default, subtitle, href, target, image, availability, pointsTo, tab_type. */
|
|
5027
4988
|
metadata: LedgerSegmentDetailMetadataSchema
|
|
5028
4989
|
});
|
|
5029
|
-
var SegmentSchema =
|
|
5030
|
-
segmentId:
|
|
5031
|
-
segmentHash:
|
|
5032
|
-
section:
|
|
5033
|
-
locale:
|
|
4990
|
+
var SegmentSchema = z21.object({
|
|
4991
|
+
segmentId: z21.string(),
|
|
4992
|
+
segmentHash: z21.string(),
|
|
4993
|
+
section: z21.string(),
|
|
4994
|
+
locale: z21.string(),
|
|
5034
4995
|
/** Sidebar order across segments (docs_ledger_deployment_segments.sort_order). */
|
|
5035
|
-
sortOrder:
|
|
4996
|
+
sortOrder: z21.number(),
|
|
5036
4997
|
/** Whether the segment is hidden from the sidebar. */
|
|
5037
|
-
hidden:
|
|
4998
|
+
hidden: z21.boolean(),
|
|
5038
4999
|
/** Segment type descriptor (seg.metadata): { type, title, icon, apiDefinitionId, overviewPageId, pointsTo, ... }. */
|
|
5039
5000
|
metadata: LedgerSegmentMetadataSchema,
|
|
5040
5001
|
/** Full product/version/variant/tab detail metadata, or null when the dimension is absent. */
|
|
@@ -5044,26 +5005,26 @@ var SegmentSchema = z22.object({
|
|
|
5044
5005
|
tab: SegmentDetailSchema.nullable(),
|
|
5045
5006
|
// ── Flat name/icon retained for back-compat (derivable from the
|
|
5046
5007
|
// detail objects above). ──
|
|
5047
|
-
productId:
|
|
5048
|
-
productName:
|
|
5049
|
-
productIcon:
|
|
5050
|
-
versionId:
|
|
5051
|
-
versionName:
|
|
5052
|
-
versionIcon:
|
|
5053
|
-
variantId:
|
|
5054
|
-
variantName:
|
|
5055
|
-
variantIcon:
|
|
5056
|
-
tabId:
|
|
5057
|
-
tabName:
|
|
5058
|
-
tabIcon:
|
|
5059
|
-
});
|
|
5060
|
-
var VersionMetadataInputSchema =
|
|
5061
|
-
deploymentId:
|
|
5062
|
-
locale:
|
|
5063
|
-
});
|
|
5064
|
-
var VersionMetadataResponseSchema =
|
|
5065
|
-
deploymentId:
|
|
5066
|
-
version:
|
|
5008
|
+
productId: z21.string().nullable(),
|
|
5009
|
+
productName: z21.string().nullable(),
|
|
5010
|
+
productIcon: z21.string().nullable(),
|
|
5011
|
+
versionId: z21.string().nullable(),
|
|
5012
|
+
versionName: z21.string().nullable(),
|
|
5013
|
+
versionIcon: z21.string().nullable(),
|
|
5014
|
+
variantId: z21.string().nullable(),
|
|
5015
|
+
variantName: z21.string().nullable(),
|
|
5016
|
+
variantIcon: z21.string().nullable(),
|
|
5017
|
+
tabId: z21.string().nullable(),
|
|
5018
|
+
tabName: z21.string().nullable(),
|
|
5019
|
+
tabIcon: z21.string().nullable()
|
|
5020
|
+
});
|
|
5021
|
+
var VersionMetadataInputSchema = z21.object({
|
|
5022
|
+
deploymentId: z21.string(),
|
|
5023
|
+
locale: z21.string().optional()
|
|
5024
|
+
});
|
|
5025
|
+
var VersionMetadataResponseSchema = z21.object({
|
|
5026
|
+
deploymentId: z21.string(),
|
|
5027
|
+
version: z21.string().nullable(),
|
|
5067
5028
|
/**
|
|
5068
5029
|
* Inline structural config (ADR 0009). Contains everything from
|
|
5069
5030
|
* {@link LedgerConfigSchema} except `header`, `footer`, `css.inline`,
|
|
@@ -5082,76 +5043,76 @@ var VersionMetadataResponseSchema = z22.object({
|
|
|
5082
5043
|
/** CAS ref for the joined `config.js.inline` blob (`\n`-separated JS). */
|
|
5083
5044
|
jsInline: ContentRefSchema.nullable(),
|
|
5084
5045
|
jsFiles: ContentRefSchema.nullable(),
|
|
5085
|
-
segments:
|
|
5046
|
+
segments: z21.array(SegmentSchema),
|
|
5086
5047
|
/** Mapping from human-readable API name slug to API definition UUID. */
|
|
5087
|
-
apiNameToId:
|
|
5048
|
+
apiNameToId: z21.record(z21.string(), z21.string()),
|
|
5088
5049
|
/**
|
|
5089
5050
|
* Git provenance for the deployment (ADR 0012 / FER-10489). Optional —
|
|
5090
5051
|
* nullable on CLIs that don't send `git` on the publish input. When
|
|
5091
5052
|
* present, the docs loader synthesises `editThisPageUrl` from `repoUrl`,
|
|
5092
5053
|
* `branch`, and the page `filename` server-side.
|
|
5093
5054
|
*/
|
|
5094
|
-
git:
|
|
5095
|
-
repoUrl:
|
|
5096
|
-
branch:
|
|
5097
|
-
commitSha:
|
|
5055
|
+
git: z21.object({
|
|
5056
|
+
repoUrl: z21.string(),
|
|
5057
|
+
branch: z21.string(),
|
|
5058
|
+
commitSha: z21.string().nullable().optional()
|
|
5098
5059
|
}).optional(),
|
|
5099
5060
|
/**
|
|
5100
5061
|
* Docs deployment status from the legacy `docs_sites` table, resolved
|
|
5101
5062
|
* via Kysely join in the DAO. Null when no matching row exists.
|
|
5102
5063
|
*/
|
|
5103
|
-
docsStatus:
|
|
5104
|
-
});
|
|
5105
|
-
var PageContentInputSchema =
|
|
5106
|
-
deploymentId:
|
|
5107
|
-
fullPath:
|
|
5108
|
-
pageId:
|
|
5109
|
-
locale:
|
|
5110
|
-
});
|
|
5111
|
-
var PageContentResponseSchema =
|
|
5112
|
-
s3Key:
|
|
5113
|
-
segmentHash:
|
|
5114
|
-
url:
|
|
5115
|
-
pageId:
|
|
5116
|
-
});
|
|
5117
|
-
var BatchPageContentInputSchema =
|
|
5118
|
-
deploymentId:
|
|
5119
|
-
pageIds:
|
|
5120
|
-
locale:
|
|
5121
|
-
});
|
|
5122
|
-
var BatchPageContentItemSchema =
|
|
5123
|
-
pageId:
|
|
5124
|
-
s3Key:
|
|
5125
|
-
url:
|
|
5126
|
-
});
|
|
5127
|
-
var BatchPageContentResponseSchema =
|
|
5128
|
-
items:
|
|
5129
|
-
});
|
|
5130
|
-
var NavInputSchema =
|
|
5131
|
-
segmentHash:
|
|
5132
|
-
});
|
|
5133
|
-
var NavResponseSchema =
|
|
5134
|
-
routes:
|
|
5135
|
-
});
|
|
5136
|
-
var RouteContextInputSchema =
|
|
5137
|
-
deploymentId:
|
|
5138
|
-
fullPath:
|
|
5139
|
-
locale:
|
|
5140
|
-
});
|
|
5141
|
-
var RouteContextResponseBaseSchema =
|
|
5142
|
-
artifactId:
|
|
5064
|
+
docsStatus: z21.enum(["PUBLISHING", "LIVE", "UNPUBLISHED", "ERROR"]).nullable().optional()
|
|
5065
|
+
});
|
|
5066
|
+
var PageContentInputSchema = z21.object({
|
|
5067
|
+
deploymentId: z21.string(),
|
|
5068
|
+
fullPath: z21.string().optional(),
|
|
5069
|
+
pageId: z21.string().optional(),
|
|
5070
|
+
locale: z21.string().optional()
|
|
5071
|
+
});
|
|
5072
|
+
var PageContentResponseSchema = z21.object({
|
|
5073
|
+
s3Key: z21.string(),
|
|
5074
|
+
segmentHash: z21.string(),
|
|
5075
|
+
url: z21.string(),
|
|
5076
|
+
pageId: z21.string().optional()
|
|
5077
|
+
});
|
|
5078
|
+
var BatchPageContentInputSchema = z21.object({
|
|
5079
|
+
deploymentId: z21.string(),
|
|
5080
|
+
pageIds: z21.array(z21.string()).min(1).max(2e3),
|
|
5081
|
+
locale: z21.string().optional()
|
|
5082
|
+
});
|
|
5083
|
+
var BatchPageContentItemSchema = z21.object({
|
|
5084
|
+
pageId: z21.string(),
|
|
5085
|
+
s3Key: z21.string(),
|
|
5086
|
+
url: z21.string()
|
|
5087
|
+
});
|
|
5088
|
+
var BatchPageContentResponseSchema = z21.object({
|
|
5089
|
+
items: z21.array(BatchPageContentItemSchema)
|
|
5090
|
+
});
|
|
5091
|
+
var NavInputSchema = z21.object({
|
|
5092
|
+
segmentHash: z21.string()
|
|
5093
|
+
});
|
|
5094
|
+
var NavResponseSchema = z21.object({
|
|
5095
|
+
routes: z21.array(LedgerNavRouteSchema)
|
|
5096
|
+
});
|
|
5097
|
+
var RouteContextInputSchema = z21.object({
|
|
5098
|
+
deploymentId: z21.string(),
|
|
5099
|
+
fullPath: z21.string(),
|
|
5100
|
+
locale: z21.string().optional()
|
|
5101
|
+
});
|
|
5102
|
+
var RouteContextResponseBaseSchema = z21.object({
|
|
5103
|
+
artifactId: z21.string(),
|
|
5143
5104
|
/** Hash of the segment that owns the matched route — feed to `nav`. */
|
|
5144
|
-
segmentHash:
|
|
5105
|
+
segmentHash: z21.string(),
|
|
5145
5106
|
/** Section path of the owning segment (e.g. "models/command"). */
|
|
5146
|
-
section:
|
|
5147
|
-
locale:
|
|
5107
|
+
section: z21.string(),
|
|
5108
|
+
locale: z21.string(),
|
|
5148
5109
|
/**
|
|
5149
5110
|
* Page content reference, or null for non-page artifacts (links/redirects)
|
|
5150
5111
|
* and route-only aliases that carry no content blob.
|
|
5151
5112
|
*/
|
|
5152
|
-
page:
|
|
5153
|
-
s3Key:
|
|
5154
|
-
url:
|
|
5113
|
+
page: z21.object({
|
|
5114
|
+
s3Key: z21.string(),
|
|
5115
|
+
url: z21.string()
|
|
5155
5116
|
}).nullable(),
|
|
5156
5117
|
/** Identity of the owning segment, for switchers + breadcrumbs. */
|
|
5157
5118
|
product: SegmentDetailSchema.nullable(),
|
|
@@ -5159,7 +5120,7 @@ var RouteContextResponseBaseSchema = z22.object({
|
|
|
5159
5120
|
variant: SegmentDetailSchema.nullable(),
|
|
5160
5121
|
tab: SegmentDetailSchema.nullable()
|
|
5161
5122
|
});
|
|
5162
|
-
var RouteContextResponseSchema =
|
|
5123
|
+
var RouteContextResponseSchema = z21.discriminatedUnion("artifactType", [
|
|
5163
5124
|
artifactTypeVariant(RouteContextResponseBaseSchema, "markdown"),
|
|
5164
5125
|
artifactTypeVariant(RouteContextResponseBaseSchema, "page"),
|
|
5165
5126
|
artifactTypeVariant(RouteContextResponseBaseSchema, "rest"),
|
|
@@ -5173,116 +5134,116 @@ var RouteContextResponseSchema = z22.discriminatedUnion("artifactType", [
|
|
|
5173
5134
|
artifactTypeVariant(RouteContextResponseBaseSchema, "image"),
|
|
5174
5135
|
artifactTypeVariant(RouteContextResponseBaseSchema, "redirect")
|
|
5175
5136
|
]);
|
|
5176
|
-
var TopLevelNavigationInputSchema =
|
|
5177
|
-
deploymentId:
|
|
5178
|
-
locale:
|
|
5179
|
-
});
|
|
5180
|
-
var TopLevelNavigationResponseSchema =
|
|
5181
|
-
products:
|
|
5182
|
-
versions:
|
|
5183
|
-
variants:
|
|
5184
|
-
tabs:
|
|
5185
|
-
});
|
|
5186
|
-
var VersionSwitchTargetsInputSchema =
|
|
5187
|
-
deploymentId:
|
|
5188
|
-
fullPath:
|
|
5189
|
-
locale:
|
|
5190
|
-
});
|
|
5191
|
-
var VersionSwitchTargetSchema =
|
|
5137
|
+
var TopLevelNavigationInputSchema = z21.object({
|
|
5138
|
+
deploymentId: z21.string(),
|
|
5139
|
+
locale: z21.string().optional()
|
|
5140
|
+
});
|
|
5141
|
+
var TopLevelNavigationResponseSchema = z21.object({
|
|
5142
|
+
products: z21.array(SegmentDetailSchema),
|
|
5143
|
+
versions: z21.array(SegmentDetailSchema),
|
|
5144
|
+
variants: z21.array(SegmentDetailSchema),
|
|
5145
|
+
tabs: z21.array(SegmentDetailSchema)
|
|
5146
|
+
});
|
|
5147
|
+
var VersionSwitchTargetsInputSchema = z21.object({
|
|
5148
|
+
deploymentId: z21.string(),
|
|
5149
|
+
fullPath: z21.string(),
|
|
5150
|
+
locale: z21.string().optional()
|
|
5151
|
+
});
|
|
5152
|
+
var VersionSwitchTargetSchema = z21.object({
|
|
5192
5153
|
/** The version detail id (matches a `SegmentDetail.id` from `versionMetadata`). */
|
|
5193
|
-
versionId:
|
|
5154
|
+
versionId: z21.string(),
|
|
5194
5155
|
/**
|
|
5195
5156
|
* Slug to navigate to when switching to this version — the equivalent
|
|
5196
5157
|
* route in the target version, or that version's landing/root slug when
|
|
5197
5158
|
* no equivalent exists. The current version maps to `fullPath` itself.
|
|
5198
5159
|
*/
|
|
5199
|
-
targetSlug:
|
|
5160
|
+
targetSlug: z21.string()
|
|
5200
5161
|
});
|
|
5201
|
-
var VersionSwitchTargetsResponseSchema =
|
|
5202
|
-
targets:
|
|
5162
|
+
var VersionSwitchTargetsResponseSchema = z21.object({
|
|
5163
|
+
targets: z21.array(VersionSwitchTargetSchema)
|
|
5203
5164
|
});
|
|
5204
|
-
var ApiDefinitionInputSchema =
|
|
5205
|
-
deploymentId:
|
|
5206
|
-
apiDefinitionId:
|
|
5165
|
+
var ApiDefinitionInputSchema = z21.object({
|
|
5166
|
+
deploymentId: z21.string(),
|
|
5167
|
+
apiDefinitionId: z21.string()
|
|
5207
5168
|
});
|
|
5208
|
-
var ApiDefinitionResponseSchema =
|
|
5209
|
-
s3Key:
|
|
5210
|
-
contentType:
|
|
5211
|
-
url:
|
|
5169
|
+
var ApiDefinitionResponseSchema = z21.object({
|
|
5170
|
+
s3Key: z21.string(),
|
|
5171
|
+
contentType: z21.string(),
|
|
5172
|
+
url: z21.string()
|
|
5212
5173
|
});
|
|
5213
|
-
var PrunedApiDefinitionInputSchema =
|
|
5214
|
-
deploymentId:
|
|
5215
|
-
apiDefinitionId:
|
|
5174
|
+
var PrunedApiDefinitionInputSchema = z21.object({
|
|
5175
|
+
deploymentId: z21.string(),
|
|
5176
|
+
apiDefinitionId: z21.string(),
|
|
5216
5177
|
/** Discriminator matching PruningNodeType.type → artifact metadata field. */
|
|
5217
|
-
nodeType:
|
|
5178
|
+
nodeType: z21.enum(["endpoint", "webSocket", "webhook", "grpc", "graphql"]),
|
|
5218
5179
|
/** The node ID value (endpointId, webSocketId, etc.). */
|
|
5219
|
-
nodeId:
|
|
5220
|
-
});
|
|
5221
|
-
var PrunedApiDefinitionResponseSchema =
|
|
5222
|
-
s3Key:
|
|
5223
|
-
contentType:
|
|
5224
|
-
url:
|
|
5225
|
-
});
|
|
5226
|
-
var FileArtifactInputSchema =
|
|
5227
|
-
deploymentId:
|
|
5228
|
-
fullPath:
|
|
5229
|
-
});
|
|
5230
|
-
var FileArtifactResponseSchema =
|
|
5231
|
-
fullPath:
|
|
5232
|
-
type:
|
|
5233
|
-
contentType:
|
|
5234
|
-
contentLength:
|
|
5235
|
-
filename:
|
|
5236
|
-
url:
|
|
5237
|
-
width:
|
|
5238
|
-
height:
|
|
5239
|
-
blurDataURL:
|
|
5240
|
-
});
|
|
5241
|
-
var PresignedFileDownloadInputSchema =
|
|
5180
|
+
nodeId: z21.string()
|
|
5181
|
+
});
|
|
5182
|
+
var PrunedApiDefinitionResponseSchema = z21.object({
|
|
5183
|
+
s3Key: z21.string(),
|
|
5184
|
+
contentType: z21.string(),
|
|
5185
|
+
url: z21.string()
|
|
5186
|
+
});
|
|
5187
|
+
var FileArtifactInputSchema = z21.object({
|
|
5188
|
+
deploymentId: z21.string(),
|
|
5189
|
+
fullPath: z21.string()
|
|
5190
|
+
});
|
|
5191
|
+
var FileArtifactResponseSchema = z21.object({
|
|
5192
|
+
fullPath: z21.string(),
|
|
5193
|
+
type: z21.enum(["file", "image"]),
|
|
5194
|
+
contentType: z21.string(),
|
|
5195
|
+
contentLength: z21.number().optional(),
|
|
5196
|
+
filename: z21.string(),
|
|
5197
|
+
url: z21.string(),
|
|
5198
|
+
width: z21.number().optional(),
|
|
5199
|
+
height: z21.number().optional(),
|
|
5200
|
+
blurDataURL: z21.string().optional()
|
|
5201
|
+
});
|
|
5202
|
+
var PresignedFileDownloadInputSchema = z21.object({
|
|
5242
5203
|
/** S3 object key in the public docs bucket (format: `{domain}/{hash}/{path}`). */
|
|
5243
|
-
s3Key:
|
|
5204
|
+
s3Key: z21.string().regex(/^[a-zA-Z0-9._-]+(?:\/[^/]+){2,}$/)
|
|
5244
5205
|
});
|
|
5245
|
-
var PresignedFileDownloadResponseSchema =
|
|
5206
|
+
var PresignedFileDownloadResponseSchema = z21.object({
|
|
5246
5207
|
/** Presigned S3 GET URL with long expiry (7 days). */
|
|
5247
|
-
url:
|
|
5208
|
+
url: z21.string()
|
|
5248
5209
|
});
|
|
5249
|
-
var FileMetadataInputSchema =
|
|
5250
|
-
deploymentId:
|
|
5251
|
-
fullPath:
|
|
5210
|
+
var FileMetadataInputSchema = z21.object({
|
|
5211
|
+
deploymentId: z21.string(),
|
|
5212
|
+
fullPath: z21.string()
|
|
5252
5213
|
});
|
|
5253
|
-
var FileMetadataResponseSchema =
|
|
5214
|
+
var FileMetadataResponseSchema = z21.object({
|
|
5254
5215
|
/** Content hash — used by the loader to construct CDN URLs. */
|
|
5255
|
-
hash:
|
|
5216
|
+
hash: z21.string(),
|
|
5256
5217
|
/** Domain under which the file bytes were uploaded in the docs files bucket. */
|
|
5257
|
-
domain:
|
|
5258
|
-
contentType:
|
|
5259
|
-
contentLength:
|
|
5260
|
-
filename:
|
|
5261
|
-
width:
|
|
5262
|
-
height:
|
|
5263
|
-
blurDataURL:
|
|
5218
|
+
domain: z21.string(),
|
|
5219
|
+
contentType: z21.string(),
|
|
5220
|
+
contentLength: z21.number().optional(),
|
|
5221
|
+
filename: z21.string().optional(),
|
|
5222
|
+
width: z21.number().optional(),
|
|
5223
|
+
height: z21.number().optional(),
|
|
5224
|
+
blurDataURL: z21.string().optional()
|
|
5264
5225
|
});
|
|
5265
5226
|
var docsLedgerReadContract = {
|
|
5266
|
-
currentVersion:
|
|
5267
|
-
currentPreview:
|
|
5268
|
-
versionMetadata:
|
|
5269
|
-
pageContent:
|
|
5270
|
-
batchPageContent:
|
|
5271
|
-
nav:
|
|
5272
|
-
routeContext:
|
|
5273
|
-
topLevelNavigation:
|
|
5274
|
-
versionSwitchTargets:
|
|
5275
|
-
apiDefinition:
|
|
5276
|
-
prunedApiDefinition:
|
|
5277
|
-
fileArtifact:
|
|
5278
|
-
fileMetadata:
|
|
5279
|
-
presignedFileDownload:
|
|
5227
|
+
currentVersion: import_contract19.oc.route({ method: "GET", path: "/current-version" }).input(CurrentVersionInputSchema).output(CurrentVersionResponseSchema),
|
|
5228
|
+
currentPreview: import_contract19.oc.route({ method: "GET", path: "/current-preview" }).input(CurrentPreviewInputSchema).output(CurrentVersionResponseSchema),
|
|
5229
|
+
versionMetadata: import_contract19.oc.route({ method: "GET", path: "/version-metadata/{deploymentId}" }).input(VersionMetadataInputSchema).output(VersionMetadataResponseSchema),
|
|
5230
|
+
pageContent: import_contract19.oc.route({ method: "GET", path: "/page-content/{deploymentId}" }).input(PageContentInputSchema).output(PageContentResponseSchema),
|
|
5231
|
+
batchPageContent: import_contract19.oc.route({ method: "POST", path: "/batch-page-content/{deploymentId}" }).input(BatchPageContentInputSchema).output(BatchPageContentResponseSchema),
|
|
5232
|
+
nav: import_contract19.oc.route({ method: "GET", path: "/nav/{segmentHash}" }).input(NavInputSchema).output(NavResponseSchema),
|
|
5233
|
+
routeContext: import_contract19.oc.route({ method: "GET", path: "/route-context/{deploymentId}" }).input(RouteContextInputSchema).output(RouteContextResponseSchema),
|
|
5234
|
+
topLevelNavigation: import_contract19.oc.route({ method: "GET", path: "/top-level-navigation/{deploymentId}" }).input(TopLevelNavigationInputSchema).output(TopLevelNavigationResponseSchema),
|
|
5235
|
+
versionSwitchTargets: import_contract19.oc.route({ method: "GET", path: "/version-switch-targets/{deploymentId}" }).input(VersionSwitchTargetsInputSchema).output(VersionSwitchTargetsResponseSchema),
|
|
5236
|
+
apiDefinition: import_contract19.oc.route({ method: "GET", path: "/api-definition/{deploymentId}/{apiDefinitionId}" }).input(ApiDefinitionInputSchema).output(ApiDefinitionResponseSchema),
|
|
5237
|
+
prunedApiDefinition: import_contract19.oc.route({ method: "GET", path: "/pruned-api/{deploymentId}/{apiDefinitionId}" }).input(PrunedApiDefinitionInputSchema).output(PrunedApiDefinitionResponseSchema),
|
|
5238
|
+
fileArtifact: import_contract19.oc.route({ method: "GET", path: "/file/{deploymentId}" }).input(FileArtifactInputSchema).output(FileArtifactResponseSchema),
|
|
5239
|
+
fileMetadata: import_contract19.oc.route({ method: "GET", path: "/file-metadata/{deploymentId}" }).input(FileMetadataInputSchema).output(FileMetadataResponseSchema),
|
|
5240
|
+
presignedFileDownload: import_contract19.oc.route({ method: "POST", path: "/presigned-file-download" }).input(PresignedFileDownloadInputSchema).output(PresignedFileDownloadResponseSchema)
|
|
5280
5241
|
};
|
|
5281
5242
|
|
|
5282
5243
|
// src/orpc-client/docs-ledger/client.ts
|
|
5283
5244
|
function createDocsLedgerClient(options) {
|
|
5284
5245
|
const baseUrl = options.baseUrl.replace(/\/+$/, "");
|
|
5285
|
-
const link = new
|
|
5246
|
+
const link = new import_fetch10.OpenAPILink(docsLedgerContract, {
|
|
5286
5247
|
url: `${baseUrl}/docs-ledger`,
|
|
5287
5248
|
headers: () => ({
|
|
5288
5249
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -5290,53 +5251,53 @@ function createDocsLedgerClient(options) {
|
|
|
5290
5251
|
}),
|
|
5291
5252
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
5292
5253
|
});
|
|
5293
|
-
return (0,
|
|
5254
|
+
return (0, import_client15.createORPCClient)(link);
|
|
5294
5255
|
}
|
|
5295
5256
|
|
|
5296
5257
|
// src/orpc-client/editor-snapshot/client.ts
|
|
5297
|
-
var
|
|
5298
|
-
var
|
|
5258
|
+
var import_client16 = require("@orpc/client");
|
|
5259
|
+
var import_fetch11 = require("@orpc/openapi-client/fetch");
|
|
5299
5260
|
|
|
5300
5261
|
// src/orpc-client/editor-snapshot/contract.ts
|
|
5301
|
-
var
|
|
5302
|
-
var
|
|
5303
|
-
var GetSnapshotInputSchema =
|
|
5304
|
-
domain:
|
|
5305
|
-
branchName:
|
|
5262
|
+
var import_contract21 = require("@orpc/contract");
|
|
5263
|
+
var z22 = __toESM(require("zod"), 1);
|
|
5264
|
+
var GetSnapshotInputSchema = z22.object({
|
|
5265
|
+
domain: z22.string(),
|
|
5266
|
+
branchName: z22.string()
|
|
5306
5267
|
});
|
|
5307
|
-
var SetSnapshotInputSchema =
|
|
5308
|
-
domain:
|
|
5309
|
-
branchName:
|
|
5310
|
-
data:
|
|
5268
|
+
var SetSnapshotInputSchema = z22.object({
|
|
5269
|
+
domain: z22.string(),
|
|
5270
|
+
branchName: z22.string(),
|
|
5271
|
+
data: z22.unknown()
|
|
5311
5272
|
});
|
|
5312
|
-
var GetDocumentsForBranchesInputSchema =
|
|
5313
|
-
domain:
|
|
5314
|
-
branchNames:
|
|
5273
|
+
var GetDocumentsForBranchesInputSchema = z22.object({
|
|
5274
|
+
domain: z22.string(),
|
|
5275
|
+
branchNames: z22.array(z22.string())
|
|
5315
5276
|
});
|
|
5316
|
-
var EditorDocumentSchema =
|
|
5317
|
-
id:
|
|
5318
|
-
domain:
|
|
5319
|
-
branchName:
|
|
5320
|
-
data:
|
|
5321
|
-
createdAt:
|
|
5322
|
-
updatedAt:
|
|
5323
|
-
expiresAt:
|
|
5277
|
+
var EditorDocumentSchema = z22.object({
|
|
5278
|
+
id: z22.string(),
|
|
5279
|
+
domain: z22.string(),
|
|
5280
|
+
branchName: z22.string(),
|
|
5281
|
+
data: z22.unknown(),
|
|
5282
|
+
createdAt: z22.string(),
|
|
5283
|
+
updatedAt: z22.string(),
|
|
5284
|
+
expiresAt: z22.string().optional()
|
|
5324
5285
|
});
|
|
5325
|
-
var GetSnapshotResponseSchema =
|
|
5326
|
-
data:
|
|
5286
|
+
var GetSnapshotResponseSchema = z22.object({
|
|
5287
|
+
data: z22.unknown().nullable()
|
|
5327
5288
|
});
|
|
5328
|
-
var GetDocumentsForBranchesResponseSchema =
|
|
5329
|
-
documents:
|
|
5289
|
+
var GetDocumentsForBranchesResponseSchema = z22.object({
|
|
5290
|
+
documents: z22.array(EditorDocumentSchema)
|
|
5330
5291
|
});
|
|
5331
5292
|
var editorSnapshotContract = {
|
|
5332
|
-
getSnapshot:
|
|
5333
|
-
setSnapshot:
|
|
5334
|
-
getDocumentsForBranches:
|
|
5293
|
+
getSnapshot: import_contract21.oc.route({ method: "POST", path: "/get" }).input(GetSnapshotInputSchema).output(GetSnapshotResponseSchema),
|
|
5294
|
+
setSnapshot: import_contract21.oc.route({ method: "POST", path: "/set" }).input(SetSnapshotInputSchema).output(z22.object({})),
|
|
5295
|
+
getDocumentsForBranches: import_contract21.oc.route({ method: "POST", path: "/branches" }).input(GetDocumentsForBranchesInputSchema).output(GetDocumentsForBranchesResponseSchema)
|
|
5335
5296
|
};
|
|
5336
5297
|
|
|
5337
5298
|
// src/orpc-client/editor-snapshot/client.ts
|
|
5338
5299
|
function createEditorSnapshotClient(options) {
|
|
5339
|
-
const link = new
|
|
5300
|
+
const link = new import_fetch11.OpenAPILink(editorSnapshotContract, {
|
|
5340
5301
|
url: `${options.baseUrl.replace(/\/+$/, "")}/editor-snapshot`,
|
|
5341
5302
|
headers: () => ({
|
|
5342
5303
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -5344,16 +5305,16 @@ function createEditorSnapshotClient(options) {
|
|
|
5344
5305
|
}),
|
|
5345
5306
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
5346
5307
|
});
|
|
5347
|
-
return (0,
|
|
5308
|
+
return (0, import_client16.createORPCClient)(link);
|
|
5348
5309
|
}
|
|
5349
5310
|
|
|
5350
5311
|
// src/orpc-client/generators/cli/client.ts
|
|
5351
|
-
var
|
|
5352
|
-
var
|
|
5312
|
+
var import_client17 = require("@orpc/client");
|
|
5313
|
+
var import_fetch12 = require("@orpc/openapi-client/fetch");
|
|
5353
5314
|
|
|
5354
5315
|
// src/orpc-client/generators/contract.ts
|
|
5355
|
-
var
|
|
5356
|
-
var
|
|
5316
|
+
var import_contract23 = require("@orpc/contract");
|
|
5317
|
+
var z23 = __toESM(require("zod"), 1);
|
|
5357
5318
|
function GeneratorId(value) {
|
|
5358
5319
|
return value;
|
|
5359
5320
|
}
|
|
@@ -5372,7 +5333,7 @@ var ReleaseType = {
|
|
|
5372
5333
|
Ga: "GA",
|
|
5373
5334
|
Rc: "RC"
|
|
5374
5335
|
};
|
|
5375
|
-
var GeneratorLanguageSchema =
|
|
5336
|
+
var GeneratorLanguageSchema = z23.enum([
|
|
5376
5337
|
"python",
|
|
5377
5338
|
"go",
|
|
5378
5339
|
"java",
|
|
@@ -5383,182 +5344,182 @@ var GeneratorLanguageSchema = z24.enum([
|
|
|
5383
5344
|
"swift",
|
|
5384
5345
|
"rust"
|
|
5385
5346
|
]);
|
|
5386
|
-
var ScriptSchema =
|
|
5387
|
-
steps:
|
|
5347
|
+
var ScriptSchema = z23.object({
|
|
5348
|
+
steps: z23.array(z23.string())
|
|
5388
5349
|
});
|
|
5389
|
-
var GeneratorScriptsSchema =
|
|
5350
|
+
var GeneratorScriptsSchema = z23.object({
|
|
5390
5351
|
preInstallScript: ScriptSchema.nullish(),
|
|
5391
5352
|
installScript: ScriptSchema.nullish(),
|
|
5392
5353
|
compileScript: ScriptSchema.nullish(),
|
|
5393
5354
|
testScript: ScriptSchema.nullish()
|
|
5394
5355
|
});
|
|
5395
|
-
var GeneratorTypeSchema =
|
|
5396
|
-
|
|
5397
|
-
|
|
5398
|
-
|
|
5399
|
-
|
|
5356
|
+
var GeneratorTypeSchema = z23.discriminatedUnion("type", [
|
|
5357
|
+
z23.object({ type: z23.literal("sdk") }),
|
|
5358
|
+
z23.object({ type: z23.literal("model") }),
|
|
5359
|
+
z23.object({ type: z23.literal("server") }),
|
|
5360
|
+
z23.object({ type: z23.literal("other") })
|
|
5400
5361
|
]);
|
|
5401
|
-
var ChangelogEntryTypeSchema =
|
|
5402
|
-
var ChangelogEntrySchema =
|
|
5362
|
+
var ChangelogEntryTypeSchema = z23.enum(["fix", "feat", "chore", "break", "internal"]);
|
|
5363
|
+
var ChangelogEntrySchema = z23.object({
|
|
5403
5364
|
type: ChangelogEntryTypeSchema,
|
|
5404
|
-
summary:
|
|
5405
|
-
links:
|
|
5406
|
-
upgradeNotes:
|
|
5407
|
-
added:
|
|
5408
|
-
changed:
|
|
5409
|
-
deprecated:
|
|
5410
|
-
removed:
|
|
5411
|
-
fixed:
|
|
5412
|
-
});
|
|
5413
|
-
var YankSchema =
|
|
5414
|
-
remediationVerision:
|
|
5415
|
-
});
|
|
5416
|
-
var ReleaseTypeSchema =
|
|
5417
|
-
var VersionRangeSchema =
|
|
5418
|
-
|
|
5419
|
-
|
|
5365
|
+
summary: z23.string(),
|
|
5366
|
+
links: z23.array(z23.string()).nullish(),
|
|
5367
|
+
upgradeNotes: z23.string().nullish(),
|
|
5368
|
+
added: z23.array(z23.string()).nullish(),
|
|
5369
|
+
changed: z23.array(z23.string()).nullish(),
|
|
5370
|
+
deprecated: z23.array(z23.string()).nullish(),
|
|
5371
|
+
removed: z23.array(z23.string()).nullish(),
|
|
5372
|
+
fixed: z23.array(z23.string()).nullish()
|
|
5373
|
+
});
|
|
5374
|
+
var YankSchema = z23.object({
|
|
5375
|
+
remediationVerision: z23.string().nullish()
|
|
5376
|
+
});
|
|
5377
|
+
var ReleaseTypeSchema = z23.enum(["GA", "RC"]);
|
|
5378
|
+
var VersionRangeSchema = z23.discriminatedUnion("type", [
|
|
5379
|
+
z23.object({ type: z23.literal("inclusive"), value: z23.string() }),
|
|
5380
|
+
z23.object({ type: z23.literal("exclusive"), value: z23.string() })
|
|
5420
5381
|
]);
|
|
5421
|
-
var GeneratorSchema =
|
|
5422
|
-
id:
|
|
5423
|
-
displayName:
|
|
5382
|
+
var GeneratorSchema = z23.object({
|
|
5383
|
+
id: z23.string(),
|
|
5384
|
+
displayName: z23.string(),
|
|
5424
5385
|
generatorType: GeneratorTypeSchema,
|
|
5425
5386
|
generatorLanguage: GeneratorLanguageSchema.nullish(),
|
|
5426
|
-
dockerImage:
|
|
5387
|
+
dockerImage: z23.string(),
|
|
5427
5388
|
scripts: GeneratorScriptsSchema.nullish()
|
|
5428
5389
|
});
|
|
5429
|
-
var GeneratorOutputSchema =
|
|
5430
|
-
id:
|
|
5431
|
-
displayName:
|
|
5390
|
+
var GeneratorOutputSchema = z23.object({
|
|
5391
|
+
id: z23.string(),
|
|
5392
|
+
displayName: z23.string(),
|
|
5432
5393
|
generatorType: GeneratorTypeSchema,
|
|
5433
5394
|
generatorLanguage: GeneratorLanguageSchema.nullish(),
|
|
5434
|
-
dockerImage:
|
|
5395
|
+
dockerImage: z23.string(),
|
|
5435
5396
|
scripts: GeneratorScriptsSchema.nullish()
|
|
5436
5397
|
});
|
|
5437
|
-
var GetGeneratorByImageInputSchema =
|
|
5438
|
-
dockerImage:
|
|
5398
|
+
var GetGeneratorByImageInputSchema = z23.object({
|
|
5399
|
+
dockerImage: z23.string()
|
|
5439
5400
|
});
|
|
5440
|
-
var GetGeneratorInputSchema =
|
|
5441
|
-
generatorId:
|
|
5401
|
+
var GetGeneratorInputSchema = z23.object({
|
|
5402
|
+
generatorId: z23.string()
|
|
5442
5403
|
});
|
|
5443
|
-
var GeneratorReleaseSchema =
|
|
5444
|
-
version:
|
|
5445
|
-
createdAt:
|
|
5404
|
+
var GeneratorReleaseSchema = z23.object({
|
|
5405
|
+
version: z23.string(),
|
|
5406
|
+
createdAt: z23.string().nullish(),
|
|
5446
5407
|
isYanked: YankSchema.nullish(),
|
|
5447
|
-
changelogEntry:
|
|
5408
|
+
changelogEntry: z23.array(ChangelogEntrySchema).nullish(),
|
|
5448
5409
|
releaseType: ReleaseTypeSchema,
|
|
5449
|
-
majorVersion:
|
|
5450
|
-
generatorId:
|
|
5451
|
-
irVersion:
|
|
5452
|
-
migration:
|
|
5453
|
-
customConfigSchema:
|
|
5454
|
-
tags:
|
|
5455
|
-
});
|
|
5456
|
-
var GeneratorReleaseRequestSchema =
|
|
5457
|
-
version:
|
|
5458
|
-
createdAt:
|
|
5410
|
+
majorVersion: z23.number(),
|
|
5411
|
+
generatorId: z23.string(),
|
|
5412
|
+
irVersion: z23.number(),
|
|
5413
|
+
migration: z23.string().nullish(),
|
|
5414
|
+
customConfigSchema: z23.string().nullish(),
|
|
5415
|
+
tags: z23.array(z23.string()).nullish()
|
|
5416
|
+
});
|
|
5417
|
+
var GeneratorReleaseRequestSchema = z23.object({
|
|
5418
|
+
version: z23.string(),
|
|
5419
|
+
createdAt: z23.string().nullish(),
|
|
5459
5420
|
isYanked: YankSchema.nullish(),
|
|
5460
|
-
changelogEntry:
|
|
5461
|
-
generatorId:
|
|
5462
|
-
irVersion:
|
|
5463
|
-
migration:
|
|
5464
|
-
customConfigSchema:
|
|
5465
|
-
tags:
|
|
5466
|
-
});
|
|
5467
|
-
var GetLatestGeneratorReleaseInputSchema =
|
|
5468
|
-
generator:
|
|
5469
|
-
cliVersion:
|
|
5470
|
-
irVersion:
|
|
5471
|
-
generatorMajorVersion:
|
|
5472
|
-
releaseTypes:
|
|
5473
|
-
});
|
|
5474
|
-
var GetGeneratorChangelogInputSchema =
|
|
5475
|
-
generator:
|
|
5421
|
+
changelogEntry: z23.array(ChangelogEntrySchema).nullish(),
|
|
5422
|
+
generatorId: z23.string(),
|
|
5423
|
+
irVersion: z23.number(),
|
|
5424
|
+
migration: z23.string().nullish(),
|
|
5425
|
+
customConfigSchema: z23.string().nullish(),
|
|
5426
|
+
tags: z23.array(z23.string()).nullish()
|
|
5427
|
+
});
|
|
5428
|
+
var GetLatestGeneratorReleaseInputSchema = z23.object({
|
|
5429
|
+
generator: z23.string(),
|
|
5430
|
+
cliVersion: z23.string().nullish(),
|
|
5431
|
+
irVersion: z23.number().nullish(),
|
|
5432
|
+
generatorMajorVersion: z23.number().nullish(),
|
|
5433
|
+
releaseTypes: z23.array(ReleaseTypeSchema).nullish()
|
|
5434
|
+
});
|
|
5435
|
+
var GetGeneratorChangelogInputSchema = z23.object({
|
|
5436
|
+
generator: z23.string(),
|
|
5476
5437
|
fromVersion: VersionRangeSchema,
|
|
5477
5438
|
toVersion: VersionRangeSchema
|
|
5478
5439
|
});
|
|
5479
|
-
var ChangelogResponseSchema =
|
|
5480
|
-
version:
|
|
5481
|
-
changelogEntry:
|
|
5440
|
+
var ChangelogResponseSchema = z23.object({
|
|
5441
|
+
version: z23.string(),
|
|
5442
|
+
changelogEntry: z23.array(ChangelogEntrySchema)
|
|
5482
5443
|
});
|
|
5483
|
-
var GetChangelogResponseSchema =
|
|
5484
|
-
entries:
|
|
5444
|
+
var GetChangelogResponseSchema = z23.object({
|
|
5445
|
+
entries: z23.array(ChangelogResponseSchema)
|
|
5485
5446
|
});
|
|
5486
|
-
var GetGeneratorReleaseInputSchema =
|
|
5487
|
-
generator:
|
|
5488
|
-
version:
|
|
5447
|
+
var GetGeneratorReleaseInputSchema = z23.object({
|
|
5448
|
+
generator: z23.string(),
|
|
5449
|
+
version: z23.string()
|
|
5489
5450
|
});
|
|
5490
|
-
var ListGeneratorReleasesInputSchema =
|
|
5491
|
-
generator:
|
|
5492
|
-
page:
|
|
5493
|
-
pageSize:
|
|
5451
|
+
var ListGeneratorReleasesInputSchema = z23.object({
|
|
5452
|
+
generator: z23.string(),
|
|
5453
|
+
page: z23.coerce.number().nullish(),
|
|
5454
|
+
pageSize: z23.coerce.number().nullish()
|
|
5494
5455
|
});
|
|
5495
|
-
var ListGeneratorReleasesResponseSchema =
|
|
5496
|
-
generatorReleases:
|
|
5456
|
+
var ListGeneratorReleasesResponseSchema = z23.object({
|
|
5457
|
+
generatorReleases: z23.array(GeneratorReleaseSchema)
|
|
5497
5458
|
});
|
|
5498
|
-
var CliReleaseSchema =
|
|
5499
|
-
version:
|
|
5500
|
-
createdAt:
|
|
5459
|
+
var CliReleaseSchema = z23.object({
|
|
5460
|
+
version: z23.string(),
|
|
5461
|
+
createdAt: z23.string().nullish(),
|
|
5501
5462
|
isYanked: YankSchema.nullish(),
|
|
5502
|
-
changelogEntry:
|
|
5463
|
+
changelogEntry: z23.array(ChangelogEntrySchema).nullish(),
|
|
5503
5464
|
releaseType: ReleaseTypeSchema,
|
|
5504
|
-
majorVersion:
|
|
5505
|
-
irVersion:
|
|
5506
|
-
tags:
|
|
5465
|
+
majorVersion: z23.number(),
|
|
5466
|
+
irVersion: z23.number(),
|
|
5467
|
+
tags: z23.array(z23.string()).nullish()
|
|
5507
5468
|
});
|
|
5508
|
-
var GetLatestCliReleaseInputSchema =
|
|
5509
|
-
releaseTypes:
|
|
5510
|
-
irVersion:
|
|
5469
|
+
var GetLatestCliReleaseInputSchema = z23.object({
|
|
5470
|
+
releaseTypes: z23.array(ReleaseTypeSchema).nullish(),
|
|
5471
|
+
irVersion: z23.number().nullish()
|
|
5511
5472
|
});
|
|
5512
|
-
var GetCliChangelogInputSchema =
|
|
5473
|
+
var GetCliChangelogInputSchema = z23.object({
|
|
5513
5474
|
fromVersion: VersionRangeSchema,
|
|
5514
5475
|
toVersion: VersionRangeSchema
|
|
5515
5476
|
});
|
|
5516
|
-
var GetMinCliForIrInputSchema =
|
|
5517
|
-
irVersion:
|
|
5477
|
+
var GetMinCliForIrInputSchema = z23.object({
|
|
5478
|
+
irVersion: z23.coerce.number()
|
|
5518
5479
|
});
|
|
5519
|
-
var UpsertCliReleaseInputSchema =
|
|
5520
|
-
version:
|
|
5521
|
-
createdAt:
|
|
5480
|
+
var UpsertCliReleaseInputSchema = z23.object({
|
|
5481
|
+
version: z23.string(),
|
|
5482
|
+
createdAt: z23.string().nullish(),
|
|
5522
5483
|
isYanked: YankSchema.nullish(),
|
|
5523
|
-
changelogEntry:
|
|
5524
|
-
irVersion:
|
|
5525
|
-
tags:
|
|
5484
|
+
changelogEntry: z23.array(ChangelogEntrySchema).nullish(),
|
|
5485
|
+
irVersion: z23.number(),
|
|
5486
|
+
tags: z23.array(z23.string()).nullish()
|
|
5526
5487
|
});
|
|
5527
|
-
var GetCliReleaseInputSchema =
|
|
5528
|
-
cliVersion:
|
|
5488
|
+
var GetCliReleaseInputSchema = z23.object({
|
|
5489
|
+
cliVersion: z23.string()
|
|
5529
5490
|
});
|
|
5530
|
-
var ListCliReleasesInputSchema =
|
|
5531
|
-
page:
|
|
5532
|
-
pageSize:
|
|
5491
|
+
var ListCliReleasesInputSchema = z23.object({
|
|
5492
|
+
page: z23.coerce.number().nullish(),
|
|
5493
|
+
pageSize: z23.coerce.number().nullish()
|
|
5533
5494
|
});
|
|
5534
|
-
var ListCliReleasesResponseSchema =
|
|
5535
|
-
cliReleases:
|
|
5495
|
+
var ListCliReleasesResponseSchema = z23.object({
|
|
5496
|
+
cliReleases: z23.array(CliReleaseSchema)
|
|
5536
5497
|
});
|
|
5537
5498
|
var generatorsContract = {
|
|
5538
|
-
upsertGenerator:
|
|
5539
|
-
getGeneratorByImage:
|
|
5540
|
-
getGenerator:
|
|
5541
|
-
listGenerators:
|
|
5499
|
+
upsertGenerator: import_contract23.oc.route({ method: "PUT", path: "/" }).input(GeneratorSchema).output(z23.void()),
|
|
5500
|
+
getGeneratorByImage: import_contract23.oc.route({ method: "POST", path: "/by-image" }).input(GetGeneratorByImageInputSchema).output(GeneratorOutputSchema.nullish()),
|
|
5501
|
+
getGenerator: import_contract23.oc.route({ method: "GET", path: "/{generatorId}" }).input(GetGeneratorInputSchema).output(GeneratorOutputSchema.nullish()),
|
|
5502
|
+
listGenerators: import_contract23.oc.route({ method: "GET", path: "/" }).input(z23.object({})).output(z23.array(GeneratorOutputSchema))
|
|
5542
5503
|
};
|
|
5543
5504
|
var generatorVersionsContract = {
|
|
5544
|
-
getLatestGeneratorRelease:
|
|
5545
|
-
getChangelog:
|
|
5546
|
-
upsertGeneratorRelease:
|
|
5547
|
-
getGeneratorRelease:
|
|
5548
|
-
listGeneratorReleases:
|
|
5505
|
+
getLatestGeneratorRelease: import_contract23.oc.route({ method: "POST", path: "/latest" }).input(GetLatestGeneratorReleaseInputSchema).output(GeneratorReleaseSchema),
|
|
5506
|
+
getChangelog: import_contract23.oc.route({ method: "POST", path: "/{generator}/changelog" }).input(GetGeneratorChangelogInputSchema).output(GetChangelogResponseSchema),
|
|
5507
|
+
upsertGeneratorRelease: import_contract23.oc.route({ method: "PUT", path: "/" }).input(GeneratorReleaseRequestSchema).output(z23.void()),
|
|
5508
|
+
getGeneratorRelease: import_contract23.oc.route({ method: "GET", path: "/{generator}/{version}" }).input(GetGeneratorReleaseInputSchema).output(GeneratorReleaseSchema),
|
|
5509
|
+
listGeneratorReleases: import_contract23.oc.route({ method: "GET", path: "/{generator}" }).input(ListGeneratorReleasesInputSchema).output(ListGeneratorReleasesResponseSchema)
|
|
5549
5510
|
};
|
|
5550
5511
|
var generatorCliContract = {
|
|
5551
|
-
getLatestCliRelease:
|
|
5552
|
-
getChangelog:
|
|
5553
|
-
getMinCliForIr:
|
|
5554
|
-
upsertCliRelease:
|
|
5555
|
-
getCliRelease:
|
|
5556
|
-
listCliReleases:
|
|
5512
|
+
getLatestCliRelease: import_contract23.oc.route({ method: "POST", path: "/latest" }).input(GetLatestCliReleaseInputSchema).output(CliReleaseSchema),
|
|
5513
|
+
getChangelog: import_contract23.oc.route({ method: "POST", path: "/changelog" }).input(GetCliChangelogInputSchema).output(GetChangelogResponseSchema),
|
|
5514
|
+
getMinCliForIr: import_contract23.oc.route({ method: "GET", path: "/for-ir/{irVersion}" }).input(GetMinCliForIrInputSchema).output(CliReleaseSchema),
|
|
5515
|
+
upsertCliRelease: import_contract23.oc.route({ method: "PUT", path: "/" }).input(UpsertCliReleaseInputSchema).output(z23.void()),
|
|
5516
|
+
getCliRelease: import_contract23.oc.route({ method: "GET", path: "/{cliVersion}" }).input(GetCliReleaseInputSchema).output(CliReleaseSchema),
|
|
5517
|
+
listCliReleases: import_contract23.oc.route({ method: "GET", path: "/" }).input(ListCliReleasesInputSchema).output(ListCliReleasesResponseSchema)
|
|
5557
5518
|
};
|
|
5558
5519
|
|
|
5559
5520
|
// src/orpc-client/generators/cli/client.ts
|
|
5560
5521
|
function createGeneratorCliClient(options) {
|
|
5561
|
-
const link = new
|
|
5522
|
+
const link = new import_fetch12.OpenAPILink(generatorCliContract, {
|
|
5562
5523
|
url: `${options.baseUrl}/generators/cli`,
|
|
5563
5524
|
headers: () => ({
|
|
5564
5525
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -5566,14 +5527,14 @@ function createGeneratorCliClient(options) {
|
|
|
5566
5527
|
}),
|
|
5567
5528
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
5568
5529
|
});
|
|
5569
|
-
return (0,
|
|
5530
|
+
return (0, import_client17.createORPCClient)(link);
|
|
5570
5531
|
}
|
|
5571
5532
|
|
|
5572
5533
|
// src/orpc-client/generators/client.ts
|
|
5573
|
-
var
|
|
5574
|
-
var
|
|
5534
|
+
var import_client18 = require("@orpc/client");
|
|
5535
|
+
var import_fetch13 = require("@orpc/openapi-client/fetch");
|
|
5575
5536
|
function createGeneratorsRootClient(options) {
|
|
5576
|
-
const link = new
|
|
5537
|
+
const link = new import_fetch13.OpenAPILink(generatorsContract, {
|
|
5577
5538
|
url: `${options.baseUrl}/generators`,
|
|
5578
5539
|
headers: () => ({
|
|
5579
5540
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -5581,14 +5542,14 @@ function createGeneratorsRootClient(options) {
|
|
|
5581
5542
|
}),
|
|
5582
5543
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
5583
5544
|
});
|
|
5584
|
-
return (0,
|
|
5545
|
+
return (0, import_client18.createORPCClient)(link);
|
|
5585
5546
|
}
|
|
5586
5547
|
|
|
5587
5548
|
// src/orpc-client/generators/versions/client.ts
|
|
5588
|
-
var
|
|
5589
|
-
var
|
|
5549
|
+
var import_client19 = require("@orpc/client");
|
|
5550
|
+
var import_fetch14 = require("@orpc/openapi-client/fetch");
|
|
5590
5551
|
function createGeneratorVersionsClient(options) {
|
|
5591
|
-
const link = new
|
|
5552
|
+
const link = new import_fetch14.OpenAPILink(generatorVersionsContract, {
|
|
5592
5553
|
url: `${options.baseUrl}/generators/versions`,
|
|
5593
5554
|
headers: () => ({
|
|
5594
5555
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -5596,135 +5557,135 @@ function createGeneratorVersionsClient(options) {
|
|
|
5596
5557
|
}),
|
|
5597
5558
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
5598
5559
|
});
|
|
5599
|
-
return (0,
|
|
5560
|
+
return (0, import_client19.createORPCClient)(link);
|
|
5600
5561
|
}
|
|
5601
5562
|
|
|
5602
5563
|
// src/orpc-client/git/client.ts
|
|
5603
|
-
var
|
|
5604
|
-
var
|
|
5564
|
+
var import_client20 = require("@orpc/client");
|
|
5565
|
+
var import_fetch15 = require("@orpc/openapi-client/fetch");
|
|
5605
5566
|
|
|
5606
5567
|
// src/orpc-client/git/contract.ts
|
|
5607
|
-
var
|
|
5608
|
-
var
|
|
5609
|
-
var CheckRunSchema =
|
|
5610
|
-
checkId:
|
|
5611
|
-
repositoryOwner:
|
|
5612
|
-
repositoryName:
|
|
5613
|
-
ref:
|
|
5614
|
-
name:
|
|
5615
|
-
status:
|
|
5616
|
-
conclusion:
|
|
5617
|
-
checkRunUrl:
|
|
5618
|
-
createdAt:
|
|
5619
|
-
completedAt:
|
|
5620
|
-
rawCheckRun:
|
|
5621
|
-
});
|
|
5622
|
-
var GithubRepositoryIdSchema =
|
|
5623
|
-
id:
|
|
5624
|
-
});
|
|
5625
|
-
var RepositoryIdSchema =
|
|
5626
|
-
|
|
5568
|
+
var import_contract27 = require("@orpc/contract");
|
|
5569
|
+
var z24 = __toESM(require("zod"), 1);
|
|
5570
|
+
var CheckRunSchema = z24.object({
|
|
5571
|
+
checkId: z24.string(),
|
|
5572
|
+
repositoryOwner: z24.string(),
|
|
5573
|
+
repositoryName: z24.string(),
|
|
5574
|
+
ref: z24.string(),
|
|
5575
|
+
name: z24.string(),
|
|
5576
|
+
status: z24.string(),
|
|
5577
|
+
conclusion: z24.string(),
|
|
5578
|
+
checkRunUrl: z24.string(),
|
|
5579
|
+
createdAt: z24.string(),
|
|
5580
|
+
completedAt: z24.string().nullish(),
|
|
5581
|
+
rawCheckRun: z24.unknown()
|
|
5582
|
+
});
|
|
5583
|
+
var GithubRepositoryIdSchema = z24.object({
|
|
5584
|
+
id: z24.string()
|
|
5585
|
+
});
|
|
5586
|
+
var RepositoryIdSchema = z24.discriminatedUnion("type", [
|
|
5587
|
+
z24.object({ type: z24.literal("github") }).merge(GithubRepositoryIdSchema)
|
|
5627
5588
|
]);
|
|
5628
|
-
var BaseRepositorySchema =
|
|
5589
|
+
var BaseRepositorySchema = z24.object({
|
|
5629
5590
|
id: RepositoryIdSchema,
|
|
5630
|
-
name:
|
|
5631
|
-
owner:
|
|
5632
|
-
fullName:
|
|
5633
|
-
url:
|
|
5634
|
-
repositoryOwnerOrganizationId:
|
|
5635
|
-
defaultBranchChecks:
|
|
5591
|
+
name: z24.string(),
|
|
5592
|
+
owner: z24.string(),
|
|
5593
|
+
fullName: z24.string(),
|
|
5594
|
+
url: z24.string(),
|
|
5595
|
+
repositoryOwnerOrganizationId: z24.string(),
|
|
5596
|
+
defaultBranchChecks: z24.array(CheckRunSchema)
|
|
5636
5597
|
});
|
|
5637
5598
|
var SdkRepositorySchema = BaseRepositorySchema.extend({
|
|
5638
|
-
type:
|
|
5639
|
-
sdkLanguage:
|
|
5599
|
+
type: z24.literal("sdk"),
|
|
5600
|
+
sdkLanguage: z24.string()
|
|
5640
5601
|
});
|
|
5641
5602
|
var FernConfigRepositorySchema = BaseRepositorySchema.extend({
|
|
5642
|
-
type:
|
|
5603
|
+
type: z24.literal("config")
|
|
5643
5604
|
});
|
|
5644
|
-
var FernRepositorySchema =
|
|
5645
|
-
var GithubUserSchema =
|
|
5646
|
-
name:
|
|
5647
|
-
email:
|
|
5648
|
-
username:
|
|
5605
|
+
var FernRepositorySchema = z24.discriminatedUnion("type", [SdkRepositorySchema, FernConfigRepositorySchema]);
|
|
5606
|
+
var GithubUserSchema = z24.object({
|
|
5607
|
+
name: z24.string().nullish(),
|
|
5608
|
+
email: z24.string().nullish(),
|
|
5609
|
+
username: z24.string()
|
|
5649
5610
|
});
|
|
5650
|
-
var GithubTeamSchema =
|
|
5651
|
-
name:
|
|
5652
|
-
teamId:
|
|
5611
|
+
var GithubTeamSchema = z24.object({
|
|
5612
|
+
name: z24.string(),
|
|
5613
|
+
teamId: z24.string()
|
|
5653
5614
|
});
|
|
5654
|
-
var PullRequestReviewerSchema =
|
|
5655
|
-
|
|
5656
|
-
|
|
5615
|
+
var PullRequestReviewerSchema = z24.discriminatedUnion("type", [
|
|
5616
|
+
z24.object({ type: z24.literal("user") }).merge(GithubUserSchema),
|
|
5617
|
+
z24.object({ type: z24.literal("team") }).merge(GithubTeamSchema)
|
|
5657
5618
|
]);
|
|
5658
|
-
var PullRequestStateSchema =
|
|
5619
|
+
var PullRequestStateSchema = z24.enum(["open", "closed", "merged"]);
|
|
5659
5620
|
var PullRequestState = {
|
|
5660
5621
|
Open: "open",
|
|
5661
5622
|
Closed: "closed",
|
|
5662
5623
|
Merged: "merged"
|
|
5663
5624
|
};
|
|
5664
|
-
var PullRequestSchema =
|
|
5665
|
-
pullRequestNumber:
|
|
5666
|
-
repositoryName:
|
|
5667
|
-
repositoryOwner:
|
|
5625
|
+
var PullRequestSchema = z24.object({
|
|
5626
|
+
pullRequestNumber: z24.number().int(),
|
|
5627
|
+
repositoryName: z24.string(),
|
|
5628
|
+
repositoryOwner: z24.string(),
|
|
5668
5629
|
author: GithubUserSchema.nullish(),
|
|
5669
|
-
reviewers:
|
|
5670
|
-
title:
|
|
5671
|
-
url:
|
|
5672
|
-
checks:
|
|
5630
|
+
reviewers: z24.array(PullRequestReviewerSchema),
|
|
5631
|
+
title: z24.string(),
|
|
5632
|
+
url: z24.string(),
|
|
5633
|
+
checks: z24.array(CheckRunSchema),
|
|
5673
5634
|
state: PullRequestStateSchema,
|
|
5674
|
-
createdAt:
|
|
5675
|
-
updatedAt:
|
|
5676
|
-
mergedAt:
|
|
5677
|
-
closedAt:
|
|
5678
|
-
});
|
|
5679
|
-
var ListRepositoriesResponseSchema =
|
|
5680
|
-
repositories:
|
|
5681
|
-
});
|
|
5682
|
-
var ListPullRequestsResponseSchema =
|
|
5683
|
-
pullRequests:
|
|
5684
|
-
});
|
|
5685
|
-
var GetRepositoryInputSchema =
|
|
5686
|
-
repositoryOwner:
|
|
5687
|
-
repositoryName:
|
|
5688
|
-
});
|
|
5689
|
-
var ListRepositoriesInputSchema =
|
|
5690
|
-
page:
|
|
5691
|
-
pageSize:
|
|
5692
|
-
organizationId:
|
|
5693
|
-
repositoryName:
|
|
5694
|
-
repositoryOwner:
|
|
5695
|
-
});
|
|
5696
|
-
var DeleteRepositoryInputSchema =
|
|
5697
|
-
repositoryOwner:
|
|
5698
|
-
repositoryName:
|
|
5699
|
-
});
|
|
5700
|
-
var GetPullRequestInputSchema =
|
|
5701
|
-
repositoryOwner:
|
|
5702
|
-
repositoryName:
|
|
5703
|
-
pullRequestNumber:
|
|
5704
|
-
});
|
|
5705
|
-
var ListPullRequestsInputSchema =
|
|
5706
|
-
page:
|
|
5707
|
-
pageSize:
|
|
5708
|
-
repositoryName:
|
|
5709
|
-
repositoryOwner:
|
|
5710
|
-
organizationId:
|
|
5711
|
-
state:
|
|
5712
|
-
author:
|
|
5713
|
-
});
|
|
5714
|
-
var DeletePullRequestInputSchema =
|
|
5715
|
-
repositoryOwner:
|
|
5716
|
-
repositoryName:
|
|
5717
|
-
pullRequestNumber:
|
|
5635
|
+
createdAt: z24.string(),
|
|
5636
|
+
updatedAt: z24.string().nullish(),
|
|
5637
|
+
mergedAt: z24.string().nullish(),
|
|
5638
|
+
closedAt: z24.string().nullish()
|
|
5639
|
+
});
|
|
5640
|
+
var ListRepositoriesResponseSchema = z24.object({
|
|
5641
|
+
repositories: z24.array(FernRepositorySchema)
|
|
5642
|
+
});
|
|
5643
|
+
var ListPullRequestsResponseSchema = z24.object({
|
|
5644
|
+
pullRequests: z24.array(PullRequestSchema)
|
|
5645
|
+
});
|
|
5646
|
+
var GetRepositoryInputSchema = z24.object({
|
|
5647
|
+
repositoryOwner: z24.string(),
|
|
5648
|
+
repositoryName: z24.string()
|
|
5649
|
+
});
|
|
5650
|
+
var ListRepositoriesInputSchema = z24.object({
|
|
5651
|
+
page: z24.number().int().nullish(),
|
|
5652
|
+
pageSize: z24.number().int().nullish(),
|
|
5653
|
+
organizationId: z24.string().nullish(),
|
|
5654
|
+
repositoryName: z24.string().nullish(),
|
|
5655
|
+
repositoryOwner: z24.string().nullish()
|
|
5656
|
+
});
|
|
5657
|
+
var DeleteRepositoryInputSchema = z24.object({
|
|
5658
|
+
repositoryOwner: z24.string(),
|
|
5659
|
+
repositoryName: z24.string()
|
|
5660
|
+
});
|
|
5661
|
+
var GetPullRequestInputSchema = z24.object({
|
|
5662
|
+
repositoryOwner: z24.string(),
|
|
5663
|
+
repositoryName: z24.string(),
|
|
5664
|
+
pullRequestNumber: z24.coerce.number().int()
|
|
5665
|
+
});
|
|
5666
|
+
var ListPullRequestsInputSchema = z24.object({
|
|
5667
|
+
page: z24.number().int().nullish(),
|
|
5668
|
+
pageSize: z24.number().int().nullish(),
|
|
5669
|
+
repositoryName: z24.string().nullish(),
|
|
5670
|
+
repositoryOwner: z24.string().nullish(),
|
|
5671
|
+
organizationId: z24.string().nullish(),
|
|
5672
|
+
state: z24.array(PullRequestStateSchema).nullish(),
|
|
5673
|
+
author: z24.array(z24.string()).nullish()
|
|
5674
|
+
});
|
|
5675
|
+
var DeletePullRequestInputSchema = z24.object({
|
|
5676
|
+
repositoryOwner: z24.string(),
|
|
5677
|
+
repositoryName: z24.string(),
|
|
5678
|
+
pullRequestNumber: z24.coerce.number().int()
|
|
5718
5679
|
});
|
|
5719
5680
|
var gitContract = {
|
|
5720
|
-
getRepository:
|
|
5721
|
-
listRepositories:
|
|
5722
|
-
upsertRepository:
|
|
5723
|
-
deleteRepository:
|
|
5724
|
-
getPullRequest:
|
|
5725
|
-
listPullRequests:
|
|
5726
|
-
upsertPullRequest:
|
|
5727
|
-
deletePullRequest:
|
|
5681
|
+
getRepository: import_contract27.oc.route({ method: "GET", path: "/repository/{repositoryOwner}/{repositoryName}" }).input(GetRepositoryInputSchema).output(FernRepositorySchema),
|
|
5682
|
+
listRepositories: import_contract27.oc.route({ method: "POST", path: "/repository/list" }).input(ListRepositoriesInputSchema).output(ListRepositoriesResponseSchema),
|
|
5683
|
+
upsertRepository: import_contract27.oc.route({ method: "PUT", path: "/repository/upsert" }).input(FernRepositorySchema),
|
|
5684
|
+
deleteRepository: import_contract27.oc.route({ method: "DELETE", path: "/repository/{repositoryOwner}/{repositoryName}/delete" }).input(DeleteRepositoryInputSchema),
|
|
5685
|
+
getPullRequest: import_contract27.oc.route({ method: "GET", path: "/pull-request/{repositoryOwner}/{repositoryName}/{pullRequestNumber}" }).input(GetPullRequestInputSchema).output(PullRequestSchema),
|
|
5686
|
+
listPullRequests: import_contract27.oc.route({ method: "POST", path: "/pull-request/list" }).input(ListPullRequestsInputSchema).output(ListPullRequestsResponseSchema),
|
|
5687
|
+
upsertPullRequest: import_contract27.oc.route({ method: "PUT", path: "/pull-request/upsert" }).input(PullRequestSchema),
|
|
5688
|
+
deletePullRequest: import_contract27.oc.route({
|
|
5728
5689
|
method: "DELETE",
|
|
5729
5690
|
path: "/pull-request/{repositoryOwner}/{repositoryName}/{pullRequestNumber}/delete"
|
|
5730
5691
|
}).input(DeletePullRequestInputSchema)
|
|
@@ -5732,7 +5693,7 @@ var gitContract = {
|
|
|
5732
5693
|
|
|
5733
5694
|
// src/orpc-client/git/client.ts
|
|
5734
5695
|
function createGitClient(options) {
|
|
5735
|
-
const link = new
|
|
5696
|
+
const link = new import_fetch15.OpenAPILink(gitContract, {
|
|
5736
5697
|
url: `${options.baseUrl}/generators/github`,
|
|
5737
5698
|
headers: () => ({
|
|
5738
5699
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -5740,106 +5701,106 @@ function createGitClient(options) {
|
|
|
5740
5701
|
}),
|
|
5741
5702
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
5742
5703
|
});
|
|
5743
|
-
return (0,
|
|
5704
|
+
return (0, import_client20.createORPCClient)(link);
|
|
5744
5705
|
}
|
|
5745
5706
|
|
|
5746
5707
|
// src/orpc-client/pdf-export/client.ts
|
|
5747
|
-
var
|
|
5748
|
-
var
|
|
5708
|
+
var import_client21 = require("@orpc/client");
|
|
5709
|
+
var import_fetch16 = require("@orpc/openapi-client/fetch");
|
|
5749
5710
|
|
|
5750
5711
|
// src/orpc-client/pdf-export/contract.ts
|
|
5751
|
-
var
|
|
5752
|
-
var
|
|
5753
|
-
var PdfExportScopeSchema =
|
|
5754
|
-
pageSlugs:
|
|
5755
|
-
});
|
|
5756
|
-
var PdfExportOptionsV1Schema =
|
|
5757
|
-
coverTitle:
|
|
5758
|
-
coverSubtitle:
|
|
5759
|
-
hideCoverFooter:
|
|
5760
|
-
headerLeftTemplate:
|
|
5761
|
-
headerRightTemplate:
|
|
5762
|
-
footerLeftTemplate:
|
|
5763
|
-
footerRightTemplate:
|
|
5712
|
+
var import_contract29 = require("@orpc/contract");
|
|
5713
|
+
var z25 = __toESM(require("zod"), 1);
|
|
5714
|
+
var PdfExportScopeSchema = z25.object({
|
|
5715
|
+
pageSlugs: z25.array(z25.string())
|
|
5716
|
+
});
|
|
5717
|
+
var PdfExportOptionsV1Schema = z25.object({
|
|
5718
|
+
coverTitle: z25.string().nullish(),
|
|
5719
|
+
coverSubtitle: z25.string().nullish(),
|
|
5720
|
+
hideCoverFooter: z25.boolean().nullish(),
|
|
5721
|
+
headerLeftTemplate: z25.string().nullish(),
|
|
5722
|
+
headerRightTemplate: z25.string().nullish(),
|
|
5723
|
+
footerLeftTemplate: z25.string().nullish(),
|
|
5724
|
+
footerRightTemplate: z25.string().nullish(),
|
|
5764
5725
|
scope: PdfExportScopeSchema.nullish(),
|
|
5765
|
-
hideCover:
|
|
5766
|
-
hideToc:
|
|
5726
|
+
hideCover: z25.boolean().nullish(),
|
|
5727
|
+
hideToc: z25.boolean().nullish()
|
|
5767
5728
|
});
|
|
5768
|
-
var PdfExportOptionsSchema =
|
|
5769
|
-
|
|
5729
|
+
var PdfExportOptionsSchema = z25.discriminatedUnion("version", [
|
|
5730
|
+
z25.object({ version: z25.literal("v1") }).merge(PdfExportOptionsV1Schema)
|
|
5770
5731
|
]);
|
|
5771
|
-
var PdfExportTaskStatusSchema =
|
|
5772
|
-
var PdfExportTaskSchema =
|
|
5773
|
-
id:
|
|
5774
|
-
orgId:
|
|
5775
|
-
docsUrl:
|
|
5776
|
-
productId:
|
|
5777
|
-
versionId:
|
|
5778
|
-
requesterName:
|
|
5779
|
-
notifyEmails:
|
|
5732
|
+
var PdfExportTaskStatusSchema = z25.enum(["PENDING", "RUNNING", "COMPLETED", "FAILED"]);
|
|
5733
|
+
var PdfExportTaskSchema = z25.object({
|
|
5734
|
+
id: z25.string(),
|
|
5735
|
+
orgId: z25.string(),
|
|
5736
|
+
docsUrl: z25.string(),
|
|
5737
|
+
productId: z25.string().nullish(),
|
|
5738
|
+
versionId: z25.string().nullish(),
|
|
5739
|
+
requesterName: z25.string().nullish(),
|
|
5740
|
+
notifyEmails: z25.array(z25.string()).nullish(),
|
|
5780
5741
|
status: PdfExportTaskStatusSchema,
|
|
5781
5742
|
options: PdfExportOptionsSchema.nullish(),
|
|
5782
|
-
createdAt:
|
|
5783
|
-
startedAt:
|
|
5784
|
-
completedAt:
|
|
5785
|
-
fileName:
|
|
5786
|
-
sizeBytes:
|
|
5787
|
-
errorMessage:
|
|
5788
|
-
});
|
|
5789
|
-
var ListPdfExportTasksResponseSchema =
|
|
5790
|
-
tasks:
|
|
5791
|
-
});
|
|
5792
|
-
var PdfExportDownloadResponseSchema =
|
|
5793
|
-
downloadUrl:
|
|
5794
|
-
fileName:
|
|
5795
|
-
sizeBytes:
|
|
5796
|
-
});
|
|
5797
|
-
var CreatePdfExportTaskInputSchema =
|
|
5798
|
-
orgId:
|
|
5799
|
-
docsUrl:
|
|
5800
|
-
productId:
|
|
5801
|
-
versionId:
|
|
5802
|
-
requesterName:
|
|
5743
|
+
createdAt: z25.string(),
|
|
5744
|
+
startedAt: z25.string().nullish(),
|
|
5745
|
+
completedAt: z25.string().nullish(),
|
|
5746
|
+
fileName: z25.string().nullish(),
|
|
5747
|
+
sizeBytes: z25.number().nullish(),
|
|
5748
|
+
errorMessage: z25.string().nullish()
|
|
5749
|
+
});
|
|
5750
|
+
var ListPdfExportTasksResponseSchema = z25.object({
|
|
5751
|
+
tasks: z25.array(PdfExportTaskSchema)
|
|
5752
|
+
});
|
|
5753
|
+
var PdfExportDownloadResponseSchema = z25.object({
|
|
5754
|
+
downloadUrl: z25.string(),
|
|
5755
|
+
fileName: z25.string(),
|
|
5756
|
+
sizeBytes: z25.number()
|
|
5757
|
+
});
|
|
5758
|
+
var CreatePdfExportTaskInputSchema = z25.object({
|
|
5759
|
+
orgId: z25.string(),
|
|
5760
|
+
docsUrl: z25.string(),
|
|
5761
|
+
productId: z25.string().nullish(),
|
|
5762
|
+
versionId: z25.string().nullish(),
|
|
5763
|
+
requesterName: z25.string().nullish(),
|
|
5803
5764
|
options: PdfExportOptionsSchema.nullish()
|
|
5804
5765
|
});
|
|
5805
|
-
var ListPdfExportTasksInputSchema =
|
|
5806
|
-
orgId:
|
|
5807
|
-
docsUrl:
|
|
5808
|
-
limit:
|
|
5766
|
+
var ListPdfExportTasksInputSchema = z25.object({
|
|
5767
|
+
orgId: z25.string(),
|
|
5768
|
+
docsUrl: z25.string(),
|
|
5769
|
+
limit: z25.coerce.number().nullish()
|
|
5809
5770
|
});
|
|
5810
|
-
var GetPdfExportTaskInputSchema =
|
|
5811
|
-
taskId:
|
|
5771
|
+
var GetPdfExportTaskInputSchema = z25.object({
|
|
5772
|
+
taskId: z25.string()
|
|
5812
5773
|
});
|
|
5813
|
-
var UpdatePdfExportTaskInputSchema =
|
|
5814
|
-
taskId:
|
|
5774
|
+
var UpdatePdfExportTaskInputSchema = z25.object({
|
|
5775
|
+
taskId: z25.string(),
|
|
5815
5776
|
status: PdfExportTaskStatusSchema,
|
|
5816
|
-
startedAt:
|
|
5817
|
-
completedAt:
|
|
5818
|
-
s3Key:
|
|
5819
|
-
fileName:
|
|
5820
|
-
sizeBytes:
|
|
5821
|
-
errorMessage:
|
|
5777
|
+
startedAt: z25.string().nullish(),
|
|
5778
|
+
completedAt: z25.string().nullish(),
|
|
5779
|
+
s3Key: z25.string().nullish(),
|
|
5780
|
+
fileName: z25.string().nullish(),
|
|
5781
|
+
sizeBytes: z25.number().nullish(),
|
|
5782
|
+
errorMessage: z25.string().nullish()
|
|
5822
5783
|
});
|
|
5823
|
-
var GetPdfExportDownloadUrlInputSchema =
|
|
5824
|
-
taskId:
|
|
5784
|
+
var GetPdfExportDownloadUrlInputSchema = z25.object({
|
|
5785
|
+
taskId: z25.string()
|
|
5825
5786
|
});
|
|
5826
|
-
var CleanupPdfExportsResponseSchema =
|
|
5827
|
-
expiredTasksDeleted:
|
|
5828
|
-
s3ObjectsDeleted:
|
|
5829
|
-
timedOutTasksFailed:
|
|
5787
|
+
var CleanupPdfExportsResponseSchema = z25.object({
|
|
5788
|
+
expiredTasksDeleted: z25.number(),
|
|
5789
|
+
s3ObjectsDeleted: z25.number(),
|
|
5790
|
+
timedOutTasksFailed: z25.number()
|
|
5830
5791
|
});
|
|
5831
5792
|
var pdfExportContract = {
|
|
5832
|
-
createTask:
|
|
5833
|
-
listTasks:
|
|
5834
|
-
getTask:
|
|
5835
|
-
updateTask:
|
|
5836
|
-
getDownloadUrl:
|
|
5837
|
-
cleanup:
|
|
5793
|
+
createTask: import_contract29.oc.route({ method: "POST", path: "/task" }).input(CreatePdfExportTaskInputSchema).output(PdfExportTaskSchema),
|
|
5794
|
+
listTasks: import_contract29.oc.route({ method: "GET", path: "/tasks" }).input(ListPdfExportTasksInputSchema).output(ListPdfExportTasksResponseSchema),
|
|
5795
|
+
getTask: import_contract29.oc.route({ method: "GET", path: "/task/{taskId}" }).input(GetPdfExportTaskInputSchema).output(PdfExportTaskSchema),
|
|
5796
|
+
updateTask: import_contract29.oc.route({ method: "POST", path: "/task/{taskId}" }).input(UpdatePdfExportTaskInputSchema).output(PdfExportTaskSchema),
|
|
5797
|
+
getDownloadUrl: import_contract29.oc.route({ method: "GET", path: "/task/{taskId}/download-url" }).input(GetPdfExportDownloadUrlInputSchema).output(PdfExportDownloadResponseSchema),
|
|
5798
|
+
cleanup: import_contract29.oc.route({ method: "POST", path: "/cleanup" }).output(CleanupPdfExportsResponseSchema)
|
|
5838
5799
|
};
|
|
5839
5800
|
|
|
5840
5801
|
// src/orpc-client/pdf-export/client.ts
|
|
5841
5802
|
function createPdfExportClient(options) {
|
|
5842
|
-
const link = new
|
|
5803
|
+
const link = new import_fetch16.OpenAPILink(pdfExportContract, {
|
|
5843
5804
|
url: `${options.baseUrl}/pdf-export`,
|
|
5844
5805
|
headers: () => ({
|
|
5845
5806
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -5847,17 +5808,17 @@ function createPdfExportClient(options) {
|
|
|
5847
5808
|
}),
|
|
5848
5809
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
5849
5810
|
});
|
|
5850
|
-
return (0,
|
|
5811
|
+
return (0, import_client21.createORPCClient)(link);
|
|
5851
5812
|
}
|
|
5852
5813
|
|
|
5853
5814
|
// src/orpc-client/sdks/client.ts
|
|
5854
|
-
var
|
|
5855
|
-
var
|
|
5815
|
+
var import_client22 = require("@orpc/client");
|
|
5816
|
+
var import_fetch17 = require("@orpc/openapi-client/fetch");
|
|
5856
5817
|
|
|
5857
5818
|
// src/orpc-client/sdks/contract.ts
|
|
5858
|
-
var
|
|
5859
|
-
var
|
|
5860
|
-
var LanguageEnumSchema =
|
|
5819
|
+
var import_contract31 = require("@orpc/contract");
|
|
5820
|
+
var z26 = __toESM(require("zod"), 1);
|
|
5821
|
+
var LanguageEnumSchema = z26.enum([
|
|
5861
5822
|
"Go",
|
|
5862
5823
|
"TypeScript",
|
|
5863
5824
|
"Java",
|
|
@@ -5868,23 +5829,23 @@ var LanguageEnumSchema = z27.enum([
|
|
|
5868
5829
|
"Swift",
|
|
5869
5830
|
"Rust"
|
|
5870
5831
|
]);
|
|
5871
|
-
var VersionBumpEnumSchema =
|
|
5872
|
-
var ComputeSemanticVersionInputSchema =
|
|
5873
|
-
package:
|
|
5832
|
+
var VersionBumpEnumSchema = z26.enum(["MAJOR", "MINOR", "PATCH"]);
|
|
5833
|
+
var ComputeSemanticVersionInputSchema = z26.object({
|
|
5834
|
+
package: z26.string(),
|
|
5874
5835
|
language: LanguageEnumSchema,
|
|
5875
|
-
githubRepository:
|
|
5836
|
+
githubRepository: z26.string().nullish()
|
|
5876
5837
|
});
|
|
5877
|
-
var ComputeSemanticVersionOutputSchema =
|
|
5878
|
-
version:
|
|
5838
|
+
var ComputeSemanticVersionOutputSchema = z26.object({
|
|
5839
|
+
version: z26.string(),
|
|
5879
5840
|
bump: VersionBumpEnumSchema
|
|
5880
5841
|
});
|
|
5881
5842
|
var sdksContract = {
|
|
5882
|
-
computeSemanticVersion:
|
|
5843
|
+
computeSemanticVersion: import_contract31.oc.route({ method: "POST", path: "/semantic-version/compute" }).input(ComputeSemanticVersionInputSchema).output(ComputeSemanticVersionOutputSchema)
|
|
5883
5844
|
};
|
|
5884
5845
|
|
|
5885
5846
|
// src/orpc-client/sdks/client.ts
|
|
5886
5847
|
function createSdksClient(options) {
|
|
5887
|
-
const link = new
|
|
5848
|
+
const link = new import_fetch17.OpenAPILink(sdksContract, {
|
|
5888
5849
|
url: `${options.baseUrl}/sdks`,
|
|
5889
5850
|
headers: () => ({
|
|
5890
5851
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -5892,50 +5853,50 @@ function createSdksClient(options) {
|
|
|
5892
5853
|
}),
|
|
5893
5854
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
5894
5855
|
});
|
|
5895
|
-
return (0,
|
|
5856
|
+
return (0, import_client22.createORPCClient)(link);
|
|
5896
5857
|
}
|
|
5897
5858
|
|
|
5898
5859
|
// src/orpc-client/slugs/client.ts
|
|
5899
|
-
var
|
|
5900
|
-
var
|
|
5860
|
+
var import_client23 = require("@orpc/client");
|
|
5861
|
+
var import_fetch18 = require("@orpc/openapi-client/fetch");
|
|
5901
5862
|
|
|
5902
5863
|
// src/orpc-client/slugs/contract.ts
|
|
5903
|
-
var
|
|
5904
|
-
var
|
|
5905
|
-
var SlugsInputSchema =
|
|
5906
|
-
domain:
|
|
5907
|
-
basepath:
|
|
5908
|
-
});
|
|
5909
|
-
var SlugEntrySchema =
|
|
5910
|
-
orgId:
|
|
5911
|
-
domain:
|
|
5912
|
-
basepath:
|
|
5913
|
-
slug:
|
|
5914
|
-
lastUpdated:
|
|
5915
|
-
});
|
|
5916
|
-
var MarkdownEntrySchema =
|
|
5917
|
-
orgId:
|
|
5918
|
-
domain:
|
|
5919
|
-
basepath:
|
|
5920
|
-
pageId:
|
|
5921
|
-
slug:
|
|
5922
|
-
hash:
|
|
5923
|
-
lastUpdated:
|
|
5924
|
-
});
|
|
5925
|
-
var GetSlugEntriesResponseSchema =
|
|
5926
|
-
entries:
|
|
5927
|
-
});
|
|
5928
|
-
var GetMarkdownEntriesResponseSchema =
|
|
5929
|
-
entries:
|
|
5864
|
+
var import_contract33 = require("@orpc/contract");
|
|
5865
|
+
var z27 = __toESM(require("zod"), 1);
|
|
5866
|
+
var SlugsInputSchema = z27.object({
|
|
5867
|
+
domain: z27.string(),
|
|
5868
|
+
basepath: z27.string().optional().default("")
|
|
5869
|
+
});
|
|
5870
|
+
var SlugEntrySchema = z27.object({
|
|
5871
|
+
orgId: z27.string(),
|
|
5872
|
+
domain: z27.string(),
|
|
5873
|
+
basepath: z27.string(),
|
|
5874
|
+
slug: z27.string(),
|
|
5875
|
+
lastUpdated: z27.string()
|
|
5876
|
+
});
|
|
5877
|
+
var MarkdownEntrySchema = z27.object({
|
|
5878
|
+
orgId: z27.string(),
|
|
5879
|
+
domain: z27.string(),
|
|
5880
|
+
basepath: z27.string(),
|
|
5881
|
+
pageId: z27.string(),
|
|
5882
|
+
slug: z27.string(),
|
|
5883
|
+
hash: z27.string(),
|
|
5884
|
+
lastUpdated: z27.string()
|
|
5885
|
+
});
|
|
5886
|
+
var GetSlugEntriesResponseSchema = z27.object({
|
|
5887
|
+
entries: z27.array(SlugEntrySchema)
|
|
5888
|
+
});
|
|
5889
|
+
var GetMarkdownEntriesResponseSchema = z27.object({
|
|
5890
|
+
entries: z27.array(MarkdownEntrySchema)
|
|
5930
5891
|
});
|
|
5931
5892
|
var slugsContract = {
|
|
5932
|
-
getSlugEntries:
|
|
5933
|
-
getMarkdownEntries:
|
|
5893
|
+
getSlugEntries: import_contract33.oc.route({ method: "POST", path: "/slugs" }).input(SlugsInputSchema).output(GetSlugEntriesResponseSchema),
|
|
5894
|
+
getMarkdownEntries: import_contract33.oc.route({ method: "POST", path: "/markdowns" }).input(SlugsInputSchema).output(GetMarkdownEntriesResponseSchema)
|
|
5934
5895
|
};
|
|
5935
5896
|
|
|
5936
5897
|
// src/orpc-client/slugs/client.ts
|
|
5937
5898
|
function createSlugsClient(options) {
|
|
5938
|
-
const link = new
|
|
5899
|
+
const link = new import_fetch18.OpenAPILink(slugsContract, {
|
|
5939
5900
|
url: `${options.baseUrl.replace(/\/+$/, "")}/slugs`,
|
|
5940
5901
|
headers: () => ({
|
|
5941
5902
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -5943,118 +5904,118 @@ function createSlugsClient(options) {
|
|
|
5943
5904
|
}),
|
|
5944
5905
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
5945
5906
|
});
|
|
5946
|
-
return (0,
|
|
5907
|
+
return (0, import_client23.createORPCClient)(link);
|
|
5947
5908
|
}
|
|
5948
5909
|
|
|
5949
5910
|
// src/orpc-client/snippets/client.ts
|
|
5950
|
-
var
|
|
5951
|
-
var
|
|
5911
|
+
var import_client24 = require("@orpc/client");
|
|
5912
|
+
var import_fetch19 = require("@orpc/openapi-client/fetch");
|
|
5952
5913
|
|
|
5953
5914
|
// src/orpc-client/snippets/contract.ts
|
|
5954
|
-
var
|
|
5955
|
-
var
|
|
5956
|
-
var TypeScriptSdkSchema =
|
|
5957
|
-
var PythonSdkSchema =
|
|
5958
|
-
var GoSdkSchema =
|
|
5959
|
-
var RubySdkSchema =
|
|
5960
|
-
var JavaSdkSchema =
|
|
5961
|
-
var CsharpSdkSchema =
|
|
5962
|
-
var BaseSnippetCreateSchema =
|
|
5915
|
+
var import_contract35 = require("@orpc/contract");
|
|
5916
|
+
var z28 = __toESM(require("zod"), 1);
|
|
5917
|
+
var TypeScriptSdkSchema = z28.object({ package: z28.string(), version: z28.string() });
|
|
5918
|
+
var PythonSdkSchema = z28.object({ package: z28.string(), version: z28.string() });
|
|
5919
|
+
var GoSdkSchema = z28.object({ githubRepo: z28.string(), version: z28.string() });
|
|
5920
|
+
var RubySdkSchema = z28.object({ gem: z28.string(), version: z28.string() });
|
|
5921
|
+
var JavaSdkSchema = z28.object({ group: z28.string(), artifact: z28.string(), version: z28.string() });
|
|
5922
|
+
var CsharpSdkSchema = z28.object({ package: z28.string(), version: z28.string() });
|
|
5923
|
+
var BaseSnippetCreateSchema = z28.object({
|
|
5963
5924
|
endpoint: EndpointIdentifierSchema,
|
|
5964
|
-
exampleIdentifier:
|
|
5925
|
+
exampleIdentifier: z28.string().nullish()
|
|
5965
5926
|
});
|
|
5966
|
-
var SdkSnippetsCreateSchema =
|
|
5967
|
-
|
|
5968
|
-
type:
|
|
5927
|
+
var SdkSnippetsCreateSchema = z28.discriminatedUnion("type", [
|
|
5928
|
+
z28.object({
|
|
5929
|
+
type: z28.literal("typescript"),
|
|
5969
5930
|
sdk: TypeScriptSdkSchema,
|
|
5970
|
-
snippets:
|
|
5931
|
+
snippets: z28.array(BaseSnippetCreateSchema.extend({ snippet: z28.object({ client: z28.string() }) }))
|
|
5971
5932
|
}),
|
|
5972
|
-
|
|
5973
|
-
type:
|
|
5933
|
+
z28.object({
|
|
5934
|
+
type: z28.literal("python"),
|
|
5974
5935
|
sdk: PythonSdkSchema,
|
|
5975
|
-
snippets:
|
|
5936
|
+
snippets: z28.array(
|
|
5976
5937
|
BaseSnippetCreateSchema.extend({
|
|
5977
|
-
snippet:
|
|
5938
|
+
snippet: z28.object({ async_client: z28.string(), sync_client: z28.string() })
|
|
5978
5939
|
})
|
|
5979
5940
|
)
|
|
5980
5941
|
}),
|
|
5981
|
-
|
|
5982
|
-
type:
|
|
5942
|
+
z28.object({
|
|
5943
|
+
type: z28.literal("go"),
|
|
5983
5944
|
sdk: GoSdkSchema,
|
|
5984
|
-
snippets:
|
|
5945
|
+
snippets: z28.array(BaseSnippetCreateSchema.extend({ snippet: z28.object({ client: z28.string() }) }))
|
|
5985
5946
|
}),
|
|
5986
|
-
|
|
5987
|
-
type:
|
|
5947
|
+
z28.object({
|
|
5948
|
+
type: z28.literal("java"),
|
|
5988
5949
|
sdk: JavaSdkSchema,
|
|
5989
|
-
snippets:
|
|
5950
|
+
snippets: z28.array(
|
|
5990
5951
|
BaseSnippetCreateSchema.extend({
|
|
5991
|
-
snippet:
|
|
5952
|
+
snippet: z28.object({ async_client: z28.string(), sync_client: z28.string() })
|
|
5992
5953
|
})
|
|
5993
5954
|
)
|
|
5994
5955
|
}),
|
|
5995
|
-
|
|
5996
|
-
type:
|
|
5956
|
+
z28.object({
|
|
5957
|
+
type: z28.literal("ruby"),
|
|
5997
5958
|
sdk: RubySdkSchema,
|
|
5998
|
-
snippets:
|
|
5959
|
+
snippets: z28.array(BaseSnippetCreateSchema.extend({ snippet: z28.object({ client: z28.string() }) }))
|
|
5999
5960
|
}),
|
|
6000
|
-
|
|
6001
|
-
type:
|
|
5961
|
+
z28.object({
|
|
5962
|
+
type: z28.literal("csharp"),
|
|
6002
5963
|
sdk: CsharpSdkSchema,
|
|
6003
|
-
snippets:
|
|
5964
|
+
snippets: z28.array(BaseSnippetCreateSchema.extend({ snippet: z28.object({ client: z28.string() }) }))
|
|
6004
5965
|
})
|
|
6005
5966
|
]);
|
|
6006
5967
|
var snippetsFactoryContract = {
|
|
6007
|
-
createSnippetsForSdk:
|
|
6008
|
-
|
|
6009
|
-
orgId:
|
|
6010
|
-
apiId:
|
|
5968
|
+
createSnippetsForSdk: import_contract35.oc.route({ method: "POST", path: "/create" }).input(
|
|
5969
|
+
z28.object({
|
|
5970
|
+
orgId: z28.string(),
|
|
5971
|
+
apiId: z28.string(),
|
|
6011
5972
|
snippets: SdkSnippetsCreateSchema
|
|
6012
5973
|
})
|
|
6013
5974
|
)
|
|
6014
5975
|
};
|
|
6015
|
-
var ParameterPayloadSchema =
|
|
6016
|
-
name:
|
|
6017
|
-
value:
|
|
5976
|
+
var ParameterPayloadSchema = z28.object({
|
|
5977
|
+
name: z28.string(),
|
|
5978
|
+
value: z28.unknown()
|
|
6018
5979
|
});
|
|
6019
|
-
var AuthPayloadSchema =
|
|
6020
|
-
|
|
6021
|
-
|
|
5980
|
+
var AuthPayloadSchema = z28.discriminatedUnion("type", [
|
|
5981
|
+
z28.object({ type: z28.literal("bearer"), token: z28.string() }),
|
|
5982
|
+
z28.object({ type: z28.literal("basic"), username: z28.string(), password: z28.string() })
|
|
6022
5983
|
]);
|
|
6023
|
-
var CustomSnippetPayloadSchema =
|
|
6024
|
-
headers:
|
|
6025
|
-
pathParameters:
|
|
6026
|
-
queryParameters:
|
|
6027
|
-
requestBody:
|
|
5984
|
+
var CustomSnippetPayloadSchema = z28.object({
|
|
5985
|
+
headers: z28.array(ParameterPayloadSchema).nullish(),
|
|
5986
|
+
pathParameters: z28.array(ParameterPayloadSchema).nullish(),
|
|
5987
|
+
queryParameters: z28.array(ParameterPayloadSchema).nullish(),
|
|
5988
|
+
requestBody: z28.unknown().nullish(),
|
|
6028
5989
|
auth: AuthPayloadSchema.nullish()
|
|
6029
5990
|
});
|
|
6030
5991
|
var snippetsContract = {
|
|
6031
|
-
get:
|
|
6032
|
-
|
|
6033
|
-
orgId:
|
|
6034
|
-
apiId:
|
|
6035
|
-
sdks:
|
|
5992
|
+
get: import_contract35.oc.route({ method: "POST", path: "/" }).input(
|
|
5993
|
+
z28.object({
|
|
5994
|
+
orgId: z28.string().nullish(),
|
|
5995
|
+
apiId: z28.string().nullish(),
|
|
5996
|
+
sdks: z28.array(SdkRequestSchema).nullish(),
|
|
6036
5997
|
endpoint: EndpointIdentifierSchema,
|
|
6037
|
-
exampleIdentifier:
|
|
5998
|
+
exampleIdentifier: z28.string().nullish(),
|
|
6038
5999
|
payload: CustomSnippetPayloadSchema.nullish()
|
|
6039
6000
|
})
|
|
6040
|
-
).output(
|
|
6041
|
-
load:
|
|
6042
|
-
|
|
6043
|
-
orgId:
|
|
6044
|
-
apiId:
|
|
6045
|
-
sdks:
|
|
6001
|
+
).output(z28.array(z28.unknown())),
|
|
6002
|
+
load: import_contract35.oc.route({ method: "POST", path: "/load" }).input(
|
|
6003
|
+
z28.object({
|
|
6004
|
+
orgId: z28.string().nullish(),
|
|
6005
|
+
apiId: z28.string().nullish(),
|
|
6006
|
+
sdks: z28.array(SdkRequestSchema).nullish()
|
|
6046
6007
|
})
|
|
6047
6008
|
).output(
|
|
6048
|
-
|
|
6049
|
-
next:
|
|
6050
|
-
snippets:
|
|
6009
|
+
z28.object({
|
|
6010
|
+
next: z28.number().nullish(),
|
|
6011
|
+
snippets: z28.record(z28.string(), z28.unknown())
|
|
6051
6012
|
})
|
|
6052
6013
|
)
|
|
6053
6014
|
};
|
|
6054
6015
|
|
|
6055
6016
|
// src/orpc-client/snippets/client.ts
|
|
6056
6017
|
function createSnippetsFactoryClient(options) {
|
|
6057
|
-
const link = new
|
|
6018
|
+
const link = new import_fetch19.OpenAPILink(snippetsFactoryContract, {
|
|
6058
6019
|
url: `${options.baseUrl}/snippets`,
|
|
6059
6020
|
headers: () => ({
|
|
6060
6021
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -6062,10 +6023,10 @@ function createSnippetsFactoryClient(options) {
|
|
|
6062
6023
|
}),
|
|
6063
6024
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
6064
6025
|
});
|
|
6065
|
-
return (0,
|
|
6026
|
+
return (0, import_client24.createORPCClient)(link);
|
|
6066
6027
|
}
|
|
6067
6028
|
function createSnippetsClient(options) {
|
|
6068
|
-
const link = new
|
|
6029
|
+
const link = new import_fetch19.OpenAPILink(snippetsContract, {
|
|
6069
6030
|
url: `${options.baseUrl}/snippets`,
|
|
6070
6031
|
headers: () => ({
|
|
6071
6032
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -6073,63 +6034,63 @@ function createSnippetsClient(options) {
|
|
|
6073
6034
|
}),
|
|
6074
6035
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
6075
6036
|
});
|
|
6076
|
-
return (0,
|
|
6037
|
+
return (0, import_client24.createORPCClient)(link);
|
|
6077
6038
|
}
|
|
6078
6039
|
|
|
6079
6040
|
// src/orpc-client/templates/client.ts
|
|
6080
|
-
var
|
|
6081
|
-
var
|
|
6041
|
+
var import_client25 = require("@orpc/client");
|
|
6042
|
+
var import_fetch20 = require("@orpc/openapi-client/fetch");
|
|
6082
6043
|
|
|
6083
6044
|
// src/orpc-client/templates/contract.ts
|
|
6084
|
-
var
|
|
6085
|
-
var
|
|
6086
|
-
var SnippetRegistryEntrySchema =
|
|
6045
|
+
var import_contract37 = require("@orpc/contract");
|
|
6046
|
+
var z29 = __toESM(require("zod"), 1);
|
|
6047
|
+
var SnippetRegistryEntrySchema = z29.object({
|
|
6087
6048
|
sdk: SdkSchema,
|
|
6088
|
-
endpointId:
|
|
6089
|
-
path:
|
|
6049
|
+
endpointId: z29.object({
|
|
6050
|
+
path: z29.string(),
|
|
6090
6051
|
method: HttpMethodSchema,
|
|
6091
|
-
identifierOverride:
|
|
6052
|
+
identifierOverride: z29.string().nullish()
|
|
6092
6053
|
}),
|
|
6093
|
-
snippetTemplate:
|
|
6094
|
-
type:
|
|
6095
|
-
functionInvocation:
|
|
6096
|
-
clientInstantiation:
|
|
6054
|
+
snippetTemplate: z29.object({
|
|
6055
|
+
type: z29.literal("v1"),
|
|
6056
|
+
functionInvocation: z29.unknown(),
|
|
6057
|
+
clientInstantiation: z29.string()
|
|
6097
6058
|
}),
|
|
6098
|
-
additionalTemplates:
|
|
6059
|
+
additionalTemplates: z29.record(z29.string(), z29.unknown()).nullish()
|
|
6099
6060
|
});
|
|
6100
|
-
var RegisterInputSchema =
|
|
6101
|
-
orgId:
|
|
6102
|
-
apiId:
|
|
6103
|
-
apiDefinitionId:
|
|
6061
|
+
var RegisterInputSchema = z29.object({
|
|
6062
|
+
orgId: z29.string(),
|
|
6063
|
+
apiId: z29.string(),
|
|
6064
|
+
apiDefinitionId: z29.string(),
|
|
6104
6065
|
snippet: SnippetRegistryEntrySchema
|
|
6105
6066
|
});
|
|
6106
|
-
var RegisterBatchInputSchema =
|
|
6107
|
-
orgId:
|
|
6108
|
-
apiId:
|
|
6109
|
-
apiDefinitionId:
|
|
6110
|
-
snippets:
|
|
6067
|
+
var RegisterBatchInputSchema = z29.object({
|
|
6068
|
+
orgId: z29.string(),
|
|
6069
|
+
apiId: z29.string(),
|
|
6070
|
+
apiDefinitionId: z29.string(),
|
|
6071
|
+
snippets: z29.array(SnippetRegistryEntrySchema)
|
|
6111
6072
|
});
|
|
6112
|
-
var GetInputSchema =
|
|
6113
|
-
orgId:
|
|
6114
|
-
apiId:
|
|
6073
|
+
var GetInputSchema = z29.object({
|
|
6074
|
+
orgId: z29.string(),
|
|
6075
|
+
apiId: z29.string(),
|
|
6115
6076
|
sdk: SdkSchema,
|
|
6116
|
-
endpointId:
|
|
6117
|
-
path:
|
|
6077
|
+
endpointId: z29.object({
|
|
6078
|
+
path: z29.string(),
|
|
6118
6079
|
method: HttpMethodSchema,
|
|
6119
|
-
identifierOverride:
|
|
6080
|
+
identifierOverride: z29.string().nullish()
|
|
6120
6081
|
})
|
|
6121
6082
|
});
|
|
6122
|
-
var EndpointSnippetTemplateSchema =
|
|
6083
|
+
var EndpointSnippetTemplateSchema = z29.record(z29.string(), z29.unknown());
|
|
6123
6084
|
var templatesContract = {
|
|
6124
|
-
register:
|
|
6125
|
-
registerBatch:
|
|
6126
|
-
get:
|
|
6085
|
+
register: import_contract37.oc.route({ method: "POST", path: "/register" }).input(RegisterInputSchema),
|
|
6086
|
+
registerBatch: import_contract37.oc.route({ method: "POST", path: "/register/batch" }).input(RegisterBatchInputSchema),
|
|
6087
|
+
get: import_contract37.oc.route({ method: "POST", path: "/get" }).input(GetInputSchema).output(EndpointSnippetTemplateSchema)
|
|
6127
6088
|
};
|
|
6128
6089
|
|
|
6129
6090
|
// src/orpc-client/templates/client.ts
|
|
6130
6091
|
function createTemplatesClient(options) {
|
|
6131
6092
|
const baseUrl = options.baseUrl.replace(/\/+$/, "");
|
|
6132
|
-
const link = new
|
|
6093
|
+
const link = new import_fetch20.OpenAPILink(templatesContract, {
|
|
6133
6094
|
url: `${baseUrl}/snippet-template`,
|
|
6134
6095
|
headers: () => ({
|
|
6135
6096
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -6137,36 +6098,36 @@ function createTemplatesClient(options) {
|
|
|
6137
6098
|
}),
|
|
6138
6099
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
6139
6100
|
});
|
|
6140
|
-
return (0,
|
|
6101
|
+
return (0, import_client25.createORPCClient)(link);
|
|
6141
6102
|
}
|
|
6142
6103
|
|
|
6143
6104
|
// src/orpc-client/tokens/client.ts
|
|
6144
|
-
var
|
|
6145
|
-
var
|
|
6105
|
+
var import_client26 = require("@orpc/client");
|
|
6106
|
+
var import_fetch21 = require("@orpc/openapi-client/fetch");
|
|
6146
6107
|
|
|
6147
6108
|
// src/orpc-client/tokens/contract.ts
|
|
6148
|
-
var
|
|
6149
|
-
var
|
|
6150
|
-
var GenerateTokenInputSchema =
|
|
6151
|
-
orgId:
|
|
6152
|
-
scope:
|
|
6109
|
+
var import_contract39 = require("@orpc/contract");
|
|
6110
|
+
var z30 = __toESM(require("zod"), 1);
|
|
6111
|
+
var GenerateTokenInputSchema = z30.object({
|
|
6112
|
+
orgId: z30.string(),
|
|
6113
|
+
scope: z30.string()
|
|
6153
6114
|
});
|
|
6154
|
-
var RevokeTokenInputSchema =
|
|
6155
|
-
orgId:
|
|
6156
|
-
tokenId:
|
|
6115
|
+
var RevokeTokenInputSchema = z30.object({
|
|
6116
|
+
orgId: z30.string(),
|
|
6117
|
+
tokenId: z30.string()
|
|
6157
6118
|
});
|
|
6158
|
-
var GenerateTokenOutputSchema =
|
|
6159
|
-
token:
|
|
6160
|
-
id:
|
|
6119
|
+
var GenerateTokenOutputSchema = z30.object({
|
|
6120
|
+
token: z30.string(),
|
|
6121
|
+
id: z30.string()
|
|
6161
6122
|
});
|
|
6162
6123
|
var tokensContract = {
|
|
6163
|
-
generate:
|
|
6164
|
-
revoke:
|
|
6124
|
+
generate: import_contract39.oc.route({ method: "POST", path: "/generate" }).input(GenerateTokenInputSchema).output(GenerateTokenOutputSchema),
|
|
6125
|
+
revoke: import_contract39.oc.route({ method: "POST", path: "/revoke" }).input(RevokeTokenInputSchema)
|
|
6165
6126
|
};
|
|
6166
6127
|
|
|
6167
6128
|
// src/orpc-client/tokens/client.ts
|
|
6168
6129
|
function createTokensClient(options) {
|
|
6169
|
-
const link = new
|
|
6130
|
+
const link = new import_fetch21.OpenAPILink(tokensContract, {
|
|
6170
6131
|
url: `${options.baseUrl}/tokens`,
|
|
6171
6132
|
headers: () => ({
|
|
6172
6133
|
Authorization: `Bearer ${options.token}`,
|
|
@@ -6174,7 +6135,7 @@ function createTokensClient(options) {
|
|
|
6174
6135
|
}),
|
|
6175
6136
|
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
6176
6137
|
});
|
|
6177
|
-
return (0,
|
|
6138
|
+
return (0, import_client26.createORPCClient)(link);
|
|
6178
6139
|
}
|
|
6179
6140
|
|
|
6180
6141
|
// src/orpc-client/client.ts
|
|
@@ -6207,6 +6168,45 @@ function createFdrORPCClient(options) {
|
|
|
6207
6168
|
};
|
|
6208
6169
|
}
|
|
6209
6170
|
|
|
6171
|
+
// src/orpc-client/docs/v1/write/client.ts
|
|
6172
|
+
var import_client44 = require("@orpc/client");
|
|
6173
|
+
var import_fetch22 = require("@orpc/openapi-client/fetch");
|
|
6174
|
+
|
|
6175
|
+
// src/orpc-client/docs/v1/write/contract.ts
|
|
6176
|
+
var import_contract41 = require("@orpc/contract");
|
|
6177
|
+
var z31 = __toESM(require("zod"), 1);
|
|
6178
|
+
var StartDocsRegisterV1InputSchema = z31.object({
|
|
6179
|
+
orgId: z31.string(),
|
|
6180
|
+
domain: z31.string(),
|
|
6181
|
+
filepaths: z31.array(z31.string())
|
|
6182
|
+
});
|
|
6183
|
+
var StartDocsRegisterV1ResponseSchema = z31.object({
|
|
6184
|
+
docsRegistrationId: z31.string(),
|
|
6185
|
+
uploadUrls: z31.record(z31.string(), FileS3UploadUrlSchema),
|
|
6186
|
+
skippedFiles: z31.array(z31.string())
|
|
6187
|
+
});
|
|
6188
|
+
var FinishDocsRegisterV1InputSchema = z31.object({
|
|
6189
|
+
docsRegistrationId: z31.string(),
|
|
6190
|
+
docsDefinition: z31.unknown()
|
|
6191
|
+
});
|
|
6192
|
+
var docsV1WriteContract = {
|
|
6193
|
+
startDocsRegister: import_contract41.oc.route({ method: "POST", path: "/init" }).input(StartDocsRegisterV1InputSchema).output(StartDocsRegisterV1ResponseSchema),
|
|
6194
|
+
finishDocsRegister: import_contract41.oc.route({ method: "POST", path: "/register/{docsRegistrationId}" }).input(FinishDocsRegisterV1InputSchema).output(z31.void())
|
|
6195
|
+
};
|
|
6196
|
+
|
|
6197
|
+
// src/orpc-client/docs/v1/write/client.ts
|
|
6198
|
+
function createDocsV1WriteClient(options) {
|
|
6199
|
+
const link = new import_fetch22.OpenAPILink(docsV1WriteContract, {
|
|
6200
|
+
url: `${options.baseUrl}/registry/docs`,
|
|
6201
|
+
headers: () => ({
|
|
6202
|
+
Authorization: `Bearer ${options.token}`,
|
|
6203
|
+
...options.headers
|
|
6204
|
+
}),
|
|
6205
|
+
...options.fetch != null ? { fetch: options.fetch } : {}
|
|
6206
|
+
});
|
|
6207
|
+
return (0, import_client44.createORPCClient)(link);
|
|
6208
|
+
}
|
|
6209
|
+
|
|
6210
6210
|
// src/orpc-client/docs-ledger/config-files.ts
|
|
6211
6211
|
var z32 = __toESM(require("zod"), 1);
|
|
6212
6212
|
var PATH_OR_URL_METADATA_KEYS = [
|