@meetkai/mka1 0.51.12 → 0.51.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (245) hide show
  1. package/README.md +239 -227
  2. package/bin/mcp-server.js +936 -433
  3. package/bin/mcp-server.js.map +24 -9
  4. package/dist/commonjs/funcs/servingEligibilityPreview.d.ts +19 -0
  5. package/dist/commonjs/funcs/servingEligibilityPreview.d.ts.map +1 -0
  6. package/dist/commonjs/funcs/servingEligibilityPreview.js +133 -0
  7. package/dist/commonjs/funcs/servingEligibilityPreview.js.map +1 -0
  8. package/dist/commonjs/funcs/servingSpendGet.d.ts +19 -0
  9. package/dist/commonjs/funcs/servingSpendGet.d.ts.map +1 -0
  10. package/dist/commonjs/funcs/servingSpendGet.js +135 -0
  11. package/dist/commonjs/funcs/servingSpendGet.js.map +1 -0
  12. package/dist/commonjs/lib/config.d.ts +2 -2
  13. package/dist/commonjs/lib/config.js +2 -2
  14. package/dist/commonjs/mcp-server/mcp-server.js +1 -1
  15. package/dist/commonjs/mcp-server/server.d.ts.map +1 -1
  16. package/dist/commonjs/mcp-server/server.js +5 -1
  17. package/dist/commonjs/mcp-server/server.js.map +1 -1
  18. package/dist/commonjs/mcp-server/tools/servingEligibilityPreview.d.ts +8 -0
  19. package/dist/commonjs/mcp-server/tools/servingEligibilityPreview.d.ts.map +1 -0
  20. package/dist/commonjs/mcp-server/tools/servingEligibilityPreview.js +64 -0
  21. package/dist/commonjs/mcp-server/tools/servingEligibilityPreview.js.map +1 -0
  22. package/dist/commonjs/mcp-server/tools/servingSpendGet.d.ts +8 -0
  23. package/dist/commonjs/mcp-server/tools/servingSpendGet.d.ts.map +1 -0
  24. package/dist/commonjs/mcp-server/tools/servingSpendGet.js +64 -0
  25. package/dist/commonjs/mcp-server/tools/servingSpendGet.js.map +1 -0
  26. package/dist/commonjs/models/components/acceleratorpriceband.d.ts +22 -0
  27. package/dist/commonjs/models/components/acceleratorpriceband.d.ts.map +1 -0
  28. package/dist/commonjs/models/components/acceleratorpriceband.js +60 -0
  29. package/dist/commonjs/models/components/acceleratorpriceband.js.map +1 -0
  30. package/dist/commonjs/models/components/acceleratortype.d.ts +22 -0
  31. package/dist/commonjs/models/components/acceleratortype.d.ts.map +1 -1
  32. package/dist/commonjs/models/components/acceleratortype.js +14 -0
  33. package/dist/commonjs/models/components/acceleratortype.js.map +1 -1
  34. package/dist/commonjs/models/components/acquirability.d.ts +20 -0
  35. package/dist/commonjs/models/components/acquirability.d.ts.map +1 -0
  36. package/dist/commonjs/models/components/acquirability.js +54 -0
  37. package/dist/commonjs/models/components/acquirability.js.map +1 -0
  38. package/dist/commonjs/models/components/eligibilitypreview.d.ts +73 -0
  39. package/dist/commonjs/models/components/eligibilitypreview.d.ts.map +1 -0
  40. package/dist/commonjs/models/components/eligibilitypreview.js +99 -0
  41. package/dist/commonjs/models/components/eligibilitypreview.js.map +1 -0
  42. package/dist/commonjs/models/components/eligibilitypriceband.d.ts +24 -0
  43. package/dist/commonjs/models/components/eligibilitypriceband.d.ts.map +1 -0
  44. package/dist/commonjs/models/components/eligibilitypriceband.js +62 -0
  45. package/dist/commonjs/models/components/eligibilitypriceband.js.map +1 -0
  46. package/dist/commonjs/models/components/eligibilityrequest.d.ts +28 -0
  47. package/dist/commonjs/models/components/eligibilityrequest.d.ts.map +1 -0
  48. package/dist/commonjs/models/components/eligibilityrequest.js +59 -0
  49. package/dist/commonjs/models/components/eligibilityrequest.js.map +1 -0
  50. package/dist/commonjs/models/components/index.d.ts +9 -0
  51. package/dist/commonjs/models/components/index.d.ts.map +1 -1
  52. package/dist/commonjs/models/components/index.js +9 -0
  53. package/dist/commonjs/models/components/index.js.map +1 -1
  54. package/dist/commonjs/models/components/spendgroup.d.ts +29 -0
  55. package/dist/commonjs/models/components/spendgroup.d.ts.map +1 -0
  56. package/dist/commonjs/models/components/spendgroup.js +70 -0
  57. package/dist/commonjs/models/components/spendgroup.js.map +1 -0
  58. package/dist/commonjs/models/components/spenditem.d.ts +27 -0
  59. package/dist/commonjs/models/components/spenditem.d.ts.map +1 -0
  60. package/dist/commonjs/models/components/spenditem.js +62 -0
  61. package/dist/commonjs/models/components/spenditem.js.map +1 -0
  62. package/dist/commonjs/models/components/spendsummary.d.ts +40 -0
  63. package/dist/commonjs/models/components/spendsummary.d.ts.map +1 -0
  64. package/dist/commonjs/models/components/spendsummary.js +75 -0
  65. package/dist/commonjs/models/components/spendsummary.js.map +1 -0
  66. package/dist/commonjs/models/components/spendwindow.d.ts +25 -0
  67. package/dist/commonjs/models/components/spendwindow.d.ts.map +1 -0
  68. package/dist/commonjs/models/components/spendwindow.js +60 -0
  69. package/dist/commonjs/models/components/spendwindow.js.map +1 -0
  70. package/dist/commonjs/models/operations/getspend.d.ts +24 -0
  71. package/dist/commonjs/models/operations/getspend.d.ts.map +1 -0
  72. package/dist/commonjs/models/operations/getspend.js +71 -0
  73. package/dist/commonjs/models/operations/getspend.js.map +1 -0
  74. package/dist/commonjs/models/operations/index.d.ts +2 -0
  75. package/dist/commonjs/models/operations/index.d.ts.map +1 -1
  76. package/dist/commonjs/models/operations/index.js +2 -0
  77. package/dist/commonjs/models/operations/index.js.map +1 -1
  78. package/dist/commonjs/models/operations/previeweligibility.d.ts +23 -0
  79. package/dist/commonjs/models/operations/previeweligibility.d.ts.map +1 -0
  80. package/dist/commonjs/models/operations/previeweligibility.js +72 -0
  81. package/dist/commonjs/models/operations/previeweligibility.js.map +1 -0
  82. package/dist/commonjs/react-query/index.d.ts +2 -0
  83. package/dist/commonjs/react-query/index.d.ts.map +1 -1
  84. package/dist/commonjs/react-query/index.js +2 -0
  85. package/dist/commonjs/react-query/index.js.map +1 -1
  86. package/dist/commonjs/react-query/servingEligibilityPreview.d.ts +30 -0
  87. package/dist/commonjs/react-query/servingEligibilityPreview.d.ts.map +1 -0
  88. package/dist/commonjs/react-query/servingEligibilityPreview.js +47 -0
  89. package/dist/commonjs/react-query/servingEligibilityPreview.js.map +1 -0
  90. package/dist/commonjs/react-query/servingSpendGet.core.d.ts +17 -0
  91. package/dist/commonjs/react-query/servingSpendGet.core.d.ts.map +1 -0
  92. package/dist/commonjs/react-query/servingSpendGet.core.js +38 -0
  93. package/dist/commonjs/react-query/servingSpendGet.core.js.map +1 -0
  94. package/dist/commonjs/react-query/servingSpendGet.d.ts +41 -0
  95. package/dist/commonjs/react-query/servingSpendGet.d.ts.map +1 -0
  96. package/dist/commonjs/react-query/servingSpendGet.js +60 -0
  97. package/dist/commonjs/react-query/servingSpendGet.js.map +1 -0
  98. package/dist/commonjs/sdk/eligibility.d.ts +13 -0
  99. package/dist/commonjs/sdk/eligibility.d.ts.map +1 -0
  100. package/dist/commonjs/sdk/eligibility.js +22 -0
  101. package/dist/commonjs/sdk/eligibility.js.map +1 -0
  102. package/dist/commonjs/sdk/serving.d.ts +6 -0
  103. package/dist/commonjs/sdk/serving.d.ts.map +1 -1
  104. package/dist/commonjs/sdk/serving.js +8 -0
  105. package/dist/commonjs/sdk/serving.js.map +1 -1
  106. package/dist/commonjs/sdk/spend.d.ts +13 -0
  107. package/dist/commonjs/sdk/spend.d.ts.map +1 -0
  108. package/dist/commonjs/sdk/spend.js +22 -0
  109. package/dist/commonjs/sdk/spend.js.map +1 -0
  110. package/dist/esm/funcs/servingEligibilityPreview.d.ts +19 -0
  111. package/dist/esm/funcs/servingEligibilityPreview.d.ts.map +1 -0
  112. package/dist/esm/funcs/servingEligibilityPreview.js +97 -0
  113. package/dist/esm/funcs/servingEligibilityPreview.js.map +1 -0
  114. package/dist/esm/funcs/servingSpendGet.d.ts +19 -0
  115. package/dist/esm/funcs/servingSpendGet.d.ts.map +1 -0
  116. package/dist/esm/funcs/servingSpendGet.js +99 -0
  117. package/dist/esm/funcs/servingSpendGet.js.map +1 -0
  118. package/dist/esm/lib/config.d.ts +2 -2
  119. package/dist/esm/lib/config.js +2 -2
  120. package/dist/esm/mcp-server/mcp-server.js +1 -1
  121. package/dist/esm/mcp-server/server.d.ts.map +1 -1
  122. package/dist/esm/mcp-server/server.js +5 -1
  123. package/dist/esm/mcp-server/server.js.map +1 -1
  124. package/dist/esm/mcp-server/tools/servingEligibilityPreview.d.ts +8 -0
  125. package/dist/esm/mcp-server/tools/servingEligibilityPreview.d.ts.map +1 -0
  126. package/dist/esm/mcp-server/tools/servingEligibilityPreview.js +28 -0
  127. package/dist/esm/mcp-server/tools/servingEligibilityPreview.js.map +1 -0
  128. package/dist/esm/mcp-server/tools/servingSpendGet.d.ts +8 -0
  129. package/dist/esm/mcp-server/tools/servingSpendGet.d.ts.map +1 -0
  130. package/dist/esm/mcp-server/tools/servingSpendGet.js +28 -0
  131. package/dist/esm/mcp-server/tools/servingSpendGet.js.map +1 -0
  132. package/dist/esm/models/components/acceleratorpriceband.d.ts +22 -0
  133. package/dist/esm/models/components/acceleratorpriceband.d.ts.map +1 -0
  134. package/dist/esm/models/components/acceleratorpriceband.js +22 -0
  135. package/dist/esm/models/components/acceleratorpriceband.js.map +1 -0
  136. package/dist/esm/models/components/acceleratortype.d.ts +22 -0
  137. package/dist/esm/models/components/acceleratortype.d.ts.map +1 -1
  138. package/dist/esm/models/components/acceleratortype.js +14 -0
  139. package/dist/esm/models/components/acceleratortype.js.map +1 -1
  140. package/dist/esm/models/components/acquirability.d.ts +20 -0
  141. package/dist/esm/models/components/acquirability.d.ts.map +1 -0
  142. package/dist/esm/models/components/acquirability.js +18 -0
  143. package/dist/esm/models/components/acquirability.js.map +1 -0
  144. package/dist/esm/models/components/eligibilitypreview.d.ts +73 -0
  145. package/dist/esm/models/components/eligibilitypreview.d.ts.map +1 -0
  146. package/dist/esm/models/components/eligibilitypreview.js +61 -0
  147. package/dist/esm/models/components/eligibilitypreview.js.map +1 -0
  148. package/dist/esm/models/components/eligibilitypriceband.d.ts +24 -0
  149. package/dist/esm/models/components/eligibilitypriceband.d.ts.map +1 -0
  150. package/dist/esm/models/components/eligibilitypriceband.js +24 -0
  151. package/dist/esm/models/components/eligibilitypriceband.js.map +1 -0
  152. package/dist/esm/models/components/eligibilityrequest.d.ts +28 -0
  153. package/dist/esm/models/components/eligibilityrequest.d.ts.map +1 -0
  154. package/dist/esm/models/components/eligibilityrequest.js +21 -0
  155. package/dist/esm/models/components/eligibilityrequest.js.map +1 -0
  156. package/dist/esm/models/components/index.d.ts +9 -0
  157. package/dist/esm/models/components/index.d.ts.map +1 -1
  158. package/dist/esm/models/components/index.js +9 -0
  159. package/dist/esm/models/components/index.js.map +1 -1
  160. package/dist/esm/models/components/spendgroup.d.ts +29 -0
  161. package/dist/esm/models/components/spendgroup.d.ts.map +1 -0
  162. package/dist/esm/models/components/spendgroup.js +32 -0
  163. package/dist/esm/models/components/spendgroup.js.map +1 -0
  164. package/dist/esm/models/components/spenditem.d.ts +27 -0
  165. package/dist/esm/models/components/spenditem.d.ts.map +1 -0
  166. package/dist/esm/models/components/spenditem.js +24 -0
  167. package/dist/esm/models/components/spenditem.js.map +1 -0
  168. package/dist/esm/models/components/spendsummary.d.ts +40 -0
  169. package/dist/esm/models/components/spendsummary.d.ts.map +1 -0
  170. package/dist/esm/models/components/spendsummary.js +37 -0
  171. package/dist/esm/models/components/spendsummary.js.map +1 -0
  172. package/dist/esm/models/components/spendwindow.d.ts +25 -0
  173. package/dist/esm/models/components/spendwindow.d.ts.map +1 -0
  174. package/dist/esm/models/components/spendwindow.js +22 -0
  175. package/dist/esm/models/components/spendwindow.js.map +1 -0
  176. package/dist/esm/models/operations/getspend.d.ts +24 -0
  177. package/dist/esm/models/operations/getspend.d.ts.map +1 -0
  178. package/dist/esm/models/operations/getspend.js +33 -0
  179. package/dist/esm/models/operations/getspend.js.map +1 -0
  180. package/dist/esm/models/operations/index.d.ts +2 -0
  181. package/dist/esm/models/operations/index.d.ts.map +1 -1
  182. package/dist/esm/models/operations/index.js +2 -0
  183. package/dist/esm/models/operations/index.js.map +1 -1
  184. package/dist/esm/models/operations/previeweligibility.d.ts +23 -0
  185. package/dist/esm/models/operations/previeweligibility.d.ts.map +1 -0
  186. package/dist/esm/models/operations/previeweligibility.js +34 -0
  187. package/dist/esm/models/operations/previeweligibility.js.map +1 -0
  188. package/dist/esm/react-query/index.d.ts +2 -0
  189. package/dist/esm/react-query/index.d.ts.map +1 -1
  190. package/dist/esm/react-query/index.js +2 -0
  191. package/dist/esm/react-query/index.js.map +1 -1
  192. package/dist/esm/react-query/servingEligibilityPreview.d.ts +30 -0
  193. package/dist/esm/react-query/servingEligibilityPreview.d.ts.map +1 -0
  194. package/dist/esm/react-query/servingEligibilityPreview.js +42 -0
  195. package/dist/esm/react-query/servingEligibilityPreview.js.map +1 -0
  196. package/dist/esm/react-query/servingSpendGet.core.d.ts +17 -0
  197. package/dist/esm/react-query/servingSpendGet.core.d.ts.map +1 -0
  198. package/dist/esm/react-query/servingSpendGet.core.js +33 -0
  199. package/dist/esm/react-query/servingSpendGet.core.js.map +1 -0
  200. package/dist/esm/react-query/servingSpendGet.d.ts +41 -0
  201. package/dist/esm/react-query/servingSpendGet.d.ts.map +1 -0
  202. package/dist/esm/react-query/servingSpendGet.js +50 -0
  203. package/dist/esm/react-query/servingSpendGet.js.map +1 -0
  204. package/dist/esm/sdk/eligibility.d.ts +13 -0
  205. package/dist/esm/sdk/eligibility.d.ts.map +1 -0
  206. package/dist/esm/sdk/eligibility.js +18 -0
  207. package/dist/esm/sdk/eligibility.js.map +1 -0
  208. package/dist/esm/sdk/serving.d.ts +6 -0
  209. package/dist/esm/sdk/serving.d.ts.map +1 -1
  210. package/dist/esm/sdk/serving.js +8 -0
  211. package/dist/esm/sdk/serving.js.map +1 -1
  212. package/dist/esm/sdk/spend.d.ts +13 -0
  213. package/dist/esm/sdk/spend.d.ts.map +1 -0
  214. package/dist/esm/sdk/spend.js +18 -0
  215. package/dist/esm/sdk/spend.js.map +1 -0
  216. package/jsr.json +1 -1
  217. package/package.json +1 -1
  218. package/src/funcs/servingEligibilityPreview.ts +193 -0
  219. package/src/funcs/servingSpendGet.ts +197 -0
  220. package/src/lib/config.ts +2 -2
  221. package/src/mcp-server/mcp-server.ts +1 -1
  222. package/src/mcp-server/server.ts +5 -1
  223. package/src/mcp-server/tools/servingEligibilityPreview.ts +37 -0
  224. package/src/mcp-server/tools/servingSpendGet.ts +37 -0
  225. package/src/models/components/acceleratorpriceband.ts +58 -0
  226. package/src/models/components/acceleratortype.ts +43 -0
  227. package/src/models/components/acquirability.ts +29 -0
  228. package/src/models/components/eligibilitypreview.ts +145 -0
  229. package/src/models/components/eligibilitypriceband.ts +62 -0
  230. package/src/models/components/eligibilityrequest.ts +67 -0
  231. package/src/models/components/index.ts +9 -0
  232. package/src/models/components/spendgroup.ts +75 -0
  233. package/src/models/components/spenditem.ts +61 -0
  234. package/src/models/components/spendsummary.ts +95 -0
  235. package/src/models/components/spendwindow.ts +59 -0
  236. package/src/models/operations/getspend.ts +73 -0
  237. package/src/models/operations/index.ts +2 -0
  238. package/src/models/operations/previeweligibility.ts +70 -0
  239. package/src/react-query/index.ts +2 -0
  240. package/src/react-query/servingEligibilityPreview.ts +113 -0
  241. package/src/react-query/servingSpendGet.core.ts +79 -0
  242. package/src/react-query/servingSpendGet.ts +145 -0
  243. package/src/sdk/eligibility.ts +28 -0
  244. package/src/sdk/serving.ts +12 -0
  245. package/src/sdk/spend.ts +28 -0
