@openrouter/sdk 1.5.19 → 1.5.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. package/esm/funcs/privateEndpointsUpdate.d.ts +2 -2
  2. package/esm/funcs/privateEndpointsUpdate.js +2 -2
  3. package/esm/funcs/privateEndpointsUpdateParameters.d.ts +4 -2
  4. package/esm/funcs/privateEndpointsUpdateParameters.js +4 -2
  5. package/esm/funcs/privateEndpointsUpdatePricing.d.ts +4 -2
  6. package/esm/funcs/privateEndpointsUpdatePricing.js +4 -2
  7. package/esm/funcs/privateProvidersCreate.d.ts +18 -0
  8. package/esm/funcs/privateProvidersCreate.js +99 -0
  9. package/esm/funcs/privateProvidersDelete.d.ts +18 -0
  10. package/esm/funcs/privateProvidersDelete.js +102 -0
  11. package/esm/funcs/privateProvidersGet.d.ts +18 -0
  12. package/esm/funcs/privateProvidersGet.js +102 -0
  13. package/esm/funcs/privateProvidersList.d.ts +18 -0
  14. package/esm/funcs/privateProvidersList.js +96 -0
  15. package/esm/funcs/privateProvidersUpdate.d.ts +18 -0
  16. package/esm/funcs/privateProvidersUpdate.js +105 -0
  17. package/esm/lib/config.d.ts +3 -3
  18. package/esm/lib/config.js +3 -3
  19. package/esm/models/createprivateendpointrequest.d.ts +6 -0
  20. package/esm/models/createprivateendpointrequest.js +2 -0
  21. package/esm/models/createprivateproviderrequest.d.ts +36 -0
  22. package/esm/models/createprivateproviderrequest.js +25 -0
  23. package/esm/models/index.d.ts +8 -0
  24. package/esm/models/index.js +8 -0
  25. package/esm/models/operations/createprivateprovider.d.ts +67 -0
  26. package/esm/models/operations/createprivateprovider.js +31 -0
  27. package/esm/models/operations/deleteprivateprovider.d.ts +75 -0
  28. package/esm/models/operations/deleteprivateprovider.js +36 -0
  29. package/esm/models/operations/getprivateprovider.d.ts +67 -0
  30. package/esm/models/operations/getprivateprovider.js +30 -0
  31. package/esm/models/operations/index.d.ts +5 -0
  32. package/esm/models/operations/index.js +5 -0
  33. package/esm/models/operations/listprivateproviders.d.ts +65 -0
  34. package/esm/models/operations/listprivateproviders.js +29 -0
  35. package/esm/models/operations/updateprivateprovider.d.ts +69 -0
  36. package/esm/models/operations/updateprivateprovider.js +32 -0
  37. package/esm/models/privateendpoint.d.ts +5 -0
  38. package/esm/models/privateendpoint.js +2 -0
  39. package/esm/models/privateendpointquantization.d.ts +28 -0
  40. package/esm/models/privateendpointquantization.js +27 -0
  41. package/esm/models/privateendpointreasoningreturnmechanism.d.ts +20 -0
  42. package/esm/models/privateendpointreasoningreturnmechanism.js +19 -0
  43. package/esm/models/privateendpointsettings.d.ts +142 -0
  44. package/esm/models/privateendpointsettings.js +112 -0
  45. package/esm/models/privateprovider.d.ts +47 -0
  46. package/esm/models/privateprovider.js +41 -0
  47. package/esm/models/privateproviderdatapolicy.d.ts +28 -0
  48. package/esm/models/privateproviderdatapolicy.js +21 -0
  49. package/esm/models/updateprivateendpointrequest.d.ts +17 -2
  50. package/esm/models/updateprivateendpointrequest.js +9 -1
  51. package/esm/models/updateprivateendpointsettingsrequest.d.ts +177 -0
  52. package/esm/models/updateprivateendpointsettingsrequest.js +111 -0
  53. package/esm/models/updateprivateproviderrequest.d.ts +42 -0
  54. package/esm/models/updateprivateproviderrequest.js +36 -0
  55. package/esm/sdk/privateendpoints.d.ts +10 -6
  56. package/esm/sdk/privateendpoints.js +10 -6
  57. package/esm/sdk/privateproviders.d.ts +40 -0
  58. package/esm/sdk/privateproviders.js +59 -0
  59. package/esm/sdk/sdk.d.ts +3 -0
  60. package/esm/sdk/sdk.js +4 -0
  61. package/jsr.json +1 -1
  62. package/package.json +7 -7
@@ -24,6 +24,7 @@ export * from "./createpresetschatcompletions.js";
24
24
  export * from "./createpresetsmessages.js";
25
25
  export * from "./createpresetsresponses.js";
26
26
  export * from "./createprivateendpoint.js";
27
+ export * from "./createprivateprovider.js";
27
28
  export * from "./creatererank.js";
28
29
  export * from "./createresponses.js";
29
30
  export * from "./createscimgroupmapping.js";
