@openrouter/sdk 0.5.1 → 0.9.11
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/FUNCTIONS.md +5 -1
- package/esm/funcs/analyticsGetUserActivity.d.ts +1 -1
- package/esm/funcs/analyticsGetUserActivity.js +4 -2
- package/esm/funcs/apiKeysCreate.d.ts +1 -1
- package/esm/funcs/apiKeysCreate.js +5 -3
- package/esm/funcs/apiKeysDelete.d.ts +1 -1
- package/esm/funcs/apiKeysDelete.js +3 -1
- package/esm/funcs/apiKeysGet.d.ts +1 -1
- package/esm/funcs/apiKeysGet.js +3 -1
- package/esm/funcs/apiKeysGetCurrentKeyMetadata.d.ts +1 -1
- package/esm/funcs/apiKeysGetCurrentKeyMetadata.js +14 -3
- package/esm/funcs/apiKeysList.d.ts +1 -1
- package/esm/funcs/apiKeysList.js +4 -2
- package/esm/funcs/apiKeysUpdate.d.ts +1 -1
- package/esm/funcs/apiKeysUpdate.js +3 -1
- package/esm/funcs/betaResponsesSend.d.ts +9 -5
- package/esm/funcs/betaResponsesSend.js +10 -5
- package/esm/funcs/chatSend.d.ts +11 -7
- package/esm/funcs/chatSend.js +28 -7
- package/esm/funcs/creditsCreateCoinbaseCharge.d.ts +1 -2
- package/esm/funcs/creditsCreateCoinbaseCharge.js +7 -4
- package/esm/funcs/creditsGetCredits.d.ts +2 -2
- package/esm/funcs/creditsGetCredits.js +15 -4
- package/esm/funcs/embeddingsGenerate.js +4 -2
- package/esm/funcs/embeddingsListModels.d.ts +2 -1
- package/esm/funcs/embeddingsListModels.js +15 -3
- package/esm/funcs/endpointsList.js +2 -0
- package/esm/funcs/endpointsListZdrEndpoints.d.ts +1 -1
- package/esm/funcs/endpointsListZdrEndpoints.js +14 -3
- package/esm/funcs/generationsGetGeneration.js +3 -1
- package/esm/funcs/guardrailsBulkAssignKeys.d.ts +1 -1
- package/esm/funcs/guardrailsBulkAssignKeys.js +3 -1
- package/esm/funcs/guardrailsBulkAssignMembers.d.ts +1 -1
- package/esm/funcs/guardrailsBulkAssignMembers.js +3 -1
- package/esm/funcs/guardrailsBulkUnassignKeys.d.ts +1 -1
- package/esm/funcs/guardrailsBulkUnassignKeys.js +3 -1
- package/esm/funcs/guardrailsBulkUnassignMembers.d.ts +1 -1
- package/esm/funcs/guardrailsBulkUnassignMembers.js +3 -1
- package/esm/funcs/guardrailsCreate.d.ts +1 -1
- package/esm/funcs/guardrailsCreate.js +5 -3
- package/esm/funcs/guardrailsDelete.d.ts +1 -1
- package/esm/funcs/guardrailsDelete.js +3 -1
- package/esm/funcs/guardrailsGet.d.ts +1 -1
- package/esm/funcs/guardrailsGet.js +3 -1
- package/esm/funcs/guardrailsList.d.ts +1 -1
- package/esm/funcs/guardrailsList.js +4 -2
- package/esm/funcs/guardrailsListGuardrailKeyAssignments.d.ts +1 -1
- package/esm/funcs/guardrailsListGuardrailKeyAssignments.js +3 -1
- package/esm/funcs/guardrailsListGuardrailMemberAssignments.d.ts +1 -1
- package/esm/funcs/guardrailsListGuardrailMemberAssignments.js +3 -1
- package/esm/funcs/guardrailsListKeyAssignments.d.ts +1 -1
- package/esm/funcs/guardrailsListKeyAssignments.js +4 -2
- package/esm/funcs/guardrailsListMemberAssignments.d.ts +1 -1
- package/esm/funcs/guardrailsListMemberAssignments.js +4 -2
- package/esm/funcs/guardrailsUpdate.d.ts +1 -1
- package/esm/funcs/guardrailsUpdate.js +3 -1
- package/esm/funcs/modelsCount.d.ts +2 -1
- package/esm/funcs/modelsCount.js +15 -3
- package/esm/funcs/modelsList.js +3 -1
- package/esm/funcs/modelsListForUser.d.ts +1 -1
- package/esm/funcs/modelsListForUser.js +15 -3
- package/esm/funcs/oAuthCreateAuthCode.js +4 -2
- package/esm/funcs/oAuthExchangeAuthCodeForAPIKey.js +4 -2
- package/esm/funcs/providersList.d.ts +1 -1
- package/esm/funcs/providersList.js +14 -3
- package/esm/lib/config.d.ts +2 -2
- package/esm/lib/config.js +2 -2
- package/esm/lib/model-result.d.ts +3 -5
- package/esm/lib/model-result.js +98 -46
- package/esm/models/assistantmessage.d.ts +47 -36
- package/esm/models/assistantmessage.js +35 -47
- package/esm/models/assistantmessageimages.d.ts +33 -0
- package/esm/models/assistantmessageimages.js +44 -0
- package/esm/models/chatgenerationparams.d.ts +318 -182
- package/esm/models/chatgenerationparams.js +157 -143
- package/esm/models/chatgenerationtokenusage.d.ts +48 -0
- package/esm/models/chatmessagecontentitem.d.ts +15 -10
- package/esm/models/chatmessagecontentitem.js +25 -4
- package/esm/models/chatmessagecontentitemaudio.d.ts +20 -2
- package/esm/models/chatmessagecontentitemaudio.js +9 -2
- package/esm/models/chatmessagecontentitemcachecontrol.d.ts +14 -3
- package/esm/models/chatmessagecontentitemcachecontrol.js +9 -2
- package/esm/models/chatmessagecontentitemimage.d.ts +26 -3
- package/esm/models/chatmessagecontentitemimage.js +12 -2
- package/esm/models/chatmessagecontentitemtext.d.ts +17 -2
- package/esm/models/chatmessagecontentitemtext.js +9 -2
- package/esm/models/chatmessagecontentitemvideo.d.ts +12 -55
- package/esm/models/chatmessagecontentitemvideo.js +5 -72
- package/esm/models/chatmessagecontentitemvideolegacy.d.ts +28 -0
- package/esm/models/chatmessagecontentitemvideolegacy.js +33 -0
- package/esm/models/chatmessagetokenlogprob.d.ts +15 -0
- package/esm/models/chatmessagetokenlogprobs.d.ts +9 -0
- package/esm/models/chatmessagetoolcall.d.ts +23 -2
- package/esm/models/chatmessagetoolcall.js +9 -2
- package/esm/models/chatresponse.d.ts +29 -1
- package/esm/models/chatresponse.js +6 -1
- package/esm/models/chatresponsechoice.d.ts +13 -2
- package/esm/models/chatresponsechoice.js +1 -2
- package/esm/models/chatstreamingchoice.d.ts +13 -2
- package/esm/models/chatstreamingchoice.js +1 -2
- package/esm/models/chatstreamingmessagechunk.d.ts +29 -2
- package/esm/models/chatstreamingmessagechunk.js +5 -2
- package/esm/models/chatstreamingmessagetoolcall.d.ts +38 -1
- package/esm/models/chatstreamingmessagetoolcall.js +9 -1
- package/esm/models/chatstreamingresponsechunk.d.ts +45 -11
- package/esm/models/chatstreamingresponsechunk.js +11 -25
- package/esm/models/chatstreamoptions.d.ts +8 -0
- package/esm/models/debugoptions.d.ts +18 -0
- package/esm/models/debugoptions.js +18 -0
- package/esm/models/developermessage.d.ts +35 -0
- package/esm/models/developermessage.js +24 -0
- package/esm/models/errors/index.d.ts +0 -1
- package/esm/models/errors/index.js +0 -1
- package/esm/models/index.d.ts +13 -5
- package/esm/models/index.js +13 -5
- package/esm/models/jsonschemaconfig.d.ts +17 -2
- package/esm/models/jsonschemaconfig.js +1 -1
- package/esm/models/message.d.ts +10 -23
- package/esm/models/message.js +3 -20
- package/esm/models/modelscountresponse.d.ts +4 -4
- package/esm/models/modelscountresponse.js +4 -4
- package/esm/models/namedtoolchoice.d.ts +15 -2
- package/esm/models/namedtoolchoice.js +6 -1
- package/esm/models/openairesponsesreasoningconfig.d.ts +1 -1
- package/esm/models/openairesponsesreasoningconfig.js +1 -1
- package/esm/models/openresponsesnonstreamingresponse.d.ts +4 -4
- package/esm/models/openresponsesnonstreamingresponse.js +3 -3
- package/esm/models/openresponsesreasoning.d.ts +2 -2
- package/esm/models/openresponsesreasoning.js +1 -1
- package/esm/models/openresponsesreasoningconfig.d.ts +2 -2
- package/esm/models/openresponsesreasoningconfig.js +1 -1
- package/esm/models/openresponsesrequest.d.ts +31 -13
- package/esm/models/openresponsesrequest.js +25 -0
- package/esm/models/operations/bulkassignkeystoguardrail.d.ts +30 -0
- package/esm/models/operations/bulkassignkeystoguardrail.js +4 -0
- package/esm/models/operations/bulkassignmemberstoguardrail.d.ts +30 -0
- package/esm/models/operations/bulkassignmemberstoguardrail.js +4 -0
- package/esm/models/operations/bulkunassignkeysfromguardrail.d.ts +30 -0
- package/esm/models/operations/bulkunassignkeysfromguardrail.js +4 -0
- package/esm/models/operations/bulkunassignmembersfromguardrail.d.ts +30 -0
- package/esm/models/operations/bulkunassignmembersfromguardrail.js +4 -0
- package/esm/models/operations/createauthkeyscode.d.ts +66 -2
- package/esm/models/operations/createauthkeyscode.js +30 -1
- package/esm/models/operations/createcoinbasecharge.d.ts +41 -0
- package/esm/models/operations/createcoinbasecharge.js +16 -0
- package/esm/models/operations/createembeddings.d.ts +42 -2
- package/esm/models/operations/createembeddings.js +16 -1
- package/esm/models/operations/createguardrail.d.ts +42 -2
- package/esm/models/operations/createguardrail.js +16 -1
- package/esm/models/operations/createkeys.d.ts +42 -2
- package/esm/models/operations/createkeys.js +16 -1
- package/esm/models/operations/createresponses.d.ts +40 -0
- package/esm/models/operations/createresponses.js +16 -0
- package/esm/models/operations/deleteguardrail.d.ts +30 -0
- package/esm/models/operations/deleteguardrail.js +8 -0
- package/esm/models/operations/deletekeys.d.ts +30 -0
- package/esm/models/operations/deletekeys.js +8 -0
- package/esm/models/operations/exchangeauthcodeforapikey.d.ts +42 -2
- package/esm/models/operations/exchangeauthcodeforapikey.js +16 -1
- package/esm/models/operations/getcredits.d.ts +38 -0
- package/esm/models/operations/getcredits.js +13 -0
- package/esm/models/operations/getcurrentkey.d.ts +45 -1
- package/esm/models/operations/getcurrentkey.js +15 -0
- package/esm/models/operations/getgeneration.d.ts +153 -0
- package/esm/models/operations/getgeneration.js +135 -0
- package/esm/models/operations/getguardrail.d.ts +30 -0
- package/esm/models/operations/getguardrail.js +7 -0
- package/esm/models/operations/getkey.d.ts +30 -0
- package/esm/models/operations/getkey.js +7 -0
- package/esm/models/operations/getmodels.d.ts +30 -0
- package/esm/models/operations/getmodels.js +4 -0
- package/esm/models/operations/getuseractivity.d.ts +30 -0
- package/esm/models/operations/getuseractivity.js +8 -0
- package/esm/models/operations/index.d.ts +2 -0
- package/esm/models/operations/index.js +2 -0
- package/esm/models/operations/list.d.ts +30 -0
- package/esm/models/operations/list.js +4 -0
- package/esm/models/operations/listembeddingsmodels.d.ts +40 -0
- package/esm/models/operations/listembeddingsmodels.js +20 -0
- package/esm/models/operations/listendpoints.d.ts +30 -0
- package/esm/models/operations/listendpoints.js +8 -0
- package/esm/models/operations/listendpointszdr.d.ts +38 -0
- package/esm/models/operations/listendpointszdr.js +14 -0
- package/esm/models/operations/listguardrailkeyassignments.d.ts +30 -0
- package/esm/models/operations/listguardrailkeyassignments.js +7 -0
- package/esm/models/operations/listguardrailmemberassignments.d.ts +30 -0
- package/esm/models/operations/listguardrailmemberassignments.js +7 -0
- package/esm/models/operations/listguardrails.d.ts +30 -0
- package/esm/models/operations/listguardrails.js +7 -0
- package/esm/models/operations/listkeyassignments.d.ts +30 -0
- package/esm/models/operations/listkeyassignments.js +7 -0
- package/esm/models/operations/listmemberassignments.d.ts +30 -0
- package/esm/models/operations/listmemberassignments.js +7 -0
- package/esm/models/operations/listmodelscount.d.ts +40 -0
- package/esm/models/operations/listmodelscount.js +20 -0
- package/esm/models/operations/listmodelsuser.d.ts +38 -0
- package/esm/models/operations/listmodelsuser.js +14 -0
- package/esm/models/operations/listproviders.d.ts +38 -0
- package/esm/models/operations/listproviders.js +13 -0
- package/esm/models/operations/sendchatcompletionrequest.d.ts +53 -1
- package/esm/models/operations/sendchatcompletionrequest.js +36 -2
- package/esm/models/operations/updateguardrail.d.ts +30 -0
- package/esm/models/operations/updateguardrail.js +4 -0
- package/esm/models/operations/updatekeys.d.ts +30 -0
- package/esm/models/operations/updatekeys.js +4 -0
- package/esm/models/providername.d.ts +4 -0
- package/esm/models/providername.js +4 -0
- package/esm/models/providerpreferences.d.ts +46 -27
- package/esm/models/providerpreferences.js +29 -15
- package/esm/models/providersort.d.ts +6 -0
- package/esm/models/providersort.js +3 -0
- package/esm/models/providersortconfig.d.ts +30 -2
- package/esm/models/providersortconfig.js +15 -2
- package/esm/models/publicendpoint.d.ts +0 -39
- package/esm/models/publicpricing.d.ts +0 -39
- package/esm/models/reasoningdetailencrypted.d.ts +42 -0
- package/esm/models/reasoningdetailencrypted.js +42 -0
- package/esm/models/reasoningdetailsummary.d.ts +42 -0
- package/esm/models/reasoningdetailsummary.js +42 -0
- package/esm/models/reasoningdetailtext.d.ts +44 -0
- package/esm/models/reasoningdetailtext.js +44 -0
- package/esm/models/reasoningdetailunion.d.ts +19 -0
- package/esm/models/reasoningdetailunion.js +28 -0
- package/esm/models/responseformatjsonobject.d.ts +20 -0
- package/esm/models/responseformatjsonobject.js +21 -0
- package/esm/models/responseformatjsonschema.d.ts +6 -0
- package/esm/models/responseformattext.d.ts +15 -0
- package/esm/models/responseformattext.js +13 -0
- package/esm/models/responseformattextconfig.d.ts +3 -3
- package/esm/models/responseformattextconfig.js +3 -3
- package/esm/models/responseformattextgrammar.d.ts +6 -0
- package/esm/models/responseformattextpython.d.ts +15 -0
- package/esm/models/responseformattextpython.js +13 -0
- package/esm/models/responseserrorfield.d.ts +4 -4
- package/esm/models/responseserrorfield.js +4 -4
- package/esm/models/responsesoutputitemreasoning.d.ts +2 -2
- package/esm/models/responsesoutputitemreasoning.js +2 -2
- package/esm/models/systemmessage.d.ts +12 -0
- package/esm/models/toolchoiceoption.d.ts +31 -0
- package/esm/models/toolchoiceoption.js +32 -0
- package/esm/models/tooldefinitionjson.d.ts +38 -4
- package/esm/models/tooldefinitionjson.js +14 -2
- package/esm/models/toolresponsemessage.d.ts +12 -0
- package/esm/models/usermessage.d.ts +12 -0
- package/esm/models/videoinput.d.ts +23 -0
- package/esm/models/videoinput.js +22 -0
- package/esm/sdk/analytics.d.ts +1 -1
- package/esm/sdk/analytics.js +1 -1
- package/esm/sdk/apikeys.d.ts +6 -6
- package/esm/sdk/apikeys.js +7 -7
- package/esm/sdk/chat.d.ts +10 -6
- package/esm/sdk/credits.d.ts +3 -4
- package/esm/sdk/credits.js +3 -3
- package/esm/sdk/embeddings.d.ts +1 -1
- package/esm/sdk/embeddings.js +2 -2
- package/esm/sdk/endpoints.d.ts +1 -1
- package/esm/sdk/endpoints.js +2 -2
- package/esm/sdk/guardrails.d.ts +13 -13
- package/esm/sdk/guardrails.js +13 -13
- package/esm/sdk/models.d.ts +2 -2
- package/esm/sdk/models.js +4 -4
- package/esm/sdk/providers.d.ts +1 -1
- package/esm/sdk/providers.js +2 -2
- package/esm/sdk/responses.d.ts +9 -5
- package/esm/sdk/sdk.d.ts +2 -2
- package/esm/sdk/sdk.js +3 -3
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/esm/models/chaterror.d.ts +0 -17
- package/esm/models/chaterror.js +0 -25
- package/esm/models/errors/chaterror.d.ts +0 -19
- package/esm/models/errors/chaterror.js +0 -32
- package/esm/models/providersortunion.d.ts +0 -10
- package/esm/models/providersortunion.js +0 -13
- package/esm/models/responsesformatjsonobject.d.ts +0 -20
- package/esm/models/responsesformatjsonobject.js +0 -21
- package/esm/models/schema0.d.ts +0 -84
- package/esm/models/schema0.js +0 -87
- package/esm/models/schema2.d.ts +0 -92
- package/esm/models/schema2.js +0 -109
package/esm/models/schema0.js
DELETED
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
* @generated-id: 14bff3bd8497
|
|
4
|
-
*/
|
|
5
|
-
import * as z from "zod/v4";
|
|
6
|
-
import * as openEnums from "../types/enums.js";
|
|
7
|
-
export const Schema0Enum = {
|
|
8
|
-
Ai21: "AI21",
|
|
9
|
-
AionLabs: "AionLabs",
|
|
10
|
-
Alibaba: "Alibaba",
|
|
11
|
-
AmazonBedrock: "Amazon Bedrock",
|
|
12
|
-
AmazonNova: "Amazon Nova",
|
|
13
|
-
Anthropic: "Anthropic",
|
|
14
|
-
ArceeAI: "Arcee AI",
|
|
15
|
-
AtlasCloud: "AtlasCloud",
|
|
16
|
-
Avian: "Avian",
|
|
17
|
-
Azure: "Azure",
|
|
18
|
-
BaseTen: "BaseTen",
|
|
19
|
-
BytePlus: "BytePlus",
|
|
20
|
-
BlackForestLabs: "Black Forest Labs",
|
|
21
|
-
Cerebras: "Cerebras",
|
|
22
|
-
Chutes: "Chutes",
|
|
23
|
-
Cirrascale: "Cirrascale",
|
|
24
|
-
Clarifai: "Clarifai",
|
|
25
|
-
Cloudflare: "Cloudflare",
|
|
26
|
-
Cohere: "Cohere",
|
|
27
|
-
Crusoe: "Crusoe",
|
|
28
|
-
DeepInfra: "DeepInfra",
|
|
29
|
-
DeepSeek: "DeepSeek",
|
|
30
|
-
Featherless: "Featherless",
|
|
31
|
-
Fireworks: "Fireworks",
|
|
32
|
-
Friendli: "Friendli",
|
|
33
|
-
GMICloud: "GMICloud",
|
|
34
|
-
Google: "Google",
|
|
35
|
-
GoogleAIStudio: "Google AI Studio",
|
|
36
|
-
Groq: "Groq",
|
|
37
|
-
Hyperbolic: "Hyperbolic",
|
|
38
|
-
Inception: "Inception",
|
|
39
|
-
Inceptron: "Inceptron",
|
|
40
|
-
InferenceNet: "InferenceNet",
|
|
41
|
-
Infermatic: "Infermatic",
|
|
42
|
-
Inflection: "Inflection",
|
|
43
|
-
Liquid: "Liquid",
|
|
44
|
-
Mara: "Mara",
|
|
45
|
-
Mancer2: "Mancer 2",
|
|
46
|
-
Minimax: "Minimax",
|
|
47
|
-
ModelRun: "ModelRun",
|
|
48
|
-
Mistral: "Mistral",
|
|
49
|
-
Modular: "Modular",
|
|
50
|
-
MoonshotAI: "Moonshot AI",
|
|
51
|
-
Morph: "Morph",
|
|
52
|
-
NCompass: "NCompass",
|
|
53
|
-
Nebius: "Nebius",
|
|
54
|
-
NextBit: "NextBit",
|
|
55
|
-
Novita: "Novita",
|
|
56
|
-
Nvidia: "Nvidia",
|
|
57
|
-
OpenAI: "OpenAI",
|
|
58
|
-
OpenInference: "OpenInference",
|
|
59
|
-
Parasail: "Parasail",
|
|
60
|
-
Perplexity: "Perplexity",
|
|
61
|
-
Phala: "Phala",
|
|
62
|
-
Relace: "Relace",
|
|
63
|
-
SambaNova: "SambaNova",
|
|
64
|
-
Seed: "Seed",
|
|
65
|
-
SiliconFlow: "SiliconFlow",
|
|
66
|
-
Sourceful: "Sourceful",
|
|
67
|
-
Stealth: "Stealth",
|
|
68
|
-
StreamLake: "StreamLake",
|
|
69
|
-
Switchpoint: "Switchpoint",
|
|
70
|
-
Together: "Together",
|
|
71
|
-
Upstage: "Upstage",
|
|
72
|
-
Venice: "Venice",
|
|
73
|
-
WandB: "WandB",
|
|
74
|
-
Xiaomi: "Xiaomi",
|
|
75
|
-
XAI: "xAI",
|
|
76
|
-
ZAi: "Z.AI",
|
|
77
|
-
FakeProvider: "FakeProvider",
|
|
78
|
-
};
|
|
79
|
-
/** @internal */
|
|
80
|
-
export const Schema0Enum$outboundSchema = openEnums.outboundSchema(Schema0Enum);
|
|
81
|
-
/** @internal */
|
|
82
|
-
export const Schema0$outboundSchema = z
|
|
83
|
-
.union([Schema0Enum$outboundSchema, z.string()]);
|
|
84
|
-
export function schema0ToJSON(schema0) {
|
|
85
|
-
return JSON.stringify(Schema0$outboundSchema.parse(schema0));
|
|
86
|
-
}
|
|
87
|
-
//# sourceMappingURL=schema0.js.map
|
package/esm/models/schema2.d.ts
DELETED
|
@@ -1,92 +0,0 @@
|
|
|
1
|
-
import * as z from "zod/v4";
|
|
2
|
-
import { OpenEnum } from "../types/enums.js";
|
|
3
|
-
import { Result as SafeParseResult } from "../types/fp.js";
|
|
4
|
-
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
5
|
-
export declare const Schema4: {
|
|
6
|
-
readonly Unknown: "unknown";
|
|
7
|
-
readonly OpenaiResponsesV1: "openai-responses-v1";
|
|
8
|
-
readonly AzureOpenaiResponsesV1: "azure-openai-responses-v1";
|
|
9
|
-
readonly XaiResponsesV1: "xai-responses-v1";
|
|
10
|
-
readonly AnthropicClaudeV1: "anthropic-claude-v1";
|
|
11
|
-
readonly GoogleGeminiV1: "google-gemini-v1";
|
|
12
|
-
};
|
|
13
|
-
export type Schema4 = OpenEnum<typeof Schema4>;
|
|
14
|
-
export type Schema2ReasoningText = {
|
|
15
|
-
type: "reasoning.text";
|
|
16
|
-
text?: string | null | undefined;
|
|
17
|
-
signature?: string | null | undefined;
|
|
18
|
-
id?: string | null | undefined;
|
|
19
|
-
format?: Schema4 | null | undefined;
|
|
20
|
-
index?: number | undefined;
|
|
21
|
-
};
|
|
22
|
-
export type Schema2ReasoningEncrypted = {
|
|
23
|
-
type: "reasoning.encrypted";
|
|
24
|
-
data: string;
|
|
25
|
-
id?: string | null | undefined;
|
|
26
|
-
format?: Schema4 | null | undefined;
|
|
27
|
-
index?: number | undefined;
|
|
28
|
-
};
|
|
29
|
-
export type Schema2ReasoningSummary = {
|
|
30
|
-
type: "reasoning.summary";
|
|
31
|
-
summary: string;
|
|
32
|
-
id?: string | null | undefined;
|
|
33
|
-
format?: Schema4 | null | undefined;
|
|
34
|
-
index?: number | undefined;
|
|
35
|
-
};
|
|
36
|
-
export type Schema2 = Schema2ReasoningSummary | Schema2ReasoningEncrypted | Schema2ReasoningText;
|
|
37
|
-
/** @internal */
|
|
38
|
-
export declare const Schema4$inboundSchema: z.ZodType<Schema4, unknown>;
|
|
39
|
-
/** @internal */
|
|
40
|
-
export declare const Schema4$outboundSchema: z.ZodType<string, Schema4>;
|
|
41
|
-
/** @internal */
|
|
42
|
-
export declare const Schema2ReasoningText$inboundSchema: z.ZodType<Schema2ReasoningText, unknown>;
|
|
43
|
-
/** @internal */
|
|
44
|
-
export type Schema2ReasoningText$Outbound = {
|
|
45
|
-
type: "reasoning.text";
|
|
46
|
-
text?: string | null | undefined;
|
|
47
|
-
signature?: string | null | undefined;
|
|
48
|
-
id?: string | null | undefined;
|
|
49
|
-
format?: string | null | undefined;
|
|
50
|
-
index?: number | undefined;
|
|
51
|
-
};
|
|
52
|
-
/** @internal */
|
|
53
|
-
export declare const Schema2ReasoningText$outboundSchema: z.ZodType<Schema2ReasoningText$Outbound, Schema2ReasoningText>;
|
|
54
|
-
export declare function schema2ReasoningTextToJSON(schema2ReasoningText: Schema2ReasoningText): string;
|
|
55
|
-
export declare function schema2ReasoningTextFromJSON(jsonString: string): SafeParseResult<Schema2ReasoningText, SDKValidationError>;
|
|
56
|
-
/** @internal */
|
|
57
|
-
export declare const Schema2ReasoningEncrypted$inboundSchema: z.ZodType<Schema2ReasoningEncrypted, unknown>;
|
|
58
|
-
/** @internal */
|
|
59
|
-
export type Schema2ReasoningEncrypted$Outbound = {
|
|
60
|
-
type: "reasoning.encrypted";
|
|
61
|
-
data: string;
|
|
62
|
-
id?: string | null | undefined;
|
|
63
|
-
format?: string | null | undefined;
|
|
64
|
-
index?: number | undefined;
|
|
65
|
-
};
|
|
66
|
-
/** @internal */
|
|
67
|
-
export declare const Schema2ReasoningEncrypted$outboundSchema: z.ZodType<Schema2ReasoningEncrypted$Outbound, Schema2ReasoningEncrypted>;
|
|
68
|
-
export declare function schema2ReasoningEncryptedToJSON(schema2ReasoningEncrypted: Schema2ReasoningEncrypted): string;
|
|
69
|
-
export declare function schema2ReasoningEncryptedFromJSON(jsonString: string): SafeParseResult<Schema2ReasoningEncrypted, SDKValidationError>;
|
|
70
|
-
/** @internal */
|
|
71
|
-
export declare const Schema2ReasoningSummary$inboundSchema: z.ZodType<Schema2ReasoningSummary, unknown>;
|
|
72
|
-
/** @internal */
|
|
73
|
-
export type Schema2ReasoningSummary$Outbound = {
|
|
74
|
-
type: "reasoning.summary";
|
|
75
|
-
summary: string;
|
|
76
|
-
id?: string | null | undefined;
|
|
77
|
-
format?: string | null | undefined;
|
|
78
|
-
index?: number | undefined;
|
|
79
|
-
};
|
|
80
|
-
/** @internal */
|
|
81
|
-
export declare const Schema2ReasoningSummary$outboundSchema: z.ZodType<Schema2ReasoningSummary$Outbound, Schema2ReasoningSummary>;
|
|
82
|
-
export declare function schema2ReasoningSummaryToJSON(schema2ReasoningSummary: Schema2ReasoningSummary): string;
|
|
83
|
-
export declare function schema2ReasoningSummaryFromJSON(jsonString: string): SafeParseResult<Schema2ReasoningSummary, SDKValidationError>;
|
|
84
|
-
/** @internal */
|
|
85
|
-
export declare const Schema2$inboundSchema: z.ZodType<Schema2, unknown>;
|
|
86
|
-
/** @internal */
|
|
87
|
-
export type Schema2$Outbound = Schema2ReasoningSummary$Outbound | Schema2ReasoningEncrypted$Outbound | Schema2ReasoningText$Outbound;
|
|
88
|
-
/** @internal */
|
|
89
|
-
export declare const Schema2$outboundSchema: z.ZodType<Schema2$Outbound, Schema2>;
|
|
90
|
-
export declare function schema2ToJSON(schema2: Schema2): string;
|
|
91
|
-
export declare function schema2FromJSON(jsonString: string): SafeParseResult<Schema2, SDKValidationError>;
|
|
92
|
-
//# sourceMappingURL=schema2.d.ts.map
|
package/esm/models/schema2.js
DELETED
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
* @generated-id: f5d5abd15e27
|
|
4
|
-
*/
|
|
5
|
-
import * as z from "zod/v4";
|
|
6
|
-
import { safeParse } from "../lib/schemas.js";
|
|
7
|
-
import * as openEnums from "../types/enums.js";
|
|
8
|
-
export const Schema4 = {
|
|
9
|
-
Unknown: "unknown",
|
|
10
|
-
OpenaiResponsesV1: "openai-responses-v1",
|
|
11
|
-
AzureOpenaiResponsesV1: "azure-openai-responses-v1",
|
|
12
|
-
XaiResponsesV1: "xai-responses-v1",
|
|
13
|
-
AnthropicClaudeV1: "anthropic-claude-v1",
|
|
14
|
-
GoogleGeminiV1: "google-gemini-v1",
|
|
15
|
-
};
|
|
16
|
-
/** @internal */
|
|
17
|
-
export const Schema4$inboundSchema = openEnums
|
|
18
|
-
.inboundSchema(Schema4);
|
|
19
|
-
/** @internal */
|
|
20
|
-
export const Schema4$outboundSchema = openEnums
|
|
21
|
-
.outboundSchema(Schema4);
|
|
22
|
-
/** @internal */
|
|
23
|
-
export const Schema2ReasoningText$inboundSchema = z.object({
|
|
24
|
-
type: z.literal("reasoning.text"),
|
|
25
|
-
text: z.nullable(z.string()).optional(),
|
|
26
|
-
signature: z.nullable(z.string()).optional(),
|
|
27
|
-
id: z.nullable(z.string()).optional(),
|
|
28
|
-
format: z.nullable(Schema4$inboundSchema).optional(),
|
|
29
|
-
index: z.number().optional(),
|
|
30
|
-
});
|
|
31
|
-
/** @internal */
|
|
32
|
-
export const Schema2ReasoningText$outboundSchema = z.object({
|
|
33
|
-
type: z.literal("reasoning.text"),
|
|
34
|
-
text: z.nullable(z.string()).optional(),
|
|
35
|
-
signature: z.nullable(z.string()).optional(),
|
|
36
|
-
id: z.nullable(z.string()).optional(),
|
|
37
|
-
format: z.nullable(Schema4$outboundSchema).optional(),
|
|
38
|
-
index: z.number().optional(),
|
|
39
|
-
});
|
|
40
|
-
export function schema2ReasoningTextToJSON(schema2ReasoningText) {
|
|
41
|
-
return JSON.stringify(Schema2ReasoningText$outboundSchema.parse(schema2ReasoningText));
|
|
42
|
-
}
|
|
43
|
-
export function schema2ReasoningTextFromJSON(jsonString) {
|
|
44
|
-
return safeParse(jsonString, (x) => Schema2ReasoningText$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Schema2ReasoningText' from JSON`);
|
|
45
|
-
}
|
|
46
|
-
/** @internal */
|
|
47
|
-
export const Schema2ReasoningEncrypted$inboundSchema = z.object({
|
|
48
|
-
type: z.literal("reasoning.encrypted"),
|
|
49
|
-
data: z.string(),
|
|
50
|
-
id: z.nullable(z.string()).optional(),
|
|
51
|
-
format: z.nullable(Schema4$inboundSchema).optional(),
|
|
52
|
-
index: z.number().optional(),
|
|
53
|
-
});
|
|
54
|
-
/** @internal */
|
|
55
|
-
export const Schema2ReasoningEncrypted$outboundSchema = z.object({
|
|
56
|
-
type: z.literal("reasoning.encrypted"),
|
|
57
|
-
data: z.string(),
|
|
58
|
-
id: z.nullable(z.string()).optional(),
|
|
59
|
-
format: z.nullable(Schema4$outboundSchema).optional(),
|
|
60
|
-
index: z.number().optional(),
|
|
61
|
-
});
|
|
62
|
-
export function schema2ReasoningEncryptedToJSON(schema2ReasoningEncrypted) {
|
|
63
|
-
return JSON.stringify(Schema2ReasoningEncrypted$outboundSchema.parse(schema2ReasoningEncrypted));
|
|
64
|
-
}
|
|
65
|
-
export function schema2ReasoningEncryptedFromJSON(jsonString) {
|
|
66
|
-
return safeParse(jsonString, (x) => Schema2ReasoningEncrypted$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Schema2ReasoningEncrypted' from JSON`);
|
|
67
|
-
}
|
|
68
|
-
/** @internal */
|
|
69
|
-
export const Schema2ReasoningSummary$inboundSchema = z.object({
|
|
70
|
-
type: z.literal("reasoning.summary"),
|
|
71
|
-
summary: z.string(),
|
|
72
|
-
id: z.nullable(z.string()).optional(),
|
|
73
|
-
format: z.nullable(Schema4$inboundSchema).optional(),
|
|
74
|
-
index: z.number().optional(),
|
|
75
|
-
});
|
|
76
|
-
/** @internal */
|
|
77
|
-
export const Schema2ReasoningSummary$outboundSchema = z.object({
|
|
78
|
-
type: z.literal("reasoning.summary"),
|
|
79
|
-
summary: z.string(),
|
|
80
|
-
id: z.nullable(z.string()).optional(),
|
|
81
|
-
format: z.nullable(Schema4$outboundSchema).optional(),
|
|
82
|
-
index: z.number().optional(),
|
|
83
|
-
});
|
|
84
|
-
export function schema2ReasoningSummaryToJSON(schema2ReasoningSummary) {
|
|
85
|
-
return JSON.stringify(Schema2ReasoningSummary$outboundSchema.parse(schema2ReasoningSummary));
|
|
86
|
-
}
|
|
87
|
-
export function schema2ReasoningSummaryFromJSON(jsonString) {
|
|
88
|
-
return safeParse(jsonString, (x) => Schema2ReasoningSummary$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Schema2ReasoningSummary' from JSON`);
|
|
89
|
-
}
|
|
90
|
-
/** @internal */
|
|
91
|
-
export const Schema2$inboundSchema = z.union([
|
|
92
|
-
z.lazy(() => Schema2ReasoningSummary$inboundSchema),
|
|
93
|
-
z.lazy(() => Schema2ReasoningEncrypted$inboundSchema),
|
|
94
|
-
z.lazy(() => Schema2ReasoningText$inboundSchema),
|
|
95
|
-
]);
|
|
96
|
-
/** @internal */
|
|
97
|
-
export const Schema2$outboundSchema = z
|
|
98
|
-
.union([
|
|
99
|
-
z.lazy(() => Schema2ReasoningSummary$outboundSchema),
|
|
100
|
-
z.lazy(() => Schema2ReasoningEncrypted$outboundSchema),
|
|
101
|
-
z.lazy(() => Schema2ReasoningText$outboundSchema),
|
|
102
|
-
]);
|
|
103
|
-
export function schema2ToJSON(schema2) {
|
|
104
|
-
return JSON.stringify(Schema2$outboundSchema.parse(schema2));
|
|
105
|
-
}
|
|
106
|
-
export function schema2FromJSON(jsonString) {
|
|
107
|
-
return safeParse(jsonString, (x) => Schema2$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Schema2' from JSON`);
|
|
108
|
-
}
|
|
109
|
-
//# sourceMappingURL=schema2.js.map
|