@@ -0,0 +1,62 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { Result as SafeParseResult } from "../../types/fp.js";
8
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
9
+
10
+ /**
11
+ * USD-per-hour price band across the configurations matching an eligibility request.
12
+ */
13
+ export type EligibilityPriceBand = {
14
+ max: number;
15
+ min: number;
16
+ p50: number;
17
+ };
18
+
19
+ /** @internal */
20
+ export const EligibilityPriceBand$inboundSchema: z.ZodType<
21
+ EligibilityPriceBand,
22
+ z.ZodTypeDef,
23
+ unknown
24
+ > = z.object({
25
+ max: z.number(),
26
+ min: z.number(),
27
+ p50: z.number(),
28
+ });
29
+ /** @internal */
30
+ export type EligibilityPriceBand$Outbound = {
31
+ max: number;
32
+ min: number;
33
+ p50: number;
34
+ };
35
+
36
+ /** @internal */
37
+ export const EligibilityPriceBand$outboundSchema: z.ZodType<
38
+ EligibilityPriceBand$Outbound,
39
+ z.ZodTypeDef,
40
+ EligibilityPriceBand
41
+ > = z.object({
42
+ max: z.number(),
43
+ min: z.number(),
44
+ p50: z.number(),
45
+ });
46
+
47
+ export function eligibilityPriceBandToJSON(
48
+ eligibilityPriceBand: EligibilityPriceBand,
49
+ ): string {
50
+ return JSON.stringify(
51
+ EligibilityPriceBand$outboundSchema.parse(eligibilityPriceBand),
52
+ );
53
+ }
54
+ export function eligibilityPriceBandFromJSON(
55
+ jsonString: string,
56
+ ): SafeParseResult<EligibilityPriceBand, SDKValidationError> {
57
+ return safeParse(
58
+ jsonString,
59
+ (x) => EligibilityPriceBand$inboundSchema.parse(JSON.parse(x)),
60
+ `Failed to parse 'EligibilityPriceBand' from JSON`,
61
+ );
62
+ }
@@ -0,0 +1,67 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { Result as SafeParseResult } from "../../types/fp.js";
8
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
9
+ import {
10
+ AcceleratorSpec,
11
+ AcceleratorSpec$inboundSchema,
12
+ AcceleratorSpec$Outbound,
13
+ AcceleratorSpec$outboundSchema,
14
+ } from "./acceleratorspec.js";
15
+
16
+ /**
17
+ * Pre-submission eligibility preview request. Mirrors the job form's accelerator block: type, count, and optional ordered fallback types.
18
+ */
19
+ export type EligibilityRequest = {
20
+ /**
21
+ * A hardware accelerator request — GPU, NPU, TPU, or similar.
22
+ *
23
+ * @remarks
24
+ *
25
+ * Request an accelerator by type and count, with optional fallback types.
26
+ */
27
+ accelerator: AcceleratorSpec;
28
+ };
29
+
30
+ /** @internal */
31
+ export const EligibilityRequest$inboundSchema: z.ZodType<
32
+ EligibilityRequest,
33
+ z.ZodTypeDef,
34
+ unknown
35
+ > = z.object({
36
+ accelerator: AcceleratorSpec$inboundSchema,
37
+ });
38
+ /** @internal */
39
+ export type EligibilityRequest$Outbound = {
40
+ accelerator: AcceleratorSpec$Outbound;
41
+ };
42
+
43
+ /** @internal */
44
+ export const EligibilityRequest$outboundSchema: z.ZodType<
45
+ EligibilityRequest$Outbound,
46
+ z.ZodTypeDef,
47
+ EligibilityRequest
48
+ > = z.object({
49
+ accelerator: AcceleratorSpec$outboundSchema,
50
+ });
51
+
52
+ export function eligibilityRequestToJSON(
53
+ eligibilityRequest: EligibilityRequest,
54
+ ): string {
55
+ return JSON.stringify(
56
+ EligibilityRequest$outboundSchema.parse(eligibilityRequest),
57
+ );
58
+ }
59
+ export function eligibilityRequestFromJSON(
60
+ jsonString: string,
61
+ ): SafeParseResult<EligibilityRequest, SDKValidationError> {
62
+ return safeParse(
63
+ jsonString,
64
+ (x) => EligibilityRequest$inboundSchema.parse(JSON.parse(x)),
65
+ `Failed to parse 'EligibilityRequest' from JSON`,
66
+ );
67
+ }
@@ -2,6 +2,7 @@
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
4
 
