@openrouter/sdk 1.3.29 → 1.3.30
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/README.md +1 -1
- package/esm/funcs/batchCreateBatches.d.ts +19 -0
- package/esm/funcs/batchCreateBatches.js +98 -0
- package/esm/funcs/batchDelete.d.ts +19 -0
- package/esm/funcs/batchDelete.js +103 -0
- package/esm/funcs/batchGetBatches.d.ts +19 -0
- package/esm/funcs/batchGetBatches.js +103 -0
- package/esm/funcs/batchList.d.ts +21 -0
- package/esm/funcs/batchList.js +134 -0
- package/esm/lib/config.d.ts +2 -2
- package/esm/lib/config.js +2 -2
- package/esm/models/anthropicadvisortoolresult.d.ts +14 -0
- package/esm/models/anthropicadvisortoolresult.js +21 -0
- package/esm/models/anthropicbase64pdfsource.d.ts +17 -2
- package/esm/models/anthropicbase64pdfsource.js +25 -2
- package/esm/models/anthropicbashcodeexecutioncontent.d.ts +11 -0
- package/esm/models/anthropicbashcodeexecutioncontent.js +17 -0
- package/esm/models/anthropicbashcodeexecutionoutput.d.ts +18 -0
- package/esm/models/anthropicbashcodeexecutionoutput.js +25 -0
- package/esm/models/anthropicbashcodeexecutionresult.d.ts +15 -0
- package/esm/models/anthropicbashcodeexecutionresult.js +24 -0
- package/esm/models/anthropicbashcodeexecutiontoolresult.d.ts +13 -0
- package/esm/models/anthropicbashcodeexecutiontoolresult.js +22 -0
- package/esm/models/anthropicbashcodeexecutiontoolresulterror.d.ts +22 -0
- package/esm/models/anthropicbashcodeexecutiontoolresulterror.js +30 -0
- package/esm/models/anthropiccaller.d.ts +12 -0
- package/esm/models/anthropiccaller.js +19 -0
- package/esm/models/anthropiccitationcharlocation.d.ts +16 -0
- package/esm/models/anthropiccitationcharlocation.js +30 -0
- package/esm/models/anthropiccitationcontentblocklocation.d.ts +16 -0
- package/esm/models/anthropiccitationcontentblocklocation.js +30 -0
- package/esm/models/anthropiccitationpagelocation.d.ts +16 -0
- package/esm/models/anthropiccitationpagelocation.js +30 -0
- package/esm/models/anthropiccitationsconfig.d.ts +10 -0
- package/esm/models/anthropiccitationsconfig.js +14 -0
- package/esm/models/anthropiccitationsearchresultlocation.d.ts +16 -0
- package/esm/models/anthropiccitationsearchresultlocation.js +28 -0
- package/esm/models/anthropiccitationwebsearchresultlocation.d.ts +14 -0
- package/esm/models/anthropiccitationwebsearchresultlocation.js +24 -0
- package/esm/models/anthropiccodeexecution20250825caller.d.ts +11 -0
- package/esm/models/anthropiccodeexecution20250825caller.js +20 -0
- package/esm/models/anthropiccodeexecution20260120caller.d.ts +11 -0
- package/esm/models/anthropiccodeexecution20260120caller.js +20 -0
- package/esm/models/anthropiccodeexecutioncontent.d.ts +12 -0
- package/esm/models/anthropiccodeexecutioncontent.js +19 -0
- package/esm/models/anthropiccodeexecutionoutput.d.ts +18 -0
- package/esm/models/anthropiccodeexecutionoutput.js +25 -0
- package/esm/models/anthropiccodeexecutionresult.d.ts +15 -0
- package/esm/models/anthropiccodeexecutionresult.js +24 -0
- package/esm/models/anthropiccodeexecutiontoolresult.d.ts +13 -0
- package/esm/models/anthropiccodeexecutiontoolresult.js +22 -0
- package/esm/models/anthropiccodeexecutiontoolresulterror.d.ts +12 -0
- package/esm/models/anthropiccodeexecutiontoolresulterror.js +21 -0
- package/esm/models/anthropiccompactionblock.d.ts +12 -0
- package/esm/models/anthropiccompactionblock.js +21 -0
- package/esm/models/anthropiccontainer.d.ts +13 -0
- package/esm/models/anthropiccontainer.js +22 -0
- package/esm/models/anthropiccontainerskill.d.ts +20 -0
- package/esm/models/anthropiccontainerskill.js +28 -0
- package/esm/models/anthropiccontainerupload.d.ts +11 -0
- package/esm/models/anthropiccontainerupload.js +20 -0
- package/esm/models/anthropicdirectcaller.d.ts +10 -0
- package/esm/models/anthropicdirectcaller.js +14 -0
- package/esm/models/anthropicdocumentblock.d.ts +36 -0
- package/esm/models/anthropicdocumentblock.js +45 -0
- package/esm/models/anthropicdocumentblockparam.d.ts +20 -4
- package/esm/models/anthropicdocumentblockparam.js +4 -4
- package/esm/models/anthropicencryptedcodeexecutionresult.d.ts +15 -0
- package/esm/models/anthropicencryptedcodeexecutionresult.js +25 -0
- package/esm/models/anthropicinputtransformation.d.ts +18 -0
- package/esm/models/anthropicinputtransformation.js +16 -0
- package/esm/models/anthropicoutputtokensdetails.d.ts +10 -0
- package/esm/models/anthropicoutputtokensdetails.js +19 -0
- package/esm/models/anthropicplaintextsource.d.ts +17 -2
- package/esm/models/anthropicplaintextsource.js +25 -2
- package/esm/models/anthropicredactedthinkingblock.d.ts +11 -0
- package/esm/models/anthropicredactedthinkingblock.js +15 -0
- package/esm/models/anthropicrefusalstopdetails.d.ts +32 -0
- package/esm/models/anthropicrefusalstopdetails.js +31 -0
- package/esm/models/anthropicservertoolerrorcode.d.ts +12 -0
- package/esm/models/anthropicservertoolerrorcode.js +14 -0
- package/esm/models/anthropicservertoolusage.d.ts +11 -0
- package/esm/models/anthropicservertoolusage.js +21 -0
- package/esm/models/anthropicservicetier.d.ts +11 -0
- package/esm/models/anthropicservicetier.js +13 -0
- package/esm/models/anthropictextblock.d.ts +13 -0
- package/esm/models/anthropictextblock.js +17 -0
- package/esm/models/anthropictextcitation.d.ts +14 -0
- package/esm/models/anthropictextcitation.js +23 -0
- package/esm/models/anthropictexteditorcodeexecutioncontent.d.ts +13 -0
- package/esm/models/anthropictexteditorcodeexecutioncontent.js +21 -0
- package/esm/models/anthropictexteditorcodeexecutioncreateresult.d.ts +11 -0
- package/esm/models/anthropictexteditorcodeexecutioncreateresult.js +20 -0
- package/esm/models/anthropictexteditorcodeexecutionstrreplaceresult.d.ts +15 -0
- package/esm/models/anthropictexteditorcodeexecutionstrreplaceresult.js +28 -0
- package/esm/models/anthropictexteditorcodeexecutiontoolresult.d.ts +13 -0
- package/esm/models/anthropictexteditorcodeexecutiontoolresult.js +22 -0
- package/esm/models/anthropictexteditorcodeexecutiontoolresulterror.d.ts +23 -0
- package/esm/models/anthropictexteditorcodeexecutiontoolresulterror.js +33 -0
- package/esm/models/anthropictexteditorcodeexecutionviewresult.d.ts +24 -0
- package/esm/models/anthropictexteditorcodeexecutionviewresult.js +36 -0
- package/esm/models/anthropicthinkingblock.d.ts +12 -0
- package/esm/models/anthropicthinkingblock.js +16 -0
- package/esm/models/anthropictoolreference.d.ts +18 -0
- package/esm/models/anthropictoolreference.js +25 -0
- package/esm/models/anthropictoolsearchcontent.d.ts +11 -0
- package/esm/models/anthropictoolsearchcontent.js +17 -0
- package/esm/models/anthropictoolsearchresult.d.ts +12 -0
- package/esm/models/anthropictoolsearchresult.js +21 -0
- package/esm/models/anthropictoolsearchresulterror.d.ts +13 -0
- package/esm/models/anthropictoolsearchresulterror.js +23 -0
- package/esm/models/anthropictoolsearchtoolresult.d.ts +13 -0
- package/esm/models/anthropictoolsearchtoolresult.js +22 -0
- package/esm/models/anthropictooluseblock.d.ts +15 -0
- package/esm/models/anthropictooluseblock.js +19 -0
- package/esm/models/anthropicwebfetchblock.d.ts +14 -0
- package/esm/models/anthropicwebfetchblock.js +23 -0
- package/esm/models/anthropicwebfetchcontent.d.ts +11 -0
- package/esm/models/anthropicwebfetchcontent.js +17 -0
- package/esm/models/anthropicwebfetchtoolresult.d.ts +15 -0
- package/esm/models/anthropicwebfetchtoolresult.js +24 -0
- package/esm/models/anthropicwebfetchtoolresulterror.d.ts +25 -0
- package/esm/models/anthropicwebfetchtoolresulterror.js +33 -0
- package/esm/models/anthropicwebsearchresult.d.ts +21 -0
- package/esm/models/anthropicwebsearchresult.js +29 -0
- package/esm/models/anthropicwebsearchtoolresult.d.ts +20 -0
- package/esm/models/anthropicwebsearchtoolresult.js +36 -0
- package/esm/models/anthropicwebsearchtoolresulterror.d.ts +29 -0
- package/esm/models/anthropicwebsearchtoolresulterror.js +37 -0
- package/esm/models/batchdeletedobject.d.ts +26 -0
- package/esm/models/batchdeletedobject.js +22 -0
- package/esm/models/batchdeletionoutcome.d.ts +17 -0
- package/esm/models/batchdeletionoutcome.js +16 -0
- package/esm/models/batchdeletiontargets.d.ts +50 -0
- package/esm/models/batchdeletiontargets.js +32 -0
- package/esm/models/batcherrorresponse.d.ts +11 -0
- package/esm/models/batcherrorresponse.js +15 -0
- package/esm/models/batchlistitem.d.ts +181 -0
- package/esm/models/batchlistitem.js +159 -0
- package/esm/models/batchlistresponse.d.ts +25 -0
- package/esm/models/batchlistresponse.js +31 -0
- package/esm/models/batchliststatus.d.ts +20 -0
- package/esm/models/batchliststatus.js +19 -0
- package/esm/models/batchlisttimestamp.d.ts +12 -0
- package/esm/models/batchlisttimestamp.js +15 -0
- package/esm/models/batchobject.d.ts +750 -0
- package/esm/models/batchobject.js +810 -0
- package/esm/models/batchpaymentrequiredresponseerror.d.ts +159 -0
- package/esm/models/batchpaymentrequiredresponseerror.js +136 -0
- package/esm/models/batchproviderpreferences.d.ts +25 -0
- package/esm/models/batchproviderpreferences.js +20 -0
- package/esm/models/batchsubmitbody.d.ts +62 -0
- package/esm/models/batchsubmitbody.js +51 -0
- package/esm/models/debugevent.d.ts +12 -12
- package/esm/models/debugevent.js +11 -12
- package/esm/models/errors/batcherrorresponse.d.ts +19 -0
- package/esm/models/errors/batcherrorresponse.js +32 -0
- package/esm/models/errors/batchpaymentrequiredresponseerror.d.ts +53 -0
- package/esm/models/errors/batchpaymentrequiredresponseerror.js +64 -0
- package/esm/models/errors/index.d.ts +2 -0
- package/esm/models/errors/index.js +2 -0
- package/esm/models/finishreason.d.ts +13 -0
- package/esm/models/finishreason.js +15 -0
- package/esm/models/imagegenerationusage.d.ts +4 -4
- package/esm/models/imagegenerationusage.js +4 -6
- package/esm/models/index.d.ts +75 -0
- package/esm/models/index.js +75 -0
- package/esm/models/internchatchoice.d.ts +4 -4
- package/esm/models/internchatchoice.js +3 -3
- package/esm/models/messagesmessageparam.d.ts +8 -8
- package/esm/models/messagesmessageparam.js +6 -7
- package/esm/models/operations/createbatches.d.ts +59 -0
- package/esm/models/operations/createbatches.js +23 -0
- package/esm/models/operations/deletebatch.d.ts +58 -0
- package/esm/models/operations/deletebatch.js +21 -0
- package/esm/models/operations/getbatches.d.ts +58 -0
- package/esm/models/operations/getbatches.js +21 -0
- package/esm/models/operations/index.d.ts +4 -0
- package/esm/models/operations/index.js +4 -0
- package/esm/models/operations/listbatches.d.ts +87 -0
- package/esm/models/operations/listbatches.js +40 -0
- package/esm/models/oranthropicbashtoolresult.d.ts +43 -0
- package/esm/models/oranthropicbashtoolresult.js +49 -0
- package/esm/models/oranthropiccontentblock.d.ts +25 -0
- package/esm/models/oranthropiccontentblock.js +45 -0
- package/esm/models/oranthropicnullablecaller.d.ts +12 -0
- package/esm/models/oranthropicnullablecaller.js +19 -0
- package/esm/models/oranthropicservertooluseblock.d.ts +15 -0
- package/esm/models/oranthropicservertooluseblock.js +19 -0
- package/esm/models/oranthropicshelltoolresult.d.ts +43 -0
- package/esm/models/oranthropicshelltoolresult.js +50 -0
- package/esm/models/oranthropicstopreason.d.ts +16 -0
- package/esm/models/oranthropicstopreason.js +18 -0
- package/esm/models/outputfusionservertoolitem.d.ts +8 -8
- package/esm/models/outputfusionservertoolitem.js +8 -8
- package/esm/models/submitgenerationfeedbackrequest.d.ts +4 -4
- package/esm/models/submitgenerationfeedbackrequest.js +3 -4
- package/esm/sdk/batch.d.ts +37 -0
- package/esm/sdk/batch.js +50 -0
- package/esm/sdk/sdk.d.ts +3 -0
- package/esm/sdk/sdk.js +4 -0
- package/jsr.json +1 -1
- package/package.json +6 -6
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
import * as models from "../index.js";
|
|
3
|
+
export type CreateBatchesGlobals = {
|
|
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 CreateBatchesRequest = {
|
|
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
|
+
* The batch to create. Each item in `requests` has a unique `custom_id` and a `body` in the request format of the chosen `endpoint`.
|
|
46
|
+
*/
|
|
47
|
+
batchSubmitBody: models.BatchSubmitBody;
|
|
48
|
+
};
|
|
49
|
+
/** @internal */
|
|
50
|
+
export type CreateBatchesRequest$Outbound = {
|
|
51
|
+
"HTTP-Referer"?: string | undefined;
|
|
52
|
+
appTitle?: string | undefined;
|
|
53
|
+
appCategories?: string | undefined;
|
|
54
|
+
BatchSubmitBody: models.BatchSubmitBody$Outbound;
|
|
55
|
+
};
|
|
56
|
+
/** @internal */
|
|
57
|
+
export declare const CreateBatchesRequest$outboundSchema: z.ZodType<CreateBatchesRequest$Outbound, CreateBatchesRequest>;
|
|
58
|
+
export declare function createBatchesRequestToJSON(createBatchesRequest: CreateBatchesRequest): string;
|
|
59
|
+
//# sourceMappingURL=createbatches.d.ts.map
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: ebc64cef17ca
|
|
4
|
+
*/
|
|
5
|
+
import * as z from "zod/v4";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { BatchSubmitBody$outboundSchema as models_BatchSubmitBody$outboundSchema } from "../batchsubmitbody.js";
|
|
8
|
+
/** @internal */
|
|
9
|
+
export const CreateBatchesRequest$outboundSchema = z.object({
|
|
10
|
+
httpReferer: z.string().optional(),
|
|
11
|
+
appTitle: z.string().optional(),
|
|
12
|
+
appCategories: z.string().optional(),
|
|
13
|
+
batchSubmitBody: models_BatchSubmitBody$outboundSchema,
|
|
14
|
+
}).transform((v) => {
|
|
15
|
+
return remap$(v, {
|
|
16
|
+
httpReferer: "HTTP-Referer",
|
|
17
|
+
batchSubmitBody: "BatchSubmitBody",
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
export function createBatchesRequestToJSON(createBatchesRequest) {
|
|
21
|
+
return JSON.stringify(CreateBatchesRequest$outboundSchema.parse(createBatchesRequest));
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=createbatches.js.map
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
export type DeleteBatchGlobals = {
|
|
3
|
+
/**
|
|
4
|
+
* The app identifier should be your app's URL and is used as the primary identifier for rankings.
|
|
5
|
+
*
|
|
6
|
+
* @remarks
|
|
7
|
+
* This is used to track API usage per application.
|
|
8
|
+
*/
|
|
9
|
+
httpReferer?: string | undefined;
|
|
10
|
+
/**
|
|
11
|
+
* The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
|
12
|
+
*
|
|
13
|
+
* @remarks
|
|
14
|
+
*/
|
|
15
|
+
appTitle?: string | undefined;
|
|
16
|
+
/**
|
|
17
|
+
* Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
|
|
18
|
+
*
|
|
19
|
+
* @remarks
|
|
20
|
+
*/
|
|
21
|
+
appCategories?: string | undefined;
|
|
22
|
+
};
|
|
23
|
+
export type DeleteBatchRequest = {
|
|
24
|
+
/**
|
|
25
|
+
* The app identifier should be your app's URL and is used as the primary identifier for rankings.
|
|
26
|
+
*
|
|
27
|
+
* @remarks
|
|
28
|
+
* This is used to track API usage per application.
|
|
29
|
+
*/
|
|
30
|
+
httpReferer?: string | undefined;
|
|
31
|
+
/**
|
|
32
|
+
* The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
|
33
|
+
*
|
|
34
|
+
* @remarks
|
|
35
|
+
*/
|
|
36
|
+
appTitle?: string | undefined;
|
|
37
|
+
/**
|
|
38
|
+
* Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
|
|
39
|
+
*
|
|
40
|
+
* @remarks
|
|
41
|
+
*/
|
|
42
|
+
appCategories?: string | undefined;
|
|
43
|
+
/**
|
|
44
|
+
* The batch job id returned from submit.
|
|
45
|
+
*/
|
|
46
|
+
id: string;
|
|
47
|
+
};
|
|
48
|
+
/** @internal */
|
|
49
|
+
export type DeleteBatchRequest$Outbound = {
|
|
50
|
+
"HTTP-Referer"?: string | undefined;
|
|
51
|
+
appTitle?: string | undefined;
|
|
52
|
+
appCategories?: string | undefined;
|
|
53
|
+
id: string;
|
|
54
|
+
};
|
|
55
|
+
/** @internal */
|
|
56
|
+
export declare const DeleteBatchRequest$outboundSchema: z.ZodType<DeleteBatchRequest$Outbound, DeleteBatchRequest>;
|
|
57
|
+
export declare function deleteBatchRequestToJSON(deleteBatchRequest: DeleteBatchRequest): string;
|
|
58
|
+
//# sourceMappingURL=deletebatch.d.ts.map
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: f2c0c45a0e0b
|
|
4
|
+
*/
|
|
5
|
+
import * as z from "zod/v4";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
/** @internal */
|
|
8
|
+
export const DeleteBatchRequest$outboundSchema = z.object({
|
|
9
|
+
httpReferer: z.string().optional(),
|
|
10
|
+
appTitle: z.string().optional(),
|
|
11
|
+
appCategories: z.string().optional(),
|
|
12
|
+
id: z.string(),
|
|
13
|
+
}).transform((v) => {
|
|
14
|
+
return remap$(v, {
|
|
15
|
+
httpReferer: "HTTP-Referer",
|
|
16
|
+
});
|
|
17
|
+
});
|
|
18
|
+
export function deleteBatchRequestToJSON(deleteBatchRequest) {
|
|
19
|
+
return JSON.stringify(DeleteBatchRequest$outboundSchema.parse(deleteBatchRequest));
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=deletebatch.js.map
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
export type GetBatchesGlobals = {
|
|
3
|
+
/**
|
|
4
|
+
* The app identifier should be your app's URL and is used as the primary identifier for rankings.
|
|
5
|
+
*
|
|
6
|
+
* @remarks
|
|
7
|
+
* This is used to track API usage per application.
|
|
8
|
+
*/
|
|
9
|
+
httpReferer?: string | undefined;
|
|
10
|
+
/**
|
|
11
|
+
* The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
|
12
|
+
*
|
|
13
|
+
* @remarks
|
|
14
|
+
*/
|
|
15
|
+
appTitle?: string | undefined;
|
|
16
|
+
/**
|
|
17
|
+
* Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
|
|
18
|
+
*
|
|
19
|
+
* @remarks
|
|
20
|
+
*/
|
|
21
|
+
appCategories?: string | undefined;
|
|
22
|
+
};
|
|
23
|
+
export type GetBatchesRequest = {
|
|
24
|
+
/**
|
|
25
|
+
* The app identifier should be your app's URL and is used as the primary identifier for rankings.
|
|
26
|
+
*
|
|
27
|
+
* @remarks
|
|
28
|
+
* This is used to track API usage per application.
|
|
29
|
+
*/
|
|
30
|
+
httpReferer?: string | undefined;
|
|
31
|
+
/**
|
|
32
|
+
* The app display name allows you to customize how your app appears in OpenRouter's dashboard.
|
|
33
|
+
*
|
|
34
|
+
* @remarks
|
|
35
|
+
*/
|
|
36
|
+
appTitle?: string | undefined;
|
|
37
|
+
/**
|
|
38
|
+
* Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
|
|
39
|
+
*
|
|
40
|
+
* @remarks
|
|
41
|
+
*/
|
|
42
|
+
appCategories?: string | undefined;
|
|
43
|
+
/**
|
|
44
|
+
* The batch job id returned from submit.
|
|
45
|
+
*/
|
|
46
|
+
id: string;
|
|
47
|
+
};
|
|
48
|
+
/** @internal */
|
|
49
|
+
export type GetBatchesRequest$Outbound = {
|
|
50
|
+
"HTTP-Referer"?: string | undefined;
|
|
51
|
+
appTitle?: string | undefined;
|
|
52
|
+
appCategories?: string | undefined;
|
|
53
|
+
id: string;
|
|
54
|
+
};
|
|
55
|
+
/** @internal */
|
|
56
|
+
export declare const GetBatchesRequest$outboundSchema: z.ZodType<GetBatchesRequest$Outbound, GetBatchesRequest>;
|
|
57
|
+
export declare function getBatchesRequestToJSON(getBatchesRequest: GetBatchesRequest): string;
|
|
58
|
+
//# sourceMappingURL=getbatches.d.ts.map
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: 25fcdd59c2f1
|
|
4
|
+
*/
|
|
5
|
+
import * as z from "zod/v4";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
/** @internal */
|
|
8
|
+
export const GetBatchesRequest$outboundSchema = z.object({
|
|
9
|
+
httpReferer: z.string().optional(),
|
|
10
|
+
appTitle: z.string().optional(),
|
|
11
|
+
appCategories: z.string().optional(),
|
|
12
|
+
id: z.string(),
|
|
13
|
+
}).transform((v) => {
|
|
14
|
+
return remap$(v, {
|
|
15
|
+
httpReferer: "HTTP-Referer",
|
|
16
|
+
});
|
|
17
|
+
});
|
|
18
|
+
export function getBatchesRequestToJSON(getBatchesRequest) {
|
|
19
|
+
return JSON.stringify(GetBatchesRequest$outboundSchema.parse(getBatchesRequest));
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=getbatches.js.map
|
|
@@ -10,6 +10,7 @@ export * from "./createaudiospeech.js";
|
|
|
10
10
|
export * from "./createaudiotranscriptions.js";
|
|
11
11
|
export * from "./createaudiotranscriptionsmultipart.js";
|
|
12
12
|
export * from "./createauthkeyscode.js";
|
|
13
|
+
export * from "./createbatches.js";
|
|
13
14
|
export * from "./createbyokkey.js";
|
|
14
15
|
export * from "./createembeddings.js";
|
|
15
16
|
export * from "./createguardrail.js";
|
|
@@ -29,6 +30,7 @@ export * from "./createscimsyncjob.js";
|
|
|
29
30
|
export * from "./createsystemone.js";
|
|
30
31
|
export * from "./createvideos.js";
|
|
31
32
|
export * from "./createworkspace.js";
|
|
33
|
+
export * from "./deletebatch.js";
|
|
32
34
|
export * from "./deletebyokkey.js";
|
|
33
35
|
export * from "./deletefile.js";
|
|
34
36
|
export * from "./deleteguardrail.js";
|
|
@@ -45,6 +47,7 @@ export * from "./downloadfilecontent.js";
|
|
|
45
47
|
export * from "./exchangeauthcodeforapikey.js";
|
|
46
48
|
export * from "./getanalyticsmeta.js";
|
|
47
49
|
export * from "./getapprankings.js";
|
|
50
|
+
export * from "./getbatches.js";
|
|
48
51
|
export * from "./getbenchmarks.js";
|
|
49
52
|
export * from "./getbyokkey.js";
|
|
50
53
|
export * from "./getcontainerfile.js";
|
|
@@ -72,6 +75,7 @@ export * from "./getworkspace.js";
|
|
|
72
75
|
export * from "./getworkspacebudget.js";
|
|
73
76
|
export * from "./invokeintern.js";
|
|
74
77
|
export * from "./list.js";
|
|
78
|
+
export * from "./listbatches.js";
|
|
75
79
|
export * from "./listbyokkeys.js";
|
|
76
80
|
export * from "./listcontainerfiles.js";
|
|
77
81
|
export * from "./listembeddingsmodels.js";
|
|
@@ -14,6 +14,7 @@ export * from "./createaudiospeech.js";
|
|
|
14
14
|
export * from "./createaudiotranscriptions.js";
|
|
15
15
|
export * from "./createaudiotranscriptionsmultipart.js";
|
|
16
16
|
export * from "./createauthkeyscode.js";
|
|
17
|
+
export * from "./createbatches.js";
|
|
17
18
|
export * from "./createbyokkey.js";
|
|
18
19
|
export * from "./createembeddings.js";
|
|
19
20
|
export * from "./createguardrail.js";
|
|
@@ -33,6 +34,7 @@ export * from "./createscimsyncjob.js";
|
|
|
33
34
|
export * from "./createsystemone.js";
|
|
34
35
|
export * from "./createvideos.js";
|
|
35
36
|
export * from "./createworkspace.js";
|
|
37
|
+
export * from "./deletebatch.js";
|
|
36
38
|
export * from "./deletebyokkey.js";
|
|
37
39
|
export * from "./deletefile.js";
|
|
38
40
|
export * from "./deleteguardrail.js";
|
|
@@ -49,6 +51,7 @@ export * from "./downloadfilecontent.js";
|
|
|
49
51
|
export * from "./exchangeauthcodeforapikey.js";
|
|
50
52
|
export * from "./getanalyticsmeta.js";
|
|
51
53
|
export * from "./getapprankings.js";
|
|
54
|
+
export * from "./getbatches.js";
|
|
52
55
|
export * from "./getbenchmarks.js";
|
|
53
56
|
export * from "./getbyokkey.js";
|
|
54
57
|
export * from "./getcontainerfile.js";
|
|
@@ -76,6 +79,7 @@ export * from "./getworkspace.js";
|
|
|
76
79
|
export * from "./getworkspacebudget.js";
|
|
77
80
|
export * from "./invokeintern.js";
|
|
78
81
|
export * from "./list.js";
|
|
82
|
+
export * from "./listbatches.js";
|
|
79
83
|
export * from "./listbyokkeys.js";
|
|
80
84
|
export * from "./listcontainerfiles.js";
|
|
81
85
|
export * from "./listembeddingsmodels.js";
|
|
@@ -0,0 +1,87 @@
|
|
|
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 ListBatchesGlobals = {
|
|
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 ListBatchesRequest = {
|
|
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
|
+
* Maximum number of batches to return, from 1 through 100.
|
|
48
|
+
*/
|
|
49
|
+
limit?: number | undefined;
|
|
50
|
+
/**
|
|
51
|
+
* Batch id from the previous page's `last_id`.
|
|
52
|
+
*/
|
|
53
|
+
after?: string | undefined;
|
|
54
|
+
/**
|
|
55
|
+
* Repeat this parameter to include more than one status.
|
|
56
|
+
*/
|
|
57
|
+
status?: Array<models.BatchListStatus> | undefined;
|
|
58
|
+
/**
|
|
59
|
+
* Only include batches created strictly after this timestamp.
|
|
60
|
+
*/
|
|
61
|
+
createdAfter?: models.BatchListTimestamp | undefined;
|
|
62
|
+
/**
|
|
63
|
+
* Only include batches created strictly before this timestamp.
|
|
64
|
+
*/
|
|
65
|
+
createdBefore?: models.BatchListTimestamp | undefined;
|
|
66
|
+
};
|
|
67
|
+
export type ListBatchesResponse = {
|
|
68
|
+
result: models.BatchListResponse;
|
|
69
|
+
};
|
|
70
|
+
/** @internal */
|
|
71
|
+
export type ListBatchesRequest$Outbound = {
|
|
72
|
+
"HTTP-Referer"?: string | undefined;
|
|
73
|
+
appTitle?: string | undefined;
|
|
74
|
+
appCategories?: string | undefined;
|
|
75
|
+
limit?: number | undefined;
|
|
76
|
+
after?: string | undefined;
|
|
77
|
+
status?: Array<string> | undefined;
|
|
78
|
+
created_after?: models.BatchListTimestamp$Outbound | undefined;
|
|
79
|
+
created_before?: models.BatchListTimestamp$Outbound | undefined;
|
|
80
|
+
};
|
|
81
|
+
/** @internal */
|
|
82
|
+
export declare const ListBatchesRequest$outboundSchema: z.ZodType<ListBatchesRequest$Outbound, ListBatchesRequest>;
|
|
83
|
+
export declare function listBatchesRequestToJSON(listBatchesRequest: ListBatchesRequest): string;
|
|
84
|
+
/** @internal */
|
|
85
|
+
export declare const ListBatchesResponse$inboundSchema: z.ZodType<ListBatchesResponse, unknown>;
|
|
86
|
+
export declare function listBatchesResponseFromJSON(jsonString: string): SafeParseResult<ListBatchesResponse, SDKValidationError>;
|
|
87
|
+
//# sourceMappingURL=listbatches.d.ts.map
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: ed6b34dc34af
|
|
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 { BatchListResponse$inboundSchema as models_BatchListResponse$inboundSchema } from "../batchlistresponse.js"; import { BatchListStatus$outboundSchema as models_BatchListStatus$outboundSchema } from "../batchliststatus.js"; import { BatchListTimestamp$outboundSchema as models_BatchListTimestamp$outboundSchema } from "../batchlisttimestamp.js";
|
|
9
|
+
/** @internal */
|
|
10
|
+
export const ListBatchesRequest$outboundSchema = z.object({
|
|
11
|
+
httpReferer: z.string().optional(),
|
|
12
|
+
appTitle: z.string().optional(),
|
|
13
|
+
appCategories: z.string().optional(),
|
|
14
|
+
limit: z.int().optional(),
|
|
15
|
+
after: z.string().optional(),
|
|
16
|
+
status: z.array(models_BatchListStatus$outboundSchema).optional(),
|
|
17
|
+
createdAfter: models_BatchListTimestamp$outboundSchema.optional(),
|
|
18
|
+
createdBefore: models_BatchListTimestamp$outboundSchema.optional(),
|
|
19
|
+
}).transform((v) => {
|
|
20
|
+
return remap$(v, {
|
|
21
|
+
httpReferer: "HTTP-Referer",
|
|
22
|
+
createdAfter: "created_after",
|
|
23
|
+
createdBefore: "created_before",
|
|
24
|
+
});
|
|
25
|
+
});
|
|
26
|
+
export function listBatchesRequestToJSON(listBatchesRequest) {
|
|
27
|
+
return JSON.stringify(ListBatchesRequest$outboundSchema.parse(listBatchesRequest));
|
|
28
|
+
}
|
|
29
|
+
/** @internal */
|
|
30
|
+
export const ListBatchesResponse$inboundSchema = z.object({
|
|
31
|
+
Result: models_BatchListResponse$inboundSchema,
|
|
32
|
+
}).transform((v) => {
|
|
33
|
+
return remap$(v, {
|
|
34
|
+
"Result": "result",
|
|
35
|
+
});
|
|
36
|
+
});
|
|
37
|
+
export function listBatchesResponseFromJSON(jsonString) {
|
|
38
|
+
return safeParse(jsonString, (x) => ListBatchesResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ListBatchesResponse' from JSON`);
|
|
39
|
+
}
|
|
40
|
+
//# sourceMappingURL=listbatches.js.map
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
import { ClosedEnum } from "../types/enums.js";
|
|
3
|
+
import { Result as SafeParseResult } from "../types/fp.js";
|
|
4
|
+
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
5
|
+
export declare const ORAnthropicBashToolResultTypeContainerFileCitation: {
|
|
6
|
+
readonly ContainerFileCitation: "container_file_citation";
|
|
7
|
+
};
|
|
8
|
+
export type ORAnthropicBashToolResultTypeContainerFileCitation = ClosedEnum<typeof ORAnthropicBashToolResultTypeContainerFileCitation>;
|
|
9
|
+
export type ORAnthropicBashToolResultFile = {
|
|
10
|
+
containerId: string;
|
|
11
|
+
endIndex: number;
|
|
12
|
+
fileId: string;
|
|
13
|
+
filename: string;
|
|
14
|
+
startIndex: number;
|
|
15
|
+
type: ORAnthropicBashToolResultTypeContainerFileCitation;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Output of an `openrouter:bash` call executed in the OpenRouter sandbox (`engine: 'openrouter'`)
|
|
19
|
+
*/
|
|
20
|
+
export type ORAnthropicBashToolResult = {
|
|
21
|
+
/**
|
|
22
|
+
* The canonical container id the command ran under — the `{container_id}` for the Container Files API, reusable as a `container_reference` in later requests. Present on every sandbox-executed call, even when no files changed.
|
|
23
|
+
*/
|
|
24
|
+
containerId?: string | undefined;
|
|
25
|
+
content: {
|
|
26
|
+
[k: string]: any;
|
|
27
|
+
};
|
|
28
|
+
/**
|
|
29
|
+
* Citations for the files the sandbox command created or modified, most-recently-touched first (at most 10). Retrieve them via the Container Files API.
|
|
30
|
+
*/
|
|
31
|
+
files?: Array<ORAnthropicBashToolResultFile> | undefined;
|
|
32
|
+
toolUseId: string;
|
|
33
|
+
type: "openrouter_bash_tool_result";
|
|
34
|
+
};
|
|
35
|
+
/** @internal */
|
|
36
|
+
export declare const ORAnthropicBashToolResultTypeContainerFileCitation$inboundSchema: z.ZodEnum<typeof ORAnthropicBashToolResultTypeContainerFileCitation>;
|
|
37
|
+
/** @internal */
|
|
38
|
+
export declare const ORAnthropicBashToolResultFile$inboundSchema: z.ZodType<ORAnthropicBashToolResultFile, unknown>;
|
|
39
|
+
export declare function orAnthropicBashToolResultFileFromJSON(jsonString: string): SafeParseResult<ORAnthropicBashToolResultFile, SDKValidationError>;
|
|
40
|
+
/** @internal */
|
|
41
|
+
export declare const ORAnthropicBashToolResult$inboundSchema: z.ZodType<ORAnthropicBashToolResult, unknown>;
|
|
42
|
+
export declare function orAnthropicBashToolResultFromJSON(jsonString: string): SafeParseResult<ORAnthropicBashToolResult, SDKValidationError>;
|
|
43
|
+
//# sourceMappingURL=oranthropicbashtoolresult.d.ts.map
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: 13070e32efe3
|
|
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
|
+
export const ORAnthropicBashToolResultTypeContainerFileCitation = {
|
|
9
|
+
ContainerFileCitation: "container_file_citation",
|
|
10
|
+
};
|
|
11
|
+
/** @internal */
|
|
12
|
+
export const ORAnthropicBashToolResultTypeContainerFileCitation$inboundSchema = z.enum(ORAnthropicBashToolResultTypeContainerFileCitation);
|
|
13
|
+
/** @internal */
|
|
14
|
+
export const ORAnthropicBashToolResultFile$inboundSchema = z.object({
|
|
15
|
+
container_id: z.string(),
|
|
16
|
+
end_index: z.int(),
|
|
17
|
+
file_id: z.string(),
|
|
18
|
+
filename: z.string(),
|
|
19
|
+
start_index: z.int(),
|
|
20
|
+
type: ORAnthropicBashToolResultTypeContainerFileCitation$inboundSchema,
|
|
21
|
+
}).transform((v) => {
|
|
22
|
+
return remap$(v, {
|
|
23
|
+
"container_id": "containerId",
|
|
24
|
+
"end_index": "endIndex",
|
|
25
|
+
"file_id": "fileId",
|
|
26
|
+
"start_index": "startIndex",
|
|
27
|
+
});
|
|
28
|
+
});
|
|
29
|
+
export function orAnthropicBashToolResultFileFromJSON(jsonString) {
|
|
30
|
+
return safeParse(jsonString, (x) => ORAnthropicBashToolResultFile$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ORAnthropicBashToolResultFile' from JSON`);
|
|
31
|
+
}
|
|
32
|
+
/** @internal */
|
|
33
|
+
export const ORAnthropicBashToolResult$inboundSchema = z.object({
|
|
34
|
+
container_id: z.string().optional(),
|
|
35
|
+
content: z.record(z.string(), z.any()),
|
|
36
|
+
files: z.array(z.lazy(() => ORAnthropicBashToolResultFile$inboundSchema))
|
|
37
|
+
.optional(),
|
|
38
|
+
tool_use_id: z.string(),
|
|
39
|
+
type: z.literal("openrouter_bash_tool_result"),
|
|
40
|
+
}).transform((v) => {
|
|
41
|
+
return remap$(v, {
|
|
42
|
+
"container_id": "containerId",
|
|
43
|
+
"tool_use_id": "toolUseId",
|
|
44
|
+
});
|
|
45
|
+
});
|
|
46
|
+
export function orAnthropicBashToolResultFromJSON(jsonString) {
|
|
47
|
+
return safeParse(jsonString, (x) => ORAnthropicBashToolResult$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ORAnthropicBashToolResult' from JSON`);
|
|
48
|
+
}
|
|
49
|
+
//# sourceMappingURL=oranthropicbashtoolresult.js.map
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
import * as discriminatedUnionTypes from "../types/discriminatedUnion.js";
|
|
3
|
+
import { Result as SafeParseResult } from "../types/fp.js";
|
|
4
|
+
import { AnthropicAdvisorToolResult } from "./anthropicadvisortoolresult.js";
|
|
5
|
+
import { AnthropicBashCodeExecutionToolResult } from "./anthropicbashcodeexecutiontoolresult.js";
|
|
6
|
+
import { AnthropicCodeExecutionToolResult } from "./anthropiccodeexecutiontoolresult.js";
|
|
7
|
+
import { AnthropicCompactionBlock } from "./anthropiccompactionblock.js";
|
|
8
|
+
import { AnthropicContainerUpload } from "./anthropiccontainerupload.js";
|
|
9
|
+
import { AnthropicRedactedThinkingBlock } from "./anthropicredactedthinkingblock.js";
|
|
10
|
+
import { AnthropicTextBlock } from "./anthropictextblock.js";
|
|
11
|
+
import { AnthropicTextEditorCodeExecutionToolResult } from "./anthropictexteditorcodeexecutiontoolresult.js";
|
|
12
|
+
import { AnthropicThinkingBlock } from "./anthropicthinkingblock.js";
|
|
13
|
+
import { AnthropicToolSearchToolResult } from "./anthropictoolsearchtoolresult.js";
|
|
14
|
+
import { AnthropicToolUseBlock } from "./anthropictooluseblock.js";
|
|
15
|
+
import { AnthropicWebFetchToolResult } from "./anthropicwebfetchtoolresult.js";
|
|
16
|
+
import { AnthropicWebSearchToolResult } from "./anthropicwebsearchtoolresult.js";
|
|
17
|
+
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
18
|
+
import { ORAnthropicBashToolResult } from "./oranthropicbashtoolresult.js";
|
|
19
|
+
import { ORAnthropicServerToolUseBlock } from "./oranthropicservertooluseblock.js";
|
|
20
|
+
import { ORAnthropicShellToolResult } from "./oranthropicshelltoolresult.js";
|
|
21
|
+
export type ORAnthropicContentBlock = AnthropicAdvisorToolResult | AnthropicBashCodeExecutionToolResult | AnthropicCodeExecutionToolResult | AnthropicCompactionBlock | AnthropicContainerUpload | ORAnthropicBashToolResult | ORAnthropicShellToolResult | AnthropicRedactedThinkingBlock | ORAnthropicServerToolUseBlock | AnthropicTextBlock | AnthropicTextEditorCodeExecutionToolResult | AnthropicThinkingBlock | AnthropicToolSearchToolResult | AnthropicToolUseBlock | AnthropicWebFetchToolResult | AnthropicWebSearchToolResult | discriminatedUnionTypes.Unknown<"type">;
|
|
22
|
+
/** @internal */
|
|
23
|
+
export declare const ORAnthropicContentBlock$inboundSchema: z.ZodType<ORAnthropicContentBlock, unknown>;
|
|
24
|
+
export declare function orAnthropicContentBlockFromJSON(jsonString: string): SafeParseResult<ORAnthropicContentBlock, SDKValidationError>;
|
|
25
|
+
//# sourceMappingURL=oranthropiccontentblock.d.ts.map
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: 29775b270fae
|
|
4
|
+
*/
|
|
5
|
+
import { safeParse } from "../lib/schemas.js";
|
|
6
|
+
import { discriminatedUnion } from "../types/discriminatedUnion.js";
|
|
7
|
+
import { AnthropicAdvisorToolResult$inboundSchema, } from "./anthropicadvisortoolresult.js";
|
|
8
|
+
import { AnthropicBashCodeExecutionToolResult$inboundSchema, } from "./anthropicbashcodeexecutiontoolresult.js";
|
|
9
|
+
import { AnthropicCodeExecutionToolResult$inboundSchema, } from "./anthropiccodeexecutiontoolresult.js";
|
|
10
|
+
import { AnthropicCompactionBlock$inboundSchema, } from "./anthropiccompactionblock.js";
|
|
11
|
+
import { AnthropicContainerUpload$inboundSchema, } from "./anthropiccontainerupload.js";
|
|
12
|
+
import { AnthropicRedactedThinkingBlock$inboundSchema, } from "./anthropicredactedthinkingblock.js";
|
|
13
|
+
import { AnthropicTextBlock$inboundSchema, } from "./anthropictextblock.js";
|
|
14
|
+
import { AnthropicTextEditorCodeExecutionToolResult$inboundSchema, } from "./anthropictexteditorcodeexecutiontoolresult.js";
|
|
15
|
+
import { AnthropicThinkingBlock$inboundSchema, } from "./anthropicthinkingblock.js";
|
|
16
|
+
import { AnthropicToolSearchToolResult$inboundSchema, } from "./anthropictoolsearchtoolresult.js";
|
|
17
|
+
import { AnthropicToolUseBlock$inboundSchema, } from "./anthropictooluseblock.js";
|
|
18
|
+
import { AnthropicWebFetchToolResult$inboundSchema, } from "./anthropicwebfetchtoolresult.js";
|
|
19
|
+
import { AnthropicWebSearchToolResult$inboundSchema, } from "./anthropicwebsearchtoolresult.js";
|
|
20
|
+
import { ORAnthropicBashToolResult$inboundSchema, } from "./oranthropicbashtoolresult.js";
|
|
21
|
+
import { ORAnthropicServerToolUseBlock$inboundSchema, } from "./oranthropicservertooluseblock.js";
|
|
22
|
+
import { ORAnthropicShellToolResult$inboundSchema, } from "./oranthropicshelltoolresult.js";
|
|
23
|
+
/** @internal */
|
|
24
|
+
export const ORAnthropicContentBlock$inboundSchema = discriminatedUnion("type", {
|
|
25
|
+
advisor_tool_result: AnthropicAdvisorToolResult$inboundSchema,
|
|
26
|
+
bash_code_execution_tool_result: AnthropicBashCodeExecutionToolResult$inboundSchema,
|
|
27
|
+
code_execution_tool_result: AnthropicCodeExecutionToolResult$inboundSchema,
|
|
28
|
+
compaction: AnthropicCompactionBlock$inboundSchema,
|
|
29
|
+
container_upload: AnthropicContainerUpload$inboundSchema,
|
|
30
|
+
openrouter_bash_tool_result: ORAnthropicBashToolResult$inboundSchema,
|
|
31
|
+
openrouter_shell_tool_result: ORAnthropicShellToolResult$inboundSchema,
|
|
32
|
+
redacted_thinking: AnthropicRedactedThinkingBlock$inboundSchema,
|
|
33
|
+
server_tool_use: ORAnthropicServerToolUseBlock$inboundSchema,
|
|
34
|
+
text: AnthropicTextBlock$inboundSchema,
|
|
35
|
+
text_editor_code_execution_tool_result: AnthropicTextEditorCodeExecutionToolResult$inboundSchema,
|
|
36
|
+
thinking: AnthropicThinkingBlock$inboundSchema,
|
|
37
|
+
tool_search_tool_result: AnthropicToolSearchToolResult$inboundSchema,
|
|
38
|
+
tool_use: AnthropicToolUseBlock$inboundSchema,
|
|
39
|
+
web_fetch_tool_result: AnthropicWebFetchToolResult$inboundSchema,
|
|
40
|
+
web_search_tool_result: AnthropicWebSearchToolResult$inboundSchema,
|
|
41
|
+
});
|
|
42
|
+
export function orAnthropicContentBlockFromJSON(jsonString) {
|
|
43
|
+
return safeParse(jsonString, (x) => ORAnthropicContentBlock$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ORAnthropicContentBlock' from JSON`);
|
|
44
|
+
}
|
|
45
|
+
//# sourceMappingURL=oranthropiccontentblock.js.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
import * as discriminatedUnionTypes from "../types/discriminatedUnion.js";
|
|
3
|
+
import { Result as SafeParseResult } from "../types/fp.js";
|
|
4
|
+
import { AnthropicCodeExecution20250825Caller } from "./anthropiccodeexecution20250825caller.js";
|
|
5
|
+
import { AnthropicCodeExecution20260120Caller } from "./anthropiccodeexecution20260120caller.js";
|
|
6
|
+
import { AnthropicDirectCaller } from "./anthropicdirectcaller.js";
|
|
7
|
+
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
8
|
+
export type ORAnthropicNullableCaller = AnthropicCodeExecution20250825Caller | AnthropicCodeExecution20260120Caller | AnthropicDirectCaller | discriminatedUnionTypes.Unknown<"type">;
|
|
9
|
+
/** @internal */
|
|
10
|
+
export declare const ORAnthropicNullableCaller$inboundSchema: z.ZodType<ORAnthropicNullableCaller, unknown>;
|
|
11
|
+
export declare function orAnthropicNullableCallerFromJSON(jsonString: string): SafeParseResult<ORAnthropicNullableCaller, SDKValidationError>;
|
|
12
|
+
//# sourceMappingURL=oranthropicnullablecaller.d.ts.map
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: ecf0849a25c1
|
|
4
|
+
*/
|
|
5
|
+
import { safeParse } from "../lib/schemas.js";
|
|
6
|
+
import { discriminatedUnion } from "../types/discriminatedUnion.js";
|
|
7
|
+
import { AnthropicCodeExecution20250825Caller$inboundSchema, } from "./anthropiccodeexecution20250825caller.js";
|
|
8
|
+
import { AnthropicCodeExecution20260120Caller$inboundSchema, } from "./anthropiccodeexecution20260120caller.js";
|
|
9
|
+
import { AnthropicDirectCaller$inboundSchema, } from "./anthropicdirectcaller.js";
|
|
10
|
+
/** @internal */
|
|
11
|
+
export const ORAnthropicNullableCaller$inboundSchema = discriminatedUnion("type", {
|
|
12
|
+
code_execution_20250825: AnthropicCodeExecution20250825Caller$inboundSchema,
|
|
13
|
+
code_execution_20260120: AnthropicCodeExecution20260120Caller$inboundSchema,
|
|
14
|
+
direct: AnthropicDirectCaller$inboundSchema,
|
|
15
|
+
});
|
|
16
|
+
export function orAnthropicNullableCallerFromJSON(jsonString) {
|
|
17
|
+
return safeParse(jsonString, (x) => ORAnthropicNullableCaller$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ORAnthropicNullableCaller' from JSON`);
|
|
18
|
+
}
|
|
19
|
+
//# sourceMappingURL=oranthropicnullablecaller.js.map
|
|
@@ -0,0 +1,15 @@
|
|
|
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 { ORAnthropicNullableCaller } from "./oranthropicnullablecaller.js";
|
|
5
|
+
export type ORAnthropicServerToolUseBlock = {
|
|
6
|
+
caller?: ORAnthropicNullableCaller | null | undefined;
|
|
7
|
+
id: string;
|
|
8
|
+
input?: any | undefined;
|
|
9
|
+
name: string;
|
|
10
|
+
type: "server_tool_use";
|
|
11
|
+
};
|
|
12
|
+
/** @internal */
|
|
13
|
+
export declare const ORAnthropicServerToolUseBlock$inboundSchema: z.ZodType<ORAnthropicServerToolUseBlock, unknown>;
|
|
14
|
+
export declare function orAnthropicServerToolUseBlockFromJSON(jsonString: string): SafeParseResult<ORAnthropicServerToolUseBlock, SDKValidationError>;
|
|
15
|
+
//# sourceMappingURL=oranthropicservertooluseblock.d.ts.map
|