@openrouter/sdk 0.13.44 → 0.13.46
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/byokList.js +1 -1
- package/esm/funcs/embeddingsListModels.d.ts +4 -2
- package/esm/funcs/embeddingsListModels.js +45 -8
- package/esm/funcs/guardrailsList.js +1 -1
- package/esm/funcs/guardrailsListGuardrailKeyAssignments.js +1 -1
- package/esm/funcs/guardrailsListGuardrailMemberAssignments.js +1 -1
- package/esm/funcs/guardrailsListKeyAssignments.js +1 -1
- package/esm/funcs/guardrailsListMemberAssignments.js +1 -1
- package/esm/funcs/modelsList.d.ts +4 -2
- package/esm/funcs/modelsList.js +39 -7
- package/esm/funcs/modelsListForUser.d.ts +4 -2
- package/esm/funcs/modelsListForUser.js +45 -8
- package/esm/funcs/observabilityList.js +1 -1
- package/esm/funcs/organizationListMembers.js +1 -1
- package/esm/funcs/presetsList.js +1 -1
- package/esm/funcs/presetsListVersions.js +1 -1
- package/esm/funcs/workspacesList.js +1 -1
- package/esm/funcs/workspacesListMembers.js +1 -1
- package/esm/lib/config.d.ts +2 -2
- package/esm/lib/config.js +2 -2
- package/esm/models/additionaltoolsitem.d.ts +5 -5
- package/esm/models/additionaltoolsitem.js +3 -3
- package/esm/models/anthropiccitationsearchresultlocationparam.d.ts +24 -0
- package/esm/models/{anthropiccitationsearchresultlocation.js → anthropiccitationsearchresultlocationparam.js} +5 -5
- package/esm/models/anthropiccitationwebsearchresultlocationparam.d.ts +20 -0
- package/esm/models/{anthropiccitationwebsearchresultlocation.js → anthropiccitationwebsearchresultlocationparam.js} +5 -5
- package/esm/models/anthropictextblockparam.d.ts +6 -6
- package/esm/models/anthropictextblockparam.js +6 -6
- package/esm/models/chatformatjsonobjectconfig.d.ts +15 -0
- package/esm/models/chatformatjsonobjectconfig.js +13 -0
- package/esm/models/chatrequest.d.ts +5 -5
- package/esm/models/chatrequest.js +3 -3
- package/esm/models/createobservabilitydestinationrequest.d.ts +3 -3
- package/esm/models/createobservabilitydestinationrequest.js +2 -2
- package/esm/models/imagegenerationproviderpreferences.d.ts +811 -0
- package/esm/models/imagegenerationproviderpreferences.js +208 -0
- package/esm/models/imagegenerationrequest.d.ts +4 -753
- package/esm/models/imagegenerationrequest.js +2 -162
- package/esm/models/imageinputmodality.d.ts +13 -0
- package/esm/models/imageinputmodality.js +15 -0
- package/esm/models/imagemodelarchitecture.d.ts +2 -2
- package/esm/models/imagemodelarchitecture.js +2 -2
- package/esm/models/index.d.ts +10 -2
- package/esm/models/index.js +10 -2
- package/esm/models/legacychatcontentvideo.d.ts +3 -3
- package/esm/models/legacychatcontentvideo.js +3 -3
- package/esm/models/legacychatcontentvideoinput.d.ts +23 -0
- package/esm/models/legacychatcontentvideoinput.js +21 -0
- package/esm/models/messagesrequest.d.ts +5 -5
- package/esm/models/messagesrequest.js +3 -3
- package/esm/models/messagessearchmodelsservertool.d.ts +28 -0
- package/esm/models/messagessearchmodelsservertool.js +20 -0
- package/esm/models/modelarchitecture.d.ts +2 -35
- package/esm/models/modelarchitecture.js +2 -32
- package/esm/models/modelslistresponse.d.ts +20 -0
- package/esm/models/modelslistresponse.js +14 -0
- package/esm/models/observabilityfilterrulegroup.d.ts +94 -0
- package/esm/models/observabilityfilterrulegroup.js +103 -0
- package/esm/models/observabilityfilterrulesconfig.d.ts +3 -100
- package/esm/models/observabilityfilterrulesconfig.js +2 -105
- package/esm/models/observabilityfilterrulesconfignullable.d.ts +18 -0
- package/esm/models/observabilityfilterrulesconfignullable.js +15 -0
- package/esm/models/operations/createembeddings.d.ts +1 -12
- package/esm/models/operations/createembeddings.js +1 -17
- package/esm/models/operations/getmodels.d.ts +19 -0
- package/esm/models/operations/getmodels.js +15 -0
- package/esm/models/operations/listbyokkeys.d.ts +2 -2
- package/esm/models/operations/listbyokkeys.js +2 -2
- package/esm/models/operations/listembeddingsmodels.d.ts +19 -0
- package/esm/models/operations/listembeddingsmodels.js +15 -0
- package/esm/models/operations/listguardrailkeyassignments.d.ts +2 -2
- package/esm/models/operations/listguardrailkeyassignments.js +2 -2
- package/esm/models/operations/listguardrailmemberassignments.d.ts +2 -2
- package/esm/models/operations/listguardrailmemberassignments.js +2 -2
- package/esm/models/operations/listguardrails.d.ts +2 -2
- package/esm/models/operations/listguardrails.js +2 -2
- package/esm/models/operations/listkeyassignments.d.ts +2 -2
- package/esm/models/operations/listkeyassignments.js +2 -2
- package/esm/models/operations/listmemberassignments.d.ts +2 -2
- package/esm/models/operations/listmemberassignments.js +2 -2
- package/esm/models/operations/listmodelsuser.d.ts +19 -0
- package/esm/models/operations/listmodelsuser.js +15 -0
- package/esm/models/operations/listobservabilitydestinations.d.ts +2 -2
- package/esm/models/operations/listobservabilitydestinations.js +2 -2
- package/esm/models/operations/listorganizationmembers.d.ts +2 -2
- package/esm/models/operations/listorganizationmembers.js +2 -2
- package/esm/models/operations/listpresets.d.ts +2 -2
- package/esm/models/operations/listpresets.js +2 -2
- package/esm/models/operations/listpresetversions.d.ts +2 -2
- package/esm/models/operations/listpresetversions.js +2 -2
- package/esm/models/operations/listworkspacemembers.d.ts +2 -2
- package/esm/models/operations/listworkspacemembers.js +2 -2
- package/esm/models/operations/listworkspaces.d.ts +2 -2
- package/esm/models/operations/listworkspaces.js +2 -2
- package/esm/models/providerpreferences.d.ts +16 -16
- package/esm/models/providerpreferences.js +12 -19
- package/esm/models/responsesrequest.d.ts +5 -5
- package/esm/models/responsesrequest.js +3 -3
- package/esm/models/searchmodelsservertoolopenrouter.d.ts +28 -0
- package/esm/models/searchmodelsservertoolopenrouter.js +20 -0
- package/esm/models/updateobservabilitydestinationrequest.d.ts +3 -3
- package/esm/models/updateobservabilitydestinationrequest.js +2 -2
- package/esm/sdk/embeddings.d.ts +4 -2
- package/esm/sdk/embeddings.js +2 -1
- package/esm/sdk/models.d.ts +7 -2
- package/esm/sdk/models.js +3 -2
- package/jsr.json +1 -1
- package/package.json +5 -5
- package/esm/models/anthropiccitationsearchresultlocation.d.ts +0 -24
- package/esm/models/anthropiccitationwebsearchresultlocation.d.ts +0 -20
|
@@ -1,41 +1,10 @@
|
|
|
1
1
|
import * as z from "zod/v4";
|
|
2
|
-
import { OpenEnum } from "../types/enums.js";
|
|
3
2
|
import { Result as SafeParseResult } from "../types/fp.js";
|
|
4
3
|
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
5
4
|
import { InputModality } from "./inputmodality.js";
|
|
5
|
+
import { InstructType } from "./instructtype.js";
|
|
6
6
|
import { ModelGroup } from "./modelgroup.js";
|
|
7
7
|
import { OutputModality } from "./outputmodality.js";
|
|
8
|
-
/**
|
|
9
|
-
* Instruction format type
|
|
10
|
-
*/
|
|
11
|
-
export declare const ModelArchitectureInstructType: {
|
|
12
|
-
readonly None: "none";
|
|
13
|
-
readonly Airoboros: "airoboros";
|
|
14
|
-
readonly Alpaca: "alpaca";
|
|
15
|
-
readonly AlpacaModif: "alpaca-modif";
|
|
16
|
-
readonly Chatml: "chatml";
|
|
17
|
-
readonly Claude: "claude";
|
|
18
|
-
readonly CodeLlama: "code-llama";
|
|
19
|
-
readonly Gemma: "gemma";
|
|
20
|
-
readonly Llama2: "llama2";
|
|
21
|
-
readonly Llama3: "llama3";
|
|
22
|
-
readonly Mistral: "mistral";
|
|
23
|
-
readonly Nemotron: "nemotron";
|
|
24
|
-
readonly Neural: "neural";
|
|
25
|
-
readonly Openchat: "openchat";
|
|
26
|
-
readonly Phi3: "phi3";
|
|
27
|
-
readonly Rwkv: "rwkv";
|
|
28
|
-
readonly Vicuna: "vicuna";
|
|
29
|
-
readonly Zephyr: "zephyr";
|
|
30
|
-
readonly DeepseekR1: "deepseek-r1";
|
|
31
|
-
readonly DeepseekV31: "deepseek-v3.1";
|
|
32
|
-
readonly Qwq: "qwq";
|
|
33
|
-
readonly Qwen3: "qwen3";
|
|
34
|
-
};
|
|
35
|
-
/**
|
|
36
|
-
* Instruction format type
|
|
37
|
-
*/
|
|
38
|
-
export type ModelArchitectureInstructType = OpenEnum<typeof ModelArchitectureInstructType>;
|
|
39
8
|
/**
|
|
40
9
|
* Model architecture information
|
|
41
10
|
*/
|
|
@@ -47,7 +16,7 @@ export type ModelArchitecture = {
|
|
|
47
16
|
/**
|
|
48
17
|
* Instruction format type
|
|
49
18
|
*/
|
|
50
|
-
instructType?:
|
|
19
|
+
instructType?: InstructType | null | undefined;
|
|
51
20
|
/**
|
|
52
21
|
* Primary modality of the model
|
|
53
22
|
*/
|
|
@@ -62,8 +31,6 @@ export type ModelArchitecture = {
|
|
|
62
31
|
tokenizer?: ModelGroup | undefined;
|
|
63
32
|
};
|
|
64
33
|
/** @internal */
|
|
65
|
-
export declare const ModelArchitectureInstructType$inboundSchema: z.ZodType<ModelArchitectureInstructType, unknown>;
|
|
66
|
-
/** @internal */
|
|
67
34
|
export declare const ModelArchitecture$inboundSchema: z.ZodType<ModelArchitecture, unknown>;
|
|
68
35
|
export declare function modelArchitectureFromJSON(jsonString: string): SafeParseResult<ModelArchitecture, SDKValidationError>;
|
|
69
36
|
//# sourceMappingURL=modelarchitecture.d.ts.map
|
|
@@ -5,44 +5,14 @@
|
|
|
5
5
|
import * as z from "zod/v4";
|
|
6
6
|
import { remap as remap$ } from "../lib/primitives.js";
|
|
7
7
|
import { safeParse } from "../lib/schemas.js";
|
|
8
|
-
import * as openEnums from "../types/enums.js";
|
|
9
8
|
import { InputModality$inboundSchema } from "./inputmodality.js";
|
|
9
|
+
import { InstructType$inboundSchema } from "./instructtype.js";
|
|
10
10
|
import { ModelGroup$inboundSchema } from "./modelgroup.js";
|
|
11
11
|
import { OutputModality$inboundSchema, } from "./outputmodality.js";
|
|
12
|
-
/**
|
|
13
|
-
* Instruction format type
|
|
14
|
-
*/
|
|
15
|
-
export const ModelArchitectureInstructType = {
|
|
16
|
-
None: "none",
|
|
17
|
-
Airoboros: "airoboros",
|
|
18
|
-
Alpaca: "alpaca",
|
|
19
|
-
AlpacaModif: "alpaca-modif",
|
|
20
|
-
Chatml: "chatml",
|
|
21
|
-
Claude: "claude",
|
|
22
|
-
CodeLlama: "code-llama",
|
|
23
|
-
Gemma: "gemma",
|
|
24
|
-
Llama2: "llama2",
|
|
25
|
-
Llama3: "llama3",
|
|
26
|
-
Mistral: "mistral",
|
|
27
|
-
Nemotron: "nemotron",
|
|
28
|
-
Neural: "neural",
|
|
29
|
-
Openchat: "openchat",
|
|
30
|
-
Phi3: "phi3",
|
|
31
|
-
Rwkv: "rwkv",
|
|
32
|
-
Vicuna: "vicuna",
|
|
33
|
-
Zephyr: "zephyr",
|
|
34
|
-
DeepseekR1: "deepseek-r1",
|
|
35
|
-
DeepseekV31: "deepseek-v3.1",
|
|
36
|
-
Qwq: "qwq",
|
|
37
|
-
Qwen3: "qwen3",
|
|
38
|
-
};
|
|
39
|
-
/** @internal */
|
|
40
|
-
export const ModelArchitectureInstructType$inboundSchema = openEnums.inboundSchema(ModelArchitectureInstructType);
|
|
41
12
|
/** @internal */
|
|
42
13
|
export const ModelArchitecture$inboundSchema = z.object({
|
|
43
14
|
input_modalities: z.array(InputModality$inboundSchema),
|
|
44
|
-
instruct_type: z.nullable(
|
|
45
|
-
.optional(),
|
|
15
|
+
instruct_type: z.nullable(InstructType$inboundSchema).optional(),
|
|
46
16
|
modality: z.nullable(z.string()),
|
|
47
17
|
output_modalities: z.array(OutputModality$inboundSchema),
|
|
48
18
|
tokenizer: ModelGroup$inboundSchema.optional(),
|
|
@@ -2,6 +2,15 @@ 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 { Model } from "./model.js";
|
|
5
|
+
/**
|
|
6
|
+
* Pagination links
|
|
7
|
+
*/
|
|
8
|
+
export type Links = {
|
|
9
|
+
/**
|
|
10
|
+
* URL for the next page of results, or null if this is the last page
|
|
11
|
+
*/
|
|
12
|
+
next: string | null;
|
|
13
|
+
};
|
|
5
14
|
/**
|
|
6
15
|
* List of available models
|
|
7
16
|
*/
|
|
@@ -10,8 +19,19 @@ export type ModelsListResponse = {
|
|
|
10
19
|
* List of available models
|
|
11
20
|
*/
|
|
12
21
|
data: Array<Model>;
|
|
22
|
+
/**
|
|
23
|
+
* Pagination links
|
|
24
|
+
*/
|
|
25
|
+
links: Links;
|
|
26
|
+
/**
|
|
27
|
+
* Total number of models matching the query
|
|
28
|
+
*/
|
|
29
|
+
totalCount: number;
|
|
13
30
|
};
|
|
14
31
|
/** @internal */
|
|
32
|
+
export declare const Links$inboundSchema: z.ZodType<Links, unknown>;
|
|
33
|
+
export declare function linksFromJSON(jsonString: string): SafeParseResult<Links, SDKValidationError>;
|
|
34
|
+
/** @internal */
|
|
15
35
|
export declare const ModelsListResponse$inboundSchema: z.ZodType<ModelsListResponse, unknown>;
|
|
16
36
|
export declare function modelsListResponseFromJSON(jsonString: string): SafeParseResult<ModelsListResponse, SDKValidationError>;
|
|
17
37
|
//# sourceMappingURL=modelslistresponse.d.ts.map
|
|
@@ -3,11 +3,25 @@
|
|
|
3
3
|
* @generated-id: ea0e62a13d8d
|
|
4
4
|
*/
|
|
5
5
|
import * as z from "zod/v4";
|
|
6
|
+
import { remap as remap$ } from "../lib/primitives.js";
|
|
6
7
|
import { safeParse } from "../lib/schemas.js";
|
|
7
8
|
import { Model$inboundSchema } from "./model.js";
|
|
8
9
|
/** @internal */
|
|
10
|
+
export const Links$inboundSchema = z.object({
|
|
11
|
+
next: z.nullable(z.string()),
|
|
12
|
+
});
|
|
13
|
+
export function linksFromJSON(jsonString) {
|
|
14
|
+
return safeParse(jsonString, (x) => Links$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Links' from JSON`);
|
|
15
|
+
}
|
|
16
|
+
/** @internal */
|
|
9
17
|
export const ModelsListResponse$inboundSchema = z.object({
|
|
10
18
|
data: z.array(Model$inboundSchema),
|
|
19
|
+
links: z.lazy(() => Links$inboundSchema),
|
|
20
|
+
total_count: z.int(),
|
|
21
|
+
}).transform((v) => {
|
|
22
|
+
return remap$(v, {
|
|
23
|
+
"total_count": "totalCount",
|
|
24
|
+
});
|
|
11
25
|
});
|
|
12
26
|
export function modelsListResponseFromJSON(jsonString) {
|
|
13
27
|
return safeParse(jsonString, (x) => ModelsListResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ModelsListResponse' from JSON`);
|
|
@@ -0,0 +1,94 @@
|
|
|
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 Logic: {
|
|
6
|
+
readonly And: "and";
|
|
7
|
+
readonly Or: "or";
|
|
8
|
+
};
|
|
9
|
+
export type Logic = OpenEnum<typeof Logic>;
|
|
10
|
+
export declare const Field: {
|
|
11
|
+
readonly Model: "model";
|
|
12
|
+
readonly Provider: "provider";
|
|
13
|
+
readonly SessionId: "session_id";
|
|
14
|
+
readonly UserId: "user_id";
|
|
15
|
+
readonly ApiKeyName: "api_key_name";
|
|
16
|
+
readonly FinishReason: "finish_reason";
|
|
17
|
+
readonly Input: "input";
|
|
18
|
+
readonly Output: "output";
|
|
19
|
+
readonly TotalCost: "total_cost";
|
|
20
|
+
readonly TotalTokens: "total_tokens";
|
|
21
|
+
readonly PromptTokens: "prompt_tokens";
|
|
22
|
+
readonly CompletionTokens: "completion_tokens";
|
|
23
|
+
};
|
|
24
|
+
export type Field = OpenEnum<typeof Field>;
|
|
25
|
+
export declare const Operator: {
|
|
26
|
+
readonly Equals: "equals";
|
|
27
|
+
readonly NotEquals: "not_equals";
|
|
28
|
+
readonly Contains: "contains";
|
|
29
|
+
readonly NotContains: "not_contains";
|
|
30
|
+
readonly Regex: "regex";
|
|
31
|
+
readonly StartsWith: "starts_with";
|
|
32
|
+
readonly EndsWith: "ends_with";
|
|
33
|
+
readonly Gt: "gt";
|
|
34
|
+
readonly Lt: "lt";
|
|
35
|
+
readonly Gte: "gte";
|
|
36
|
+
readonly Lte: "lte";
|
|
37
|
+
readonly Exists: "exists";
|
|
38
|
+
readonly NotExists: "not_exists";
|
|
39
|
+
};
|
|
40
|
+
export type Operator = OpenEnum<typeof Operator>;
|
|
41
|
+
export type ObservabilityFilterRuleGroupValue = string | number;
|
|
42
|
+
export type Rule = {
|
|
43
|
+
field: Field;
|
|
44
|
+
operator: Operator;
|
|
45
|
+
value?: string | number | undefined;
|
|
46
|
+
};
|
|
47
|
+
export type ObservabilityFilterRuleGroup = {
|
|
48
|
+
logic?: Logic | undefined;
|
|
49
|
+
rules: Array<Rule>;
|
|
50
|
+
};
|
|
51
|
+
/** @internal */
|
|
52
|
+
export declare const Logic$inboundSchema: z.ZodType<Logic, unknown>;
|
|
53
|
+
/** @internal */
|
|
54
|
+
export declare const Logic$outboundSchema: z.ZodType<string, Logic>;
|
|
55
|
+
/** @internal */
|
|
56
|
+
export declare const Field$inboundSchema: z.ZodType<Field, unknown>;
|
|
57
|
+
/** @internal */
|
|
58
|
+
export declare const Field$outboundSchema: z.ZodType<string, Field>;
|
|
59
|
+
/** @internal */
|
|
60
|
+
export declare const Operator$inboundSchema: z.ZodType<Operator, unknown>;
|
|
61
|
+
/** @internal */
|
|
62
|
+
export declare const Operator$outboundSchema: z.ZodType<string, Operator>;
|
|
63
|
+
/** @internal */
|
|
64
|
+
export declare const ObservabilityFilterRuleGroupValue$inboundSchema: z.ZodType<ObservabilityFilterRuleGroupValue, unknown>;
|
|
65
|
+
/** @internal */
|
|
66
|
+
export type ObservabilityFilterRuleGroupValue$Outbound = string | number;
|
|
67
|
+
/** @internal */
|
|
68
|
+
export declare const ObservabilityFilterRuleGroupValue$outboundSchema: z.ZodType<ObservabilityFilterRuleGroupValue$Outbound, ObservabilityFilterRuleGroupValue>;
|
|
69
|
+
export declare function observabilityFilterRuleGroupValueToJSON(observabilityFilterRuleGroupValue: ObservabilityFilterRuleGroupValue): string;
|
|
70
|
+
export declare function observabilityFilterRuleGroupValueFromJSON(jsonString: string): SafeParseResult<ObservabilityFilterRuleGroupValue, SDKValidationError>;
|
|
71
|
+
/** @internal */
|
|
72
|
+
export declare const Rule$inboundSchema: z.ZodType<Rule, unknown>;
|
|
73
|
+
/** @internal */
|
|
74
|
+
export type Rule$Outbound = {
|
|
75
|
+
field: string;
|
|
76
|
+
operator: string;
|
|
77
|
+
value?: string | number | undefined;
|
|
78
|
+
};
|
|
79
|
+
/** @internal */
|
|
80
|
+
export declare const Rule$outboundSchema: z.ZodType<Rule$Outbound, Rule>;
|
|
81
|
+
export declare function ruleToJSON(rule: Rule): string;
|
|
82
|
+
export declare function ruleFromJSON(jsonString: string): SafeParseResult<Rule, SDKValidationError>;
|
|
83
|
+
/** @internal */
|
|
84
|
+
export declare const ObservabilityFilterRuleGroup$inboundSchema: z.ZodType<ObservabilityFilterRuleGroup, unknown>;
|
|
85
|
+
/** @internal */
|
|
86
|
+
export type ObservabilityFilterRuleGroup$Outbound = {
|
|
87
|
+
logic: string;
|
|
88
|
+
rules: Array<Rule$Outbound>;
|
|
89
|
+
};
|
|
90
|
+
/** @internal */
|
|
91
|
+
export declare const ObservabilityFilterRuleGroup$outboundSchema: z.ZodType<ObservabilityFilterRuleGroup$Outbound, ObservabilityFilterRuleGroup>;
|
|
92
|
+
export declare function observabilityFilterRuleGroupToJSON(observabilityFilterRuleGroup: ObservabilityFilterRuleGroup): string;
|
|
93
|
+
export declare function observabilityFilterRuleGroupFromJSON(jsonString: string): SafeParseResult<ObservabilityFilterRuleGroup, SDKValidationError>;
|
|
94
|
+
//# sourceMappingURL=observabilityfilterrulegroup.d.ts.map
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: 8d44f7499b39
|
|
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 Logic = {
|
|
9
|
+
And: "and",
|
|
10
|
+
Or: "or",
|
|
11
|
+
};
|
|
12
|
+
export const Field = {
|
|
13
|
+
Model: "model",
|
|
14
|
+
Provider: "provider",
|
|
15
|
+
SessionId: "session_id",
|
|
16
|
+
UserId: "user_id",
|
|
17
|
+
ApiKeyName: "api_key_name",
|
|
18
|
+
FinishReason: "finish_reason",
|
|
19
|
+
Input: "input",
|
|
20
|
+
Output: "output",
|
|
21
|
+
TotalCost: "total_cost",
|
|
22
|
+
TotalTokens: "total_tokens",
|
|
23
|
+
PromptTokens: "prompt_tokens",
|
|
24
|
+
CompletionTokens: "completion_tokens",
|
|
25
|
+
};
|
|
26
|
+
export const Operator = {
|
|
27
|
+
Equals: "equals",
|
|
28
|
+
NotEquals: "not_equals",
|
|
29
|
+
Contains: "contains",
|
|
30
|
+
NotContains: "not_contains",
|
|
31
|
+
Regex: "regex",
|
|
32
|
+
StartsWith: "starts_with",
|
|
33
|
+
EndsWith: "ends_with",
|
|
34
|
+
Gt: "gt",
|
|
35
|
+
Lt: "lt",
|
|
36
|
+
Gte: "gte",
|
|
37
|
+
Lte: "lte",
|
|
38
|
+
Exists: "exists",
|
|
39
|
+
NotExists: "not_exists",
|
|
40
|
+
};
|
|
41
|
+
/** @internal */
|
|
42
|
+
export const Logic$inboundSchema = openEnums
|
|
43
|
+
.inboundSchema(Logic);
|
|
44
|
+
/** @internal */
|
|
45
|
+
export const Logic$outboundSchema = openEnums
|
|
46
|
+
.outboundSchema(Logic);
|
|
47
|
+
/** @internal */
|
|
48
|
+
export const Field$inboundSchema = openEnums
|
|
49
|
+
.inboundSchema(Field);
|
|
50
|
+
/** @internal */
|
|
51
|
+
export const Field$outboundSchema = openEnums
|
|
52
|
+
.outboundSchema(Field);
|
|
53
|
+
/** @internal */
|
|
54
|
+
export const Operator$inboundSchema = openEnums
|
|
55
|
+
.inboundSchema(Operator);
|
|
56
|
+
/** @internal */
|
|
57
|
+
export const Operator$outboundSchema = openEnums
|
|
58
|
+
.outboundSchema(Operator);
|
|
59
|
+
/** @internal */
|
|
60
|
+
export const ObservabilityFilterRuleGroupValue$inboundSchema = z.union([z.string(), z.number()]);
|
|
61
|
+
/** @internal */
|
|
62
|
+
export const ObservabilityFilterRuleGroupValue$outboundSchema = z.union([z.string(), z.number()]);
|
|
63
|
+
export function observabilityFilterRuleGroupValueToJSON(observabilityFilterRuleGroupValue) {
|
|
64
|
+
return JSON.stringify(ObservabilityFilterRuleGroupValue$outboundSchema.parse(observabilityFilterRuleGroupValue));
|
|
65
|
+
}
|
|
66
|
+
export function observabilityFilterRuleGroupValueFromJSON(jsonString) {
|
|
67
|
+
return safeParse(jsonString, (x) => ObservabilityFilterRuleGroupValue$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ObservabilityFilterRuleGroupValue' from JSON`);
|
|
68
|
+
}
|
|
69
|
+
/** @internal */
|
|
70
|
+
export const Rule$inboundSchema = z.object({
|
|
71
|
+
field: Field$inboundSchema,
|
|
72
|
+
operator: Operator$inboundSchema,
|
|
73
|
+
value: z.union([z.string(), z.number()]).optional(),
|
|
74
|
+
});
|
|
75
|
+
/** @internal */
|
|
76
|
+
export const Rule$outboundSchema = z.object({
|
|
77
|
+
field: Field$outboundSchema,
|
|
78
|
+
operator: Operator$outboundSchema,
|
|
79
|
+
value: z.union([z.string(), z.number()]).optional(),
|
|
80
|
+
});
|
|
81
|
+
export function ruleToJSON(rule) {
|
|
82
|
+
return JSON.stringify(Rule$outboundSchema.parse(rule));
|
|
83
|
+
}
|
|
84
|
+
export function ruleFromJSON(jsonString) {
|
|
85
|
+
return safeParse(jsonString, (x) => Rule$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Rule' from JSON`);
|
|
86
|
+
}
|
|
87
|
+
/** @internal */
|
|
88
|
+
export const ObservabilityFilterRuleGroup$inboundSchema = z.object({
|
|
89
|
+
logic: Logic$inboundSchema.default("and"),
|
|
90
|
+
rules: z.array(z.lazy(() => Rule$inboundSchema)),
|
|
91
|
+
});
|
|
92
|
+
/** @internal */
|
|
93
|
+
export const ObservabilityFilterRuleGroup$outboundSchema = z.object({
|
|
94
|
+
logic: Logic$outboundSchema.default("and"),
|
|
95
|
+
rules: z.array(z.lazy(() => Rule$outboundSchema)),
|
|
96
|
+
});
|
|
97
|
+
export function observabilityFilterRuleGroupToJSON(observabilityFilterRuleGroup) {
|
|
98
|
+
return JSON.stringify(ObservabilityFilterRuleGroup$outboundSchema.parse(observabilityFilterRuleGroup));
|
|
99
|
+
}
|
|
100
|
+
export function observabilityFilterRuleGroupFromJSON(jsonString) {
|
|
101
|
+
return safeParse(jsonString, (x) => ObservabilityFilterRuleGroup$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ObservabilityFilterRuleGroup' from JSON`);
|
|
102
|
+
}
|
|
103
|
+
//# sourceMappingURL=observabilityfilterrulegroup.js.map
|
|
@@ -1,112 +1,15 @@
|
|
|
1
1
|
import * as z from "zod/v4";
|
|
2
|
-
import { OpenEnum } from "../types/enums.js";
|
|
3
2
|
import { Result as SafeParseResult } from "../types/fp.js";
|
|
4
3
|
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
5
|
-
|
|
6
|
-
readonly And: "and";
|
|
7
|
-
readonly Or: "or";
|
|
8
|
-
};
|
|
9
|
-
export type Logic = OpenEnum<typeof Logic>;
|
|
10
|
-
export declare const Field: {
|
|
11
|
-
readonly Model: "model";
|
|
12
|
-
readonly Provider: "provider";
|
|
13
|
-
readonly SessionId: "session_id";
|
|
14
|
-
readonly UserId: "user_id";
|
|
15
|
-
readonly ApiKeyName: "api_key_name";
|
|
16
|
-
readonly FinishReason: "finish_reason";
|
|
17
|
-
readonly Input: "input";
|
|
18
|
-
readonly Output: "output";
|
|
19
|
-
readonly TotalCost: "total_cost";
|
|
20
|
-
readonly TotalTokens: "total_tokens";
|
|
21
|
-
readonly PromptTokens: "prompt_tokens";
|
|
22
|
-
readonly CompletionTokens: "completion_tokens";
|
|
23
|
-
};
|
|
24
|
-
export type Field = OpenEnum<typeof Field>;
|
|
25
|
-
export declare const Operator: {
|
|
26
|
-
readonly Equals: "equals";
|
|
27
|
-
readonly NotEquals: "not_equals";
|
|
28
|
-
readonly Contains: "contains";
|
|
29
|
-
readonly NotContains: "not_contains";
|
|
30
|
-
readonly Regex: "regex";
|
|
31
|
-
readonly StartsWith: "starts_with";
|
|
32
|
-
readonly EndsWith: "ends_with";
|
|
33
|
-
readonly Gt: "gt";
|
|
34
|
-
readonly Lt: "lt";
|
|
35
|
-
readonly Gte: "gte";
|
|
36
|
-
readonly Lte: "lte";
|
|
37
|
-
readonly Exists: "exists";
|
|
38
|
-
readonly NotExists: "not_exists";
|
|
39
|
-
};
|
|
40
|
-
export type Operator = OpenEnum<typeof Operator>;
|
|
41
|
-
export type ObservabilityFilterRulesConfigValue = string | number;
|
|
42
|
-
export type Rule = {
|
|
43
|
-
field: Field;
|
|
44
|
-
operator: Operator;
|
|
45
|
-
value?: string | number | undefined;
|
|
46
|
-
};
|
|
47
|
-
export type Group = {
|
|
48
|
-
logic?: Logic | undefined;
|
|
49
|
-
rules: Array<Rule>;
|
|
50
|
-
};
|
|
4
|
+
import { ObservabilityFilterRuleGroup } from "./observabilityfilterrulegroup.js";
|
|
51
5
|
/**
|
|
52
6
|
* Optional structured filter rules controlling which events are forwarded.
|
|
53
7
|
*/
|
|
54
8
|
export type ObservabilityFilterRulesConfig = {
|
|
55
|
-
enabled?: boolean | undefined;
|
|
56
|
-
groups: Array<Group>;
|
|
57
|
-
};
|
|
58
|
-
/** @internal */
|
|
59
|
-
export declare const Logic$inboundSchema: z.ZodType<Logic, unknown>;
|
|
60
|
-
/** @internal */
|
|
61
|
-
export declare const Logic$outboundSchema: z.ZodType<string, Logic>;
|
|
62
|
-
/** @internal */
|
|
63
|
-
export declare const Field$inboundSchema: z.ZodType<Field, unknown>;
|
|
64
|
-
/** @internal */
|
|
65
|
-
export declare const Field$outboundSchema: z.ZodType<string, Field>;
|
|
66
|
-
/** @internal */
|
|
67
|
-
export declare const Operator$inboundSchema: z.ZodType<Operator, unknown>;
|
|
68
|
-
/** @internal */
|
|
69
|
-
export declare const Operator$outboundSchema: z.ZodType<string, Operator>;
|
|
70
|
-
/** @internal */
|
|
71
|
-
export declare const ObservabilityFilterRulesConfigValue$inboundSchema: z.ZodType<ObservabilityFilterRulesConfigValue, unknown>;
|
|
72
|
-
/** @internal */
|
|
73
|
-
export type ObservabilityFilterRulesConfigValue$Outbound = string | number;
|
|
74
|
-
/** @internal */
|
|
75
|
-
export declare const ObservabilityFilterRulesConfigValue$outboundSchema: z.ZodType<ObservabilityFilterRulesConfigValue$Outbound, ObservabilityFilterRulesConfigValue>;
|
|
76
|
-
export declare function observabilityFilterRulesConfigValueToJSON(observabilityFilterRulesConfigValue: ObservabilityFilterRulesConfigValue): string;
|
|
77
|
-
export declare function observabilityFilterRulesConfigValueFromJSON(jsonString: string): SafeParseResult<ObservabilityFilterRulesConfigValue, SDKValidationError>;
|
|
78
|
-
/** @internal */
|
|
79
|
-
export declare const Rule$inboundSchema: z.ZodType<Rule, unknown>;
|
|
80
|
-
/** @internal */
|
|
81
|
-
export type Rule$Outbound = {
|
|
82
|
-
field: string;
|
|
83
|
-
operator: string;
|
|
84
|
-
value?: string | number | undefined;
|
|
85
|
-
};
|
|
86
|
-
/** @internal */
|
|
87
|
-
export declare const Rule$outboundSchema: z.ZodType<Rule$Outbound, Rule>;
|
|
88
|
-
export declare function ruleToJSON(rule: Rule): string;
|
|
89
|
-
export declare function ruleFromJSON(jsonString: string): SafeParseResult<Rule, SDKValidationError>;
|
|
90
|
-
/** @internal */
|
|
91
|
-
export declare const Group$inboundSchema: z.ZodType<Group, unknown>;
|
|
92
|
-
/** @internal */
|
|
93
|
-
export type Group$Outbound = {
|
|
94
|
-
logic: string;
|
|
95
|
-
rules: Array<Rule$Outbound>;
|
|
96
|
-
};
|
|
97
|
-
/** @internal */
|
|
98
|
-
export declare const Group$outboundSchema: z.ZodType<Group$Outbound, Group>;
|
|
99
|
-
export declare function groupToJSON(group: Group): string;
|
|
100
|
-
export declare function groupFromJSON(jsonString: string): SafeParseResult<Group, SDKValidationError>;
|
|
101
|
-
/** @internal */
|
|
102
|
-
export declare const ObservabilityFilterRulesConfig$inboundSchema: z.ZodType<ObservabilityFilterRulesConfig, unknown>;
|
|
103
|
-
/** @internal */
|
|
104
|
-
export type ObservabilityFilterRulesConfig$Outbound = {
|
|
105
9
|
enabled: boolean;
|
|
106
|
-
groups: Array<
|
|
10
|
+
groups: Array<ObservabilityFilterRuleGroup>;
|
|
107
11
|
};
|
|
108
12
|
/** @internal */
|
|
109
|
-
export declare const ObservabilityFilterRulesConfig$
|
|
110
|
-
export declare function observabilityFilterRulesConfigToJSON(observabilityFilterRulesConfig: ObservabilityFilterRulesConfig): string;
|
|
13
|
+
export declare const ObservabilityFilterRulesConfig$inboundSchema: z.ZodType<ObservabilityFilterRulesConfig, unknown>;
|
|
111
14
|
export declare function observabilityFilterRulesConfigFromJSON(jsonString: string): SafeParseResult<ObservabilityFilterRulesConfig, SDKValidationError>;
|
|
112
15
|
//# sourceMappingURL=observabilityfilterrulesconfig.d.ts.map
|
|
@@ -4,115 +4,12 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import * as z from "zod/v4";
|
|
6
6
|
import { safeParse } from "../lib/schemas.js";
|
|
7
|
-
import
|
|
8
|
-
export const Logic = {
|
|
9
|
-
And: "and",
|
|
10
|
-
Or: "or",
|
|
11
|
-
};
|
|
12
|
-
export const Field = {
|
|
13
|
-
Model: "model",
|
|
14
|
-
Provider: "provider",
|
|
15
|
-
SessionId: "session_id",
|
|
16
|
-
UserId: "user_id",
|
|
17
|
-
ApiKeyName: "api_key_name",
|
|
18
|
-
FinishReason: "finish_reason",
|
|
19
|
-
Input: "input",
|
|
20
|
-
Output: "output",
|
|
21
|
-
TotalCost: "total_cost",
|
|
22
|
-
TotalTokens: "total_tokens",
|
|
23
|
-
PromptTokens: "prompt_tokens",
|
|
24
|
-
CompletionTokens: "completion_tokens",
|
|
25
|
-
};
|
|
26
|
-
export const Operator = {
|
|
27
|
-
Equals: "equals",
|
|
28
|
-
NotEquals: "not_equals",
|
|
29
|
-
Contains: "contains",
|
|
30
|
-
NotContains: "not_contains",
|
|
31
|
-
Regex: "regex",
|
|
32
|
-
StartsWith: "starts_with",
|
|
33
|
-
EndsWith: "ends_with",
|
|
34
|
-
Gt: "gt",
|
|
35
|
-
Lt: "lt",
|
|
36
|
-
Gte: "gte",
|
|
37
|
-
Lte: "lte",
|
|
38
|
-
Exists: "exists",
|
|
39
|
-
NotExists: "not_exists",
|
|
40
|
-
};
|
|
41
|
-
/** @internal */
|
|
42
|
-
export const Logic$inboundSchema = openEnums
|
|
43
|
-
.inboundSchema(Logic);
|
|
44
|
-
/** @internal */
|
|
45
|
-
export const Logic$outboundSchema = openEnums
|
|
46
|
-
.outboundSchema(Logic);
|
|
47
|
-
/** @internal */
|
|
48
|
-
export const Field$inboundSchema = openEnums
|
|
49
|
-
.inboundSchema(Field);
|
|
50
|
-
/** @internal */
|
|
51
|
-
export const Field$outboundSchema = openEnums
|
|
52
|
-
.outboundSchema(Field);
|
|
53
|
-
/** @internal */
|
|
54
|
-
export const Operator$inboundSchema = openEnums
|
|
55
|
-
.inboundSchema(Operator);
|
|
56
|
-
/** @internal */
|
|
57
|
-
export const Operator$outboundSchema = openEnums
|
|
58
|
-
.outboundSchema(Operator);
|
|
59
|
-
/** @internal */
|
|
60
|
-
export const ObservabilityFilterRulesConfigValue$inboundSchema = z.union([z.string(), z.number()]);
|
|
61
|
-
/** @internal */
|
|
62
|
-
export const ObservabilityFilterRulesConfigValue$outboundSchema = z.union([z.string(), z.number()]);
|
|
63
|
-
export function observabilityFilterRulesConfigValueToJSON(observabilityFilterRulesConfigValue) {
|
|
64
|
-
return JSON.stringify(ObservabilityFilterRulesConfigValue$outboundSchema.parse(observabilityFilterRulesConfigValue));
|
|
65
|
-
}
|
|
66
|
-
export function observabilityFilterRulesConfigValueFromJSON(jsonString) {
|
|
67
|
-
return safeParse(jsonString, (x) => ObservabilityFilterRulesConfigValue$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ObservabilityFilterRulesConfigValue' from JSON`);
|
|
68
|
-
}
|
|
69
|
-
/** @internal */
|
|
70
|
-
export const Rule$inboundSchema = z.object({
|
|
71
|
-
field: Field$inboundSchema,
|
|
72
|
-
operator: Operator$inboundSchema,
|
|
73
|
-
value: z.union([z.string(), z.number()]).optional(),
|
|
74
|
-
});
|
|
75
|
-
/** @internal */
|
|
76
|
-
export const Rule$outboundSchema = z.object({
|
|
77
|
-
field: Field$outboundSchema,
|
|
78
|
-
operator: Operator$outboundSchema,
|
|
79
|
-
value: z.union([z.string(), z.number()]).optional(),
|
|
80
|
-
});
|
|
81
|
-
export function ruleToJSON(rule) {
|
|
82
|
-
return JSON.stringify(Rule$outboundSchema.parse(rule));
|
|
83
|
-
}
|
|
84
|
-
export function ruleFromJSON(jsonString) {
|
|
85
|
-
return safeParse(jsonString, (x) => Rule$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Rule' from JSON`);
|
|
86
|
-
}
|
|
87
|
-
/** @internal */
|
|
88
|
-
export const Group$inboundSchema = z.object({
|
|
89
|
-
logic: Logic$inboundSchema.default("and"),
|
|
90
|
-
rules: z.array(z.lazy(() => Rule$inboundSchema)),
|
|
91
|
-
});
|
|
92
|
-
/** @internal */
|
|
93
|
-
export const Group$outboundSchema = z.object({
|
|
94
|
-
logic: Logic$outboundSchema.default("and"),
|
|
95
|
-
rules: z.array(z.lazy(() => Rule$outboundSchema)),
|
|
96
|
-
});
|
|
97
|
-
export function groupToJSON(group) {
|
|
98
|
-
return JSON.stringify(Group$outboundSchema.parse(group));
|
|
99
|
-
}
|
|
100
|
-
export function groupFromJSON(jsonString) {
|
|
101
|
-
return safeParse(jsonString, (x) => Group$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Group' from JSON`);
|
|
102
|
-
}
|
|
7
|
+
import { ObservabilityFilterRuleGroup$inboundSchema, } from "./observabilityfilterrulegroup.js";
|
|
103
8
|
/** @internal */
|
|
104
9
|
export const ObservabilityFilterRulesConfig$inboundSchema = z.object({
|
|
105
10
|
enabled: z.boolean().default(true),
|
|
106
|
-
groups: z.array(
|
|
107
|
-
});
|
|
108
|
-
/** @internal */
|
|
109
|
-
export const ObservabilityFilterRulesConfig$outboundSchema = z.object({
|
|
110
|
-
enabled: z.boolean().default(true),
|
|
111
|
-
groups: z.array(z.lazy(() => Group$outboundSchema)),
|
|
11
|
+
groups: z.array(ObservabilityFilterRuleGroup$inboundSchema),
|
|
112
12
|
});
|
|
113
|
-
export function observabilityFilterRulesConfigToJSON(observabilityFilterRulesConfig) {
|
|
114
|
-
return JSON.stringify(ObservabilityFilterRulesConfig$outboundSchema.parse(observabilityFilterRulesConfig));
|
|
115
|
-
}
|
|
116
13
|
export function observabilityFilterRulesConfigFromJSON(jsonString) {
|
|
117
14
|
return safeParse(jsonString, (x) => ObservabilityFilterRulesConfig$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ObservabilityFilterRulesConfig' from JSON`);
|
|
118
15
|
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import * as z from "zod/v4";
|
|
2
|
+
import { ObservabilityFilterRuleGroup, ObservabilityFilterRuleGroup$Outbound } from "./observabilityfilterrulegroup.js";
|
|
3
|
+
/**
|
|
4
|
+
* Optional structured filter rules controlling which events are forwarded.
|
|
5
|
+
*/
|
|
6
|
+
export type ObservabilityFilterRulesConfigNullable = {
|
|
7
|
+
enabled?: boolean | undefined;
|
|
8
|
+
groups: Array<ObservabilityFilterRuleGroup>;
|
|
9
|
+
};
|
|
10
|
+
/** @internal */
|
|
11
|
+
export type ObservabilityFilterRulesConfigNullable$Outbound = {
|
|
12
|
+
enabled: boolean;
|
|
13
|
+
groups: Array<ObservabilityFilterRuleGroup$Outbound>;
|
|
14
|
+
};
|
|
15
|
+
/** @internal */
|
|
16
|
+
export declare const ObservabilityFilterRulesConfigNullable$outboundSchema: z.ZodType<ObservabilityFilterRulesConfigNullable$Outbound, ObservabilityFilterRulesConfigNullable>;
|
|
17
|
+
export declare function observabilityFilterRulesConfigNullableToJSON(observabilityFilterRulesConfigNullable: ObservabilityFilterRulesConfigNullable): string;
|
|
18
|
+
//# sourceMappingURL=observabilityfilterrulesconfignullable.d.ts.map
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
* @generated-id: e9a4ec0d425c
|
|
4
|
+
*/
|
|
5
|
+
import * as z from "zod/v4";
|
|
6
|
+
import { ObservabilityFilterRuleGroup$outboundSchema, } from "./observabilityfilterrulegroup.js";
|
|
7
|
+
/** @internal */
|
|
8
|
+
export const ObservabilityFilterRulesConfigNullable$outboundSchema = z.object({
|
|
9
|
+
enabled: z.boolean().default(true),
|
|
10
|
+
groups: z.array(ObservabilityFilterRuleGroup$outboundSchema),
|
|
11
|
+
});
|
|
12
|
+
export function observabilityFilterRulesConfigNullableToJSON(observabilityFilterRulesConfigNullable) {
|
|
13
|
+
return JSON.stringify(ObservabilityFilterRulesConfigNullable$outboundSchema.parse(observabilityFilterRulesConfigNullable));
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=observabilityfilterrulesconfignullable.js.map
|
|
@@ -132,14 +132,6 @@ export declare const ObjectT: {
|
|
|
132
132
|
readonly List: "list";
|
|
133
133
|
};
|
|
134
134
|
export type ObjectT = ClosedEnum<typeof ObjectT>;
|
|
135
|
-
/**
|
|
136
|
-
* Breakdown of upstream inference costs
|
|
137
|
-
*/
|
|
138
|
-
export type CostDetails = {
|
|
139
|
-
upstreamInferenceCompletionsCost: number;
|
|
140
|
-
upstreamInferenceCost?: number | null | undefined;
|
|
141
|
-
upstreamInferencePromptCost: number;
|
|
142
|
-
};
|
|
143
135
|
/**
|
|
144
136
|
* Per-modality token breakdown. Only present when the input contains 2+ modalities (e.g. text + image) and the upstream provider returns modality-level usage data. Only non-zero modality counts are included.
|
|
145
137
|
*/
|
|
@@ -176,7 +168,7 @@ export type CreateEmbeddingsUsage = {
|
|
|
176
168
|
/**
|
|
177
169
|
* Breakdown of upstream inference costs
|
|
178
170
|
*/
|
|
179
|
-
costDetails?: CostDetails | null | undefined;
|
|
171
|
+
costDetails?: models.CostDetails | null | undefined;
|
|
180
172
|
/**
|
|
181
173
|
* Whether a request was made using a Bring Your Own Key configuration
|
|
182
174
|
*/
|
|
@@ -293,9 +285,6 @@ export declare function createEmbeddingsDataFromJSON(jsonString: string): SafePa
|
|
|
293
285
|
/** @internal */
|
|
294
286
|
export declare const ObjectT$inboundSchema: z.ZodEnum<typeof ObjectT>;
|
|
295
287
|
/** @internal */
|
|
296
|
-
export declare const CostDetails$inboundSchema: z.ZodType<CostDetails, unknown>;
|
|
297
|
-
export declare function costDetailsFromJSON(jsonString: string): SafeParseResult<CostDetails, SDKValidationError>;
|
|
298
|
-
/** @internal */
|
|
299
288
|
export declare const PromptTokensDetails$inboundSchema: z.ZodType<PromptTokensDetails, unknown>;
|
|
300
289
|
export declare function promptTokensDetailsFromJSON(jsonString: string): SafeParseResult<PromptTokensDetails, SDKValidationError>;
|
|
301
290
|
/** @internal */
|