5
+ export * from "./acceleratorpriceband.js";
5
6
  export * from "./acceleratorspec.js";
6
7
  export * from "./acceleratortype.js";
7
8
  export * from "./accessentry.js";
@@ -9,6 +10,7 @@ export * from "./accesslistresponse.js";
9
10
  export * from "./accessmutationrequest.js";
10
11
  export * from "./accessmutationresponse.js";
11
12
  export * from "./acknowledgedsafetycheck.js";
13
+ export * from "./acquirability.js";
12
14
  export * from "./activateregistryentryrequest.js";
13
15
  export * from "./addcatalogmodelrequest.js";
14
16
  export * from "./agent.js";
@@ -149,6 +151,9 @@ export * from "./dpohyperparameters.js";
149
151
  export * from "./dragaction.js";
150
152
  export * from "./effectivepricerow.js";
151
153
  export * from "./effectivepricesresponse.js";
154
+ export * from "./eligibilitypreview.js";
155
+ export * from "./eligibilitypriceband.js";
156
+ export * from "./eligibilityrequest.js";
152
157
  export * from "./embeddingmodel.js";
153
158
  export * from "./embeddingmodellimits.js";
154
159
  export * from "./embeddingmodellistresponse.js";
@@ -512,6 +517,10 @@ export * from "./speakersegment.js";
512
517
  export * from "./speechhistorydeletionstatus.js";
