@openrouter/sdk 1.5.10 → 1.5.12
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/esm/funcs/endpointsList.d.ts +1 -1
- package/esm/funcs/endpointsList.js +2 -2
- package/esm/funcs/endpointsListZdrEndpoints.d.ts +1 -1
- package/esm/funcs/endpointsListZdrEndpoints.js +2 -2
- package/esm/funcs/generationsSubmitFeedback.d.ts +1 -1
- package/esm/funcs/generationsSubmitFeedback.js +2 -2
- package/esm/funcs/modelsList.d.ts +1 -1
- package/esm/funcs/modelsList.js +2 -2
- package/esm/funcs/modelsListForUser.d.ts +1 -1
- package/esm/funcs/modelsListForUser.js +2 -2
- package/esm/funcs/presetsGet.d.ts +1 -1
- package/esm/funcs/presetsGet.js +2 -2
- package/esm/funcs/presetsGetVersion.d.ts +1 -1
- package/esm/funcs/presetsGetVersion.js +2 -2
- package/esm/funcs/presetsList.d.ts +1 -1
- package/esm/funcs/presetsList.js +2 -2
- package/esm/funcs/presetsListVersions.d.ts +1 -1
- package/esm/funcs/presetsListVersions.js +2 -2
- package/esm/funcs/privateEndpointsUpdateParameters.d.ts +19 -0
- package/esm/funcs/privateEndpointsUpdateParameters.js +104 -0
- package/esm/lib/config.d.ts +2 -2
- package/esm/lib/config.js +2 -2
- package/esm/models/createprivateendpointrequest.d.ts +11 -0
- package/esm/models/createprivateendpointrequest.js +6 -0
- package/esm/models/index.d.ts +3 -0
- package/esm/models/index.js +3 -0
- package/esm/models/managedprivateendpoint.d.ts +4 -0
- package/esm/models/managedprivateendpoint.js +2 -0
- package/esm/models/operations/createprivateendpoint.d.ts +1 -1
- package/esm/models/operations/index.d.ts +1 -0
- package/esm/models/operations/index.js +1 -0
- package/esm/models/operations/updateprivateendpointparameters.d.ts +61 -0
- package/esm/models/operations/updateprivateendpointparameters.js +24 -0
- package/esm/models/privateendpoint.d.ts +12 -0
- package/esm/models/privateendpoint.js +6 -0
- package/esm/models/privateendpointdeclaredparameter.d.ts +39 -0
- package/esm/models/privateendpointdeclaredparameter.js +38 -0
- package/esm/models/privateendpointparametercheck.d.ts +11 -0
- package/esm/models/privateendpointparametercheck.js +15 -0
- package/esm/models/privateendpointvalidation.d.ts +5 -0
- package/esm/models/privateendpointvalidation.js +2 -0
- package/esm/models/privateendpointvalidationnullable.d.ts +5 -0
- package/esm/models/privateendpointvalidationnullable.js +2 -0
- package/esm/models/updateprivateendpointparametersrequest.d.ts +16 -0
- package/esm/models/updateprivateendpointparametersrequest.js +19 -0
- package/esm/sdk/privateendpoints.d.ts +7 -0
- package/esm/sdk/privateendpoints.js +10 -0
- package/jsr.json +1 -1
- package/package.json +7 -7
|
@@ -11,5 +11,5 @@ import { Result } from "../types/fp.js";
|
|
|
11
11
|
/**
|
|
12
12
|
* List all endpoints for a model
|
|
13
13
|
*/
|
|
14
|
-
export declare function endpointsList(client: OpenRouterCore, request: operations.ListEndpointsRequest, options?: RequestOptions): APIPromise<Result<operations.ListEndpointsResponse, errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
14
|
+
export declare function endpointsList(client: OpenRouterCore, request: operations.ListEndpointsRequest, options?: RequestOptions): APIPromise<Result<operations.ListEndpointsResponse, errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | errors.ServiceUnavailableResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
15
15
|
//# sourceMappingURL=endpointsList.d.ts.map
|
|
@@ -9,7 +9,7 @@ import { compactMap } from "../lib/primitives.js";
|
|
|
9
9
|
import { safeParse } from "../lib/schemas.js";
|
|
10
10
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js";
|
|
12
|
+
import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { ServiceUnavailableResponseError$inboundSchema as errors_ServiceUnavailableResponseError$inboundSchema } from "../models/errors/serviceunavailableresponseerror.js";
|
|
13
13
|
import { ListEndpointsRequest$outboundSchema as operations_ListEndpointsRequest$outboundSchema, ListEndpointsResponse$inboundSchema as operations_ListEndpointsResponse$inboundSchema } from "../models/operations/listendpoints.js";
|
|
14
14
|
import { APIPromise } from "../types/async.js";
|
|
15
15
|
/**
|
|
@@ -94,7 +94,7 @@ async function $do(client, request, options) {
|
|
|
94
94
|
const responseFields = {
|
|
95
95
|
HttpMeta: { Response: response, Request: req },
|
|
96
96
|
};
|
|
97
|
-
const [result] = await M.match(M.json(200, operations_ListEndpointsResponse$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
97
|
+
const [result] = await M.match(M.json(200, operations_ListEndpointsResponse$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.jsonErr(503, errors_ServiceUnavailableResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
98
98
|
if (!result.ok) {
|
|
99
99
|
return [result, { status: "complete", request: req, response }];
|
|
100
100
|
}
|
|
@@ -11,5 +11,5 @@ import { Result } from "../types/fp.js";
|
|
|
11
11
|
/**
|
|
12
12
|
* Preview the impact of ZDR on the available endpoints
|
|
13
13
|
*/
|
|
14
|
-
export declare function endpointsListZdrEndpoints(client: OpenRouterCore, request?: operations.ListEndpointsZdrRequest | undefined, options?: RequestOptions): APIPromise<Result<operations.ListEndpointsZdrResponse, errors.ForbiddenResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
14
|
+
export declare function endpointsListZdrEndpoints(client: OpenRouterCore, request?: operations.ListEndpointsZdrRequest | undefined, options?: RequestOptions): APIPromise<Result<operations.ListEndpointsZdrResponse, errors.ForbiddenResponseError | errors.InternalServerResponseError | errors.ServiceUnavailableResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
15
15
|
//# sourceMappingURL=endpointsListZdrEndpoints.d.ts.map
|
|
@@ -9,7 +9,7 @@ import { compactMap } from "../lib/primitives.js";
|
|
|
9
9
|
import { safeParse } from "../lib/schemas.js";
|
|
10
10
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js";
|
|
12
|
+
import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { ServiceUnavailableResponseError$inboundSchema as errors_ServiceUnavailableResponseError$inboundSchema } from "../models/errors/serviceunavailableresponseerror.js";
|
|
13
13
|
import { ListEndpointsZdrRequest$outboundSchema as operations_ListEndpointsZdrRequest$outboundSchema, ListEndpointsZdrResponse$inboundSchema as operations_ListEndpointsZdrResponse$inboundSchema } from "../models/operations/listendpointszdr.js";
|
|
14
14
|
import { APIPromise } from "../types/async.js";
|
|
15
15
|
/**
|
|
@@ -84,7 +84,7 @@ async function $do(client, request, options) {
|
|
|
84
84
|
const responseFields = {
|
|
85
85
|
HttpMeta: { Response: response, Request: req },
|
|
86
86
|
};
|
|
87
|
-
const [result] = await M.match(M.json(200, operations_ListEndpointsZdrResponse$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
87
|
+
const [result] = await M.match(M.json(200, operations_ListEndpointsZdrResponse$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.jsonErr(503, errors_ServiceUnavailableResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
88
88
|
if (!result.ok) {
|
|
89
89
|
return [result, { status: "complete", request: req, response }];
|
|
90
90
|
}
|
|
@@ -15,5 +15,5 @@ import { Result } from "../types/fp.js";
|
|
|
15
15
|
* @remarks
|
|
16
16
|
* Submit structured feedback on a generation the authenticated user made. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
17
17
|
*/
|
|
18
|
-
export declare function generationsSubmitFeedback(client: OpenRouterCore, request: operations.SubmitGenerationFeedbackRequest, options?: RequestOptions): APIPromise<Result<models.SubmitGenerationFeedbackResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.NotFoundResponseError | errors.ConflictResponseError | errors.TooManyRequestsResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
18
|
+
export declare function generationsSubmitFeedback(client: OpenRouterCore, request: operations.SubmitGenerationFeedbackRequest, options?: RequestOptions): APIPromise<Result<models.SubmitGenerationFeedbackResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.ConflictResponseError | errors.TooManyRequestsResponseError | errors.InternalServerResponseError | errors.ServiceUnavailableResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
19
19
|
//# sourceMappingURL=generationsSubmitFeedback.d.ts.map
|
|
@@ -9,7 +9,7 @@ import { compactMap } from "../lib/primitives.js";
|
|
|
9
9
|
import { safeParse } from "../lib/schemas.js";
|
|
10
10
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ConflictResponseError$inboundSchema as errors_ConflictResponseError$inboundSchema } from "../models/errors/conflictresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { TooManyRequestsResponseError$inboundSchema as errors_TooManyRequestsResponseError$inboundSchema } from "../models/errors/toomanyrequestsresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
12
|
+
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ConflictResponseError$inboundSchema as errors_ConflictResponseError$inboundSchema } from "../models/errors/conflictresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { ServiceUnavailableResponseError$inboundSchema as errors_ServiceUnavailableResponseError$inboundSchema } from "../models/errors/serviceunavailableresponseerror.js"; import { TooManyRequestsResponseError$inboundSchema as errors_TooManyRequestsResponseError$inboundSchema } from "../models/errors/toomanyrequestsresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
13
13
|
import { SubmitGenerationFeedbackResponse$inboundSchema as models_SubmitGenerationFeedbackResponse$inboundSchema } from "../models/submitgenerationfeedbackresponse.js";
|
|
14
14
|
import { SubmitGenerationFeedbackRequest$outboundSchema as operations_SubmitGenerationFeedbackRequest$outboundSchema } from "../models/operations/submitgenerationfeedback.js";
|
|
15
15
|
import { APIPromise } from "../types/async.js";
|
|
@@ -91,7 +91,7 @@ async function $do(client, request, options) {
|
|
|
91
91
|
const responseFields = {
|
|
92
92
|
HttpMeta: { Response: response, Request: req },
|
|
93
93
|
};
|
|
94
|
-
const [result] = await M.match(M.json(200, models_SubmitGenerationFeedbackResponse$inboundSchema), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(409, errors_ConflictResponseError$inboundSchema), M.jsonErr(429, errors_TooManyRequestsResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
94
|
+
const [result] = await M.match(M.json(200, models_SubmitGenerationFeedbackResponse$inboundSchema), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(409, errors_ConflictResponseError$inboundSchema), M.jsonErr(429, errors_TooManyRequestsResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.jsonErr(503, errors_ServiceUnavailableResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
95
95
|
if (!result.ok) {
|
|
96
96
|
return [result, { status: "complete", request: req, response }];
|
|
97
97
|
}
|
|
@@ -12,7 +12,7 @@ import { PageIterator } from "../types/operations.js";
|
|
|
12
12
|
/**
|
|
13
13
|
* List all models and their properties
|
|
14
14
|
*/
|
|
15
|
-
export declare function modelsList(client: OpenRouterCore, request?: operations.GetModelsRequest | undefined, options?: RequestOptions): APIPromise<PageIterator<Result<operations.GetModelsResponse, errors.BadRequestResponseError | errors.ForbiddenResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>, {
|
|
15
|
+
export declare function modelsList(client: OpenRouterCore, request?: operations.GetModelsRequest | undefined, options?: RequestOptions): APIPromise<PageIterator<Result<operations.GetModelsResponse, errors.BadRequestResponseError | errors.ForbiddenResponseError | errors.InternalServerResponseError | errors.ServiceUnavailableResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>, {
|
|
16
16
|
offset: number;
|
|
17
17
|
}>>;
|
|
18
18
|
//# sourceMappingURL=modelsList.d.ts.map
|
package/esm/funcs/modelsList.js
CHANGED
|
@@ -9,7 +9,7 @@ import { compactMap } from "../lib/primitives.js";
|
|
|
9
9
|
import { safeParse } from "../lib/schemas.js";
|
|
10
10
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js";
|
|
12
|
+
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { ServiceUnavailableResponseError$inboundSchema as errors_ServiceUnavailableResponseError$inboundSchema } from "../models/errors/serviceunavailableresponseerror.js";
|
|
13
13
|
import { GetModelsRequest$outboundSchema as operations_GetModelsRequest$outboundSchema, GetModelsResponse$inboundSchema as operations_GetModelsResponse$inboundSchema } from "../models/operations/getmodels.js";
|
|
14
14
|
import { APIPromise } from "../types/async.js";
|
|
15
15
|
import { createPageIterator, haltIterator, } from "../types/operations.js";
|
|
@@ -117,7 +117,7 @@ async function $do(client, request, options) {
|
|
|
117
117
|
const responseFields = {
|
|
118
118
|
HttpMeta: { Response: response, Request: req },
|
|
119
119
|
};
|
|
120
|
-
const [result, raw] = await M.match(M.json(200, operations_GetModelsResponse$inboundSchema, { key: "Result" }), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
120
|
+
const [result, raw] = await M.match(M.json(200, operations_GetModelsResponse$inboundSchema, { key: "Result" }), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.jsonErr(503, errors_ServiceUnavailableResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
121
121
|
if (!result.ok) {
|
|
122
122
|
return [haltIterator(result), {
|
|
123
123
|
status: "complete",
|
|
@@ -15,7 +15,7 @@ import { PageIterator } from "../types/operations.js";
|
|
|
15
15
|
* @remarks
|
|
16
16
|
* List models filtered by user provider preferences, [privacy settings](https://openrouter.ai/docs/guides/privacy/provider-logging), and [guardrails](https://openrouter.ai/docs/guides/features/guardrails). Returns text-output models by default; pass `output_modalities` (a comma-separated list of `text`, `image`, `embeddings`, `audio`, `video`, `rerank`, `speech`, `transcription`, or `all`) to include other modalities. If requesting through a regional hostname, the results will be filtered to models that satisfy in-region routing for that region.
|
|
17
17
|
*/
|
|
18
|
-
export declare function modelsListForUser(client: OpenRouterCore, security: operations.ListModelsUserSecurity, request?: operations.ListModelsUserRequest | undefined, options?: RequestOptions): APIPromise<PageIterator<Result<operations.ListModelsUserResponse, errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>, {
|
|
18
|
+
export declare function modelsListForUser(client: OpenRouterCore, security: operations.ListModelsUserSecurity, request?: operations.ListModelsUserRequest | undefined, options?: RequestOptions): APIPromise<PageIterator<Result<operations.ListModelsUserResponse, errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | errors.ServiceUnavailableResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>, {
|
|
19
19
|
offset: number;
|
|
20
20
|
}>>;
|
|
21
21
|
//# sourceMappingURL=modelsListForUser.d.ts.map
|
|
@@ -9,7 +9,7 @@ import { compactMap } from "../lib/primitives.js";
|
|
|
9
9
|
import { safeParse } from "../lib/schemas.js";
|
|
10
10
|
import { resolveSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
12
|
+
import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { ServiceUnavailableResponseError$inboundSchema as errors_ServiceUnavailableResponseError$inboundSchema } from "../models/errors/serviceunavailableresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
13
13
|
import { ListModelsUserRequest$outboundSchema as operations_ListModelsUserRequest$outboundSchema, ListModelsUserResponse$inboundSchema as operations_ListModelsUserResponse$inboundSchema } from "../models/operations/listmodelsuser.js";
|
|
14
14
|
import { APIPromise } from "../types/async.js";
|
|
15
15
|
import { createPageIterator, haltIterator, } from "../types/operations.js";
|
|
@@ -101,7 +101,7 @@ async function $do(client, security, request, options) {
|
|
|
101
101
|
};
|
|
102
102
|
const [result, raw] = await M.match(M.json(200, operations_ListModelsUserResponse$inboundSchema, {
|
|
103
103
|
key: "Result",
|
|
104
|
-
}), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
104
|
+
}), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.jsonErr(503, errors_ServiceUnavailableResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
105
105
|
if (!result.ok) {
|
|
106
106
|
return [haltIterator(result), {
|
|
107
107
|
status: "complete",
|
|
@@ -17,5 +17,5 @@ import { Result } from "../types/fp.js";
|
|
|
17
17
|
*
|
|
18
18
|
* If set, this operation will use {@link Security.apiKey} from the global security.
|
|
19
19
|
*/
|
|
20
|
-
export declare function presetsGet(client: OpenRouterCore, request: operations.GetPresetRequest, options?: RequestOptions): APIPromise<Result<models.GetPresetResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
20
|
+
export declare function presetsGet(client: OpenRouterCore, request: operations.GetPresetRequest, options?: RequestOptions): APIPromise<Result<models.GetPresetResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | errors.ServiceUnavailableResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
21
21
|
//# sourceMappingURL=presetsGet.d.ts.map
|
package/esm/funcs/presetsGet.js
CHANGED
|
@@ -9,7 +9,7 @@ import { compactMap } from "../lib/primitives.js";
|
|
|
9
9
|
import { safeParse } from "../lib/schemas.js";
|
|
10
10
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
12
|
+
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { ServiceUnavailableResponseError$inboundSchema as errors_ServiceUnavailableResponseError$inboundSchema } from "../models/errors/serviceunavailableresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
13
13
|
import { GetPresetResponse$inboundSchema as models_GetPresetResponse$inboundSchema } from "../models/getpresetresponse.js";
|
|
14
14
|
import { GetPresetRequest$outboundSchema as operations_GetPresetRequest$outboundSchema } from "../models/operations/getpreset.js";
|
|
15
15
|
import { APIPromise } from "../types/async.js";
|
|
@@ -96,7 +96,7 @@ async function $do(client, request, options) {
|
|
|
96
96
|
const responseFields = {
|
|
97
97
|
HttpMeta: { Response: response, Request: req },
|
|
98
98
|
};
|
|
99
|
-
const [result] = await M.match(M.json(200, models_GetPresetResponse$inboundSchema), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
99
|
+
const [result] = await M.match(M.json(200, models_GetPresetResponse$inboundSchema), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.jsonErr(503, errors_ServiceUnavailableResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
100
100
|
if (!result.ok) {
|
|
101
101
|
return [result, { status: "complete", request: req, response }];
|
|
102
102
|
}
|
|
@@ -17,5 +17,5 @@ import { Result } from "../types/fp.js";
|
|
|
17
17
|
*
|
|
18
18
|
* If set, this operation will use {@link Security.apiKey} from the global security.
|
|
19
19
|
*/
|
|
20
|
-
export declare function presetsGetVersion(client: OpenRouterCore, request: operations.GetPresetVersionRequest, options?: RequestOptions): APIPromise<Result<models.GetPresetVersionResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
20
|
+
export declare function presetsGetVersion(client: OpenRouterCore, request: operations.GetPresetVersionRequest, options?: RequestOptions): APIPromise<Result<models.GetPresetVersionResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | errors.ServiceUnavailableResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
21
21
|
//# sourceMappingURL=presetsGetVersion.d.ts.map
|
|
@@ -9,7 +9,7 @@ import { compactMap } from "../lib/primitives.js";
|
|
|
9
9
|
import { safeParse } from "../lib/schemas.js";
|
|
10
10
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
12
|
+
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { ServiceUnavailableResponseError$inboundSchema as errors_ServiceUnavailableResponseError$inboundSchema } from "../models/errors/serviceunavailableresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
13
13
|
import { GetPresetVersionResponse$inboundSchema as models_GetPresetVersionResponse$inboundSchema } from "../models/getpresetversionresponse.js";
|
|
14
14
|
import { GetPresetVersionRequest$outboundSchema as operations_GetPresetVersionRequest$outboundSchema } from "../models/operations/getpresetversion.js";
|
|
15
15
|
import { APIPromise } from "../types/async.js";
|
|
@@ -100,7 +100,7 @@ async function $do(client, request, options) {
|
|
|
100
100
|
const responseFields = {
|
|
101
101
|
HttpMeta: { Response: response, Request: req },
|
|
102
102
|
};
|
|
103
|
-
const [result] = await M.match(M.json(200, models_GetPresetVersionResponse$inboundSchema), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
103
|
+
const [result] = await M.match(M.json(200, models_GetPresetVersionResponse$inboundSchema), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.jsonErr(503, errors_ServiceUnavailableResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
104
104
|
if (!result.ok) {
|
|
105
105
|
return [result, { status: "complete", request: req, response }];
|
|
106
106
|
}
|
|
@@ -17,7 +17,7 @@ import { PageIterator } from "../types/operations.js";
|
|
|
17
17
|
*
|
|
18
18
|
* If set, this operation will use {@link Security.apiKey} from the global security.
|
|
19
19
|
*/
|
|
20
|
-
export declare function presetsList(client: OpenRouterCore, request?: operations.ListPresetsRequest | undefined, options?: RequestOptions): APIPromise<PageIterator<Result<operations.ListPresetsResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>, {
|
|
20
|
+
export declare function presetsList(client: OpenRouterCore, request?: operations.ListPresetsRequest | undefined, options?: RequestOptions): APIPromise<PageIterator<Result<operations.ListPresetsResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.InternalServerResponseError | errors.ServiceUnavailableResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>, {
|
|
21
21
|
offset: number;
|
|
22
22
|
}>>;
|
|
23
23
|
//# sourceMappingURL=presetsList.d.ts.map
|
package/esm/funcs/presetsList.js
CHANGED
|
@@ -9,7 +9,7 @@ import { compactMap } from "../lib/primitives.js";
|
|
|
9
9
|
import { safeParse } from "../lib/schemas.js";
|
|
10
10
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
12
|
+
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { ServiceUnavailableResponseError$inboundSchema as errors_ServiceUnavailableResponseError$inboundSchema } from "../models/errors/serviceunavailableresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
13
13
|
import { ListPresetsRequest$outboundSchema as operations_ListPresetsRequest$outboundSchema, ListPresetsResponse$inboundSchema as operations_ListPresetsResponse$inboundSchema } from "../models/operations/listpresets.js";
|
|
14
14
|
import { APIPromise } from "../types/async.js";
|
|
15
15
|
import { createPageIterator, haltIterator, } from "../types/operations.js";
|
|
@@ -97,7 +97,7 @@ async function $do(client, request, options) {
|
|
|
97
97
|
};
|
|
98
98
|
const [result, raw] = await M.match(M.json(200, operations_ListPresetsResponse$inboundSchema, {
|
|
99
99
|
key: "Result",
|
|
100
|
-
}), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
100
|
+
}), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.jsonErr(503, errors_ServiceUnavailableResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
101
101
|
if (!result.ok) {
|
|
102
102
|
return [haltIterator(result), {
|
|
103
103
|
status: "complete",
|
|
@@ -17,7 +17,7 @@ import { PageIterator } from "../types/operations.js";
|
|
|
17
17
|
*
|
|
18
18
|
* If set, this operation will use {@link Security.apiKey} from the global security.
|
|
19
19
|
*/
|
|
20
|
-
export declare function presetsListVersions(client: OpenRouterCore, request: operations.ListPresetVersionsRequest, options?: RequestOptions): APIPromise<PageIterator<Result<operations.ListPresetVersionsResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>, {
|
|
20
|
+
export declare function presetsListVersions(client: OpenRouterCore, request: operations.ListPresetVersionsRequest, options?: RequestOptions): APIPromise<PageIterator<Result<operations.ListPresetVersionsResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | errors.ServiceUnavailableResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>, {
|
|
21
21
|
offset: number;
|
|
22
22
|
}>>;
|
|
23
23
|
//# sourceMappingURL=presetsListVersions.d.ts.map
|
|
@@ -9,7 +9,7 @@ import { compactMap } from "../lib/primitives.js";
|
|
|
9
9
|
import { safeParse } from "../lib/schemas.js";
|
|
10
10
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
|
-
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
12
|
+
import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { ServiceUnavailableResponseError$inboundSchema as errors_ServiceUnavailableResponseError$inboundSchema } from "../models/errors/serviceunavailableresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js";
|
|
13
13
|
import { ListPresetVersionsRequest$outboundSchema as operations_ListPresetVersionsRequest$outboundSchema, ListPresetVersionsResponse$inboundSchema as operations_ListPresetVersionsResponse$inboundSchema } from "../models/operations/listpresetversions.js";
|
|
14
14
|
import { APIPromise } from "../types/async.js";
|
|
15
15
|
import { createPageIterator, haltIterator, } from "../types/operations.js";
|
|
@@ -103,7 +103,7 @@ async function $do(client, request, options) {
|
|
|
103
103
|
};
|
|
104
104
|
const [result, raw] = await M.match(M.json(200, operations_ListPresetVersionsResponse$inboundSchema, {
|
|
105
105
|
key: "Result",
|
|
106
|
-
}), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
106
|
+
}), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.jsonErr(503, errors_ServiceUnavailableResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
107
107
|
if (!result.ok) {
|
|
108
108
|
return [haltIterator(result), {
|
|
109
109
|
status: "complete",
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { OpenRouterCore } from "../core.js";
|
|
2
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
3
|
+
import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
|
|
4
|
+
import * as errors from "../models/errors/index.js";
|
|
5
|
+
import { OpenRouterError } from "../models/errors/openroutererror.js";
|
|
6
|
+
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
7
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
8
|
+
import * as models from "../models/index.js";
|
|
9
|
+
import * as operations from "../models/operations/index.js";
|
|
10
|
+
import { APIPromise } from "../types/async.js";
|
|
11
|
+
import { Result } from "../types/fp.js";
|
|
12
|
+
/**
|
|
13
|
+
* Set private endpoint supported parameters
|
|
14
|
+
*
|
|
15
|
+
* @remarks
|
|
16
|
+
* Declare which request parameters the upstream supports beyond the ones validation proved. Applies to drafts and active endpoints; routing picks the change up for subsequent requests. The body replaces the earlier declaration and is read as a set: order and repeated names do not matter, but the list holds at most as many entries as there are declarable parameters, repeats included. `tested_parameters` stay. Returns 400 `parameters_invalid` when `tool_choice` is declared without `tools` being tested or declared. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
17
|
+
*/
|
|
18
|
+
export declare function privateEndpointsUpdateParameters(client: OpenRouterCore, request: operations.UpdatePrivateEndpointParametersRequest, options?: RequestOptions): APIPromise<Result<models.PrivateEndpointResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.RequestTimeoutResponseError | errors.ConflictResponseError | errors.UnprocessableEntityResponseError | errors.InternalServerResponseError | errors.BadGatewayResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
19
|
+
//# sourceMappingURL=privateEndpointsUpdateParameters.d.ts.map
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: a541ac958e3d
|
|
4
|
+
*/
|
|
5
|
+
import { encodeJSON, encodeSimple } from "../lib/encodings.js";
|
|
6
|
+
import { matchStatusCode } from "../lib/http.js";
|
|
7
|
+
import * as M from "../lib/matchers.js";
|
|
8
|
+
import { compactMap } from "../lib/primitives.js";
|
|
9
|
+
import { safeParse } from "../lib/schemas.js";
|
|
10
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
11
|
+
import { pathToFunc } from "../lib/url.js";
|
|
12
|
+
import { BadGatewayResponseError$inboundSchema as errors_BadGatewayResponseError$inboundSchema } from "../models/errors/badgatewayresponseerror.js"; import { BadRequestResponseError$inboundSchema as errors_BadRequestResponseError$inboundSchema } from "../models/errors/badrequestresponseerror.js"; import { ConflictResponseError$inboundSchema as errors_ConflictResponseError$inboundSchema } from "../models/errors/conflictresponseerror.js"; import { ForbiddenResponseError$inboundSchema as errors_ForbiddenResponseError$inboundSchema } from "../models/errors/forbiddenresponseerror.js"; import { InternalServerResponseError$inboundSchema as errors_InternalServerResponseError$inboundSchema } from "../models/errors/internalserverresponseerror.js"; import { NotFoundResponseError$inboundSchema as errors_NotFoundResponseError$inboundSchema } from "../models/errors/notfoundresponseerror.js"; import { RequestTimeoutResponseError$inboundSchema as errors_RequestTimeoutResponseError$inboundSchema } from "../models/errors/requesttimeoutresponseerror.js"; import { UnauthorizedResponseError$inboundSchema as errors_UnauthorizedResponseError$inboundSchema } from "../models/errors/unauthorizedresponseerror.js"; import { UnprocessableEntityResponseError$inboundSchema as errors_UnprocessableEntityResponseError$inboundSchema } from "../models/errors/unprocessableentityresponseerror.js";
|
|
13
|
+
import { PrivateEndpointResponse$inboundSchema as models_PrivateEndpointResponse$inboundSchema } from "../models/privateendpointresponse.js";
|
|
14
|
+
import { UpdatePrivateEndpointParametersRequest$outboundSchema as operations_UpdatePrivateEndpointParametersRequest$outboundSchema } from "../models/operations/updateprivateendpointparameters.js";
|
|
15
|
+
import { APIPromise } from "../types/async.js";
|
|
16
|
+
/**
|
|
17
|
+
* Set private endpoint supported parameters
|
|
18
|
+
*
|
|
19
|
+
* @remarks
|
|
20
|
+
* Declare which request parameters the upstream supports beyond the ones validation proved. Applies to drafts and active endpoints; routing picks the change up for subsequent requests. The body replaces the earlier declaration and is read as a set: order and repeated names do not matter, but the list holds at most as many entries as there are declarable parameters, repeats included. `tested_parameters` stay. Returns 400 `parameters_invalid` when `tool_choice` is declared without `tools` being tested or declared. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
21
|
+
*/
|
|
22
|
+
export function privateEndpointsUpdateParameters(client, request, options) {
|
|
23
|
+
return new APIPromise($do(client, request, options));
|
|
24
|
+
}
|
|
25
|
+
async function $do(client, request, options) {
|
|
26
|
+
const parsed = safeParse(request, (value) => operations_UpdatePrivateEndpointParametersRequest$outboundSchema.parse(value), "Input validation failed");
|
|
27
|
+
if (!parsed.ok) {
|
|
28
|
+
return [parsed, { status: "invalid" }];
|
|
29
|
+
}
|
|
30
|
+
const payload = parsed.value;
|
|
31
|
+
const body = encodeJSON("body", payload.UpdatePrivateEndpointParametersRequest, { explode: true });
|
|
32
|
+
const pathParams = {
|
|
33
|
+
id: encodeSimple("id", payload.id, {
|
|
34
|
+
explode: false,
|
|
35
|
+
charEncoding: "percent",
|
|
36
|
+
}),
|
|
37
|
+
};
|
|
38
|
+
const path = pathToFunc("/private-endpoints/{id}/parameters")(pathParams);
|
|
39
|
+
const headers = new Headers(compactMap({
|
|
40
|
+
"Content-Type": "application/json",
|
|
41
|
+
Accept: "application/json",
|
|
42
|
+
"HTTP-Referer": encodeSimple("HTTP-Referer", payload["HTTP-Referer"] ?? client._options.httpReferer, { explode: false, charEncoding: "none" }),
|
|
43
|
+
"X-OpenRouter-Categories": encodeSimple("X-OpenRouter-Categories", payload.appCategories ?? client._options.appCategories, { explode: false, charEncoding: "none" }),
|
|
44
|
+
"X-OpenRouter-Title": encodeSimple("X-OpenRouter-Title", payload.appTitle ?? client._options.appTitle, { explode: false, charEncoding: "none" }),
|
|
45
|
+
}));
|
|
46
|
+
const secConfig = await extractSecurity(client._options.apiKey);
|
|
47
|
+
const securityInput = secConfig == null ? {} : { apiKey: secConfig };
|
|
48
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
49
|
+
const context = {
|
|
50
|
+
options: client._options,
|
|
51
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
52
|
+
operationID: "updatePrivateEndpointParameters",
|
|
53
|
+
oAuth2Scopes: null,
|
|
54
|
+
resolvedSecurity: requestSecurity,
|
|
55
|
+
securitySource: client._options.apiKey,
|
|
56
|
+
retryConfig: options?.retries
|
|
57
|
+
|| client._options.retryConfig
|
|
58
|
+
|| {
|
|
59
|
+
strategy: "backoff",
|
|
60
|
+
backoff: {
|
|
61
|
+
initialInterval: 500,
|
|
62
|
+
maxInterval: 60000,
|
|
63
|
+
exponent: 1.5,
|
|
64
|
+
maxElapsedTime: 3600000,
|
|
65
|
+
},
|
|
66
|
+
retryConnectionErrors: true,
|
|
67
|
+
}
|
|
68
|
+
|| { strategy: "none" },
|
|
69
|
+
retryCodes: options?.retryCodes || ["5XX"],
|
|
70
|
+
};
|
|
71
|
+
const requestRes = client._createRequest(context, {
|
|
72
|
+
security: requestSecurity,
|
|
73
|
+
method: "PUT",
|
|
74
|
+
baseURL: options?.serverURL,
|
|
75
|
+
path: path,
|
|
76
|
+
headers: headers,
|
|
77
|
+
body: body,
|
|
78
|
+
userAgent: client._options.userAgent,
|
|
79
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
80
|
+
}, options);
|
|
81
|
+
if (!requestRes.ok) {
|
|
82
|
+
return [requestRes, { status: "invalid" }];
|
|
83
|
+
}
|
|
84
|
+
const req = requestRes.value;
|
|
85
|
+
const doResult = await client._do(req, {
|
|
86
|
+
context,
|
|
87
|
+
isErrorStatusCode: (statusCode) => matchStatusCode({ status: statusCode }, ["4XX", "5XX"]),
|
|
88
|
+
retryConfig: context.retryConfig,
|
|
89
|
+
retryCodes: context.retryCodes,
|
|
90
|
+
});
|
|
91
|
+
if (!doResult.ok) {
|
|
92
|
+
return [doResult, { status: "request-error", request: req }];
|
|
93
|
+
}
|
|
94
|
+
const response = doResult.value;
|
|
95
|
+
const responseFields = {
|
|
96
|
+
HttpMeta: { Response: response, Request: req },
|
|
97
|
+
};
|
|
98
|
+
const [result] = await M.match(M.json(200, models_PrivateEndpointResponse$inboundSchema), M.jsonErr(400, errors_BadRequestResponseError$inboundSchema), M.jsonErr(401, errors_UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors_ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors_NotFoundResponseError$inboundSchema), M.jsonErr(408, errors_RequestTimeoutResponseError$inboundSchema), M.jsonErr(409, errors_ConflictResponseError$inboundSchema), M.jsonErr(422, errors_UnprocessableEntityResponseError$inboundSchema), M.jsonErr(500, errors_InternalServerResponseError$inboundSchema), M.jsonErr(502, errors_BadGatewayResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
|
|
99
|
+
if (!result.ok) {
|
|
100
|
+
return [result, { status: "complete", request: req, response }];
|
|
101
|
+
}
|
|
102
|
+
return [result, { status: "complete", request: req, response }];
|
|
103
|
+
}
|
|
104
|
+
//# sourceMappingURL=privateEndpointsUpdateParameters.js.map
|
package/esm/lib/config.d.ts
CHANGED
|
@@ -50,8 +50,8 @@ export declare function serverURLFromOptions(options: SDKOptions): URL | null;
|
|
|
50
50
|
export declare const SDK_METADATA: {
|
|
51
51
|
readonly language: "typescript";
|
|
52
52
|
readonly openapiDocVersion: "1.0.0";
|
|
53
|
-
readonly sdkVersion: "1.5.
|
|
53
|
+
readonly sdkVersion: "1.5.12";
|
|
54
54
|
readonly genVersion: "2.948.4";
|
|
55
|
-
readonly userAgent: "speakeasy-sdk/typescript 1.5.
|
|
55
|
+
readonly userAgent: "speakeasy-sdk/typescript 1.5.12 2.948.4 1.0.0 @openrouter/sdk";
|
|
56
56
|
};
|
|
57
57
|
//# sourceMappingURL=config.d.ts.map
|
package/esm/lib/config.js
CHANGED
|
@@ -29,8 +29,8 @@ export function serverURLFromOptions(options) {
|
|
|
29
29
|
export const SDK_METADATA = {
|
|
30
30
|
language: "typescript",
|
|
31
31
|
openapiDocVersion: "1.0.0",
|
|
32
|
-
sdkVersion: "1.5.
|
|
32
|
+
sdkVersion: "1.5.12",
|
|
33
33
|
genVersion: "2.948.4",
|
|
34
|
-
userAgent: "speakeasy-sdk/typescript 1.5.
|
|
34
|
+
userAgent: "speakeasy-sdk/typescript 1.5.12 2.948.4 1.0.0 @openrouter/sdk",
|
|
35
35
|
};
|
|
36
36
|
//# sourceMappingURL=config.js.map
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as z from "zod/v4";
|
|
2
2
|
import { OpenEnum } from "../types/enums.js";
|
|
3
3
|
import { PrivateEndpointActivation, PrivateEndpointActivation$Outbound } from "./privateendpointactivation.js";
|
|
4
|
+
import { PrivateEndpointDeclaredParameter } from "./privateendpointdeclaredparameter.js";
|
|
4
5
|
import { PrivateEndpointPricing, PrivateEndpointPricing$Outbound } from "./privateendpointpricing.js";
|
|
5
6
|
/**
|
|
6
7
|
* Attest where this deployment processes data.
|
|
@@ -23,6 +24,10 @@ export type CreatePrivateEndpointRequest = {
|
|
|
23
24
|
* HTTPS base URL of your deployment. Required unless the provider derives its URL from the BYOK credential (Azure, Amazon Bedrock, Google Vertex).
|
|
24
25
|
*/
|
|
25
26
|
baseUrl?: string | undefined;
|
|
27
|
+
/**
|
|
28
|
+
* Parameters the upstream supports beyond the tested ones. Replaces the earlier declaration; tested parameters stay. Order and repeated names are ignored, but the list holds at most as many entries as there are declarable parameters, repeats included. `tool_choice` requires `tools` to be tested or declared.
|
|
29
|
+
*/
|
|
30
|
+
declaredParameters?: Array<PrivateEndpointDeclaredParameter> | undefined;
|
|
26
31
|
/**
|
|
27
32
|
* Attest where this deployment processes data.
|
|
28
33
|
*/
|
|
@@ -31,6 +36,10 @@ export type CreatePrivateEndpointRequest = {
|
|
|
31
36
|
* Attest that this deployment retains no prompt or completion data.
|
|
32
37
|
*/
|
|
33
38
|
declaredZdr?: boolean | null | undefined;
|
|
39
|
+
/**
|
|
40
|
+
* Cap on completion tokens per request. Requests asking for more skip this endpoint, and the default output length stays within it. When omitted, the cap is copied from the public endpoint for the same model and provider, if there is one.
|
|
41
|
+
*/
|
|
42
|
+
maxCompletionTokens?: number | undefined;
|
|
34
43
|
/**
|
|
35
44
|
* Permanent slug of the model this endpoint serves.
|
|
36
45
|
*/
|
|
@@ -54,8 +63,10 @@ export declare const CreatePrivateEndpointRequestDeclaredRegion$outboundSchema:
|
|
|
54
63
|
export type CreatePrivateEndpointRequest$Outbound = {
|
|
55
64
|
activate?: PrivateEndpointActivation$Outbound | undefined;
|
|
56
65
|
base_url?: string | undefined;
|
|
66
|
+
declared_parameters?: Array<string> | undefined;
|
|
57
67
|
declared_region?: string | null | undefined;
|
|
58
68
|
declared_zdr?: boolean | null | undefined;
|
|
69
|
+
max_completion_tokens?: number | undefined;
|
|
59
70
|
model_permaslug: string;
|
|
60
71
|
pricing?: PrivateEndpointPricing$Outbound | undefined;
|
|
61
72
|
provider_slug: string;
|
|
@@ -6,6 +6,7 @@ import * as z from "zod/v4";
|
|
|
6
6
|
import { remap as remap$ } from "../lib/primitives.js";
|
|
7
7
|
import * as openEnums from "../types/enums.js";
|
|
8
8
|
import { PrivateEndpointActivation$outboundSchema, } from "./privateendpointactivation.js";
|
|
9
|
+
import { PrivateEndpointDeclaredParameter$outboundSchema, } from "./privateendpointdeclaredparameter.js";
|
|
9
10
|
import { PrivateEndpointPricing$outboundSchema, } from "./privateendpointpricing.js";
|
|
10
11
|
/**
|
|
11
12
|
* Attest where this deployment processes data.
|
|
@@ -22,8 +23,11 @@ export const CreatePrivateEndpointRequestDeclaredRegion$outboundSchema = openEnu
|
|
|
22
23
|
export const CreatePrivateEndpointRequest$outboundSchema = z.object({
|
|
23
24
|
activate: PrivateEndpointActivation$outboundSchema.optional(),
|
|
24
25
|
baseUrl: z.string().optional(),
|
|
26
|
+
declaredParameters: z.array(PrivateEndpointDeclaredParameter$outboundSchema)
|
|
27
|
+
.optional(),
|
|
25
28
|
declaredRegion: z.nullable(CreatePrivateEndpointRequestDeclaredRegion$outboundSchema).optional(),
|
|
26
29
|
declaredZdr: z.nullable(z.boolean()).optional(),
|
|
30
|
+
maxCompletionTokens: z.int().optional(),
|
|
27
31
|
modelPermaslug: z.string(),
|
|
28
32
|
pricing: PrivateEndpointPricing$outboundSchema.optional(),
|
|
29
33
|
providerSlug: z.string(),
|
|
@@ -31,8 +35,10 @@ export const CreatePrivateEndpointRequest$outboundSchema = z.object({
|
|
|
31
35
|
}).transform((v) => {
|
|
32
36
|
return remap$(v, {
|
|
33
37
|
baseUrl: "base_url",
|
|
38
|
+
declaredParameters: "declared_parameters",
|
|
34
39
|
declaredRegion: "declared_region",
|
|
35
40
|
declaredZdr: "declared_zdr",
|
|
41
|
+
maxCompletionTokens: "max_completion_tokens",
|
|
36
42
|
modelPermaslug: "model_permaslug",
|
|
37
43
|
providerSlug: "provider_slug",
|
|
38
44
|
upstreamModelId: "upstream_model_id",
|
package/esm/models/index.d.ts
CHANGED
|
@@ -612,7 +612,9 @@ export * from "./privateendpoint.js";
|
|
|
612
612
|
export * from "./privateendpointactivation.js";
|
|
613
613
|
export * from "./privateendpointcheck.js";
|
|
614
614
|
export * from "./privateendpointcheckreason.js";
|
|
615
|
+
export * from "./privateendpointdeclaredparameter.js";
|
|
615
616
|
export * from "./privateendpointdeclaredregion.js";
|
|
617
|
+
export * from "./privateendpointparametercheck.js";
|
|
616
618
|
export * from "./privateendpointpricing.js";
|
|
617
619
|
export * from "./privateendpointresponse.js";
|
|
618
620
|
export * from "./privateendpointstatus.js";
|
|
@@ -778,6 +780,7 @@ export * from "./updateguardrailresponse.js";
|
|
|
778
780
|
export * from "./updateobservabilitydestinationrequest.js";
|
|
779
781
|
export * from "./updateobservabilitydestinationresponse.js";
|
|
780
782
|
export * from "./updateorganizationsettingsrequest.js";
|
|
783
|
+
export * from "./updateprivateendpointparametersrequest.js";
|
|
781
784
|
export * from "./updateprivateendpointpricingrequest.js";
|
|
782
785
|
export * from "./updateprivateendpointrequest.js";
|
|
783
786
|
export * from "./updatescimgroupmappingrequest.js";
|
package/esm/models/index.js
CHANGED
|
@@ -616,7 +616,9 @@ export * from "./privateendpoint.js";
|
|
|
616
616
|
export * from "./privateendpointactivation.js";
|
|
617
617
|
export * from "./privateendpointcheck.js";
|
|
618
618
|
export * from "./privateendpointcheckreason.js";
|
|
619
|
+
export * from "./privateendpointdeclaredparameter.js";
|
|
619
620
|
export * from "./privateendpointdeclaredregion.js";
|
|
621
|
+
export * from "./privateendpointparametercheck.js";
|
|
620
622
|
export * from "./privateendpointpricing.js";
|
|
621
623
|
export * from "./privateendpointresponse.js";
|
|
622
624
|
export * from "./privateendpointstatus.js";
|
|
@@ -782,6 +784,7 @@ export * from "./updateguardrailresponse.js";
|
|
|
782
784
|
export * from "./updateobservabilitydestinationrequest.js";
|
|
783
785
|
export * from "./updateobservabilitydestinationresponse.js";
|
|
784
786
|
export * from "./updateorganizationsettingsrequest.js";
|
|
787
|
+
export * from "./updateprivateendpointparametersrequest.js";
|
|
785
788
|
export * from "./updateprivateendpointpricingrequest.js";
|
|
786
789
|
export * from "./updateprivateendpointrequest.js";
|
|
787
790
|
export * from "./updatescimgroupmappingrequest.js";
|
|
@@ -40,6 +40,10 @@ export type ManagedPrivateEndpoint = {
|
|
|
40
40
|
* Whether you attest this deployment retains no prompt or completion data. `null` means undeclared.
|
|
41
41
|
*/
|
|
42
42
|
declaredZdr: boolean | null;
|
|
43
|
+
/**
|
|
44
|
+
* Most completion tokens a request routed to this endpoint can produce, or `null` when the endpoint sets no cap beyond the model context length.
|
|
45
|
+
*/
|
|
46
|
+
maxCompletionTokens?: number | null | undefined;
|
|
43
47
|
};
|
|
44
48
|
/** @internal */
|
|
45
49
|
export declare const ManagedPrivateEndpoint$inboundSchema: z.ZodType<ManagedPrivateEndpoint, unknown>;
|
|
@@ -18,6 +18,7 @@ export const ManagedPrivateEndpoint$inboundSchema = z.object({
|
|
|
18
18
|
status: PrivateEndpointStatus$inboundSchema,
|
|
19
19
|
declared_region: z.nullable(PrivateEndpointDeclaredRegion$inboundSchema),
|
|
20
20
|
declared_zdr: z.nullable(z.boolean()),
|
|
21
|
+
max_completion_tokens: z.nullable(z.int()).optional(),
|
|
21
22
|
}).transform((v) => {
|
|
22
23
|
return remap$(v, {
|
|
23
24
|
"created_at": "createdAt",
|
|
@@ -27,6 +28,7 @@ export const ManagedPrivateEndpoint$inboundSchema = z.object({
|
|
|
27
28
|
"provider_name": "providerName",
|
|
28
29
|
"declared_region": "declaredRegion",
|
|
29
30
|
"declared_zdr": "declaredZdr",
|
|
31
|
+
"max_completion_tokens": "maxCompletionTokens",
|
|
30
32
|
});
|
|
31
33
|
});
|
|
32
34
|
export function managedPrivateEndpointFromJSON(jsonString) {
|
|
@@ -42,7 +42,7 @@ export type CreatePrivateEndpointRequest = {
|
|
|
42
42
|
*/
|
|
43
43
|
appCategories?: string | undefined;
|
|
44
44
|
/**
|
|
45
|
-
* Retry-safe create: a repeated create with the same key from the same organization returns the endpoint the first request created instead of creating another. The endpoint is returned as it is now. Reusing a key with a different request body (model, provider, base URL, upstream model ID, declared ZDR or region, or
|
|
45
|
+
* Retry-safe create: a repeated create with the same key from the same organization returns the endpoint the first request created instead of creating another. The endpoint is returned as it is now. Reusing a key with a different request body (model, provider, base URL, upstream model ID, declared ZDR or region, pricing, or declared parameters) is rejected with 422 `idempotency_key_reused`. Declared parameters are compared as a set, so a retry that reorders or repeats a name replays the endpoint. `activate` and `max_completion_tokens` are not compared, and later edits to the endpoint do not affect the comparison.
|
|
46
46
|
*/
|
|
47
47
|
idempotencyKey?: string | undefined;
|
|
48
48
|
createPrivateEndpointRequest: models.CreatePrivateEndpointRequest;
|
|
@@ -130,6 +130,7 @@ export * from "./updatekeys.js";
|
|
|
130
130
|
export * from "./updateobservabilitydestination.js";
|
|
131
131
|
export * from "./updateorganizationsettings.js";
|
|
132
132
|
export * from "./updateprivateendpoint.js";
|
|
133
|
+
export * from "./updateprivateendpointparameters.js";
|
|
133
134
|
export * from "./updateprivateendpointpricing.js";
|
|
134
135
|
export * from "./updatescimgroupmapping.js";
|
|
135
136
|
export * from "./updateworkspace.js";
|
|
@@ -134,6 +134,7 @@ export * from "./updatekeys.js";
|
|
|
134
134
|
export * from "./updateobservabilitydestination.js";
|
|
135
135
|
export * from "./updateorganizationsettings.js";
|
|
136
136
|
export * from "./updateprivateendpoint.js";
|
|
137
|
+
export * from "./updateprivateendpointparameters.js";
|
|
137
138
|
export * from "./updateprivateendpointpricing.js";
|
|
138
139
|
export * from "./updatescimgroupmapping.js";
|
|
139
140
|
export * from "./updateworkspace.js";
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
import * as models from "../index.js";
|
|
3
|
+
export type UpdatePrivateEndpointParametersGlobals = {
|
|
4
|
+
/**
|
|
5
|
+
* The app identifier should be your app's URL and is used as the primary identifier for rankings.
|
|
6
|
+
*
|
|
7
|
+
* @remarks
|
|
8
|
+
* This is used to track API usage per application.
|
|
9
|
+
*/
|
|
10
|
+
httpReferer?: string | undefined;
|
|
11
|
+
/**
|
|
12
|
+
* The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
|
13
|
+
*
|
|
14
|
+
* @remarks
|
|
15
|
+
*/
|
|
16
|
+
appTitle?: string | undefined;
|
|
17
|
+
/**
|
|
18
|
+
* Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
|
|
19
|
+
*
|
|
20
|
+
* @remarks
|
|
21
|
+
*/
|
|
22
|
+
appCategories?: string | undefined;
|
|
23
|
+
};
|
|
24
|
+
export type UpdatePrivateEndpointParametersRequest = {
|
|
25
|
+
/**
|
|
26
|
+
* The app identifier should be your app's URL and is used as the primary identifier for rankings.
|
|
27
|
+
*
|
|
28
|
+
* @remarks
|
|
29
|
+
* This is used to track API usage per application.
|
|
30
|
+
*/
|
|
31
|
+
httpReferer?: string | undefined;
|
|
32
|
+
/**
|
|
33
|
+
* The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
|
34
|
+
*
|
|
35
|
+
* @remarks
|
|
36
|
+
*/
|
|
37
|
+
appTitle?: string | undefined;
|
|
38
|
+
/**
|
|
39
|
+
* Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
|
|
40
|
+
*
|
|
41
|
+
* @remarks
|
|
42
|
+
*/
|
|
43
|
+
appCategories?: string | undefined;
|
|
44
|
+
/**
|
|
45
|
+
* Stable identifier of the private endpoint.
|
|
46
|
+
*/
|
|
47
|
+
id: string;
|
|
48
|
+
updatePrivateEndpointParametersRequest: models.UpdatePrivateEndpointParametersRequest;
|
|
49
|
+
};
|
|
50
|
+
/** @internal */
|
|
51
|
+
export type UpdatePrivateEndpointParametersRequest$Outbound = {
|
|
52
|
+
"HTTP-Referer"?: string | undefined;
|
|
53
|
+
appTitle?: string | undefined;
|
|
54
|
+
appCategories?: string | undefined;
|
|
55
|
+
id: string;
|
|
56
|
+
UpdatePrivateEndpointParametersRequest: models.UpdatePrivateEndpointParametersRequest$Outbound;
|
|
57
|
+
};
|
|
58
|
+
/** @internal */
|
|
59
|
+
export declare const UpdatePrivateEndpointParametersRequest$outboundSchema: z.ZodType<UpdatePrivateEndpointParametersRequest$Outbound, UpdatePrivateEndpointParametersRequest>;
|
|
60
|
+
export declare function updatePrivateEndpointParametersRequestToJSON(updatePrivateEndpointParametersRequest: UpdatePrivateEndpointParametersRequest): string;
|
|
61
|
+
//# sourceMappingURL=updateprivateendpointparameters.d.ts.map
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: 7665d9dbe783
|
|
4
|
+
*/
|
|
5
|
+
import * as z from "zod/v4";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { UpdatePrivateEndpointParametersRequest$outboundSchema as models_UpdatePrivateEndpointParametersRequest$outboundSchema } from "../updateprivateendpointparametersrequest.js";
|
|
8
|
+
/** @internal */
|
|
9
|
+
export const UpdatePrivateEndpointParametersRequest$outboundSchema = z.object({
|
|
10
|
+
httpReferer: z.string().optional(),
|
|
11
|
+
appTitle: z.string().optional(),
|
|
12
|
+
appCategories: z.string().optional(),
|
|
13
|
+
id: z.string(),
|
|
14
|
+
updatePrivateEndpointParametersRequest: models_UpdatePrivateEndpointParametersRequest$outboundSchema,
|
|
15
|
+
}).transform((v) => {
|
|
16
|
+
return remap$(v, {
|
|
17
|
+
httpReferer: "HTTP-Referer",
|
|
18
|
+
updatePrivateEndpointParametersRequest: "UpdatePrivateEndpointParametersRequest",
|
|
19
|
+
});
|
|
20
|
+
});
|
|
21
|
+
export function updatePrivateEndpointParametersRequestToJSON(updatePrivateEndpointParametersRequest) {
|
|
22
|
+
return JSON.stringify(UpdatePrivateEndpointParametersRequest$outboundSchema.parse(updatePrivateEndpointParametersRequest));
|
|
23
|
+
}
|
|
24
|
+
//# sourceMappingURL=updateprivateendpointparameters.js.map
|
|
@@ -9,6 +9,10 @@ export type PrivateEndpoint = {
|
|
|
9
9
|
* HTTPS base URL of your deployment, or `null` for providers whose URL is derived from the BYOK credential (Azure, Amazon Bedrock, Google Vertex).
|
|
10
10
|
*/
|
|
11
11
|
baseUrl: string | null;
|
|
12
|
+
/**
|
|
13
|
+
* Parameters you declared the upstream supports. Requests that use a parameter only route to this endpoint when it is tested or declared.
|
|
14
|
+
*/
|
|
15
|
+
declaredParameters: Array<string>;
|
|
12
16
|
/**
|
|
13
17
|
* Where you attest this deployment processes data. `global` means not regional; `null` means undeclared.
|
|
14
18
|
*/
|
|
@@ -21,6 +25,10 @@ export type PrivateEndpoint = {
|
|
|
21
25
|
* Stable identifier of the private endpoint.
|
|
22
26
|
*/
|
|
23
27
|
id: string;
|
|
28
|
+
/**
|
|
29
|
+
* Most completion tokens a request routed to this endpoint can produce, or `null` when the endpoint sets no cap beyond the model context length.
|
|
30
|
+
*/
|
|
31
|
+
maxCompletionTokens?: number | null | undefined;
|
|
24
32
|
/**
|
|
25
33
|
* Display name of the model, or `null` when the model is no longer listed.
|
|
26
34
|
*/
|
|
@@ -49,6 +57,10 @@ export type PrivateEndpoint = {
|
|
|
49
57
|
* Lifecycle state. `draft` endpoints are not routable until validated and activated; `disabled` endpoints are activated but temporarily not routable.
|
|
50
58
|
*/
|
|
51
59
|
status: PrivateEndpointStatus;
|
|
60
|
+
/**
|
|
61
|
+
* Parameters a validation run proved the upstream honors (`tools`, `tool_choice`, `response_format`, `structured_outputs`, `stop`). Read-only; cleared when the upstream configuration changes.
|
|
62
|
+
*/
|
|
63
|
+
testedParameters: Array<string>;
|
|
52
64
|
/**
|
|
53
65
|
* Model or deployment identifier sent to the upstream provider.
|
|
54
66
|
*/
|
|
@@ -11,9 +11,11 @@ import { PrivateEndpointStatus$inboundSchema, } from "./privateendpointstatus.js
|
|
|
11
11
|
/** @internal */
|
|
12
12
|
export const PrivateEndpoint$inboundSchema = z.object({
|
|
13
13
|
base_url: z.nullable(z.string()),
|
|
14
|
+
declared_parameters: z.array(z.string()),
|
|
14
15
|
declared_region: z.nullable(PrivateEndpointDeclaredRegion$inboundSchema),
|
|
15
16
|
declared_zdr: z.nullable(z.boolean()),
|
|
16
17
|
id: z.string(),
|
|
18
|
+
max_completion_tokens: z.nullable(z.int()).optional(),
|
|
17
19
|
model_name: z.nullable(z.string()),
|
|
18
20
|
model_permaslug: z.string(),
|
|
19
21
|
model_slug: z.nullable(z.string()),
|
|
@@ -21,17 +23,21 @@ export const PrivateEndpoint$inboundSchema = z.object({
|
|
|
21
23
|
provider_name: z.string(),
|
|
22
24
|
provider_slug: z.nullable(z.string()),
|
|
23
25
|
status: PrivateEndpointStatus$inboundSchema,
|
|
26
|
+
tested_parameters: z.array(z.string()),
|
|
24
27
|
upstream_model_id: z.string(),
|
|
25
28
|
}).transform((v) => {
|
|
26
29
|
return remap$(v, {
|
|
27
30
|
"base_url": "baseUrl",
|
|
31
|
+
"declared_parameters": "declaredParameters",
|
|
28
32
|
"declared_region": "declaredRegion",
|
|
29
33
|
"declared_zdr": "declaredZdr",
|
|
34
|
+
"max_completion_tokens": "maxCompletionTokens",
|
|
30
35
|
"model_name": "modelName",
|
|
31
36
|
"model_permaslug": "modelPermaslug",
|
|
32
37
|
"model_slug": "modelSlug",
|
|
33
38
|
"provider_name": "providerName",
|
|
34
39
|
"provider_slug": "providerSlug",
|
|
40
|
+
"tested_parameters": "testedParameters",
|
|
35
41
|
"upstream_model_id": "upstreamModelId",
|
|
36
42
|
});
|
|
37
43
|
});
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
import { OpenEnum } from "../types/enums.js";
|
|
3
|
+
/**
|
|
4
|
+
* A chat request parameter the endpoint accepts.
|
|
5
|
+
*/
|
|
6
|
+
export declare const PrivateEndpointDeclaredParameter: {
|
|
7
|
+
readonly Temperature: "temperature";
|
|
8
|
+
readonly TopP: "top_p";
|
|
9
|
+
readonly TopK: "top_k";
|
|
10
|
+
readonly MinP: "min_p";
|
|
11
|
+
readonly TopA: "top_a";
|
|
12
|
+
readonly FrequencyPenalty: "frequency_penalty";
|
|
13
|
+
readonly PresencePenalty: "presence_penalty";
|
|
14
|
+
readonly RepetitionPenalty: "repetition_penalty";
|
|
15
|
+
readonly MaxTokens: "max_tokens";
|
|
16
|
+
readonly MaxCompletionTokens: "max_completion_tokens";
|
|
17
|
+
readonly LogitBias: "logit_bias";
|
|
18
|
+
readonly Logprobs: "logprobs";
|
|
19
|
+
readonly TopLogprobs: "top_logprobs";
|
|
20
|
+
readonly Prediction: "prediction";
|
|
21
|
+
readonly Seed: "seed";
|
|
22
|
+
readonly ResponseFormat: "response_format";
|
|
23
|
+
readonly StructuredOutputs: "structured_outputs";
|
|
24
|
+
readonly Stop: "stop";
|
|
25
|
+
readonly Tools: "tools";
|
|
26
|
+
readonly ToolChoice: "tool_choice";
|
|
27
|
+
readonly ParallelToolCalls: "parallel_tool_calls";
|
|
28
|
+
readonly Reasoning: "reasoning";
|
|
29
|
+
readonly ReasoningEffort: "reasoning_effort";
|
|
30
|
+
readonly WebSearchOptions: "web_search_options";
|
|
31
|
+
readonly Verbosity: "verbosity";
|
|
32
|
+
};
|
|
33
|
+
/**
|
|
34
|
+
* A chat request parameter the endpoint accepts.
|
|
35
|
+
*/
|
|
36
|
+
export type PrivateEndpointDeclaredParameter = OpenEnum<typeof PrivateEndpointDeclaredParameter>;
|
|
37
|
+
/** @internal */
|
|
38
|
+
export declare const PrivateEndpointDeclaredParameter$outboundSchema: z.ZodType<string, PrivateEndpointDeclaredParameter>;
|
|
39
|
+
//# sourceMappingURL=privateendpointdeclaredparameter.d.ts.map
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: 590fecd9a965
|
|
4
|
+
*/
|
|
5
|
+
import * as openEnums from "../types/enums.js";
|
|
6
|
+
/**
|
|
7
|
+
* A chat request parameter the endpoint accepts.
|
|
8
|
+
*/
|
|
9
|
+
export const PrivateEndpointDeclaredParameter = {
|
|
10
|
+
Temperature: "temperature",
|
|
11
|
+
TopP: "top_p",
|
|
12
|
+
TopK: "top_k",
|
|
13
|
+
MinP: "min_p",
|
|
14
|
+
TopA: "top_a",
|
|
15
|
+
FrequencyPenalty: "frequency_penalty",
|
|
16
|
+
PresencePenalty: "presence_penalty",
|
|
17
|
+
RepetitionPenalty: "repetition_penalty",
|
|
18
|
+
MaxTokens: "max_tokens",
|
|
19
|
+
MaxCompletionTokens: "max_completion_tokens",
|
|
20
|
+
LogitBias: "logit_bias",
|
|
21
|
+
Logprobs: "logprobs",
|
|
22
|
+
TopLogprobs: "top_logprobs",
|
|
23
|
+
Prediction: "prediction",
|
|
24
|
+
Seed: "seed",
|
|
25
|
+
ResponseFormat: "response_format",
|
|
26
|
+
StructuredOutputs: "structured_outputs",
|
|
27
|
+
Stop: "stop",
|
|
28
|
+
Tools: "tools",
|
|
29
|
+
ToolChoice: "tool_choice",
|
|
30
|
+
ParallelToolCalls: "parallel_tool_calls",
|
|
31
|
+
Reasoning: "reasoning",
|
|
32
|
+
ReasoningEffort: "reasoning_effort",
|
|
33
|
+
WebSearchOptions: "web_search_options",
|
|
34
|
+
Verbosity: "verbosity",
|
|
35
|
+
};
|
|
36
|
+
/** @internal */
|
|
37
|
+
export const PrivateEndpointDeclaredParameter$outboundSchema = openEnums.outboundSchema(PrivateEndpointDeclaredParameter);
|
|
38
|
+
//# sourceMappingURL=privateendpointdeclaredparameter.js.map
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
import { Result as SafeParseResult } from "../types/fp.js";
|
|
3
|
+
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
4
|
+
export type PrivateEndpointParameterCheck = {
|
|
5
|
+
parameter: string;
|
|
6
|
+
supported: boolean;
|
|
7
|
+
};
|
|
8
|
+
/** @internal */
|
|
9
|
+
export declare const PrivateEndpointParameterCheck$inboundSchema: z.ZodType<PrivateEndpointParameterCheck, unknown>;
|
|
10
|
+
export declare function privateEndpointParameterCheckFromJSON(jsonString: string): SafeParseResult<PrivateEndpointParameterCheck, SDKValidationError>;
|
|
11
|
+
//# sourceMappingURL=privateendpointparametercheck.d.ts.map
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: 8f6f1479ff31
|
|
4
|
+
*/
|
|
5
|
+
import * as z from "zod/v4";
|
|
6
|
+
import { safeParse } from "../lib/schemas.js";
|
|
7
|
+
/** @internal */
|
|
8
|
+
export const PrivateEndpointParameterCheck$inboundSchema = z.object({
|
|
9
|
+
parameter: z.string(),
|
|
10
|
+
supported: z.boolean(),
|
|
11
|
+
});
|
|
12
|
+
export function privateEndpointParameterCheckFromJSON(jsonString) {
|
|
13
|
+
return safeParse(jsonString, (x) => PrivateEndpointParameterCheck$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PrivateEndpointParameterCheck' from JSON`);
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=privateendpointparametercheck.js.map
|
|
@@ -2,8 +2,13 @@ import * as z from "zod/v4";
|
|
|
2
2
|
import { Result as SafeParseResult } from "../types/fp.js";
|
|
3
3
|
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
4
4
|
import { PrivateEndpointCheck } from "./privateendpointcheck.js";
|
|
5
|
+
import { PrivateEndpointParameterCheck } from "./privateendpointparametercheck.js";
|
|
5
6
|
export type PrivateEndpointValidation = {
|
|
6
7
|
checks: Array<PrivateEndpointCheck>;
|
|
8
|
+
/**
|
|
9
|
+
* Request parameters probed after the checks passed, each with whether the upstream honored it. Supported ones are recorded in `tested_parameters`. Absent on a failed run and for providers that run no parameter probes; empty when every probe group was already proven.
|
|
10
|
+
*/
|
|
11
|
+
parameters?: Array<PrivateEndpointParameterCheck> | undefined;
|
|
7
12
|
/**
|
|
8
13
|
* Whether every check passed.
|
|
9
14
|
*/
|
|
@@ -5,9 +5,11 @@
|
|
|
5
5
|
import * as z from "zod/v4";
|
|
6
6
|
import { safeParse } from "../lib/schemas.js";
|
|
7
7
|
import { PrivateEndpointCheck$inboundSchema, } from "./privateendpointcheck.js";
|
|
8
|
+
import { PrivateEndpointParameterCheck$inboundSchema, } from "./privateendpointparametercheck.js";
|
|
8
9
|
/** @internal */
|
|
9
10
|
export const PrivateEndpointValidation$inboundSchema = z.object({
|
|
10
11
|
checks: z.array(PrivateEndpointCheck$inboundSchema),
|
|
12
|
+
parameters: z.array(PrivateEndpointParameterCheck$inboundSchema).optional(),
|
|
11
13
|
passed: z.boolean(),
|
|
12
14
|
});
|
|
13
15
|
export function privateEndpointValidationFromJSON(jsonString) {
|
|
@@ -2,8 +2,13 @@ import * as z from "zod/v4";
|
|
|
2
2
|
import { Result as SafeParseResult } from "../types/fp.js";
|
|
3
3
|
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
4
4
|
import { PrivateEndpointCheck } from "./privateendpointcheck.js";
|
|
5
|
+
import { PrivateEndpointParameterCheck } from "./privateendpointparametercheck.js";
|
|
5
6
|
export type PrivateEndpointValidationNullable = {
|
|
6
7
|
checks: Array<PrivateEndpointCheck>;
|
|
8
|
+
/**
|
|
9
|
+
* Request parameters probed after the checks passed, each with whether the upstream honored it. Supported ones are recorded in `tested_parameters`. Absent on a failed run and for providers that run no parameter probes; empty when every probe group was already proven.
|
|
10
|
+
*/
|
|
11
|
+
parameters?: Array<PrivateEndpointParameterCheck> | undefined;
|
|
7
12
|
/**
|
|
8
13
|
* Whether every check passed.
|
|
9
14
|
*/
|
|
@@ -5,9 +5,11 @@
|
|
|
5
5
|
import * as z from "zod/v4";
|
|
6
6
|
import { safeParse } from "../lib/schemas.js";
|
|
7
7
|
import { PrivateEndpointCheck$inboundSchema, } from "./privateendpointcheck.js";
|
|
8
|
+
import { PrivateEndpointParameterCheck$inboundSchema, } from "./privateendpointparametercheck.js";
|
|
8
9
|
/** @internal */
|
|
9
10
|
export const PrivateEndpointValidationNullable$inboundSchema = z.object({
|
|
10
11
|
checks: z.array(PrivateEndpointCheck$inboundSchema),
|
|
12
|
+
parameters: z.array(PrivateEndpointParameterCheck$inboundSchema).optional(),
|
|
11
13
|
passed: z.boolean(),
|
|
12
14
|
});
|
|
13
15
|
export function privateEndpointValidationNullableFromJSON(jsonString) {
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
import { PrivateEndpointDeclaredParameter } from "./privateendpointdeclaredparameter.js";
|
|
3
|
+
export type UpdatePrivateEndpointParametersRequest = {
|
|
4
|
+
/**
|
|
5
|
+
* Parameters the upstream supports beyond the tested ones. Replaces the earlier declaration; tested parameters stay. Order and repeated names are ignored, but the list holds at most as many entries as there are declarable parameters, repeats included. `tool_choice` requires `tools` to be tested or declared.
|
|
6
|
+
*/
|
|
7
|
+
declaredParameters: Array<PrivateEndpointDeclaredParameter>;
|
|
8
|
+
};
|
|
9
|
+
/** @internal */
|
|
10
|
+
export type UpdatePrivateEndpointParametersRequest$Outbound = {
|
|
11
|
+
declared_parameters: Array<string>;
|
|
12
|
+
};
|
|
13
|
+
/** @internal */
|
|
14
|
+
export declare const UpdatePrivateEndpointParametersRequest$outboundSchema: z.ZodType<UpdatePrivateEndpointParametersRequest$Outbound, UpdatePrivateEndpointParametersRequest>;
|
|
15
|
+
export declare function updatePrivateEndpointParametersRequestToJSON(updatePrivateEndpointParametersRequest: UpdatePrivateEndpointParametersRequest): string;
|
|
16
|
+
//# sourceMappingURL=updateprivateendpointparametersrequest.d.ts.map
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: 07aff12e19d4
|
|
4
|
+
*/
|
|
5
|
+
import * as z from "zod/v4";
|
|
6
|
+
import { remap as remap$ } from "../lib/primitives.js";
|
|
7
|
+
import { PrivateEndpointDeclaredParameter$outboundSchema, } from "./privateendpointdeclaredparameter.js";
|
|
8
|
+
/** @internal */
|
|
9
|
+
export const UpdatePrivateEndpointParametersRequest$outboundSchema = z.object({
|
|
10
|
+
declaredParameters: z.array(PrivateEndpointDeclaredParameter$outboundSchema),
|
|
11
|
+
}).transform((v) => {
|
|
12
|
+
return remap$(v, {
|
|
13
|
+
declaredParameters: "declared_parameters",
|
|
14
|
+
});
|
|
15
|
+
});
|
|
16
|
+
export function updatePrivateEndpointParametersRequestToJSON(updatePrivateEndpointParametersRequest) {
|
|
17
|
+
return JSON.stringify(UpdatePrivateEndpointParametersRequest$outboundSchema.parse(updatePrivateEndpointParametersRequest));
|
|
18
|
+
}
|
|
19
|
+
//# sourceMappingURL=updateprivateendpointparametersrequest.js.map
|
|
@@ -58,6 +58,13 @@ export declare class PrivateEndpoints extends ClientSDK {
|
|
|
58
58
|
* Resume routing to a disabled endpoint. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
59
59
|
*/
|
|
60
60
|
enable(request: operations.EnablePrivateEndpointRequest, options?: RequestOptions): Promise<models.ManagedPrivateEndpointResponse>;
|
|
61
|
+
/**
|
|
62
|
+
* Set private endpoint supported parameters
|
|
63
|
+
*
|
|
64
|
+
* @remarks
|
|
65
|
+
* Declare which request parameters the upstream supports beyond the ones validation proved. Applies to drafts and active endpoints; routing picks the change up for subsequent requests. The body replaces the earlier declaration and is read as a set: order and repeated names do not matter, but the list holds at most as many entries as there are declarable parameters, repeats included. `tested_parameters` stay. Returns 400 `parameters_invalid` when `tool_choice` is declared without `tools` being tested or declared. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
66
|
+
*/
|
|
67
|
+
updateParameters(request: operations.UpdatePrivateEndpointParametersRequest, options?: RequestOptions): Promise<models.PrivateEndpointResponse>;
|
|
61
68
|
/**
|
|
62
69
|
* Set private endpoint pricing
|
|
63
70
|
*
|
|
@@ -10,6 +10,7 @@ import { privateEndpointsEnable } from "../funcs/privateEndpointsEnable.js";
|
|
|
10
10
|
import { privateEndpointsGet } from "../funcs/privateEndpointsGet.js";
|
|
11
11
|
import { privateEndpointsList } from "../funcs/privateEndpointsList.js";
|
|
12
12
|
import { privateEndpointsUpdate } from "../funcs/privateEndpointsUpdate.js";
|
|
13
|
+
import { privateEndpointsUpdateParameters } from "../funcs/privateEndpointsUpdateParameters.js";
|
|
13
14
|
import { privateEndpointsUpdatePricing } from "../funcs/privateEndpointsUpdatePricing.js";
|
|
14
15
|
import { privateEndpointsValidate } from "../funcs/privateEndpointsValidate.js";
|
|
15
16
|
import { ClientSDK } from "../lib/sdks.js";
|
|
@@ -87,6 +88,15 @@ export class PrivateEndpoints extends ClientSDK {
|
|
|
87
88
|
async enable(request, options) {
|
|
88
89
|
return unwrapAsync(privateEndpointsEnable(this, request, options));
|
|
89
90
|
}
|
|
91
|
+
/**
|
|
92
|
+
* Set private endpoint supported parameters
|
|
93
|
+
*
|
|
94
|
+
* @remarks
|
|
95
|
+
* Declare which request parameters the upstream supports beyond the ones validation proved. Applies to drafts and active endpoints; routing picks the change up for subsequent requests. The body replaces the earlier declaration and is read as a set: order and repeated names do not matter, but the list holds at most as many entries as there are declarable parameters, repeats included. `tested_parameters` stay. Returns 400 `parameters_invalid` when `tool_choice` is declared without `tools` being tested or declared. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
96
|
+
*/
|
|
97
|
+
async updateParameters(request, options) {
|
|
98
|
+
return unwrapAsync(privateEndpointsUpdateParameters(this, request, options));
|
|
99
|
+
}
|
|
90
100
|
/**
|
|
91
101
|
* Set private endpoint pricing
|
|
92
102
|
*
|
package/jsr.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openrouter/sdk",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.12",
|
|
4
4
|
"author": "OpenRouter",
|
|
5
5
|
"description": "The OpenRouter TypeScript SDK is a type-safe toolkit for building AI applications with access to 400+ language models through a unified API.",
|
|
6
6
|
"keywords": [
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
"license": "Apache-2.0",
|
|
22
22
|
"packageManager": "pnpm@10.22.0",
|
|
23
23
|
"publishConfig": {
|
|
24
|
-
"
|
|
25
|
-
"
|
|
24
|
+
"provenance": true,
|
|
25
|
+
"access": "public"
|
|
26
26
|
},
|
|
27
27
|
"type": "module",
|
|
28
28
|
"main": "./esm/index.js",
|
|
@@ -73,14 +73,14 @@
|
|
|
73
73
|
"lint": "eslint --cache --max-warnings=0 src",
|
|
74
74
|
"build": "tsc && node scripts/unbarrel-imports.js",
|
|
75
75
|
"prepublishOnly": "npm run build",
|
|
76
|
-
"compile": "tsc && node scripts/unbarrel-imports.js",
|
|
77
76
|
"postinstall": "node scripts/check-types.js || true",
|
|
78
|
-
"prepare": "npm run build",
|
|
79
|
-
"test": "vitest --run --project unit",
|
|
80
77
|
"test:e2e": "vitest --run --project e2e",
|
|
81
|
-
"test:transit": "exit 0",
|
|
82
78
|
"test:watch": "vitest --watch --project unit",
|
|
83
79
|
"typecheck": "tsc --noEmit",
|
|
80
|
+
"compile": "tsc && node scripts/unbarrel-imports.js",
|
|
81
|
+
"prepare": "npm run build",
|
|
82
|
+
"test": "vitest --run --project unit",
|
|
83
|
+
"test:transit": "exit 0",
|
|
84
84
|
"typecheck:transit": "exit 0"
|
|
85
85
|
},
|
|
86
86
|
"peerDependencies": {
|