@@ -40,6 +41,7 @@ export * from "./deleteinternvaultsecret.js";
40
41
  export * from "./deletekeys.js";
41
42
  export * from "./deleteobservabilitydestination.js";
42
43
  export * from "./deleteprivateendpoint.js";
44
+ export * from "./deleteprivateprovider.js";
43
45
  export * from "./deletescimgroupmapping.js";
44
46
  export * from "./deletevaultsecret.js";
45
47
  export * from "./deleteworkspace.js";
@@ -69,6 +71,7 @@ export * from "./getorganizationsettings.js";
69
71
  export * from "./getpreset.js";
70
72
  export * from "./getpresetversion.js";
71
73
  export * from "./getprivateendpoint.js";
74
+ export * from "./getprivateprovider.js";
72
75
  export * from "./getrankingsdaily.js";
73
76
  export * from "./getscimgroupmapping.js";
74
77
  export * from "./getscimsyncjob.js";
@@ -107,6 +110,7 @@ export * from "./listorganizationmembers.js";
107
110
  export * from "./listpresets.js";
108
111
  export * from "./listpresetversions.js";
109
112
  export * from "./listprivateendpoints.js";
113
+ export * from "./listprivateproviders.js";
110
114
  export * from "./listproviders.js";
111
115
  export * from "./listscimgroupmappings.js";
112
116
  export * from "./listscimgroups.js";
@@ -132,6 +136,7 @@ export * from "./updateorganizationsettings.js";
132
136
  export * from "./updateprivateendpoint.js";
133
137
  export * from "./updateprivateendpointparameters.js";
134
138
  export * from "./updateprivateendpointpricing.js";
139
+ export * from "./updateprivateprovider.js";
135
140
  export * from "./updatescimgroupmapping.js";
136
141
  export * from "./updateworkspace.js";
137
142
  export * from "./uploadfile.js";
@@ -28,6 +28,7 @@ export * from "./createpresetschatcompletions.js";
28
28
  export * from "./createpresetsmessages.js";
29
29
  export * from "./createpresetsresponses.js";
30
30
  export * from "./createprivateendpoint.js";
31
+ export * from "./createprivateprovider.js";
31
32
  export * from "./creatererank.js";
32
33
  export * from "./createresponses.js";
33
34
  export * from "./createscimgroupmapping.js";
@@ -44,6 +45,7 @@ export * from "./deleteinternvaultsecret.js";
44
45
  export * from "./deletekeys.js";
45
46
  export * from "./deleteobservabilitydestination.js";
46
47
  export * from "./deleteprivateendpoint.js";
48
+ export * from "./deleteprivateprovider.js";
47
49
  export * from "./deletescimgroupmapping.js";
48
50
  export * from "./deletevaultsecret.js";
49
51
  export * from "./deleteworkspace.js";
@@ -73,6 +75,7 @@ export * from "./getorganizationsettings.js";
73
75
  export * from "./getpreset.js";
74
76
  export * from "./getpresetversion.js";
75
77
  export * from "./getprivateendpoint.js";
78
+ export * from "./getprivateprovider.js";
76
79
  export * from "./getrankingsdaily.js";
77
80
  export * from "./getscimgroupmapping.js";
78
81
  export * from "./getscimsyncjob.js";
@@ -111,6 +114,7 @@ export * from "./listorganizationmembers.js";
111
114
  export * from "./listpresets.js";
112
115
  export * from "./listpresetversions.js";
113
116
  export * from "./listprivateendpoints.js";
117
+ export * from "./listprivateproviders.js";
114
118
  export * from "./listproviders.js";
115
119
  export * from "./listscimgroupmappings.js";
116
120
  export * from "./listscimgroups.js";
@@ -136,6 +140,7 @@ export * from "./updateorganizationsettings.js";
136
140
  export * from "./updateprivateendpoint.js";
137
141
  export * from "./updateprivateendpointparameters.js";
138
142
  export * from "./updateprivateendpointpricing.js";
143
+ export * from "./updateprivateprovider.js";
139
144
  export * from "./updatescimgroupmapping.js";
140
145
  export * from "./updateworkspace.js";
141
146
  export * from "./uploadfile.js";