513
518
  export * from "./speechtotexthistorylist.js";
514
519
  export * from "./speechtotexthistoryobject.js";
520
+ export * from "./spendgroup.js";
521
+ export * from "./spenditem.js";
522
+ export * from "./spendsummary.js";
523
+ export * from "./spendwindow.js";
515
524
  export * from "./startexportfeedbackresponse.js";
516
525
  export * from "./staticchunkingstrategy.js";
517
526
  export * from "./status.js";
@@ -0,0 +1,75 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ SpendItem,
12
+ SpendItem$inboundSchema,
13
+ SpendItem$Outbound,
14
+ SpendItem$outboundSchema,
15
+ } from "./spenditem.js";
16
+
17
+ /**
18
+ * Aggregate spend for one resource class.
19
+ */
20
+ export type SpendGroup = {
21
+ /**
22
+ * Highest-spend resources first; at most 100 entries.
23
+ */
24
+ items: Array<SpendItem>;
25
+ /**
26
+ * Full spend for this group in the window, including resources beyond the items cap.
27
+ */
28
+ totalUsd: number;
29
+ };
30
+
31
+ /** @internal */
32
+ export const SpendGroup$inboundSchema: z.ZodType<
33
+ SpendGroup,
34
+ z.ZodTypeDef,
35
+ unknown
36
+ > = z.object({
37
+ items: z.array(SpendItem$inboundSchema),
38
+ total_usd: z.number(),
39
+ }).transform((v) => {
40
+ return remap$(v, {
41
+ "total_usd": "totalUsd",
42
+ });
43
+ });
44
+ /** @internal */
45
+ export type SpendGroup$Outbound = {
46
+ items: Array<SpendItem$Outbound>;
47
+ total_usd: number;
48
+ };
49
+
50
+ /** @internal */
51
+ export const SpendGroup$outboundSchema: z.ZodType<
52
+ SpendGroup$Outbound,
53
+ z.ZodTypeDef,
54
+ SpendGroup
55
+ > = z.object({
56
+ items: z.array(SpendItem$outboundSchema),
57
+ totalUsd: z.number(),
58
+ }).transform((v) => {
59
+ return remap$(v, {
60
+ totalUsd: "total_usd",
61
+ });
62
+ });
63
+
64
+ export function spendGroupToJSON(spendGroup: SpendGroup): string {
65
+ return JSON.stringify(SpendGroup$outboundSchema.parse(spendGroup));
66
+ }
67
+ export function spendGroupFromJSON(
68
+ jsonString: string,
69
+ ): SafeParseResult<SpendGroup, SDKValidationError> {
70
+ return safeParse(
71
+ jsonString,
72
+ (x) => SpendGroup$inboundSchema.parse(JSON.parse(x)),
73
+ `Failed to parse 'SpendGroup' from JSON`,
74
+ );
75
+ }
@@ -0,0 +1,61 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { Result as SafeParseResult } from "../../types/fp.js";
8
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
9
+
10
+ /**
11
+ * Computed spend for one resource within the window.
12
+ */
13
+ export type SpendItem = {
14
+ id: string;
15
+ name: string;
16
+ /**
17
+ * Computed spend within the window, in USD.
18
+ */
19
+ usd: number;
20
+ };
21
+
22
+ /** @internal */
23
+ export const SpendItem$inboundSchema: z.ZodType<
24
+ SpendItem,
25
+ z.ZodTypeDef,
26
+ unknown
27
+ > = z.object({
28
+ id: z.string(),
29
+ name: z.string(),
30
+ usd: z.number(),
31
+ });
32
+ /** @internal */
33
+ export type SpendItem$Outbound = {
34
+ id: string;
35
+ name: string;
36
+ usd: number;
37
+ };
38
+
39
+ /** @internal */
40
+ export const SpendItem$outboundSchema: z.ZodType<
41
+ SpendItem$Outbound,
42
+ z.ZodTypeDef,
43
+ SpendItem
44
+ > = z.object({
45
+ id: z.string(),
46
+ name: z.string(),
47
+ usd: z.number(),
48
+ });
49
+
50
+ export function spendItemToJSON(spendItem: SpendItem): string {
51
+ return JSON.stringify(SpendItem$outboundSchema.parse(spendItem));
52
+ }
53
+ export function spendItemFromJSON(
54
+ jsonString: string,
55
+ ): SafeParseResult<SpendItem, SDKValidationError> {
56
+ return safeParse(
57
+ jsonString,
58
+ (x) => SpendItem$inboundSchema.parse(JSON.parse(x)),
59
+ `Failed to parse 'SpendItem' from JSON`,
60
+ );
61
+ }
@@ -0,0 +1,95 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ SpendGroup,
12
+ SpendGroup$inboundSchema,
13
+ SpendGroup$Outbound,
14
+ SpendGroup$outboundSchema,
15
+ } from "./spendgroup.js";
16
+ import {
17
+ SpendWindow,
18
+ SpendWindow$inboundSchema,
19
+ SpendWindow$Outbound,
20
+ SpendWindow$outboundSchema,
21
+ } from "./spendwindow.js";
22
+
23
+ /**
24
+ * Aggregate spend computed as price × runtime overlap with the window; derived on read, never stored.
25
+ */
26
+ export type SpendSummary = {
27
+ /**
28
+ * Aggregate spend for one resource class.
29
+ */
30
+ deployments: SpendGroup;
31
+ /**
32
+ * Aggregate spend for one resource class.
33
+ */
34
+ finetune: SpendGroup;
35
+ /**
36
+ * Total spend across deployments and fine-tune jobs in the window.
37
+ */
38
+ totalUsd: number;
39
+ /**
40
+ * The resolved reporting window.
41
+ */
42
+ window: SpendWindow;
43
+ };
44
+
45
+ /** @internal */
46
+ export const SpendSummary$inboundSchema: z.ZodType<
47
+ SpendSummary,
48
+ z.ZodTypeDef,
49
+ unknown
50
+ > = z.object({
51
+ deployments: SpendGroup$inboundSchema,
52
+ finetune: SpendGroup$inboundSchema,
53
+ total_usd: z.number(),
54
+ window: SpendWindow$inboundSchema,
55
+ }).transform((v) => {
56
+ return remap$(v, {
57
+ "total_usd": "totalUsd",
58
+ });
59
+ });
60
+ /** @internal */
61
+ export type SpendSummary$Outbound = {
62
+ deployments: SpendGroup$Outbound;
63
+ finetune: SpendGroup$Outbound;
64
+ total_usd: number;
65
+ window: SpendWindow$Outbound;
66
+ };
67
+
68
+ /** @internal */
69
+ export const SpendSummary$outboundSchema: z.ZodType<
70
+ SpendSummary$Outbound,
71
+ z.ZodTypeDef,
72
+ SpendSummary
73
+ > = z.object({
74
+ deployments: SpendGroup$outboundSchema,
75
+ finetune: SpendGroup$outboundSchema,
76
+ totalUsd: z.number(),
77
+ window: SpendWindow$outboundSchema,
78
+ }).transform((v) => {
79
+ return remap$(v, {
80
+ totalUsd: "total_usd",
81
+ });
82
+ });
83
+
84
+ export function spendSummaryToJSON(spendSummary: SpendSummary): string {
85
+ return JSON.stringify(SpendSummary$outboundSchema.parse(spendSummary));
86
+ }
87
+ export function spendSummaryFromJSON(
88
+ jsonString: string,
89
+ ): SafeParseResult<SpendSummary, SDKValidationError> {
90
+ return safeParse(
91
+ jsonString,
92
+ (x) => SpendSummary$inboundSchema.parse(JSON.parse(x)),
93
+ `Failed to parse 'SpendSummary' from JSON`,
94
+ );
95
+ }
@@ -0,0 +1,59 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { Result as SafeParseResult } from "../../types/fp.js";
8
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
9
+
10
+ /**
11
+ * The resolved reporting window.
12
+ */
13
+ export type SpendWindow = {
14
+ end: Date;
15
+ /**
16
+ * Lower bound of the window; null when the request set none (total covers all history).
17
+ */
18
+ start?: Date | null | undefined;
19
+ };
20
+
21
+ /** @internal */
22
+ export const SpendWindow$inboundSchema: z.ZodType<
23
+ SpendWindow,
24
+ z.ZodTypeDef,
25
+ unknown
26
+ > = z.object({
27
+ end: z.string().datetime({ offset: true }).transform(v => new Date(v)),
28
+ start: z.nullable(
29
+ z.string().datetime({ offset: true }).transform(v => new Date(v)),
30
+ ).optional(),
31
+ });
32
+ /** @internal */
33
+ export type SpendWindow$Outbound = {
34
+ end: string;
35
+ start?: string | null | undefined;
36
+ };
37
+
38
+ /** @internal */
39
+ export const SpendWindow$outboundSchema: z.ZodType<
40
+ SpendWindow$Outbound,
41
+ z.ZodTypeDef,
42
+ SpendWindow
43
+ > = z.object({
44
+ end: z.date().transform(v => v.toISOString()),
45
+ start: z.nullable(z.date().transform(v => v.toISOString())).optional(),
46
+ });
47
+
48
+ export function spendWindowToJSON(spendWindow: SpendWindow): string {
49
+ return JSON.stringify(SpendWindow$outboundSchema.parse(spendWindow));
50
+ }
51
+ export function spendWindowFromJSON(
52
+ jsonString: string,
53
+ ): SafeParseResult<SpendWindow, SDKValidationError> {
54
+ return safeParse(
55
+ jsonString,
56
+ (x) => SpendWindow$inboundSchema.parse(JSON.parse(x)),
57
+ `Failed to parse 'SpendWindow' from JSON`,
58
+ );
59
+ }
@@ -0,0 +1,73 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+
11
+ export type GetSpendRequest = {
12
+ start?: Date | null | undefined;
13
+ end?: Date | null | undefined;
14
+ /**
15
+ * Optional external end-user identifier forwarded by the API gateway.
16
+ */
17
+ xOnBehalfOf?: string | undefined;
18
+ };
19
+
20
+ /** @internal */
21
+ export const GetSpendRequest$inboundSchema: z.ZodType<
22
+ GetSpendRequest,
23
+ z.ZodTypeDef,
24
+ unknown
25
+ > = z.object({
26
+ start: z.nullable(
27
+ z.string().datetime({ offset: true }).transform(v => new Date(v)),
28
+ ).optional(),
29
+ end: z.nullable(
30
+ z.string().datetime({ offset: true }).transform(v => new Date(v)),
31
+ ).optional(),
32
+ "X-On-Behalf-Of": z.string().optional(),
33
+ }).transform((v) => {
34
+ return remap$(v, {
35
+ "X-On-Behalf-Of": "xOnBehalfOf",
36
+ });
37
+ });
38
+ /** @internal */
39
+ export type GetSpendRequest$Outbound = {
40
+ start?: string | null | undefined;
41
+ end?: string | null | undefined;
42
+ "X-On-Behalf-Of"?: string | undefined;
43
+ };
44
+
45
+ /** @internal */
46
+ export const GetSpendRequest$outboundSchema: z.ZodType<
47
+ GetSpendRequest$Outbound,
48
+ z.ZodTypeDef,
49
+ GetSpendRequest
50
+ > = z.object({
51
+ start: z.nullable(z.date().transform(v => v.toISOString())).optional(),
52
+ end: z.nullable(z.date().transform(v => v.toISOString())).optional(),
53
+ xOnBehalfOf: z.string().optional(),
54
+ }).transform((v) => {
55
+ return remap$(v, {
56
+ xOnBehalfOf: "X-On-Behalf-Of",
57
+ });
58
+ });
59
+
60
+ export function getSpendRequestToJSON(
61
+ getSpendRequest: GetSpendRequest,
62
+ ): string {
63
+ return JSON.stringify(GetSpendRequest$outboundSchema.parse(getSpendRequest));
64
+ }
65
+ export function getSpendRequestFromJSON(
66
+ jsonString: string,
67
+ ): SafeParseResult<GetSpendRequest, SDKValidationError> {
68
+ return safeParse(
69
+ jsonString,
70
+ (x) => GetSpendRequest$inboundSchema.parse(JSON.parse(x)),
71
+ `Failed to parse 'GetSpendRequest' from JSON`,
72
+ );
73
+ }
@@ -176,6 +176,7 @@ export * from "./getskillversion.js";
176
176
  export * from "./getskillversioncontent.js";