@@ -0,0 +1,65 @@
1
+ import * as z from "zod/v4";
2
+ import { Result as SafeParseResult } from "../../types/fp.js";
3
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
4
+ import * as models from "../index.js";
5
+ export type ListPrivateProvidersGlobals = {
6
+ /**
7
+ * The app identifier should be your app's URL and is used as the primary identifier for rankings.
8
+ *
9
+ * @remarks
10
+ * This is used to track API usage per application.
11
+ */
12
+ httpReferer?: string | undefined;
13
+ /**
14
+ * The app display name allows you to customize how your app appears in OpenRouter's dashboard.
15
+ *
16
+ * @remarks
17
+ */
18
+ appTitle?: string | undefined;
19
+ /**
20
+ * Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
21
+ *
22
+ * @remarks
23
+ */
24
+ appCategories?: string | undefined;
25
+ };
26
+ export type ListPrivateProvidersRequest = {
27
+ /**
28
+ * The app identifier should be your app's URL and is used as the primary identifier for rankings.
29
+ *
30
+ * @remarks
31
+ * This is used to track API usage per application.
32
+ */
33
+ httpReferer?: string | undefined;
34
+ /**
35
+ * The app display name allows you to customize how your app appears in OpenRouter's dashboard.
36
+ *
37
+ * @remarks
38
+ */
39
+ appTitle?: string | undefined;
40
+ /**
41
+ * Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
42
+ *
43
+ * @remarks
44
+ */
45
+ appCategories?: string | undefined;
46
+ };
47
+ /**
48
+ * Private providers for the organization
49
+ */
50
+ export type ListPrivateProvidersResponse = {
51
+ data: Array<models.PrivateProvider>;
52
+ };
53
+ /** @internal */
54
+ export type ListPrivateProvidersRequest$Outbound = {
55
+ "HTTP-Referer"?: string | undefined;
56
+ appTitle?: string | undefined;
57
+ appCategories?: string | undefined;
58
+ };
59
+ /** @internal */
60
+ export declare const ListPrivateProvidersRequest$outboundSchema: z.ZodType<ListPrivateProvidersRequest$Outbound, ListPrivateProvidersRequest>;
61
+ export declare function listPrivateProvidersRequestToJSON(listPrivateProvidersRequest: ListPrivateProvidersRequest): string;
62
+ /** @internal */
63
+ export declare const ListPrivateProvidersResponse$inboundSchema: z.ZodType<ListPrivateProvidersResponse, unknown>;
64
+ export declare function listPrivateProvidersResponseFromJSON(jsonString: string): SafeParseResult<ListPrivateProvidersResponse, SDKValidationError>;
65
+ //# sourceMappingURL=listprivateproviders.d.ts.map
@@ -0,0 +1,29 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ * @generated-id: 13738022002d
4
+ */
5
+ import * as z from "zod/v4";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { PrivateProvider$inboundSchema as models_PrivateProvider$inboundSchema } from "../privateprovider.js";
9
+ /** @internal */
10
+ export const ListPrivateProvidersRequest$outboundSchema = z.object({
11
+ httpReferer: z.string().optional(),
12
+ appTitle: z.string().optional(),
13
+ appCategories: z.string().optional(),
14
+ }).transform((v) => {
15
+ return remap$(v, {
16
+ httpReferer: "HTTP-Referer",
17
+ });
18
+ });
19
+ export function listPrivateProvidersRequestToJSON(listPrivateProvidersRequest) {
20
+ return JSON.stringify(ListPrivateProvidersRequest$outboundSchema.parse(listPrivateProvidersRequest));
21
+ }
22
+ /** @internal */
23
+ export const ListPrivateProvidersResponse$inboundSchema = z.object({
24
+ data: z.array(models_PrivateProvider$inboundSchema),
25
+ });
26
+ export function listPrivateProvidersResponseFromJSON(jsonString) {
27
+ return safeParse(jsonString, (x) => ListPrivateProvidersResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ListPrivateProvidersResponse' from JSON`);
28
+ }
29
+ //# sourceMappingURL=listprivateproviders.js.map
@@ -0,0 +1,69 @@
1
+ import * as z from "zod/v4";
2
+ import { Result as SafeParseResult } from "../../types/fp.js";
3
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
4
+ import * as models from "../index.js";
5
+ export type UpdatePrivateProviderGlobals = {
6
+ /**
7
+ * The app identifier should be your app's URL and is used as the primary identifier for rankings.
8
+ *
9
+ * @remarks
10
+ * This is used to track API usage per application.
11
+ */
12
+ httpReferer?: string | undefined;
13
+ /**
14
+ * The app display name allows you to customize how your app appears in OpenRouter's dashboard.
15
+ *
16
+ * @remarks
17
+ */
18
+ appTitle?: string | undefined;
19
+ /**
20
+ * Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
21
+ *
22
+ * @remarks
23
+ */
24
+ appCategories?: string | undefined;
25
+ };
26
+ export type UpdatePrivateProviderRequest = {
27
+ /**
28
+ * The app identifier should be your app's URL and is used as the primary identifier for rankings.
29
+ *
30
+ * @remarks
31
+ * This is used to track API usage per application.
32
+ */
33
+ httpReferer?: string | undefined;
34
+ /**
35
+ * The app display name allows you to customize how your app appears in OpenRouter's dashboard.
36
+ *
37
+ * @remarks
38
+ */
39
+ appTitle?: string | undefined;
40
+ /**
41
+ * Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
42
+ *
43
+ * @remarks
44
+ */
45
+ appCategories?: string | undefined;
46
+ slug: string;
47
+ updatePrivateProviderRequest: models.UpdatePrivateProviderRequest;
48
+ };
49
+ /**
50
+ * The updated provider
51
+ */
52
+ export type UpdatePrivateProviderResponse = {
53
+ data: models.PrivateProvider;
54
+ };
55
+ /** @internal */
56
+ export type UpdatePrivateProviderRequest$Outbound = {
57
+ "HTTP-Referer"?: string | undefined;
58
+ appTitle?: string | undefined;
59
+ appCategories?: string | undefined;
60
+ slug: string;
61
+ UpdatePrivateProviderRequest: models.UpdatePrivateProviderRequest$Outbound;
62
+ };
63
+ /** @internal */
64
+ export declare const UpdatePrivateProviderRequest$outboundSchema: z.ZodType<UpdatePrivateProviderRequest$Outbound, UpdatePrivateProviderRequest>;
65
+ export declare function updatePrivateProviderRequestToJSON(updatePrivateProviderRequest: UpdatePrivateProviderRequest): string;
66
+ /** @internal */
67
+ export declare const UpdatePrivateProviderResponse$inboundSchema: z.ZodType<UpdatePrivateProviderResponse, unknown>;
68
+ export declare function updatePrivateProviderResponseFromJSON(jsonString: string): SafeParseResult<UpdatePrivateProviderResponse, SDKValidationError>;
69
+ //# sourceMappingURL=updateprivateprovider.d.ts.map
@@ -0,0 +1,32 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ * @generated-id: 9282e3dcd86e
4
+ */
5
+ import * as z from "zod/v4";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { PrivateProvider$inboundSchema as models_PrivateProvider$inboundSchema } from "../privateprovider.js"; import { UpdatePrivateProviderRequest$outboundSchema as models_UpdatePrivateProviderRequest$outboundSchema } from "../updateprivateproviderrequest.js";
9
+ /** @internal */
10
+ export const UpdatePrivateProviderRequest$outboundSchema = z.object({
11
+ httpReferer: z.string().optional(),
12
+ appTitle: z.string().optional(),
13
+ appCategories: z.string().optional(),
14
+ slug: z.string(),
15
+ updatePrivateProviderRequest: models_UpdatePrivateProviderRequest$outboundSchema,
16
+ }).transform((v) => {
17
+ return remap$(v, {
18
+ httpReferer: "HTTP-Referer",
19
+ updatePrivateProviderRequest: "UpdatePrivateProviderRequest",
20
+ });
21
+ });
22
+ export function updatePrivateProviderRequestToJSON(updatePrivateProviderRequest) {
23
+ return JSON.stringify(UpdatePrivateProviderRequest$outboundSchema.parse(updatePrivateProviderRequest));
24
+ }
25
+ /** @internal */
26
+ export const UpdatePrivateProviderResponse$inboundSchema = z.object({
27
+ data: models_PrivateProvider$inboundSchema,
28
+ });
29
+ export function updatePrivateProviderResponseFromJSON(jsonString) {
30
+ return safeParse(jsonString, (x) => UpdatePrivateProviderResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdatePrivateProviderResponse' from JSON`);
31
+ }
32
+ //# sourceMappingURL=updateprivateprovider.js.map
@@ -3,6 +3,7 @@ import { Result as SafeParseResult } from "../types/fp.js";
3
3
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
4
4
  import { PrivateEndpointDeclaredRegion } from "./privateendpointdeclaredregion.js";
5
5
  import { PrivateEndpointPricing } from "./privateendpointpricing.js";
6
+ import { PrivateEndpointSettings } from "./privateendpointsettings.js";
6
7
  import { PrivateEndpointStatus } from "./privateendpointstatus.js";
7
8
  export type PrivateEndpoint = {
8
9
  /**
@@ -53,6 +54,10 @@ export type PrivateEndpoint = {
53
54
  * Slug of the upstream provider, or `null` when the provider is no longer listed.
54
55
  */
55
56
  providerSlug: string | null;
57
+ /**
58
+ * Capabilities and limits routing uses for this endpoint. A new endpoint copies them from the public endpoint for the same model and provider, or from the model, and the owner can change them. Rate limits are not part of this object: a private endpoint is billed to its own upstream key, so request limits stay with the provider.
59
+ */
60
+ settings: PrivateEndpointSettings;
56
61
  /**
57
62
  * Lifecycle state. `draft` endpoints are not routable until validated and activated; `disabled` endpoints are activated but temporarily not routable.
58
63
  */
@@ -7,6 +7,7 @@ import { remap as remap$ } from "../lib/primitives.js";
7
7
  import { safeParse } from "../lib/schemas.js";
8
8
  import { PrivateEndpointDeclaredRegion$inboundSchema, } from "./privateendpointdeclaredregion.js";
9
9
  import { PrivateEndpointPricing$inboundSchema, } from "./privateendpointpricing.js";
10
+ import { PrivateEndpointSettings$inboundSchema, } from "./privateendpointsettings.js";
10
11
  import { PrivateEndpointStatus$inboundSchema, } from "./privateendpointstatus.js";
11
12
  /** @internal */
12
13
  export const PrivateEndpoint$inboundSchema = z.object({
@@ -22,6 +23,7 @@ export const PrivateEndpoint$inboundSchema = z.object({
22
23
  pricing: PrivateEndpointPricing$inboundSchema,
23
24
  provider_name: z.string(),
24
25
  provider_slug: z.nullable(z.string()),
26
+ settings: PrivateEndpointSettings$inboundSchema,
25
27
  status: PrivateEndpointStatus$inboundSchema,
26
28
  tested_parameters: z.array(z.string()),
27
29
  upstream_model_id: z.string(),
@@ -0,0 +1,28 @@
1
+ import * as z from "zod/v4";
2
+ import { OpenEnum } from "../types/enums.js";
3
+ /**
4
+ * Weight precision the deployment runs at; `unknown` when not stated.
5
+ */
6
+ export declare const PrivateEndpointQuantization: {
7
+ readonly Int4: "int4";
8
+ readonly Int8: "int8";
9
+ readonly Fp4: "fp4";
10
+ readonly Mxfp4: "mxfp4";
11
+ readonly Nvfp4: "nvfp4";
12
+ readonly Fp6: "fp6";
13
+ readonly Fp8: "fp8";
14
+ readonly Mxfp8: "mxfp8";
15
+ readonly Fp16: "fp16";
16
+ readonly Bf16: "bf16";
17
+ readonly Fp32: "fp32";
18
+ readonly Unknown: "unknown";
19
+ };
20
+ /**
21
+ * Weight precision the deployment runs at; `unknown` when not stated.
22
+ */
23
+ export type PrivateEndpointQuantization = OpenEnum<typeof PrivateEndpointQuantization>;
24
+ /** @internal */
25
+ export declare const PrivateEndpointQuantization$inboundSchema: z.ZodType<PrivateEndpointQuantization, unknown>;
26
+ /** @internal */
27
+ export declare const PrivateEndpointQuantization$outboundSchema: z.ZodType<string, PrivateEndpointQuantization>;
28
+ //# sourceMappingURL=privateendpointquantization.d.ts.map
@@ -0,0 +1,27 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ * @generated-id: 76e7da632993
4
+ */
5
+ import * as openEnums from "../types/enums.js";
6
+ /**
7
+ * Weight precision the deployment runs at; `unknown` when not stated.
8
+ */
9
+ export const PrivateEndpointQuantization = {
10
+ Int4: "int4",
11
+ Int8: "int8",
12
+ Fp4: "fp4",
13
+ Mxfp4: "mxfp4",
14
+ Nvfp4: "nvfp4",
15
+ Fp6: "fp6",
16
+ Fp8: "fp8",
17
+ Mxfp8: "mxfp8",
18
+ Fp16: "fp16",
19
+ Bf16: "bf16",
20
+ Fp32: "fp32",
21
+ Unknown: "unknown",
22
+ };
23
+ /** @internal */
24
+ export const PrivateEndpointQuantization$inboundSchema = openEnums.inboundSchema(PrivateEndpointQuantization);
25
+ /** @internal */
26
+ export const PrivateEndpointQuantization$outboundSchema = openEnums.outboundSchema(PrivateEndpointQuantization);
27
+ //# sourceMappingURL=privateendpointquantization.js.map
@@ -0,0 +1,20 @@
1
+ import * as z from "zod/v4";
2
+ import { OpenEnum } from "../types/enums.js";
3
+ /**
4
+ * Where the upstream puts reasoning tokens in its response: `reasoning` and `reasoning-content` are response fields, `content-string` is inline in the message, `none` returns no reasoning. `null` uses the provider default.
5
+ */
6
+ export declare const PrivateEndpointReasoningReturnMechanism: {
7
+ readonly ContentString: "content-string";
8
+ readonly ReasoningContent: "reasoning-content";
9
+ readonly Reasoning: "reasoning";
10
+ readonly None: "none";
11
+ };
12
+ /**
13
+ * Where the upstream puts reasoning tokens in its response: `reasoning` and `reasoning-content` are response fields, `content-string` is inline in the message, `none` returns no reasoning. `null` uses the provider default.
14
+ */
15
+ export type PrivateEndpointReasoningReturnMechanism = OpenEnum<typeof PrivateEndpointReasoningReturnMechanism>;
16
+ /** @internal */
17
+ export declare const PrivateEndpointReasoningReturnMechanism$inboundSchema: z.ZodType<PrivateEndpointReasoningReturnMechanism, unknown>;
18
+ /** @internal */
19
+ export declare const PrivateEndpointReasoningReturnMechanism$outboundSchema: z.ZodType<string, PrivateEndpointReasoningReturnMechanism>;
20
+ //# sourceMappingURL=privateendpointreasoningreturnmechanism.d.ts.map
@@ -0,0 +1,19 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ * @generated-id: f7b71cec5a36
4
+ */
5
+ import * as openEnums from "../types/enums.js";
6
+ /**
7
+ * Where the upstream puts reasoning tokens in its response: `reasoning` and `reasoning-content` are response fields, `content-string` is inline in the message, `none` returns no reasoning. `null` uses the provider default.
8
+ */
9
+ export const PrivateEndpointReasoningReturnMechanism = {
10
+ ContentString: "content-string",
11
+ ReasoningContent: "reasoning-content",
12
+ Reasoning: "reasoning",
13
+ None: "none",
14
+ };
15
+ /** @internal */
16
+ export const PrivateEndpointReasoningReturnMechanism$inboundSchema = openEnums.inboundSchema(PrivateEndpointReasoningReturnMechanism);
17
+ /** @internal */
18
+ export const PrivateEndpointReasoningReturnMechanism$outboundSchema = openEnums.outboundSchema(PrivateEndpointReasoningReturnMechanism);
19
+ //# sourceMappingURL=privateendpointreasoningreturnmechanism.js.map
@@ -0,0 +1,142 @@
1
+ import * as z from "zod/v4";
2
+ import { OpenEnum } from "../types/enums.js";
3
+ import { Result as SafeParseResult } from "../types/fp.js";
4
+ import { SDKValidationError } from "./errors/sdkvalidationerror.js";
5
+ import { PrivateEndpointQuantization } from "./privateendpointquantization.js";
6
+ import { PrivateEndpointReasoningReturnMechanism } from "./privateendpointreasoningreturnmechanism.js";
7
+ export type PrivateEndpointSettingsCompletions = {
8
+ /**
9
+ * Serves `/chat/completions`; `null` uses the provider default.
10
+ */
11
+ chat: boolean | null;
12
+ /**
13
+ * Serves `/completions`; `null` uses the provider default.
14
+ */
15
+ text: boolean | null;
16
+ };
17
+ export declare const PrivateEndpointSettingsExcludedParameter: {
18
+ readonly Temperature: "temperature";
19
+ readonly TopP: "top_p";
20
+ readonly TopK: "top_k";
21
+ readonly MinP: "min_p";
22
+ readonly TopA: "top_a";
23
+ readonly FrequencyPenalty: "frequency_penalty";
24
+ readonly PresencePenalty: "presence_penalty";
25
+ readonly RepetitionPenalty: "repetition_penalty";
26
+ readonly MaxTokens: "max_tokens";
27
+ readonly MaxCompletionTokens: "max_completion_tokens";
28
+ readonly LogitBias: "logit_bias";
29
+ readonly Logprobs: "logprobs";
30
+ readonly TopLogprobs: "top_logprobs";
31
+ readonly Prediction: "prediction";
32
+ readonly Seed: "seed";
33
+ readonly ResponseFormat: "response_format";
34
+ readonly StructuredOutputs: "structured_outputs";
35
+ readonly Stop: "stop";
36
+ readonly Tools: "tools";
37
+ readonly ToolChoice: "tool_choice";
38
+ readonly ParallelToolCalls: "parallel_tool_calls";
39
+ readonly IncludeReasoning: "include_reasoning";
40
+ readonly Reasoning: "reasoning";
41
+ readonly ReasoningEffort: "reasoning_effort";
42
+ readonly WebSearchOptions: "web_search_options";
43
+ readonly Verbosity: "verbosity";
44
+ };
45
+ export type PrivateEndpointSettingsExcludedParameter = OpenEnum<typeof PrivateEndpointSettingsExcludedParameter>;
46
+ export type PrivateEndpointSettingsInputs = {
47
+ /**
48
+ * Accepts audio input. `null` keeps the provider default.
49
+ */
50
+ audio: boolean | null;
51
+ /**
52
+ * Accepts base64 file data. `null` keeps the provider default.
53
+ */
54
+ base64Files: boolean | null;
55
+ /**
56
+ * Accepts base64 image data. `null` keeps the provider default.
57
+ */
58
+ base64Images: boolean | null;
59
+ /**
60
+ * Accepts file URLs. `null` keeps the provider default.
61
+ */
62
+ fileUrls: boolean | null;
63
+ /**
64
+ * Accepts image URLs. `null` keeps the provider default.
65
+ */
66
+ imageUrls: boolean | null;
67
+ };
68
+ export type PrivateEndpointSettingsReasoning = {
69
+ /**
70
+ * Where the upstream puts reasoning tokens in its response: `reasoning` and `reasoning-content` are response fields, `content-string` is inline in the message, `none` returns no reasoning. `null` uses the provider default.
71
+ */
72
+ returnMechanism: PrivateEndpointReasoningReturnMechanism | null;
73
+ /**
74
+ * Whether requests with `reasoning` route to this endpoint.
75
+ */
76
+ supported: boolean;
77
+ };
78
+ export type PrivateEndpointSettingsToolChoice = {
79
+ /**
80
+ * Accepts `tool_choice: "auto"`.
81
+ */
82
+ auto: boolean;
83
+ /**
84
+ * Accepts a named function in `tool_choice`.
85
+ */
86
+ function: boolean;
87
+ /**
88
+ * Accepts `tool_choice: "none"`.
89
+ */
90
+ none: boolean;
91
+ /**
92
+ * Accepts `tool_choice: "required"`.
93
+ */
94
+ required: boolean;
95
+ };
96
+ /**
97
+ * Capabilities and limits routing uses for this endpoint. A new endpoint copies them from the public endpoint for the same model and provider, or from the model, and the owner can change them. Rate limits are not part of this object: a private endpoint is billed to its own upstream key, so request limits stay with the provider.
98
+ */
99
+ export type PrivateEndpointSettings = {
100
+ completions: PrivateEndpointSettingsCompletions;
101
+ /**
102
+ * Longest prompt plus completion, in tokens, or `null` to keep the model default.
103
+ */
104
+ contextLength: number | null;
105
+ /**
106
+ * Request parameters the upstream rejects even though the model supports them; requests using one do not route here. Cannot name a tested parameter.
107
+ */
108
+ excludedParameters: Array<PrivateEndpointSettingsExcludedParameter>;
109
+ inputs: PrivateEndpointSettingsInputs;
110
+ /**
111
+ * Longest completion the upstream returns, in tokens, or `null` to keep the model default.
112
+ */
113
+ maxCompletionTokens: number | null;
114
+ /**
115
+ * Longest prompt, in tokens, or `null` for no cap below the context length. Cannot exceed `context_length`, or the model context length while `context_length` is `null`.
116
+ */
117
+ maxPromptTokens: number | null;
118
+ /**
119
+ * Weight precision the deployment runs at; `unknown` when not stated.
120
+ */
121
+ quantization: PrivateEndpointQuantization;
122
+ reasoning: PrivateEndpointSettingsReasoning;
123
+ toolChoice: PrivateEndpointSettingsToolChoice;
124
+ };
125
+ /** @internal */
126
+ export declare const PrivateEndpointSettingsCompletions$inboundSchema: z.ZodType<PrivateEndpointSettingsCompletions, unknown>;
127
+ export declare function privateEndpointSettingsCompletionsFromJSON(jsonString: string): SafeParseResult<PrivateEndpointSettingsCompletions, SDKValidationError>;
128
+ /** @internal */
129
+ export declare const PrivateEndpointSettingsExcludedParameter$inboundSchema: z.ZodType<PrivateEndpointSettingsExcludedParameter, unknown>;
130
+ /** @internal */
131
+ export declare const PrivateEndpointSettingsInputs$inboundSchema: z.ZodType<PrivateEndpointSettingsInputs, unknown>;
132
+ export declare function privateEndpointSettingsInputsFromJSON(jsonString: string): SafeParseResult<PrivateEndpointSettingsInputs, SDKValidationError>;
133
+ /** @internal */
134
+ export declare const PrivateEndpointSettingsReasoning$inboundSchema: z.ZodType<PrivateEndpointSettingsReasoning, unknown>;
135
+ export declare function privateEndpointSettingsReasoningFromJSON(jsonString: string): SafeParseResult<PrivateEndpointSettingsReasoning, SDKValidationError>;
136
+ /** @internal */
137
+ export declare const PrivateEndpointSettingsToolChoice$inboundSchema: z.ZodType<PrivateEndpointSettingsToolChoice, unknown>;
138
+ export declare function privateEndpointSettingsToolChoiceFromJSON(jsonString: string): SafeParseResult<PrivateEndpointSettingsToolChoice, SDKValidationError>;
139
+ /** @internal */
140
+ export declare const PrivateEndpointSettings$inboundSchema: z.ZodType<PrivateEndpointSettings, unknown>;
141
+ export declare function privateEndpointSettingsFromJSON(jsonString: string): SafeParseResult<PrivateEndpointSettings, SDKValidationError>;
142
+ //# sourceMappingURL=privateendpointsettings.d.ts.map
@@ -0,0 +1,112 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ * @generated-id: e21eccb2098e
4
+ */
5
+ import * as z from "zod/v4";
6
+ import { remap as remap$ } from "../lib/primitives.js";
7
+ import { safeParse } from "../lib/schemas.js";
8
+ import * as openEnums from "../types/enums.js";
9
+ import { PrivateEndpointQuantization$inboundSchema, } from "./privateendpointquantization.js";
10
+ import { PrivateEndpointReasoningReturnMechanism$inboundSchema, } from "./privateendpointreasoningreturnmechanism.js";
11
+ export const PrivateEndpointSettingsExcludedParameter = {
12
+ Temperature: "temperature",
13
+ TopP: "top_p",
14
+ TopK: "top_k",
15
+ MinP: "min_p",
16
+ TopA: "top_a",
17
+ FrequencyPenalty: "frequency_penalty",
18
+ PresencePenalty: "presence_penalty",
19
+ RepetitionPenalty: "repetition_penalty",
20
+ MaxTokens: "max_tokens",
21
+ MaxCompletionTokens: "max_completion_tokens",
22
+ LogitBias: "logit_bias",
23
+ Logprobs: "logprobs",
24
+ TopLogprobs: "top_logprobs",
25
+ Prediction: "prediction",
26
+ Seed: "seed",
27
+ ResponseFormat: "response_format",
28
+ StructuredOutputs: "structured_outputs",
29
+ Stop: "stop",
30
+ Tools: "tools",
31
+ ToolChoice: "tool_choice",
32
+ ParallelToolCalls: "parallel_tool_calls",
33
+ IncludeReasoning: "include_reasoning",
34
+ Reasoning: "reasoning",
35
+ ReasoningEffort: "reasoning_effort",
36
+ WebSearchOptions: "web_search_options",
37
+ Verbosity: "verbosity",
38
+ };
39
+ /** @internal */
40
+ export const PrivateEndpointSettingsCompletions$inboundSchema = z.object({
41
+ chat: z.nullable(z.boolean()),
42
+ text: z.nullable(z.boolean()),
43
+ });
44
+ export function privateEndpointSettingsCompletionsFromJSON(jsonString) {
45
+ return safeParse(jsonString, (x) => PrivateEndpointSettingsCompletions$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PrivateEndpointSettingsCompletions' from JSON`);
46
+ }
47
+ /** @internal */
48
+ export const PrivateEndpointSettingsExcludedParameter$inboundSchema = openEnums.inboundSchema(PrivateEndpointSettingsExcludedParameter);
49
+ /** @internal */
50
+ export const PrivateEndpointSettingsInputs$inboundSchema = z.object({
51
+ audio: z.nullable(z.boolean()),
52
+ base64_files: z.nullable(z.boolean()),
53
+ base64_images: z.nullable(z.boolean()),
54
+ file_urls: z.nullable(z.boolean()),
55
+ image_urls: z.nullable(z.boolean()),
56
+ }).transform((v) => {
57
+ return remap$(v, {
58
+ "base64_files": "base64Files",
59
+ "base64_images": "base64Images",
60
+ "file_urls": "fileUrls",
61
+ "image_urls": "imageUrls",
62
+ });
63
+ });
64
+ export function privateEndpointSettingsInputsFromJSON(jsonString) {
65
+ return safeParse(jsonString, (x) => PrivateEndpointSettingsInputs$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PrivateEndpointSettingsInputs' from JSON`);
66
+ }
67
+ /** @internal */
68
+ export const PrivateEndpointSettingsReasoning$inboundSchema = z.object({
69
+ return_mechanism: z.nullable(PrivateEndpointReasoningReturnMechanism$inboundSchema),
70
+ supported: z.boolean(),
71
+ }).transform((v) => {
72
+ return remap$(v, {
73
+ "return_mechanism": "returnMechanism",
74
+ });
75
+ });
76
+ export function privateEndpointSettingsReasoningFromJSON(jsonString) {
77
+ return safeParse(jsonString, (x) => PrivateEndpointSettingsReasoning$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PrivateEndpointSettingsReasoning' from JSON`);
78
+ }
79
+ /** @internal */
80
+ export const PrivateEndpointSettingsToolChoice$inboundSchema = z.object({
81
+ auto: z.boolean(),
82
+ function: z.boolean(),
83
+ none: z.boolean(),
84
+ required: z.boolean(),
85
+ });
86
+ export function privateEndpointSettingsToolChoiceFromJSON(jsonString) {
87
+ return safeParse(jsonString, (x) => PrivateEndpointSettingsToolChoice$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PrivateEndpointSettingsToolChoice' from JSON`);
88
+ }
89
+ /** @internal */
90
+ export const PrivateEndpointSettings$inboundSchema = z.object({
91
+ completions: z.lazy(() => PrivateEndpointSettingsCompletions$inboundSchema),
92
+ context_length: z.nullable(z.int()),
93
+ excluded_parameters: z.array(PrivateEndpointSettingsExcludedParameter$inboundSchema),
94
+ inputs: z.lazy(() => PrivateEndpointSettingsInputs$inboundSchema),
95
+ max_completion_tokens: z.nullable(z.int()),
96
+ max_prompt_tokens: z.nullable(z.int()),
97
+ quantization: PrivateEndpointQuantization$inboundSchema,
98
+ reasoning: z.lazy(() => PrivateEndpointSettingsReasoning$inboundSchema),
99
+ tool_choice: z.lazy(() => PrivateEndpointSettingsToolChoice$inboundSchema),
100
+ }).transform((v) => {
101
+ return remap$(v, {
102
+ "context_length": "contextLength",
103
+ "excluded_parameters": "excludedParameters",
104
+ "max_completion_tokens": "maxCompletionTokens",
105
+ "max_prompt_tokens": "maxPromptTokens",
106
+ "tool_choice": "toolChoice",
107
+ });
108
+ });
109
+ export function privateEndpointSettingsFromJSON(jsonString) {
110
+ return safeParse(jsonString, (x) => PrivateEndpointSettings$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PrivateEndpointSettings' from JSON`);
111
+ }
112
+ //# sourceMappingURL=privateendpointsettings.js.map