177
177
  export * from "./getspeechtotexthistory.js";
178
178
  export * from "./getspeechtotexthistorycontent.js";
179
+ export * from "./getspend.js";
179
180
  export * from "./getteam.js";
180
181
  export * from "./gettexttospeechhistory.js";
181
182
  export * from "./gettexttospeechhistorycontent.js";
@@ -259,6 +260,7 @@ export * from "./llmrevoke.js";
259
260
  export * from "./modifyvectorstore.js";
260
261
  export * from "./pauseagentschedule.js";
261
262
  export * from "./pausefinetuningjob.js";
263
+ export * from "./previeweligibility.js";
262
264
  export * from "./proxybrowserportrequest.js";
263
265
  export * from "./putorgautomodel.js";
264
266
  export * from "./regeneratescopedapikey.js";
@@ -0,0 +1,70 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import * as components from "../components/index.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type PreviewEligibilityRequest = {
13
+ /**
14
+ * Optional external end-user identifier forwarded by the API gateway.
15
+ */
16
+ xOnBehalfOf?: string | undefined;
17
+ eligibilityRequest: components.EligibilityRequest;
18
+ };
19
+
20
+ /** @internal */
21
+ export const PreviewEligibilityRequest$inboundSchema: z.ZodType<
22
+ PreviewEligibilityRequest,
23
+ z.ZodTypeDef,
24
+ unknown
25
+ > = z.object({
26
+ "X-On-Behalf-Of": z.string().optional(),
27
+ EligibilityRequest: components.EligibilityRequest$inboundSchema,
28
+ }).transform((v) => {
29
+ return remap$(v, {
30
+ "X-On-Behalf-Of": "xOnBehalfOf",
31
+ "EligibilityRequest": "eligibilityRequest",
32
+ });
33
+ });
34
+ /** @internal */
35
+ export type PreviewEligibilityRequest$Outbound = {
36
+ "X-On-Behalf-Of"?: string | undefined;
37
+ EligibilityRequest: components.EligibilityRequest$Outbound;
38
+ };
39
+
40
+ /** @internal */
41
+ export const PreviewEligibilityRequest$outboundSchema: z.ZodType<
42
+ PreviewEligibilityRequest$Outbound,
43
+ z.ZodTypeDef,
44
+ PreviewEligibilityRequest
45
+ > = z.object({
46
+ xOnBehalfOf: z.string().optional(),
47
+ eligibilityRequest: components.EligibilityRequest$outboundSchema,
48
+ }).transform((v) => {
49
+ return remap$(v, {
50
+ xOnBehalfOf: "X-On-Behalf-Of",
51
+ eligibilityRequest: "EligibilityRequest",
52
+ });
53
+ });
54
+
55
+ export function previewEligibilityRequestToJSON(
56
+ previewEligibilityRequest: PreviewEligibilityRequest,
57
+ ): string {
58
+ return JSON.stringify(
59
+ PreviewEligibilityRequest$outboundSchema.parse(previewEligibilityRequest),
60
+ );
61
+ }
62
+ export function previewEligibilityRequestFromJSON(
63
+ jsonString: string,
64
+ ): SafeParseResult<PreviewEligibilityRequest, SDKValidationError> {
65
+ return safeParse(
66
+ jsonString,
67
+ (x) => PreviewEligibilityRequest$inboundSchema.parse(JSON.parse(x)),
68
+ `Failed to parse 'PreviewEligibilityRequest' from JSON`,
69
+ );
70
+ }
@@ -307,6 +307,7 @@ export * from "./servingDeploymentsRegister.js";
307
307
  export * from "./servingDeploymentsRollback.js";
308
308
  export * from "./servingDeploymentsUpdate.js";
309
309
  export * from "./servingDeploymentsUpdateScaling.js";
310
+ export * from "./servingEligibilityPreview.js";
310
311
  export * from "./servingFinetuneJobsCancel.js";
311
312
  export * from "./servingFinetuneJobsCreate.js";
312
313
  export * from "./servingFinetuneJobsGet.js";
@@ -331,6 +332,7 @@ export * from "./servingRecipesSetEnabled.js";
331
332
  export * from "./servingSecretsCreate.js";
332
333
  export * from "./servingSecretsDelete.js";
333
334
  export * from "./servingSecretsList.js";
335
+ export * from "./servingSpendGet.js";
334
336
  export * from "./servingTenantsDeleteOrganization.js";
335
337
  export * from "./servingTenantsGet.js";
336
338
  export * from "./servingTenantsGetOrganizationDeletion.js";