@homeflare/distilled-litellm 0.2.0

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 (563) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +77 -0
  3. package/dist/credentials.d.ts +27 -0
  4. package/dist/credentials.d.ts.map +1 -0
  5. package/dist/credentials.js +67 -0
  6. package/dist/credentials.js.map +1 -0
  7. package/dist/errors.d.ts +92 -0
  8. package/dist/errors.d.ts.map +1 -0
  9. package/dist/errors.js +72 -0
  10. package/dist/errors.js.map +1 -0
  11. package/dist/index.d.ts +30 -0
  12. package/dist/index.d.ts.map +1 -0
  13. package/dist/index.js +30 -0
  14. package/dist/index.js.map +1 -0
  15. package/dist/protocol.d.ts +18 -0
  16. package/dist/protocol.d.ts.map +1 -0
  17. package/dist/protocol.js +135 -0
  18. package/dist/protocol.js.map +1 -0
  19. package/dist/retry.d.ts +50 -0
  20. package/dist/retry.d.ts.map +1 -0
  21. package/dist/retry.js +43 -0
  22. package/dist/retry.js.map +1 -0
  23. package/dist/services/a2a.d.ts +70 -0
  24. package/dist/services/a2a.d.ts.map +1 -0
  25. package/dist/services/a2a.js +128 -0
  26. package/dist/services/a2a.js.map +1 -0
  27. package/dist/services/a2a_registration.d.ts +43 -0
  28. package/dist/services/a2a_registration.d.ts.map +1 -0
  29. package/dist/services/a2a_registration.js +40 -0
  30. package/dist/services/a2a_registration.js.map +1 -0
  31. package/dist/services/access_groups.d.ts +192 -0
  32. package/dist/services/access_groups.d.ts.map +1 -0
  33. package/dist/services/access_groups.js +283 -0
  34. package/dist/services/access_groups.js.map +1 -0
  35. package/dist/services/adaptive_router.d.ts +15 -0
  36. package/dist/services/adaptive_router.d.ts.map +1 -0
  37. package/dist/services/adaptive_router.js +25 -0
  38. package/dist/services/adaptive_router.js.map +1 -0
  39. package/dist/services/agents.d.ts +537 -0
  40. package/dist/services/agents.d.ts.map +1 -0
  41. package/dist/services/agents.js +481 -0
  42. package/dist/services/agents.js.map +1 -0
  43. package/dist/services/alerting.d.ts +15 -0
  44. package/dist/services/alerting.d.ts.map +1 -0
  45. package/dist/services/alerting.js +25 -0
  46. package/dist/services/alerting.js.map +1 -0
  47. package/dist/services/anthropic_pass_through.d.ts +70 -0
  48. package/dist/services/anthropic_pass_through.d.ts.map +1 -0
  49. package/dist/services/anthropic_pass_through.js +114 -0
  50. package/dist/services/anthropic_pass_through.js.map +1 -0
  51. package/dist/services/anthropic_passthrough.d.ts +35 -0
  52. package/dist/services/anthropic_passthrough.d.ts.map +1 -0
  53. package/dist/services/anthropic_passthrough.js +59 -0
  54. package/dist/services/anthropic_passthrough.js.map +1 -0
  55. package/dist/services/anthropic_skills.d.ts +74 -0
  56. package/dist/services/anthropic_skills.d.ts.map +1 -0
  57. package/dist/services/anthropic_skills.js +94 -0
  58. package/dist/services/anthropic_skills.js.map +1 -0
  59. package/dist/services/assembly_ai_eu_pass_through.d.ts +70 -0
  60. package/dist/services/assembly_ai_eu_pass_through.d.ts.map +1 -0
  61. package/dist/services/assembly_ai_eu_pass_through.js +114 -0
  62. package/dist/services/assembly_ai_eu_pass_through.js.map +1 -0
  63. package/dist/services/assembly_ai_pass_through.d.ts +70 -0
  64. package/dist/services/assembly_ai_pass_through.d.ts.map +1 -0
  65. package/dist/services/assembly_ai_pass_through.js +114 -0
  66. package/dist/services/assembly_ai_pass_through.js.map +1 -0
  67. package/dist/services/assistants.d.ts +185 -0
  68. package/dist/services/assistants.d.ts.map +1 -0
  69. package/dist/services/assistants.js +331 -0
  70. package/dist/services/assistants.js.map +1 -0
  71. package/dist/services/audio.d.ts +57 -0
  72. package/dist/services/audio.d.ts.map +1 -0
  73. package/dist/services/audio.js +96 -0
  74. package/dist/services/audio.js.map +1 -0
  75. package/dist/services/audit_logging.d.ts +98 -0
  76. package/dist/services/audit_logging.d.ts.map +1 -0
  77. package/dist/services/audit_logging.js +83 -0
  78. package/dist/services/audit_logging.js.map +1 -0
  79. package/dist/services/auto_router.d.ts +286 -0
  80. package/dist/services/auto_router.d.ts.map +1 -0
  81. package/dist/services/auto_router.js +248 -0
  82. package/dist/services/auto_router.js.map +1 -0
  83. package/dist/services/aws_comprehend_medical_pass_through.d.ts +36 -0
  84. package/dist/services/aws_comprehend_medical_pass_through.d.ts.map +1 -0
  85. package/dist/services/aws_comprehend_medical_pass_through.js +56 -0
  86. package/dist/services/aws_comprehend_medical_pass_through.js.map +1 -0
  87. package/dist/services/azure_ai_pass_through.d.ts +70 -0
  88. package/dist/services/azure_ai_pass_through.d.ts.map +1 -0
  89. package/dist/services/azure_ai_pass_through.js +112 -0
  90. package/dist/services/azure_ai_pass_through.js.map +1 -0
  91. package/dist/services/azure_pass_through.d.ts +70 -0
  92. package/dist/services/azure_pass_through.d.ts.map +1 -0
  93. package/dist/services/azure_pass_through.js +107 -0
  94. package/dist/services/azure_pass_through.js.map +1 -0
  95. package/dist/services/batch.d.ts +165 -0
  96. package/dist/services/batch.d.ts.map +1 -0
  97. package/dist/services/batch.js +265 -0
  98. package/dist/services/batch.js.map +1 -0
  99. package/dist/services/bedrock_pass_through.d.ts +70 -0
  100. package/dist/services/bedrock_pass_through.d.ts.map +1 -0
  101. package/dist/services/bedrock_pass_through.js +114 -0
  102. package/dist/services/bedrock_pass_through.js.map +1 -0
  103. package/dist/services/beta_agents.d.ts +199 -0
  104. package/dist/services/beta_agents.d.ts.map +1 -0
  105. package/dist/services/beta_agents.js +151 -0
  106. package/dist/services/beta_agents.js.map +1 -0
  107. package/dist/services/beta_mcp.d.ts +37 -0
  108. package/dist/services/beta_mcp.d.ts.map +1 -0
  109. package/dist/services/beta_mcp.js +40 -0
  110. package/dist/services/beta_mcp.js.map +1 -0
  111. package/dist/services/budget_management.d.ts +185 -0
  112. package/dist/services/budget_management.d.ts.map +1 -0
  113. package/dist/services/budget_management.js +196 -0
  114. package/dist/services/budget_management.js.map +1 -0
  115. package/dist/services/budget_spend_tracking.d.ts +967 -0
  116. package/dist/services/budget_spend_tracking.d.ts.map +1 -0
  117. package/dist/services/budget_spend_tracking.js +1103 -0
  118. package/dist/services/budget_spend_tracking.js.map +1 -0
  119. package/dist/services/cache_settings.d.ts +96 -0
  120. package/dist/services/cache_settings.d.ts.map +1 -0
  121. package/dist/services/cache_settings.js +95 -0
  122. package/dist/services/cache_settings.js.map +1 -0
  123. package/dist/services/caching.d.ts +54 -0
  124. package/dist/services/caching.d.ts.map +1 -0
  125. package/dist/services/caching.js +78 -0
  126. package/dist/services/caching.js.map +1 -0
  127. package/dist/services/chat_completions.d.ts +656 -0
  128. package/dist/services/chat_completions.d.ts.map +1 -0
  129. package/dist/services/chat_completions.js +590 -0
  130. package/dist/services/chat_completions.js.map +1 -0
  131. package/dist/services/claude_code_marketplace.d.ts +212 -0
  132. package/dist/services/claude_code_marketplace.d.ts.map +1 -0
  133. package/dist/services/claude_code_marketplace.js +248 -0
  134. package/dist/services/claude_code_marketplace.js.map +1 -0
  135. package/dist/services/cloudzero.d.ts +117 -0
  136. package/dist/services/cloudzero.d.ts.map +1 -0
  137. package/dist/services/cloudzero.js +130 -0
  138. package/dist/services/cloudzero.js.map +1 -0
  139. package/dist/services/cohere_pass_through.d.ts +70 -0
  140. package/dist/services/cohere_pass_through.d.ts.map +1 -0
  141. package/dist/services/cohere_pass_through.js +112 -0
  142. package/dist/services/cohere_pass_through.js.map +1 -0
  143. package/dist/services/completions.d.ts +59 -0
  144. package/dist/services/completions.d.ts.map +1 -0
  145. package/dist/services/completions.js +98 -0
  146. package/dist/services/completions.js.map +1 -0
  147. package/dist/services/compliance.d.ts +66 -0
  148. package/dist/services/compliance.d.ts.map +1 -0
  149. package/dist/services/compliance.js +74 -0
  150. package/dist/services/compliance.js.map +1 -0
  151. package/dist/services/config_overrides.d.ts +157 -0
  152. package/dist/services/config_overrides.d.ts.map +1 -0
  153. package/dist/services/config_overrides.js +207 -0
  154. package/dist/services/config_overrides.js.map +1 -0
  155. package/dist/services/config_yaml.d.ts +647 -0
  156. package/dist/services/config_yaml.d.ts.map +1 -0
  157. package/dist/services/config_yaml.js +504 -0
  158. package/dist/services/config_yaml.js.map +1 -0
  159. package/dist/services/containers.d.ts +215 -0
  160. package/dist/services/containers.d.ts.map +1 -0
  161. package/dist/services/containers.js +416 -0
  162. package/dist/services/containers.js.map +1 -0
  163. package/dist/services/coordination_redis_settings.d.ts +93 -0
  164. package/dist/services/coordination_redis_settings.d.ts.map +1 -0
  165. package/dist/services/coordination_redis_settings.js +104 -0
  166. package/dist/services/coordination_redis_settings.js.map +1 -0
  167. package/dist/services/cost_tracking.d.ts +140 -0
  168. package/dist/services/cost_tracking.d.ts.map +1 -0
  169. package/dist/services/cost_tracking.js +181 -0
  170. package/dist/services/cost_tracking.js.map +1 -0
  171. package/dist/services/credential_management.d.ts +133 -0
  172. package/dist/services/credential_management.d.ts.map +1 -0
  173. package/dist/services/credential_management.js +198 -0
  174. package/dist/services/credential_management.js.map +1 -0
  175. package/dist/services/cursor_pass_through.d.ts +70 -0
  176. package/dist/services/cursor_pass_through.d.ts.map +1 -0
  177. package/dist/services/cursor_pass_through.js +112 -0
  178. package/dist/services/cursor_pass_through.js.map +1 -0
  179. package/dist/services/customer_management.d.ts +545 -0
  180. package/dist/services/customer_management.d.ts.map +1 -0
  181. package/dist/services/customer_management.js +567 -0
  182. package/dist/services/customer_management.js.map +1 -0
  183. package/dist/services/email_management.d.ts +57 -0
  184. package/dist/services/email_management.d.ts.map +1 -0
  185. package/dist/services/email_management.js +79 -0
  186. package/dist/services/email_management.js.map +1 -0
  187. package/dist/services/embeddings.d.ts +155 -0
  188. package/dist/services/embeddings.d.ts.map +1 -0
  189. package/dist/services/embeddings.js +168 -0
  190. package/dist/services/embeddings.js.map +1 -0
  191. package/dist/services/evals.d.ts +245 -0
  192. package/dist/services/evals.d.ts.map +1 -0
  193. package/dist/services/evals.js +292 -0
  194. package/dist/services/evals.js.map +1 -0
  195. package/dist/services/experimental.d.ts +166 -0
  196. package/dist/services/experimental.d.ts.map +1 -0
  197. package/dist/services/experimental.js +265 -0
  198. package/dist/services/experimental.js.map +1 -0
  199. package/dist/services/fallback_management.d.ts +91 -0
  200. package/dist/services/fallback_management.d.ts.map +1 -0
  201. package/dist/services/fallback_management.js +86 -0
  202. package/dist/services/fallback_management.js.map +1 -0
  203. package/dist/services/files.d.ts +219 -0
  204. package/dist/services/files.d.ts.map +1 -0
  205. package/dist/services/files.js +358 -0
  206. package/dist/services/files.js.map +1 -0
  207. package/dist/services/fine_tuning.d.ts +155 -0
  208. package/dist/services/fine_tuning.d.ts.map +1 -0
  209. package/dist/services/fine_tuning.js +232 -0
  210. package/dist/services/fine_tuning.js.map +1 -0
  211. package/dist/services/gemini_agents.d.ts +68 -0
  212. package/dist/services/gemini_agents.d.ts.map +1 -0
  213. package/dist/services/gemini_agents.js +110 -0
  214. package/dist/services/gemini_agents.js.map +1 -0
  215. package/dist/services/google_ai_studio_pass_through.d.ts +70 -0
  216. package/dist/services/google_ai_studio_pass_through.d.ts.map +1 -0
  217. package/dist/services/google_ai_studio_pass_through.js +112 -0
  218. package/dist/services/google_ai_studio_pass_through.js.map +1 -0
  219. package/dist/services/google_genai_endpoints.d.ts +174 -0
  220. package/dist/services/google_genai_endpoints.d.ts.map +1 -0
  221. package/dist/services/google_genai_endpoints.js +340 -0
  222. package/dist/services/google_genai_endpoints.js.map +1 -0
  223. package/dist/services/guardrails.d.ts +1221 -0
  224. package/dist/services/guardrails.d.ts.map +1 -0
  225. package/dist/services/guardrails.js +1087 -0
  226. package/dist/services/guardrails.js.map +1 -0
  227. package/dist/services/health.d.ts +212 -0
  228. package/dist/services/health.d.ts.map +1 -0
  229. package/dist/services/health.js +309 -0
  230. package/dist/services/health.js.map +1 -0
  231. package/dist/services/images.d.ts +117 -0
  232. package/dist/services/images.d.ts.map +1 -0
  233. package/dist/services/images.js +184 -0
  234. package/dist/services/images.js.map +1 -0
  235. package/dist/services/index.d.ts +106 -0
  236. package/dist/services/index.d.ts.map +1 -0
  237. package/dist/services/index.js +107 -0
  238. package/dist/services/index.js.map +1 -0
  239. package/dist/services/internal_user_management.d.ts +1062 -0
  240. package/dist/services/internal_user_management.d.ts.map +1 -0
  241. package/dist/services/internal_user_management.js +850 -0
  242. package/dist/services/internal_user_management.js.map +1 -0
  243. package/dist/services/invite_links.d.ts +56 -0
  244. package/dist/services/invite_links.d.ts.map +1 -0
  245. package/dist/services/invite_links.js +82 -0
  246. package/dist/services/invite_links.js.map +1 -0
  247. package/dist/services/jwt_mappings.d.ts +79 -0
  248. package/dist/services/jwt_mappings.d.ts.map +1 -0
  249. package/dist/services/jwt_mappings.js +116 -0
  250. package/dist/services/jwt_mappings.js.map +1 -0
  251. package/dist/services/key_management.d.ts +1640 -0
  252. package/dist/services/key_management.d.ts.map +1 -0
  253. package/dist/services/key_management.js +1344 -0
  254. package/dist/services/key_management.js.map +1 -0
  255. package/dist/services/langfuse_passthrough.d.ts +70 -0
  256. package/dist/services/langfuse_passthrough.d.ts.map +1 -0
  257. package/dist/services/langfuse_passthrough.js +114 -0
  258. package/dist/services/langfuse_passthrough.js.map +1 -0
  259. package/dist/services/llm_utils.d.ts +101 -0
  260. package/dist/services/llm_utils.d.ts.map +1 -0
  261. package/dist/services/llm_utils.js +110 -0
  262. package/dist/services/llm_utils.js.map +1 -0
  263. package/dist/services/logging_callbacks.d.ts +33 -0
  264. package/dist/services/logging_callbacks.d.ts.map +1 -0
  265. package/dist/services/logging_callbacks.js +46 -0
  266. package/dist/services/logging_callbacks.js.map +1 -0
  267. package/dist/services/mcp_byok_oauth.d.ts +112 -0
  268. package/dist/services/mcp_byok_oauth.d.ts.map +1 -0
  269. package/dist/services/mcp_byok_oauth.js +226 -0
  270. package/dist/services/mcp_byok_oauth.js.map +1 -0
  271. package/dist/services/mcp_discoverable.d.ts +197 -0
  272. package/dist/services/mcp_discoverable.d.ts.map +1 -0
  273. package/dist/services/mcp_discoverable.js +304 -0
  274. package/dist/services/mcp_discoverable.js.map +1 -0
  275. package/dist/services/mcp_management.d.ts +956 -0
  276. package/dist/services/mcp_management.d.ts.map +1 -0
  277. package/dist/services/mcp_management.js +1139 -0
  278. package/dist/services/mcp_management.js.map +1 -0
  279. package/dist/services/mcp_rest.d.ts +281 -0
  280. package/dist/services/mcp_rest.d.ts.map +1 -0
  281. package/dist/services/mcp_rest.js +269 -0
  282. package/dist/services/mcp_rest.js.map +1 -0
  283. package/dist/services/memory_management.d.ts +93 -0
  284. package/dist/services/memory_management.d.ts.map +1 -0
  285. package/dist/services/memory_management.js +117 -0
  286. package/dist/services/memory_management.js.map +1 -0
  287. package/dist/services/milvus_pass_through.d.ts +70 -0
  288. package/dist/services/milvus_pass_through.d.ts.map +1 -0
  289. package/dist/services/milvus_pass_through.js +112 -0
  290. package/dist/services/milvus_pass_through.js.map +1 -0
  291. package/dist/services/misc.d.ts +676 -0
  292. package/dist/services/misc.d.ts.map +1 -0
  293. package/dist/services/misc.js +954 -0
  294. package/dist/services/misc.js.map +1 -0
  295. package/dist/services/mistral_pass_through.d.ts +70 -0
  296. package/dist/services/mistral_pass_through.d.ts.map +1 -0
  297. package/dist/services/mistral_pass_through.js +114 -0
  298. package/dist/services/mistral_pass_through.js.map +1 -0
  299. package/dist/services/model_management.d.ts +1649 -0
  300. package/dist/services/model_management.d.ts.map +1 -0
  301. package/dist/services/model_management.js +1805 -0
  302. package/dist/services/model_management.js.map +1 -0
  303. package/dist/services/moderations.d.ts +25 -0
  304. package/dist/services/moderations.d.ts.map +1 -0
  305. package/dist/services/moderations.js +39 -0
  306. package/dist/services/moderations.js.map +1 -0
  307. package/dist/services/ocr.d.ts +25 -0
  308. package/dist/services/ocr.d.ts.map +1 -0
  309. package/dist/services/ocr.js +39 -0
  310. package/dist/services/ocr.js.map +1 -0
  311. package/dist/services/open_ai_pass_through.d.ts +125 -0
  312. package/dist/services/open_ai_pass_through.d.ts.map +1 -0
  313. package/dist/services/open_ai_pass_through.js +232 -0
  314. package/dist/services/open_ai_pass_through.js.map +1 -0
  315. package/dist/services/organization_management.d.ts +664 -0
  316. package/dist/services/organization_management.d.ts.map +1 -0
  317. package/dist/services/organization_management.js +644 -0
  318. package/dist/services/organization_management.js.map +1 -0
  319. package/dist/services/plugins.d.ts +106 -0
  320. package/dist/services/plugins.d.ts.map +1 -0
  321. package/dist/services/plugins.js +180 -0
  322. package/dist/services/plugins.js.map +1 -0
  323. package/dist/services/policies.d.ts +618 -0
  324. package/dist/services/policies.d.ts.map +1 -0
  325. package/dist/services/policies.js +616 -0
  326. package/dist/services/policies.js.map +1 -0
  327. package/dist/services/policy_engine.d.ts +483 -0
  328. package/dist/services/policy_engine.d.ts.map +1 -0
  329. package/dist/services/policy_engine.js +501 -0
  330. package/dist/services/policy_engine.js.map +1 -0
  331. package/dist/services/project_management.d.ts +356 -0
  332. package/dist/services/project_management.d.ts.map +1 -0
  333. package/dist/services/project_management.js +318 -0
  334. package/dist/services/project_management.js.map +1 -0
  335. package/dist/services/prompts.d.ts +193 -0
  336. package/dist/services/prompts.d.ts.map +1 -0
  337. package/dist/services/prompts.js +260 -0
  338. package/dist/services/prompts.js.map +1 -0
  339. package/dist/services/public.d.ts +300 -0
  340. package/dist/services/public.d.ts.map +1 -0
  341. package/dist/services/public.js +362 -0
  342. package/dist/services/public.js.map +1 -0
  343. package/dist/services/rag.d.ts +45 -0
  344. package/dist/services/rag.d.ts.map +1 -0
  345. package/dist/services/rag.js +71 -0
  346. package/dist/services/rag.js.map +1 -0
  347. package/dist/services/realtime.d.ts +91 -0
  348. package/dist/services/realtime.d.ts.map +1 -0
  349. package/dist/services/realtime.js +164 -0
  350. package/dist/services/realtime.js.map +1 -0
  351. package/dist/services/rerank.d.ts +35 -0
  352. package/dist/services/rerank.d.ts.map +1 -0
  353. package/dist/services/rerank.js +55 -0
  354. package/dist/services/rerank.js.map +1 -0
  355. package/dist/services/responses.d.ts +237 -0
  356. package/dist/services/responses.d.ts.map +1 -0
  357. package/dist/services/responses.js +445 -0
  358. package/dist/services/responses.js.map +1 -0
  359. package/dist/services/router_settings.d.ts +67 -0
  360. package/dist/services/router_settings.d.ts.map +1 -0
  361. package/dist/services/router_settings.js +63 -0
  362. package/dist/services/router_settings.js.map +1 -0
  363. package/dist/services/rust_control_plane.d.ts +52 -0
  364. package/dist/services/rust_control_plane.d.ts.map +1 -0
  365. package/dist/services/rust_control_plane.js +54 -0
  366. package/dist/services/rust_control_plane.js.map +1 -0
  367. package/dist/services/scim.d.ts +412 -0
  368. package/dist/services/scim.d.ts.map +1 -0
  369. package/dist/services/scim.js +519 -0
  370. package/dist/services/scim.js.map +1 -0
  371. package/dist/services/search.d.ts +79 -0
  372. package/dist/services/search.d.ts.map +1 -0
  373. package/dist/services/search.js +122 -0
  374. package/dist/services/search.js.map +1 -0
  375. package/dist/services/search_tools.d.ts +140 -0
  376. package/dist/services/search_tools.d.ts.map +1 -0
  377. package/dist/services/search_tools.js +201 -0
  378. package/dist/services/search_tools.js.map +1 -0
  379. package/dist/services/settings.d.ts +53 -0
  380. package/dist/services/settings.d.ts.map +1 -0
  381. package/dist/services/settings.js +67 -0
  382. package/dist/services/settings.js.map +1 -0
  383. package/dist/services/sso_settings.d.ts +239 -0
  384. package/dist/services/sso_settings.d.ts.map +1 -0
  385. package/dist/services/sso_settings.js +214 -0
  386. package/dist/services/sso_settings.js.map +1 -0
  387. package/dist/services/tag_management.d.ts +390 -0
  388. package/dist/services/tag_management.d.ts.map +1 -0
  389. package/dist/services/tag_management.js +407 -0
  390. package/dist/services/tag_management.js.map +1 -0
  391. package/dist/services/team_management.d.ts +1502 -0
  392. package/dist/services/team_management.d.ts.map +1 -0
  393. package/dist/services/team_management.js +1429 -0
  394. package/dist/services/team_management.js.map +1 -0
  395. package/dist/services/tools.d.ts +227 -0
  396. package/dist/services/tools.d.ts.map +1 -0
  397. package/dist/services/tools.js +266 -0
  398. package/dist/services/tools.js.map +1 -0
  399. package/dist/services/ui_settings.d.ts +90 -0
  400. package/dist/services/ui_settings.d.ts.map +1 -0
  401. package/dist/services/ui_settings.js +96 -0
  402. package/dist/services/ui_settings.js.map +1 -0
  403. package/dist/services/ui_theme_settings.d.ts +62 -0
  404. package/dist/services/ui_theme_settings.d.ts.map +1 -0
  405. package/dist/services/ui_theme_settings.js +79 -0
  406. package/dist/services/ui_theme_settings.js.map +1 -0
  407. package/dist/services/usage_ai.d.ts +39 -0
  408. package/dist/services/usage_ai.d.ts.map +1 -0
  409. package/dist/services/usage_ai.js +40 -0
  410. package/dist/services/usage_ai.js.map +1 -0
  411. package/dist/services/vantage.d.ts +108 -0
  412. package/dist/services/vantage.d.ts.map +1 -0
  413. package/dist/services/vantage.js +124 -0
  414. package/dist/services/vantage.js.map +1 -0
  415. package/dist/services/vector_store_management.d.ts +161 -0
  416. package/dist/services/vector_store_management.d.ts.map +1 -0
  417. package/dist/services/vector_store_management.js +191 -0
  418. package/dist/services/vector_store_management.js.map +1 -0
  419. package/dist/services/vector_stores.d.ts +342 -0
  420. package/dist/services/vector_stores.d.ts.map +1 -0
  421. package/dist/services/vector_stores.js +639 -0
  422. package/dist/services/vector_stores.js.map +1 -0
  423. package/dist/services/vertex_ai_pass_through.d.ts +180 -0
  424. package/dist/services/vertex_ai_pass_through.d.ts.map +1 -0
  425. package/dist/services/vertex_ai_pass_through.js +334 -0
  426. package/dist/services/vertex_ai_pass_through.js.map +1 -0
  427. package/dist/services/videos.d.ts +207 -0
  428. package/dist/services/videos.d.ts.map +1 -0
  429. package/dist/services/videos.js +373 -0
  430. package/dist/services/videos.js.map +1 -0
  431. package/dist/services/vllm_pass_through.d.ts +70 -0
  432. package/dist/services/vllm_pass_through.d.ts.map +1 -0
  433. package/dist/services/vllm_pass_through.js +104 -0
  434. package/dist/services/vllm_pass_through.js.map +1 -0
  435. package/dist/services/watsonx_pass_through.d.ts +70 -0
  436. package/dist/services/watsonx_pass_through.d.ts.map +1 -0
  437. package/dist/services/watsonx_pass_through.js +114 -0
  438. package/dist/services/watsonx_pass_through.js.map +1 -0
  439. package/dist/services/web_socket.d.ts +77 -0
  440. package/dist/services/web_socket.d.ts.map +1 -0
  441. package/dist/services/web_socket.js +135 -0
  442. package/dist/services/web_socket.js.map +1 -0
  443. package/dist/services/workflow_management.d.ts +140 -0
  444. package/dist/services/workflow_management.d.ts.map +1 -0
  445. package/dist/services/workflow_management.js +220 -0
  446. package/dist/services/workflow_management.js.map +1 -0
  447. package/dist/traits.d.ts +14 -0
  448. package/dist/traits.d.ts.map +1 -0
  449. package/dist/traits.js +15 -0
  450. package/dist/traits.js.map +1 -0
  451. package/package.json +75 -0
  452. package/src/credentials.ts +97 -0
  453. package/src/errors.ts +108 -0
  454. package/src/index.ts +33 -0
  455. package/src/protocol.ts +160 -0
  456. package/src/retry.ts +74 -0
  457. package/src/services/a2a.ts +250 -0
  458. package/src/services/a2a_registration.ts +94 -0
  459. package/src/services/access_groups.ts +716 -0
  460. package/src/services/adaptive_router.ts +49 -0
  461. package/src/services/agents.ts +1314 -0
  462. package/src/services/alerting.ts +49 -0
  463. package/src/services/anthropic_pass_through.ts +233 -0
  464. package/src/services/anthropic_passthrough.ts +123 -0
  465. package/src/services/anthropic_skills.ts +200 -0
  466. package/src/services/assembly_ai_eu_pass_through.ts +237 -0
  467. package/src/services/assembly_ai_pass_through.ts +237 -0
  468. package/src/services/assistants.ts +685 -0
  469. package/src/services/audio.ts +189 -0
  470. package/src/services/audit_logging.ts +194 -0
  471. package/src/services/auto_router.ts +625 -0
  472. package/src/services/aws_comprehend_medical_pass_through.ts +109 -0
  473. package/src/services/azure_ai_pass_through.ts +231 -0
  474. package/src/services/azure_pass_through.ts +227 -0
  475. package/src/services/batch.ts +553 -0
  476. package/src/services/bedrock_pass_through.ts +229 -0
  477. package/src/services/beta_agents.ts +444 -0
  478. package/src/services/beta_mcp.ts +105 -0
  479. package/src/services/budget_management.ts +465 -0
  480. package/src/services/budget_spend_tracking.ts +2670 -0
  481. package/src/services/cache_settings.ts +234 -0
  482. package/src/services/caching.ts +175 -0
  483. package/src/services/chat_completions.ts +1788 -0
  484. package/src/services/claude_code_marketplace.ts +569 -0
  485. package/src/services/cloudzero.ts +297 -0
  486. package/src/services/cohere_pass_through.ts +227 -0
  487. package/src/services/completions.ts +194 -0
  488. package/src/services/compliance.ts +175 -0
  489. package/src/services/config_overrides.ts +466 -0
  490. package/src/services/config_yaml.ts +1537 -0
  491. package/src/services/containers.ts +848 -0
  492. package/src/services/coordination_redis_settings.ts +251 -0
  493. package/src/services/cost_tracking.ts +407 -0
  494. package/src/services/credential_management.ts +436 -0
  495. package/src/services/cursor_pass_through.ts +227 -0
  496. package/src/services/customer_management.ts +1475 -0
  497. package/src/services/email_management.ts +171 -0
  498. package/src/services/embeddings.ts +424 -0
  499. package/src/services/evals.ts +672 -0
  500. package/src/services/experimental.ts +572 -0
  501. package/src/services/fallback_management.ts +224 -0
  502. package/src/services/files.ts +732 -0
  503. package/src/services/fine_tuning.ts +547 -0
  504. package/src/services/gemini_agents.ts +227 -0
  505. package/src/services/google_ai_studio_pass_through.ts +227 -0
  506. package/src/services/google_genai_endpoints.ts +688 -0
  507. package/src/services/guardrails.ts +3006 -0
  508. package/src/services/health.ts +713 -0
  509. package/src/services/images.ts +430 -0
  510. package/src/services/index.ts +106 -0
  511. package/src/services/internal_user_management.ts +2574 -0
  512. package/src/services/invite_links.ts +167 -0
  513. package/src/services/jwt_mappings.ts +238 -0
  514. package/src/services/key_management.ts +4162 -0
  515. package/src/services/langfuse_passthrough.ts +231 -0
  516. package/src/services/llm_utils.ts +429 -0
  517. package/src/services/logging_callbacks.ts +104 -0
  518. package/src/services/mcp_byok_oauth.ts +468 -0
  519. package/src/services/mcp_discoverable.ts +626 -0
  520. package/src/services/mcp_management.ts +2915 -0
  521. package/src/services/mcp_rest.ts +779 -0
  522. package/src/services/memory_management.ts +248 -0
  523. package/src/services/milvus_pass_through.ts +227 -0
  524. package/src/services/misc.ts +2128 -0
  525. package/src/services/mistral_pass_through.ts +229 -0
  526. package/src/services/model_management.ts +4501 -0
  527. package/src/services/moderations.ts +80 -0
  528. package/src/services/ocr.ts +78 -0
  529. package/src/services/open_ai_pass_through.ts +462 -0
  530. package/src/services/organization_management.ts +1749 -0
  531. package/src/services/plugins.ts +367 -0
  532. package/src/services/policies.ts +1676 -0
  533. package/src/services/policy_engine.ts +1318 -0
  534. package/src/services/project_management.ts +938 -0
  535. package/src/services/prompts.ts +592 -0
  536. package/src/services/public.ts +880 -0
  537. package/src/services/rag.ts +148 -0
  538. package/src/services/realtime.ts +350 -0
  539. package/src/services/rerank.ts +111 -0
  540. package/src/services/responses.ts +909 -0
  541. package/src/services/router_settings.ts +168 -0
  542. package/src/services/rust_control_plane.ts +123 -0
  543. package/src/services/scim.ts +1243 -0
  544. package/src/services/search.ts +260 -0
  545. package/src/services/search_tools.ts +439 -0
  546. package/src/services/settings.ts +146 -0
  547. package/src/services/sso_settings.ts +626 -0
  548. package/src/services/tag_management.ts +1004 -0
  549. package/src/services/team_management.ts +3990 -0
  550. package/src/services/tools.ts +628 -0
  551. package/src/services/ui_settings.ts +237 -0
  552. package/src/services/ui_theme_settings.ts +173 -0
  553. package/src/services/usage_ai.ts +86 -0
  554. package/src/services/vantage.ts +283 -0
  555. package/src/services/vector_store_management.ts +454 -0
  556. package/src/services/vector_stores.ts +1321 -0
  557. package/src/services/vertex_ai_pass_through.ts +684 -0
  558. package/src/services/videos.ts +762 -0
  559. package/src/services/vllm_pass_through.ts +227 -0
  560. package/src/services/watsonx_pass_through.ts +229 -0
  561. package/src/services/web_socket.ts +254 -0
  562. package/src/services/workflow_management.ts +482 -0
  563. package/src/traits.ts +44 -0
@@ -0,0 +1,1318 @@
1
+ // AUTO-GENERATED by scripts/generate.ts from .generated-specs (pinned litellm-openapi @ 1.100.0 — see README). Do not edit.
2
+ import * as S from "@distilled.cloud/core/schema";
3
+ import * as API from "@distilled.cloud/core/api";
4
+ import * as C from "@distilled.cloud/core/category";
5
+ import * as T from "../traits.ts";
6
+ import {
7
+ LitellmProtocol,
8
+ type LitellmOpError,
9
+ type LitellmOpContext,
10
+ } from "../protocol.ts";
11
+ import * as Retry from "../retry.ts";
12
+
13
+ export type { LitellmOpError, LitellmOpContext };
14
+
15
+ export class UnprocessableEntity
16
+ extends /*@__PURE__*/ T.applyErrorMatchers(
17
+ /*@__PURE__*/ S.TaggedError<UnprocessableEntity>()("UnprocessableEntity", {
18
+ code: S.Number,
19
+ message: S.String,
20
+ }).pipe(C.withBadRequestError),
21
+ [{ status: 422 }],
22
+ ) {}
23
+
24
+ export type CreatePolicyAttachmentPoliciesAttachmentsPostRequestKeysList =
25
+ Array<string>;
26
+ export const CreatePolicyAttachmentPoliciesAttachmentsPostRequestKeysList =
27
+ /*@__PURE__*/ S.Array(
28
+ S.String,
29
+ ) as any as S.Schema<CreatePolicyAttachmentPoliciesAttachmentsPostRequestKeysList>;
30
+
31
+ export type CreatePolicyAttachmentPoliciesAttachmentsPostRequestModelsList =
32
+ Array<string>;
33
+ export const CreatePolicyAttachmentPoliciesAttachmentsPostRequestModelsList =
34
+ /*@__PURE__*/ S.Array(
35
+ S.String,
36
+ ) as any as S.Schema<CreatePolicyAttachmentPoliciesAttachmentsPostRequestModelsList>;
37
+
38
+ export type CreatePolicyAttachmentPoliciesAttachmentsPostRequestTagsList =
39
+ Array<string>;
40
+ export const CreatePolicyAttachmentPoliciesAttachmentsPostRequestTagsList =
41
+ /*@__PURE__*/ S.Array(
42
+ S.String,
43
+ ) as any as S.Schema<CreatePolicyAttachmentPoliciesAttachmentsPostRequestTagsList>;
44
+
45
+ export type CreatePolicyAttachmentPoliciesAttachmentsPostRequestTeamsList =
46
+ Array<string>;
47
+ export const CreatePolicyAttachmentPoliciesAttachmentsPostRequestTeamsList =
48
+ /*@__PURE__*/ S.Array(
49
+ S.String,
50
+ ) as any as S.Schema<CreatePolicyAttachmentPoliciesAttachmentsPostRequestTeamsList>;
51
+
52
+ export interface CreatePolicyAttachmentPoliciesAttachmentsPostRequest {
53
+ /** Key aliases or patterns this attachment applies to. */
54
+ keys?: CreatePolicyAttachmentPoliciesAttachmentsPostRequestKeysList | null;
55
+ /** Model names or patterns this attachment applies to. */
56
+ models?: CreatePolicyAttachmentPoliciesAttachmentsPostRequestModelsList | null;
57
+ /** Name of the policy to attach. */
58
+ policy_name: string;
59
+ /** Use '*' for global scope (applies to all requests). */
60
+ scope?: string | null;
61
+ /** Tag patterns this attachment applies to. Supports wildcards (e.g., health-*). */
62
+ tags?: CreatePolicyAttachmentPoliciesAttachmentsPostRequestTagsList | null;
63
+ /** Team aliases or patterns this attachment applies to. */
64
+ teams?: CreatePolicyAttachmentPoliciesAttachmentsPostRequestTeamsList | null;
65
+ }
66
+ export const CreatePolicyAttachmentPoliciesAttachmentsPostRequest =
67
+ /*@__PURE__*/ S.suspend(() =>
68
+ S.Struct({
69
+ keys: S.optional(
70
+ S.NullOr(CreatePolicyAttachmentPoliciesAttachmentsPostRequestKeysList),
71
+ ),
72
+ models: S.optional(
73
+ S.NullOr(
74
+ CreatePolicyAttachmentPoliciesAttachmentsPostRequestModelsList,
75
+ ),
76
+ ),
77
+ policy_name: S.String,
78
+ scope: S.optional(S.NullOr(S.String)),
79
+ tags: S.optional(
80
+ S.NullOr(CreatePolicyAttachmentPoliciesAttachmentsPostRequestTagsList),
81
+ ),
82
+ teams: S.optional(
83
+ S.NullOr(CreatePolicyAttachmentPoliciesAttachmentsPostRequestTeamsList),
84
+ ),
85
+ }).pipe(
86
+ T.Http({ method: "POST", uri: "/policies/attachments", code: 200 }),
87
+ ),
88
+ ).annotate({
89
+ identifier: "CreatePolicyAttachmentPoliciesAttachmentsPostRequest",
90
+ }) as any as S.Schema<CreatePolicyAttachmentPoliciesAttachmentsPostRequest>;
91
+
92
+ /** Where this attachment is defined: 'db' (database) or 'config' (config.yaml). */
93
+ export type PolicyAttachmentDBResponseDefinitionLocation = "db" | "config";
94
+ export const PolicyAttachmentDBResponseDefinitionLocation = S.String;
95
+
96
+ /** Key patterns. */
97
+ export type PolicyAttachmentDBResponseKeysList = Array<string>;
98
+ export const PolicyAttachmentDBResponseKeysList = /*@__PURE__*/ S.Array(
99
+ S.String,
100
+ ) as any as S.Schema<PolicyAttachmentDBResponseKeysList>;
101
+
102
+ /** Model patterns. */
103
+ export type PolicyAttachmentDBResponseModelsList = Array<string>;
104
+ export const PolicyAttachmentDBResponseModelsList = /*@__PURE__*/ S.Array(
105
+ S.String,
106
+ ) as any as S.Schema<PolicyAttachmentDBResponseModelsList>;
107
+
108
+ /** Tag patterns. */
109
+ export type PolicyAttachmentDBResponseTagsList = Array<string>;
110
+ export const PolicyAttachmentDBResponseTagsList = /*@__PURE__*/ S.Array(
111
+ S.String,
112
+ ) as any as S.Schema<PolicyAttachmentDBResponseTagsList>;
113
+
114
+ /** Team patterns. */
115
+ export type PolicyAttachmentDBResponseTeamsList = Array<string>;
116
+ export const PolicyAttachmentDBResponseTeamsList = /*@__PURE__*/ S.Array(
117
+ S.String,
118
+ ) as any as S.Schema<PolicyAttachmentDBResponseTeamsList>;
119
+
120
+ /** Response for a policy attachment from the database. */
121
+ export interface PolicyAttachmentDBResponse {
122
+ /** Unique ID of the attachment. */
123
+ attachment_id: string;
124
+ /** When the attachment was created. */
125
+ created_at?: string | null;
126
+ /** Who created the attachment. */
127
+ created_by?: string | null;
128
+ /** Where this attachment is defined: 'db' (database) or 'config' (config.yaml). */
129
+ definition_location?: PolicyAttachmentDBResponseDefinitionLocation;
130
+ /** Key patterns. */
131
+ keys?: PolicyAttachmentDBResponseKeysList;
132
+ /** Model patterns. */
133
+ models?: PolicyAttachmentDBResponseModelsList;
134
+ /** Name of the attached policy. */
135
+ policy_name: string;
136
+ /** Scope of the attachment. */
137
+ scope?: string | null;
138
+ /** Tag patterns. */
139
+ tags?: PolicyAttachmentDBResponseTagsList;
140
+ /** Team patterns. */
141
+ teams?: PolicyAttachmentDBResponseTeamsList;
142
+ /** When the attachment was last updated. */
143
+ updated_at?: string | null;
144
+ /** Who last updated the attachment. */
145
+ updated_by?: string | null;
146
+ }
147
+ export const PolicyAttachmentDBResponse = /*@__PURE__*/ S.suspend(() =>
148
+ S.Struct({
149
+ attachment_id: S.String,
150
+ created_at: S.optional(S.NullOr(S.String)),
151
+ created_by: S.optional(S.NullOr(S.String)),
152
+ definition_location: S.optional(
153
+ PolicyAttachmentDBResponseDefinitionLocation,
154
+ ),
155
+ keys: S.optional(PolicyAttachmentDBResponseKeysList),
156
+ models: S.optional(PolicyAttachmentDBResponseModelsList),
157
+ policy_name: S.String,
158
+ scope: S.optional(S.NullOr(S.String)),
159
+ tags: S.optional(PolicyAttachmentDBResponseTagsList),
160
+ teams: S.optional(PolicyAttachmentDBResponseTeamsList),
161
+ updated_at: S.optional(S.NullOr(S.String)),
162
+ updated_by: S.optional(S.NullOr(S.String)),
163
+ }),
164
+ ).annotate({
165
+ identifier: "PolicyAttachmentDBResponse",
166
+ }) as any as S.Schema<PolicyAttachmentDBResponse>;
167
+
168
+ /** Condition for when a policy applies. */
169
+ export interface PolicyConditionRequest {
170
+ /** Model name pattern (exact match or regex) for when policy applies. */
171
+ model?: string | null;
172
+ }
173
+ export const PolicyConditionRequest = /*@__PURE__*/ S.suspend(() =>
174
+ S.Struct({
175
+ model: S.optional(S.NullOr(S.String)),
176
+ }),
177
+ ).annotate({
178
+ identifier: "PolicyConditionRequest",
179
+ }) as any as S.Schema<PolicyConditionRequest>;
180
+
181
+ export type CreatePolicyPoliciesPostRequestGuardrailsAddList = Array<string>;
182
+ export const CreatePolicyPoliciesPostRequestGuardrailsAddList =
183
+ /*@__PURE__*/ S.Array(
184
+ S.String,
185
+ ) as any as S.Schema<CreatePolicyPoliciesPostRequestGuardrailsAddList>;
186
+
187
+ export type CreatePolicyPoliciesPostRequestGuardrailsRemoveList = Array<string>;
188
+ export const CreatePolicyPoliciesPostRequestGuardrailsRemoveList =
189
+ /*@__PURE__*/ S.Array(
190
+ S.String,
191
+ ) as any as S.Schema<CreatePolicyPoliciesPostRequestGuardrailsRemoveList>;
192
+
193
+ export type CreatePolicyPoliciesPostRequestPipelineMap = {
194
+ [key: string]: unknown | undefined;
195
+ };
196
+ export const CreatePolicyPoliciesPostRequestPipelineMap =
197
+ /*@__PURE__*/ S.Record(
198
+ S.String,
199
+ S.Unknown,
200
+ ) as any as S.Schema<CreatePolicyPoliciesPostRequestPipelineMap>;
201
+
202
+ export interface CreatePolicyPoliciesPostRequest {
203
+ /** Condition for when this policy applies. */
204
+ condition?: PolicyConditionRequest | null;
205
+ /** Human-readable description of the policy. */
206
+ description?: string | null;
207
+ /** List of guardrail names to add. */
208
+ guardrails_add?: CreatePolicyPoliciesPostRequestGuardrailsAddList | null;
209
+ /** List of guardrail names to remove (from inherited). */
210
+ guardrails_remove?: CreatePolicyPoliciesPostRequestGuardrailsRemoveList | null;
211
+ /** Name of parent policy to inherit from. */
212
+ inherit?: string | null;
213
+ /** Optional guardrail pipeline for ordered execution. Contains 'mode' and 'steps'. */
214
+ pipeline?: CreatePolicyPoliciesPostRequestPipelineMap | null;
215
+ /** Unique name for the policy. */
216
+ policy_name: string;
217
+ }
218
+ export const CreatePolicyPoliciesPostRequest = /*@__PURE__*/ S.suspend(() =>
219
+ S.Struct({
220
+ condition: S.optional(S.NullOr(PolicyConditionRequest)),
221
+ description: S.optional(S.NullOr(S.String)),
222
+ guardrails_add: S.optional(
223
+ S.NullOr(CreatePolicyPoliciesPostRequestGuardrailsAddList),
224
+ ),
225
+ guardrails_remove: S.optional(
226
+ S.NullOr(CreatePolicyPoliciesPostRequestGuardrailsRemoveList),
227
+ ),
228
+ inherit: S.optional(S.NullOr(S.String)),
229
+ pipeline: S.optional(S.NullOr(CreatePolicyPoliciesPostRequestPipelineMap)),
230
+ policy_name: S.String,
231
+ }).pipe(T.Http({ method: "POST", uri: "/policies", code: 200 })),
232
+ ).annotate({
233
+ identifier: "CreatePolicyPoliciesPostRequest",
234
+ }) as any as S.Schema<CreatePolicyPoliciesPostRequest>;
235
+
236
+ export type PolicyDBResponseConditionMap = {
237
+ [key: string]: unknown | undefined;
238
+ };
239
+ export const PolicyDBResponseConditionMap = /*@__PURE__*/ S.Record(
240
+ S.String,
241
+ S.Unknown,
242
+ ) as any as S.Schema<PolicyDBResponseConditionMap>;
243
+
244
+ /** Where this policy is defined: 'db' (database) or 'config' (config.yaml). */
245
+ export type PolicyDBResponseDefinitionLocation = "db" | "config";
246
+ export const PolicyDBResponseDefinitionLocation = S.String;
247
+
248
+ /** Guardrails to add. */
249
+ export type PolicyDBResponseGuardrailsAddList = Array<string>;
250
+ export const PolicyDBResponseGuardrailsAddList = /*@__PURE__*/ S.Array(
251
+ S.String,
252
+ ) as any as S.Schema<PolicyDBResponseGuardrailsAddList>;
253
+
254
+ /** Guardrails to remove. */
255
+ export type PolicyDBResponseGuardrailsRemoveList = Array<string>;
256
+ export const PolicyDBResponseGuardrailsRemoveList = /*@__PURE__*/ S.Array(
257
+ S.String,
258
+ ) as any as S.Schema<PolicyDBResponseGuardrailsRemoveList>;
259
+
260
+ export type PolicyDBResponsePipelineMap = {
261
+ [key: string]: unknown | undefined;
262
+ };
263
+ export const PolicyDBResponsePipelineMap = /*@__PURE__*/ S.Record(
264
+ S.String,
265
+ S.Unknown,
266
+ ) as any as S.Schema<PolicyDBResponsePipelineMap>;
267
+
268
+ /** Response for a policy from the database. */
269
+ export interface PolicyDBResponse {
270
+ /** Policy condition. */
271
+ condition?: PolicyDBResponseConditionMap | null;
272
+ /** When the policy was created. */
273
+ created_at?: string | null;
274
+ /** Who created the policy. */
275
+ created_by?: string | null;
276
+ /** Where this policy is defined: 'db' (database) or 'config' (config.yaml). */
277
+ definition_location?: PolicyDBResponseDefinitionLocation;
278
+ /** Policy description. */
279
+ description?: string | null;
280
+ /** Guardrails to add. */
281
+ guardrails_add?: PolicyDBResponseGuardrailsAddList;
282
+ /** Guardrails to remove. */
283
+ guardrails_remove?: PolicyDBResponseGuardrailsRemoveList;
284
+ /** Parent policy name. */
285
+ inherit?: string | null;
286
+ /** True if this is the latest version by version_number. */
287
+ is_latest?: boolean;
288
+ /** Policy ID this version was cloned from. */
289
+ parent_version_id?: string | null;
290
+ /** Optional guardrail pipeline. */
291
+ pipeline?: PolicyDBResponsePipelineMap | null;
292
+ /** Unique ID of the policy. */
293
+ policy_id: string;
294
+ /** Name of the policy. */
295
+ policy_name: string;
296
+ /** When this version was promoted to production. */
297
+ production_at?: string | null;
298
+ /** When this version was published. */
299
+ published_at?: string | null;
300
+ /** When the policy was last updated. */
301
+ updated_at?: string | null;
302
+ /** Who last updated the policy. */
303
+ updated_by?: string | null;
304
+ /** Version number of this policy. */
305
+ version_number?: number;
306
+ /** One of: draft, published, production. */
307
+ version_status?: string;
308
+ }
309
+ export const PolicyDBResponse = /*@__PURE__*/ S.suspend(() =>
310
+ S.Struct({
311
+ condition: S.optional(S.NullOr(PolicyDBResponseConditionMap)),
312
+ created_at: S.optional(S.NullOr(S.String)),
313
+ created_by: S.optional(S.NullOr(S.String)),
314
+ definition_location: S.optional(PolicyDBResponseDefinitionLocation),
315
+ description: S.optional(S.NullOr(S.String)),
316
+ guardrails_add: S.optional(PolicyDBResponseGuardrailsAddList),
317
+ guardrails_remove: S.optional(PolicyDBResponseGuardrailsRemoveList),
318
+ inherit: S.optional(S.NullOr(S.String)),
319
+ is_latest: S.optional(S.Boolean),
320
+ parent_version_id: S.optional(S.NullOr(S.String)),
321
+ pipeline: S.optional(S.NullOr(PolicyDBResponsePipelineMap)),
322
+ policy_id: S.String,
323
+ policy_name: S.String,
324
+ production_at: S.optional(S.NullOr(S.String)),
325
+ published_at: S.optional(S.NullOr(S.String)),
326
+ updated_at: S.optional(S.NullOr(S.String)),
327
+ updated_by: S.optional(S.NullOr(S.String)),
328
+ version_number: S.optional(S.Number),
329
+ version_status: S.optional(S.String),
330
+ }),
331
+ ).annotate({
332
+ identifier: "PolicyDBResponse",
333
+ }) as any as S.Schema<PolicyDBResponse>;
334
+
335
+ export interface CreatePolicyVersionPoliciesNamePolicyNameVersionsPostRequest {
336
+ policy_name: string;
337
+ /** Policy ID to clone from. If None, clone from current production version. */
338
+ source_policy_id?: string | null;
339
+ }
340
+ export const CreatePolicyVersionPoliciesNamePolicyNameVersionsPostRequest =
341
+ /*@__PURE__*/ S.suspend(() =>
342
+ S.Struct({
343
+ policy_name: S.String.pipe(T.Label()),
344
+ source_policy_id: S.optional(S.NullOr(S.String)),
345
+ }).pipe(
346
+ T.Http({
347
+ method: "POST",
348
+ uri: "/policies/name/{policy_name}/versions",
349
+ code: 200,
350
+ }),
351
+ ),
352
+ ).annotate({
353
+ identifier: "CreatePolicyVersionPoliciesNamePolicyNameVersionsPostRequest",
354
+ }) as any as S.Schema<CreatePolicyVersionPoliciesNamePolicyNameVersionsPostRequest>;
355
+
356
+ export interface DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteRequest {
357
+ policy_name: string;
358
+ }
359
+ export const DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteRequest =
360
+ /*@__PURE__*/ S.suspend(() =>
361
+ S.Struct({
362
+ policy_name: S.String.pipe(T.Label()),
363
+ }).pipe(
364
+ T.Http({
365
+ method: "DELETE",
366
+ uri: "/policies/name/{policy_name}/all-versions",
367
+ code: 200,
368
+ }),
369
+ ),
370
+ ).annotate({
371
+ identifier:
372
+ "DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteRequest",
373
+ }) as any as S.Schema<DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteRequest>;
374
+
375
+ export interface DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteResponse {
376
+ body: unknown;
377
+ }
378
+ export const DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteResponse =
379
+ /*@__PURE__*/ S.suspend(() =>
380
+ S.Struct({
381
+ body: S.Unknown,
382
+ }),
383
+ ).annotate({
384
+ identifier:
385
+ "DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteResponse",
386
+ }) as any as S.Schema<DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteResponse>;
387
+
388
+ export interface DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteRequest {
389
+ attachment_id: string;
390
+ }
391
+ export const DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteRequest =
392
+ /*@__PURE__*/ S.suspend(() =>
393
+ S.Struct({
394
+ attachment_id: S.String.pipe(T.Label()),
395
+ }).pipe(
396
+ T.Http({
397
+ method: "DELETE",
398
+ uri: "/policies/attachments/{attachment_id}",
399
+ code: 200,
400
+ }),
401
+ ),
402
+ ).annotate({
403
+ identifier:
404
+ "DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteRequest",
405
+ }) as any as S.Schema<DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteRequest>;
406
+
407
+ export interface DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteResponse {
408
+ body: unknown;
409
+ }
410
+ export const DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteResponse =
411
+ /*@__PURE__*/ S.suspend(() =>
412
+ S.Struct({
413
+ body: S.Unknown,
414
+ }),
415
+ ).annotate({
416
+ identifier:
417
+ "DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteResponse",
418
+ }) as any as S.Schema<DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteResponse>;
419
+
420
+ export interface DeletePolicyPoliciesPolicyIdDeleteRequest {
421
+ policy_id: string;
422
+ }
423
+ export const DeletePolicyPoliciesPolicyIdDeleteRequest =
424
+ /*@__PURE__*/ S.suspend(() =>
425
+ S.Struct({
426
+ policy_id: S.String.pipe(T.Label()),
427
+ }).pipe(
428
+ T.Http({ method: "DELETE", uri: "/policies/{policy_id}", code: 200 }),
429
+ ),
430
+ ).annotate({
431
+ identifier: "DeletePolicyPoliciesPolicyIdDeleteRequest",
432
+ }) as any as S.Schema<DeletePolicyPoliciesPolicyIdDeleteRequest>;
433
+
434
+ export interface DeletePolicyPoliciesPolicyIdDeleteResponse {
435
+ body: unknown;
436
+ }
437
+ export const DeletePolicyPoliciesPolicyIdDeleteResponse =
438
+ /*@__PURE__*/ S.suspend(() =>
439
+ S.Struct({
440
+ body: S.Unknown,
441
+ }),
442
+ ).annotate({
443
+ identifier: "DeletePolicyPoliciesPolicyIdDeleteResponse",
444
+ }) as any as S.Schema<DeletePolicyPoliciesPolicyIdDeleteResponse>;
445
+
446
+ export interface GetComparePolicyVersionsPoliciesCompareRequest {
447
+ version_a: string;
448
+ version_b: string;
449
+ }
450
+ export const GetComparePolicyVersionsPoliciesCompareRequest =
451
+ /*@__PURE__*/ S.suspend(() =>
452
+ S.Struct({
453
+ version_a: S.String.pipe(T.Query()),
454
+ version_b: S.String.pipe(T.Query()),
455
+ }).pipe(T.Http({ method: "GET", uri: "/policies/compare", code: 200 })),
456
+ ).annotate({
457
+ identifier: "GetComparePolicyVersionsPoliciesCompareRequest",
458
+ }) as any as S.Schema<GetComparePolicyVersionsPoliciesCompareRequest>;
459
+
460
+ export type PolicyVersionCompareResponseFieldDiffsValueMap = {
461
+ [key: string]: unknown | undefined;
462
+ };
463
+ export const PolicyVersionCompareResponseFieldDiffsValueMap =
464
+ /*@__PURE__*/ S.Record(
465
+ S.String,
466
+ S.Unknown,
467
+ ) as any as S.Schema<PolicyVersionCompareResponseFieldDiffsValueMap>;
468
+
469
+ /** Field name -> {version_a: val, version_b: val} for differing fields. */
470
+ export type PolicyVersionCompareResponseFieldDiffsMap = {
471
+ [key: string]: PolicyVersionCompareResponseFieldDiffsValueMap | undefined;
472
+ };
473
+ export const PolicyVersionCompareResponseFieldDiffsMap = /*@__PURE__*/ S.Record(
474
+ S.String,
475
+ PolicyVersionCompareResponseFieldDiffsValueMap,
476
+ ) as any as S.Schema<PolicyVersionCompareResponseFieldDiffsMap>;
477
+
478
+ /** Response for comparing two policy versions. */
479
+ export interface PolicyVersionCompareResponse {
480
+ /** Field name -> {version_a: val, version_b: val} for differing fields. */
481
+ field_diffs?: PolicyVersionCompareResponseFieldDiffsMap;
482
+ /** First version. */
483
+ version_a: PolicyDBResponse;
484
+ /** Second version. */
485
+ version_b: PolicyDBResponse;
486
+ }
487
+ export const PolicyVersionCompareResponse = /*@__PURE__*/ S.suspend(() =>
488
+ S.Struct({
489
+ field_diffs: S.optional(PolicyVersionCompareResponseFieldDiffsMap),
490
+ version_a: PolicyDBResponse,
491
+ version_b: PolicyDBResponse,
492
+ }),
493
+ ).annotate({
494
+ identifier: "PolicyVersionCompareResponse",
495
+ }) as any as S.Schema<PolicyVersionCompareResponse>;
496
+
497
+ export interface GetPolicyAttachmentPoliciesAttachmentsAttachmentIdGetRequest {
498
+ attachment_id: string;
499
+ }
500
+ export const GetPolicyAttachmentPoliciesAttachmentsAttachmentIdGetRequest =
501
+ /*@__PURE__*/ S.suspend(() =>
502
+ S.Struct({
503
+ attachment_id: S.String.pipe(T.Label()),
504
+ }).pipe(
505
+ T.Http({
506
+ method: "GET",
507
+ uri: "/policies/attachments/{attachment_id}",
508
+ code: 200,
509
+ }),
510
+ ),
511
+ ).annotate({
512
+ identifier: "GetPolicyAttachmentPoliciesAttachmentsAttachmentIdGetRequest",
513
+ }) as any as S.Schema<GetPolicyAttachmentPoliciesAttachmentsAttachmentIdGetRequest>;
514
+
515
+ export interface GetPolicyPoliciesPolicyIdGetRequest {
516
+ policy_id: string;
517
+ }
518
+ export const GetPolicyPoliciesPolicyIdGetRequest = /*@__PURE__*/ S.suspend(() =>
519
+ S.Struct({
520
+ policy_id: S.String.pipe(T.Label()),
521
+ }).pipe(T.Http({ method: "GET", uri: "/policies/{policy_id}", code: 200 })),
522
+ ).annotate({
523
+ identifier: "GetPolicyPoliciesPolicyIdGetRequest",
524
+ }) as any as S.Schema<GetPolicyPoliciesPolicyIdGetRequest>;
525
+
526
+ export interface GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetRequest {
527
+ policy_id: string;
528
+ }
529
+ export const GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetRequest =
530
+ /*@__PURE__*/ S.suspend(() =>
531
+ S.Struct({
532
+ policy_id: S.String.pipe(T.Label()),
533
+ }).pipe(
534
+ T.Http({
535
+ method: "GET",
536
+ uri: "/policies/{policy_id}/resolved-guardrails",
537
+ code: 200,
538
+ }),
539
+ ),
540
+ ).annotate({
541
+ identifier:
542
+ "GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetRequest",
543
+ }) as any as S.Schema<GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetRequest>;
544
+
545
+ export interface GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetResponse {
546
+ body: unknown;
547
+ }
548
+ export const GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetResponse =
549
+ /*@__PURE__*/ S.suspend(() =>
550
+ S.Struct({
551
+ body: S.Unknown,
552
+ }),
553
+ ).annotate({
554
+ identifier:
555
+ "GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetResponse",
556
+ }) as any as S.Schema<GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetResponse>;
557
+
558
+ export interface ListPoliciesPoliciesListGetRequest {
559
+ version_status?: string;
560
+ }
561
+ export const ListPoliciesPoliciesListGetRequest = /*@__PURE__*/ S.suspend(() =>
562
+ S.Struct({
563
+ version_status: S.optional(S.String.pipe(T.Query())),
564
+ }).pipe(T.Http({ method: "GET", uri: "/policies/list", code: 200 })),
565
+ ).annotate({
566
+ identifier: "ListPoliciesPoliciesListGetRequest",
567
+ }) as any as S.Schema<ListPoliciesPoliciesListGetRequest>;
568
+
569
+ /** List of policies. */
570
+ export type PolicyListDBResponsePoliciesList = Array<PolicyDBResponse>;
571
+ export const PolicyListDBResponsePoliciesList = /*@__PURE__*/ S.Array(
572
+ PolicyDBResponse,
573
+ ) as any as S.Schema<PolicyListDBResponsePoliciesList>;
574
+
575
+ /** Response for listing policies from the database. */
576
+ export interface PolicyListDBResponse {
577
+ /** List of policies. */
578
+ policies?: PolicyListDBResponsePoliciesList;
579
+ /** Total number of policies. */
580
+ total_count?: number;
581
+ }
582
+ export const PolicyListDBResponse = /*@__PURE__*/ S.suspend(() =>
583
+ S.Struct({
584
+ policies: S.optional(PolicyListDBResponsePoliciesList),
585
+ total_count: S.optional(S.Number),
586
+ }),
587
+ ).annotate({
588
+ identifier: "PolicyListDBResponse",
589
+ }) as any as S.Schema<PolicyListDBResponse>;
590
+
591
+ export interface ListPolicyAttachmentsPoliciesAttachmentsListGetRequest {}
592
+ export const ListPolicyAttachmentsPoliciesAttachmentsListGetRequest =
593
+ /*@__PURE__*/ S.suspend(() =>
594
+ S.Struct({}).pipe(
595
+ T.Http({ method: "GET", uri: "/policies/attachments/list", code: 200 }),
596
+ ),
597
+ ).annotate({
598
+ identifier: "ListPolicyAttachmentsPoliciesAttachmentsListGetRequest",
599
+ }) as any as S.Schema<ListPolicyAttachmentsPoliciesAttachmentsListGetRequest>;
600
+
601
+ /** List of policy attachments. */
602
+ export type PolicyAttachmentListResponseAttachmentsList =
603
+ Array<PolicyAttachmentDBResponse>;
604
+ export const PolicyAttachmentListResponseAttachmentsList =
605
+ /*@__PURE__*/ S.Array(
606
+ PolicyAttachmentDBResponse,
607
+ ) as any as S.Schema<PolicyAttachmentListResponseAttachmentsList>;
608
+
609
+ /** Response for listing policy attachments. */
610
+ export interface PolicyAttachmentListResponse {
611
+ /** List of policy attachments. */
612
+ attachments?: PolicyAttachmentListResponseAttachmentsList;
613
+ /** Total number of attachments. */
614
+ total_count?: number;
615
+ }
616
+ export const PolicyAttachmentListResponse = /*@__PURE__*/ S.suspend(() =>
617
+ S.Struct({
618
+ attachments: S.optional(PolicyAttachmentListResponseAttachmentsList),
619
+ total_count: S.optional(S.Number),
620
+ }),
621
+ ).annotate({
622
+ identifier: "PolicyAttachmentListResponse",
623
+ }) as any as S.Schema<PolicyAttachmentListResponse>;
624
+
625
+ export interface ListPolicyVersionsPoliciesNamePolicyNameVersionsGetRequest {
626
+ policy_name: string;
627
+ }
628
+ export const ListPolicyVersionsPoliciesNamePolicyNameVersionsGetRequest =
629
+ /*@__PURE__*/ S.suspend(() =>
630
+ S.Struct({
631
+ policy_name: S.String.pipe(T.Label()),
632
+ }).pipe(
633
+ T.Http({
634
+ method: "GET",
635
+ uri: "/policies/name/{policy_name}/versions",
636
+ code: 200,
637
+ }),
638
+ ),
639
+ ).annotate({
640
+ identifier: "ListPolicyVersionsPoliciesNamePolicyNameVersionsGetRequest",
641
+ }) as any as S.Schema<ListPolicyVersionsPoliciesNamePolicyNameVersionsGetRequest>;
642
+
643
+ /** All versions ordered by version_number desc. */
644
+ export type PolicyVersionListResponseVersionsList = Array<PolicyDBResponse>;
645
+ export const PolicyVersionListResponseVersionsList = /*@__PURE__*/ S.Array(
646
+ PolicyDBResponse,
647
+ ) as any as S.Schema<PolicyVersionListResponseVersionsList>;
648
+
649
+ /** Response for listing all versions of a policy. */
650
+ export interface PolicyVersionListResponse {
651
+ /** Name of the policy. */
652
+ policy_name: string;
653
+ /** Total number of versions. */
654
+ total_count?: number;
655
+ /** All versions ordered by version_number desc. */
656
+ versions?: PolicyVersionListResponseVersionsList;
657
+ }
658
+ export const PolicyVersionListResponse = /*@__PURE__*/ S.suspend(() =>
659
+ S.Struct({
660
+ policy_name: S.String,
661
+ total_count: S.optional(S.Number),
662
+ versions: S.optional(PolicyVersionListResponseVersionsList),
663
+ }),
664
+ ).annotate({
665
+ identifier: "PolicyVersionListResponse",
666
+ }) as any as S.Schema<PolicyVersionListResponse>;
667
+
668
+ export type PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestKeysList =
669
+ Array<string>;
670
+ export const PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestKeysList =
671
+ /*@__PURE__*/ S.Array(
672
+ S.String,
673
+ ) as any as S.Schema<PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestKeysList>;
674
+
675
+ export type PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestModelsList =
676
+ Array<string>;
677
+ export const PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestModelsList =
678
+ /*@__PURE__*/ S.Array(
679
+ S.String,
680
+ ) as any as S.Schema<PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestModelsList>;
681
+
682
+ export type PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestTagsList =
683
+ Array<string>;
684
+ export const PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestTagsList =
685
+ /*@__PURE__*/ S.Array(
686
+ S.String,
687
+ ) as any as S.Schema<PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestTagsList>;
688
+
689
+ export type PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestTeamsList =
690
+ Array<string>;
691
+ export const PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestTeamsList =
692
+ /*@__PURE__*/ S.Array(
693
+ S.String,
694
+ ) as any as S.Schema<PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestTeamsList>;
695
+
696
+ export interface PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequest {
697
+ /** Key aliases or patterns this attachment applies to. */
698
+ keys?: PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestKeysList | null;
699
+ /** Model names or patterns this attachment applies to. */
700
+ models?: PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestModelsList | null;
701
+ /** Name of the policy to attach. */
702
+ policy_name: string;
703
+ /** Use '*' for global scope (applies to all requests). */
704
+ scope?: string | null;
705
+ /** Tag patterns this attachment applies to. Supports wildcards (e.g., health-*). */
706
+ tags?: PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestTagsList | null;
707
+ /** Team aliases or patterns this attachment applies to. */
708
+ teams?: PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestTeamsList | null;
709
+ }
710
+ export const PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequest =
711
+ /*@__PURE__*/ S.suspend(() =>
712
+ S.Struct({
713
+ keys: S.optional(
714
+ S.NullOr(
715
+ PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestKeysList,
716
+ ),
717
+ ),
718
+ models: S.optional(
719
+ S.NullOr(
720
+ PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestModelsList,
721
+ ),
722
+ ),
723
+ policy_name: S.String,
724
+ scope: S.optional(S.NullOr(S.String)),
725
+ tags: S.optional(
726
+ S.NullOr(
727
+ PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestTagsList,
728
+ ),
729
+ ),
730
+ teams: S.optional(
731
+ S.NullOr(
732
+ PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequestTeamsList,
733
+ ),
734
+ ),
735
+ }).pipe(
736
+ T.Http({
737
+ method: "POST",
738
+ uri: "/policies/attachments/estimate-impact",
739
+ code: 200,
740
+ }),
741
+ ),
742
+ ).annotate({
743
+ identifier:
744
+ "PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequest",
745
+ }) as any as S.Schema<PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequest>;
746
+
747
+ /** Sample of affected key aliases (up to 10). */
748
+ export type AttachmentImpactResponseSampleKeysList = Array<string>;
749
+ export const AttachmentImpactResponseSampleKeysList = /*@__PURE__*/ S.Array(
750
+ S.String,
751
+ ) as any as S.Schema<AttachmentImpactResponseSampleKeysList>;
752
+
753
+ /** Sample of affected team aliases (up to 10). */
754
+ export type AttachmentImpactResponseSampleTeamsList = Array<string>;
755
+ export const AttachmentImpactResponseSampleTeamsList = /*@__PURE__*/ S.Array(
756
+ S.String,
757
+ ) as any as S.Schema<AttachmentImpactResponseSampleTeamsList>;
758
+
759
+ /** Response for estimating the impact of a policy attachment. */
760
+ export interface AttachmentImpactResponse {
761
+ /** Number of keys that would be affected (named + unnamed). */
762
+ affected_keys_count?: number;
763
+ /** Number of teams that would be affected (named + unnamed). */
764
+ affected_teams_count?: number;
765
+ /** Sample of affected key aliases (up to 10). */
766
+ sample_keys?: AttachmentImpactResponseSampleKeysList;
767
+ /** Sample of affected team aliases (up to 10). */
768
+ sample_teams?: AttachmentImpactResponseSampleTeamsList;
769
+ /** Number of affected keys without an alias. */
770
+ unnamed_keys_count?: number;
771
+ /** Number of affected teams without an alias. */
772
+ unnamed_teams_count?: number;
773
+ }
774
+ export const AttachmentImpactResponse = /*@__PURE__*/ S.suspend(() =>
775
+ S.Struct({
776
+ affected_keys_count: S.optional(S.Number),
777
+ affected_teams_count: S.optional(S.Number),
778
+ sample_keys: S.optional(AttachmentImpactResponseSampleKeysList),
779
+ sample_teams: S.optional(AttachmentImpactResponseSampleTeamsList),
780
+ unnamed_keys_count: S.optional(S.Number),
781
+ unnamed_teams_count: S.optional(S.Number),
782
+ }),
783
+ ).annotate({
784
+ identifier: "AttachmentImpactResponse",
785
+ }) as any as S.Schema<AttachmentImpactResponse>;
786
+
787
+ export type PostResolvePoliciesForContextPoliciesResolveRequestTagsList =
788
+ Array<string>;
789
+ export const PostResolvePoliciesForContextPoliciesResolveRequestTagsList =
790
+ /*@__PURE__*/ S.Array(
791
+ S.String,
792
+ ) as any as S.Schema<PostResolvePoliciesForContextPoliciesResolveRequestTagsList>;
793
+
794
+ export interface PostResolvePoliciesForContextPoliciesResolveRequest {
795
+ /** Force a DB sync before resolving. Default uses in-memory cache. */
796
+ force_sync?: boolean;
797
+ /** Key alias to resolve for. */
798
+ key_alias?: string | null;
799
+ /** Model name to resolve for. */
800
+ model?: string | null;
801
+ /** Tags to resolve for. */
802
+ tags?: PostResolvePoliciesForContextPoliciesResolveRequestTagsList | null;
803
+ /** Team alias to resolve for. */
804
+ team_alias?: string | null;
805
+ }
806
+ export const PostResolvePoliciesForContextPoliciesResolveRequest =
807
+ /*@__PURE__*/ S.suspend(() =>
808
+ S.Struct({
809
+ force_sync: S.optional(S.Boolean.pipe(T.Query())),
810
+ key_alias: S.optional(S.NullOr(S.String)),
811
+ model: S.optional(S.NullOr(S.String)),
812
+ tags: S.optional(
813
+ S.NullOr(PostResolvePoliciesForContextPoliciesResolveRequestTagsList),
814
+ ),
815
+ team_alias: S.optional(S.NullOr(S.String)),
816
+ }).pipe(T.Http({ method: "POST", uri: "/policies/resolve", code: 200 })),
817
+ ).annotate({
818
+ identifier: "PostResolvePoliciesForContextPoliciesResolveRequest",
819
+ }) as any as S.Schema<PostResolvePoliciesForContextPoliciesResolveRequest>;
820
+
821
+ /** Final list of guardrails that would be applied. */
822
+ export type PolicyResolveResponseEffectiveGuardrailsList = Array<string>;
823
+ export const PolicyResolveResponseEffectiveGuardrailsList =
824
+ /*@__PURE__*/ S.Array(
825
+ S.String,
826
+ ) as any as S.Schema<PolicyResolveResponseEffectiveGuardrailsList>;
827
+
828
+ /** Guardrails this policy contributes. */
829
+ export type PolicyMatchDetailGuardrailsAddedList = Array<string>;
830
+ export const PolicyMatchDetailGuardrailsAddedList = /*@__PURE__*/ S.Array(
831
+ S.String,
832
+ ) as any as S.Schema<PolicyMatchDetailGuardrailsAddedList>;
833
+
834
+ /** Details about why a specific policy matched. */
835
+ export interface PolicyMatchDetail {
836
+ /** Guardrails this policy contributes. */
837
+ guardrails_added?: PolicyMatchDetailGuardrailsAddedList;
838
+ /** How the policy was matched (e.g., 'tag:healthcare', 'team:health-team', 'scope:*'). */
839
+ matched_via: string;
840
+ /** Name of the matched policy. */
841
+ policy_name: string;
842
+ }
843
+ export const PolicyMatchDetail = /*@__PURE__*/ S.suspend(() =>
844
+ S.Struct({
845
+ guardrails_added: S.optional(PolicyMatchDetailGuardrailsAddedList),
846
+ matched_via: S.String,
847
+ policy_name: S.String,
848
+ }),
849
+ ).annotate({
850
+ identifier: "PolicyMatchDetail",
851
+ }) as any as S.Schema<PolicyMatchDetail>;
852
+
853
+ /** Details about each matched policy and why it matched. */
854
+ export type PolicyResolveResponseMatchedPoliciesList = Array<PolicyMatchDetail>;
855
+ export const PolicyResolveResponseMatchedPoliciesList = /*@__PURE__*/ S.Array(
856
+ PolicyMatchDetail,
857
+ ) as any as S.Schema<PolicyResolveResponseMatchedPoliciesList>;
858
+
859
+ /** Response for resolving effective policies/guardrails for a context. */
860
+ export interface PolicyResolveResponse {
861
+ /** Final list of guardrails that would be applied. */
862
+ effective_guardrails?: PolicyResolveResponseEffectiveGuardrailsList;
863
+ /** Details about each matched policy and why it matched. */
864
+ matched_policies?: PolicyResolveResponseMatchedPoliciesList;
865
+ }
866
+ export const PolicyResolveResponse = /*@__PURE__*/ S.suspend(() =>
867
+ S.Struct({
868
+ effective_guardrails: S.optional(
869
+ PolicyResolveResponseEffectiveGuardrailsList,
870
+ ),
871
+ matched_policies: S.optional(PolicyResolveResponseMatchedPoliciesList),
872
+ }),
873
+ ).annotate({
874
+ identifier: "PolicyResolveResponse",
875
+ }) as any as S.Schema<PolicyResolveResponse>;
876
+
877
+ /** Pipeline definition with 'mode' and 'steps'. */
878
+ export type PostTestPipelinePoliciesTestPipelineRequestPipelineMap = {
879
+ [key: string]: unknown | undefined;
880
+ };
881
+ export const PostTestPipelinePoliciesTestPipelineRequestPipelineMap =
882
+ /*@__PURE__*/ S.Record(
883
+ S.String,
884
+ S.Unknown,
885
+ ) as any as S.Schema<PostTestPipelinePoliciesTestPipelineRequestPipelineMap>;
886
+
887
+ export type PostTestPipelinePoliciesTestPipelineRequestTestMessagesItemMap = {
888
+ [key: string]: string | undefined;
889
+ };
890
+ export const PostTestPipelinePoliciesTestPipelineRequestTestMessagesItemMap =
891
+ /*@__PURE__*/ S.Record(
892
+ S.String,
893
+ S.String,
894
+ ) as any as S.Schema<PostTestPipelinePoliciesTestPipelineRequestTestMessagesItemMap>;
895
+
896
+ /** Test messages to run through the pipeline, e.g. [{'role': 'user', 'content': '...'}]. */
897
+ export type PostTestPipelinePoliciesTestPipelineRequestTestMessagesList =
898
+ Array<PostTestPipelinePoliciesTestPipelineRequestTestMessagesItemMap>;
899
+ export const PostTestPipelinePoliciesTestPipelineRequestTestMessagesList =
900
+ /*@__PURE__*/ S.Array(
901
+ PostTestPipelinePoliciesTestPipelineRequestTestMessagesItemMap,
902
+ ) as any as S.Schema<PostTestPipelinePoliciesTestPipelineRequestTestMessagesList>;
903
+
904
+ export interface PostTestPipelinePoliciesTestPipelineRequest {
905
+ /** Pipeline definition with 'mode' and 'steps'. */
906
+ pipeline: PostTestPipelinePoliciesTestPipelineRequestPipelineMap;
907
+ /** Test messages to run through the pipeline, e.g. [{'role': 'user', 'content': '...'}]. */
908
+ test_messages: PostTestPipelinePoliciesTestPipelineRequestTestMessagesList;
909
+ }
910
+ export const PostTestPipelinePoliciesTestPipelineRequest =
911
+ /*@__PURE__*/ S.suspend(() =>
912
+ S.Struct({
913
+ pipeline: PostTestPipelinePoliciesTestPipelineRequestPipelineMap,
914
+ test_messages:
915
+ PostTestPipelinePoliciesTestPipelineRequestTestMessagesList,
916
+ }).pipe(
917
+ T.Http({ method: "POST", uri: "/policies/test-pipeline", code: 200 }),
918
+ ),
919
+ ).annotate({
920
+ identifier: "PostTestPipelinePoliciesTestPipelineRequest",
921
+ }) as any as S.Schema<PostTestPipelinePoliciesTestPipelineRequest>;
922
+
923
+ export interface PostTestPipelinePoliciesTestPipelineResponse {
924
+ body: unknown;
925
+ }
926
+ export const PostTestPipelinePoliciesTestPipelineResponse =
927
+ /*@__PURE__*/ S.suspend(() =>
928
+ S.Struct({
929
+ body: S.Unknown,
930
+ }),
931
+ ).annotate({
932
+ identifier: "PostTestPipelinePoliciesTestPipelineResponse",
933
+ }) as any as S.Schema<PostTestPipelinePoliciesTestPipelineResponse>;
934
+
935
+ export type UpdatePolicyPoliciesPolicyIdPutRequestGuardrailsAddList =
936
+ Array<string>;
937
+ export const UpdatePolicyPoliciesPolicyIdPutRequestGuardrailsAddList =
938
+ /*@__PURE__*/ S.Array(
939
+ S.String,
940
+ ) as any as S.Schema<UpdatePolicyPoliciesPolicyIdPutRequestGuardrailsAddList>;
941
+
942
+ export type UpdatePolicyPoliciesPolicyIdPutRequestGuardrailsRemoveList =
943
+ Array<string>;
944
+ export const UpdatePolicyPoliciesPolicyIdPutRequestGuardrailsRemoveList =
945
+ /*@__PURE__*/ S.Array(
946
+ S.String,
947
+ ) as any as S.Schema<UpdatePolicyPoliciesPolicyIdPutRequestGuardrailsRemoveList>;
948
+
949
+ export type UpdatePolicyPoliciesPolicyIdPutRequestPipelineMap = {
950
+ [key: string]: unknown | undefined;
951
+ };
952
+ export const UpdatePolicyPoliciesPolicyIdPutRequestPipelineMap =
953
+ /*@__PURE__*/ S.Record(
954
+ S.String,
955
+ S.Unknown,
956
+ ) as any as S.Schema<UpdatePolicyPoliciesPolicyIdPutRequestPipelineMap>;
957
+
958
+ export interface UpdatePolicyPoliciesPolicyIdPutRequest {
959
+ policy_id: string;
960
+ /** Condition for when this policy applies. */
961
+ condition?: PolicyConditionRequest | null;
962
+ /** Human-readable description of the policy. */
963
+ description?: string | null;
964
+ /** List of guardrail names to add. */
965
+ guardrails_add?: UpdatePolicyPoliciesPolicyIdPutRequestGuardrailsAddList | null;
966
+ /** List of guardrail names to remove (from inherited). */
967
+ guardrails_remove?: UpdatePolicyPoliciesPolicyIdPutRequestGuardrailsRemoveList | null;
968
+ /** Name of parent policy to inherit from. */
969
+ inherit?: string | null;
970
+ /** Optional guardrail pipeline for ordered execution. Contains 'mode' and 'steps'. */
971
+ pipeline?: UpdatePolicyPoliciesPolicyIdPutRequestPipelineMap | null;
972
+ /** New name for the policy. */
973
+ policy_name?: string | null;
974
+ }
975
+ export const UpdatePolicyPoliciesPolicyIdPutRequest = /*@__PURE__*/ S.suspend(
976
+ () =>
977
+ S.Struct({
978
+ policy_id: S.String.pipe(T.Label()),
979
+ condition: S.optional(S.NullOr(PolicyConditionRequest)),
980
+ description: S.optional(S.NullOr(S.String)),
981
+ guardrails_add: S.optional(
982
+ S.NullOr(UpdatePolicyPoliciesPolicyIdPutRequestGuardrailsAddList),
983
+ ),
984
+ guardrails_remove: S.optional(
985
+ S.NullOr(UpdatePolicyPoliciesPolicyIdPutRequestGuardrailsRemoveList),
986
+ ),
987
+ inherit: S.optional(S.NullOr(S.String)),
988
+ pipeline: S.optional(
989
+ S.NullOr(UpdatePolicyPoliciesPolicyIdPutRequestPipelineMap),
990
+ ),
991
+ policy_name: S.optional(S.NullOr(S.String)),
992
+ }).pipe(T.Http({ method: "PUT", uri: "/policies/{policy_id}", code: 200 })),
993
+ ).annotate({
994
+ identifier: "UpdatePolicyPoliciesPolicyIdPutRequest",
995
+ }) as any as S.Schema<UpdatePolicyPoliciesPolicyIdPutRequest>;
996
+
997
+ export interface UpdatePolicyVersionStatusPoliciesPolicyIdStatusPutRequest {
998
+ policy_id: string;
999
+ /** New status: 'published' or 'production'. */
1000
+ version_status: string;
1001
+ }
1002
+ export const UpdatePolicyVersionStatusPoliciesPolicyIdStatusPutRequest =
1003
+ /*@__PURE__*/ S.suspend(() =>
1004
+ S.Struct({
1005
+ policy_id: S.String.pipe(T.Label()),
1006
+ version_status: S.String,
1007
+ }).pipe(
1008
+ T.Http({ method: "PUT", uri: "/policies/{policy_id}/status", code: 200 }),
1009
+ ),
1010
+ ).annotate({
1011
+ identifier: "UpdatePolicyVersionStatusPoliciesPolicyIdStatusPutRequest",
1012
+ }) as any as S.Schema<UpdatePolicyVersionStatusPoliciesPolicyIdStatusPutRequest>;
1013
+
1014
+ export type CreatePolicyAttachmentPoliciesAttachmentsPostError =
1015
+ | UnprocessableEntity
1016
+ | LitellmOpError;
1017
+ /** Create Policy Attachment Create a new policy attachment. Example Request: ```bash curl -X POST "http://localhost:4000/policies/attachments" \ -H "Authorization: Bearer <your_api_key>" \ -H "Content-Type: application/json" \ -d '{ "policy_name": "global-baseline", "scope": "*" }' ``` Example with team-specific attachment: ```bash curl -X POST "http://localhost:4000/policies/attachments" \ -H "Authorization: Bearer <your_api_key>" \ -H "Content-Type: application/json" \ -d '{ "policy_name": "healthcare-compliance", "teams": ["healthcare-team", "medical-research"] }' ``` Example Response: ```json { "attachment_id": "123e4567-e89b-12d3-a456-426614174000", "policy_name": "global-baseline", "scope": "*", "teams": [], "keys": [], "models": [], "created_at": "2024-01-01T00:00:00Z", "updated_at": "2024-01-01T00:00:00Z" } ``` */
1018
+ export const createPolicyAttachmentPoliciesAttachmentsPost: API.OperationMethod<
1019
+ CreatePolicyAttachmentPoliciesAttachmentsPostRequest,
1020
+ PolicyAttachmentDBResponse,
1021
+ CreatePolicyAttachmentPoliciesAttachmentsPostError,
1022
+ LitellmOpContext
1023
+ > = /*@__PURE__*/ API.make(() => ({
1024
+ input: CreatePolicyAttachmentPoliciesAttachmentsPostRequest,
1025
+ output: PolicyAttachmentDBResponse,
1026
+ errors: [UnprocessableEntity],
1027
+ protocol: LitellmProtocol,
1028
+ retry: Retry.Retry,
1029
+ }));
1030
+
1031
+ export type CreatePolicyPoliciesPostError =
1032
+ | UnprocessableEntity
1033
+ | LitellmOpError;
1034
+ /** Create Policy Create a new policy. Example Request: ```bash curl -X POST "http://localhost:4000/policies" \ -H "Authorization: Bearer <your_api_key>" \ -H "Content-Type: application/json" \ -d '{ "policy_name": "global-baseline", "description": "Base guardrails for all requests", "guardrails_add": ["pii_masking", "prompt_injection"], "guardrails_remove": [] }' ``` Example Response: ```json { "policy_id": "123e4567-e89b-12d3-a456-426614174000", "policy_name": "global-baseline", "inherit": null, "description": "Base guardrails for all requests", "guardrails_add": ["pii_masking", "prompt_injection"], "guardrails_remove": [], "condition": null, "created_at": "2024-01-01T00:00:00Z", "updated_at": "2024-01-01T00:00:00Z" } ``` */
1035
+ export const createPolicyPoliciesPost: API.OperationMethod<
1036
+ CreatePolicyPoliciesPostRequest,
1037
+ PolicyDBResponse,
1038
+ CreatePolicyPoliciesPostError,
1039
+ LitellmOpContext
1040
+ > = /*@__PURE__*/ API.make(() => ({
1041
+ input: CreatePolicyPoliciesPostRequest,
1042
+ output: PolicyDBResponse,
1043
+ errors: [UnprocessableEntity],
1044
+ protocol: LitellmProtocol,
1045
+ retry: Retry.Retry,
1046
+ }));
1047
+
1048
+ export type CreatePolicyVersionPoliciesNamePolicyNameVersionsPostError =
1049
+ | UnprocessableEntity
1050
+ | LitellmOpError;
1051
+ /** Create Policy Version Create a new draft version of a policy. Copies all fields from the source. Source is current production if source_policy_id is not provided. */
1052
+ export const createPolicyVersionPoliciesNamePolicyNameVersionsPost: API.OperationMethod<
1053
+ CreatePolicyVersionPoliciesNamePolicyNameVersionsPostRequest,
1054
+ PolicyDBResponse,
1055
+ CreatePolicyVersionPoliciesNamePolicyNameVersionsPostError,
1056
+ LitellmOpContext
1057
+ > = /*@__PURE__*/ API.make(() => ({
1058
+ input: CreatePolicyVersionPoliciesNamePolicyNameVersionsPostRequest,
1059
+ output: PolicyDBResponse,
1060
+ errors: [UnprocessableEntity],
1061
+ protocol: LitellmProtocol,
1062
+ retry: Retry.Retry,
1063
+ }));
1064
+
1065
+ export type DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteError =
1066
+ | UnprocessableEntity
1067
+ | LitellmOpError;
1068
+ /** Delete All Policy Versions Delete all versions of a policy. Also removes from in-memory registry. */
1069
+ export const deleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDelete: API.OperationMethod<
1070
+ DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteRequest,
1071
+ DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteResponse,
1072
+ DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteError,
1073
+ LitellmOpContext
1074
+ > = /*@__PURE__*/ API.make(() => ({
1075
+ input: DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteRequest,
1076
+ output:
1077
+ DeleteAllPolicyVersionsPoliciesNamePolicyNameAllVersionsDeleteResponse,
1078
+ errors: [UnprocessableEntity],
1079
+ protocol: LitellmProtocol,
1080
+ retry: Retry.Retry,
1081
+ }));
1082
+
1083
+ export type DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteError =
1084
+ | UnprocessableEntity
1085
+ | LitellmOpError;
1086
+ /** Delete Policy Attachment Delete a policy attachment. Example Request: ```bash curl -X DELETE "http://localhost:4000/policies/attachments/123e4567-e89b-12d3-a456-426614174000" \ -H "Authorization: Bearer <your_api_key>" ``` Example Response: ```json { "message": "Attachment 123e4567-e89b-12d3-a456-426614174000 deleted successfully" } ``` */
1087
+ export const deletePolicyAttachmentPoliciesAttachmentsAttachmentIdDelete: API.OperationMethod<
1088
+ DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteRequest,
1089
+ DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteResponse,
1090
+ DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteError,
1091
+ LitellmOpContext
1092
+ > = /*@__PURE__*/ API.make(() => ({
1093
+ input: DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteRequest,
1094
+ output: DeletePolicyAttachmentPoliciesAttachmentsAttachmentIdDeleteResponse,
1095
+ errors: [UnprocessableEntity],
1096
+ protocol: LitellmProtocol,
1097
+ retry: Retry.Retry,
1098
+ }));
1099
+
1100
+ export type DeletePolicyPoliciesPolicyIdDeleteError =
1101
+ | UnprocessableEntity
1102
+ | LitellmOpError;
1103
+ /** Delete Policy Delete a policy. Example Request: ```bash curl -X DELETE "http://localhost:4000/policies/123e4567-e89b-12d3-a456-426614174000" \ -H "Authorization: Bearer <your_api_key>" ``` Example Response: ```json { "message": "Policy 123e4567-e89b-12d3-a456-426614174000 deleted successfully" } ``` */
1104
+ export const deletePolicyPoliciesPolicyIdDelete: API.OperationMethod<
1105
+ DeletePolicyPoliciesPolicyIdDeleteRequest,
1106
+ DeletePolicyPoliciesPolicyIdDeleteResponse,
1107
+ DeletePolicyPoliciesPolicyIdDeleteError,
1108
+ LitellmOpContext
1109
+ > = /*@__PURE__*/ API.make(() => ({
1110
+ input: DeletePolicyPoliciesPolicyIdDeleteRequest,
1111
+ output: DeletePolicyPoliciesPolicyIdDeleteResponse,
1112
+ errors: [UnprocessableEntity],
1113
+ protocol: LitellmProtocol,
1114
+ retry: Retry.Retry,
1115
+ }));
1116
+
1117
+ export type GetComparePolicyVersionsPoliciesCompareError =
1118
+ | UnprocessableEntity
1119
+ | LitellmOpError;
1120
+ /** Compare Policy Versions Compare two policy versions. Query params: version_a, version_b (policy version IDs). */
1121
+ export const getComparePolicyVersionsPoliciesCompare: API.OperationMethod<
1122
+ GetComparePolicyVersionsPoliciesCompareRequest,
1123
+ PolicyVersionCompareResponse,
1124
+ GetComparePolicyVersionsPoliciesCompareError,
1125
+ LitellmOpContext
1126
+ > = /*@__PURE__*/ API.make(() => ({
1127
+ input: GetComparePolicyVersionsPoliciesCompareRequest,
1128
+ output: PolicyVersionCompareResponse,
1129
+ errors: [UnprocessableEntity],
1130
+ protocol: LitellmProtocol,
1131
+ retry: Retry.Retry,
1132
+ }));
1133
+
1134
+ export type GetPolicyAttachmentPoliciesAttachmentsAttachmentIdGetError =
1135
+ | UnprocessableEntity
1136
+ | LitellmOpError;
1137
+ /** Get Policy Attachment Get a policy attachment by ID. Example Request: ```bash curl -X GET "http://localhost:4000/policies/attachments/123e4567-e89b-12d3-a456-426614174000" \ -H "Authorization: Bearer <your_api_key>" ``` */
1138
+ export const getPolicyAttachmentPoliciesAttachmentsAttachmentIdGet: API.OperationMethod<
1139
+ GetPolicyAttachmentPoliciesAttachmentsAttachmentIdGetRequest,
1140
+ PolicyAttachmentDBResponse,
1141
+ GetPolicyAttachmentPoliciesAttachmentsAttachmentIdGetError,
1142
+ LitellmOpContext
1143
+ > = /*@__PURE__*/ API.make(() => ({
1144
+ input: GetPolicyAttachmentPoliciesAttachmentsAttachmentIdGetRequest,
1145
+ output: PolicyAttachmentDBResponse,
1146
+ errors: [UnprocessableEntity],
1147
+ protocol: LitellmProtocol,
1148
+ retry: Retry.Retry,
1149
+ }));
1150
+
1151
+ export type GetPolicyPoliciesPolicyIdGetError =
1152
+ | UnprocessableEntity
1153
+ | LitellmOpError;
1154
+ /** Get Policy Get a policy by ID. Example Request: ```bash curl -X GET "http://localhost:4000/policies/123e4567-e89b-12d3-a456-426614174000" \ -H "Authorization: Bearer <your_api_key>" ``` */
1155
+ export const getPolicyPoliciesPolicyIdGet: API.OperationMethod<
1156
+ GetPolicyPoliciesPolicyIdGetRequest,
1157
+ PolicyDBResponse,
1158
+ GetPolicyPoliciesPolicyIdGetError,
1159
+ LitellmOpContext
1160
+ > = /*@__PURE__*/ API.make(() => ({
1161
+ input: GetPolicyPoliciesPolicyIdGetRequest,
1162
+ output: PolicyDBResponse,
1163
+ errors: [UnprocessableEntity],
1164
+ protocol: LitellmProtocol,
1165
+ retry: Retry.Retry,
1166
+ }));
1167
+
1168
+ export type GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetError =
1169
+ | UnprocessableEntity
1170
+ | LitellmOpError;
1171
+ /** Get Resolved Guardrails Get the resolved guardrails for a policy (including inherited guardrails). This endpoint resolves the full inheritance chain and returns the final set of guardrails that would be applied for this policy. Example Request: ```bash curl -X GET "http://localhost:4000/policies/123e4567-e89b-12d3-a456-426614174000/resolved-guardrails" \ -H "Authorization: Bearer <your_api_key>" ``` Example Response: ```json { "policy_id": "123e4567-e89b-12d3-a456-426614174000", "policy_name": "healthcare-compliance", "resolved_guardrails": ["pii_masking", "prompt_injection", "toxicity_filter"] } ``` */
1172
+ export const getResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGet: API.OperationMethod<
1173
+ GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetRequest,
1174
+ GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetResponse,
1175
+ GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetError,
1176
+ LitellmOpContext
1177
+ > = /*@__PURE__*/ API.make(() => ({
1178
+ input: GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetRequest,
1179
+ output: GetResolvedGuardrailsPoliciesPolicyIdResolvedGuardrailsGetResponse,
1180
+ errors: [UnprocessableEntity],
1181
+ protocol: LitellmProtocol,
1182
+ retry: Retry.Retry,
1183
+ }));
1184
+
1185
+ export type ListPoliciesPoliciesListGetError =
1186
+ | UnprocessableEntity
1187
+ | LitellmOpError;
1188
+ /** List Policies List all policies from the database and config.yaml. Optionally filter by version_status. Config-defined policies are returned with definition_location "config" and are treated as production versions. On a name conflict with a production DB policy, only the DB policy is returned, mirroring runtime resolution where only production DB versions override config. A draft or published DB version does not hide the config policy, since the config version is still the one being enforced. Query params: - version_status: Optional. One of "draft", "published", "production". If omitted, all versions are returned. Example Request: ```bash curl -X GET "http://localhost:4000/policies/list" \ -H "Authorization: Bearer <your_api_key>" curl -X GET "http://localhost:4000/policies/list?version_status=production" \ -H "Authorization: Bearer <your_api_key>" ``` Example Response: ```json { "policies": [ { "policy_id": "123e4567-e89b-12d3-a456-426614174000", "policy_name": "global-baseline", "version_number": 1, "version_status": "production", "inherit": null, "description": "Base guardrails for all requests", "guardrails_add": ["pii_masking"], "guardrails_remove": [], "condition": null, "created_at": "2024-01-01T00:00:00Z", "updated_at": "2024-01-01T00:00:00Z" } ], "total_count": 1 } ``` */
1189
+ export const listPoliciesPoliciesListGet: API.OperationMethod<
1190
+ ListPoliciesPoliciesListGetRequest,
1191
+ PolicyListDBResponse,
1192
+ ListPoliciesPoliciesListGetError,
1193
+ LitellmOpContext
1194
+ > = /*@__PURE__*/ API.make(() => ({
1195
+ input: ListPoliciesPoliciesListGetRequest,
1196
+ output: PolicyListDBResponse,
1197
+ errors: [UnprocessableEntity],
1198
+ protocol: LitellmProtocol,
1199
+ retry: Retry.Retry,
1200
+ }));
1201
+
1202
+ export type ListPolicyAttachmentsPoliciesAttachmentsListGetError =
1203
+ LitellmOpError;
1204
+ /** List Policy Attachments List all policy attachments from the database and config.yaml. Config-defined attachments are returned with definition_location "config" and a synthetic attachment_id ("config-<index>"). Example Request: ```bash curl -X GET "http://localhost:4000/policies/attachments/list" \ -H "Authorization: Bearer <your_api_key>" ``` Example Response: ```json { "attachments": [ { "attachment_id": "123e4567-e89b-12d3-a456-426614174000", "policy_name": "global-baseline", "scope": "*", "teams": [], "keys": [], "models": [], "created_at": "2024-01-01T00:00:00Z", "updated_at": "2024-01-01T00:00:00Z" } ], "total_count": 1 } ``` */
1205
+ export const listPolicyAttachmentsPoliciesAttachmentsListGet: API.OperationMethod<
1206
+ ListPolicyAttachmentsPoliciesAttachmentsListGetRequest,
1207
+ PolicyAttachmentListResponse,
1208
+ ListPolicyAttachmentsPoliciesAttachmentsListGetError,
1209
+ LitellmOpContext
1210
+ > = /*@__PURE__*/ API.make(() => ({
1211
+ input: ListPolicyAttachmentsPoliciesAttachmentsListGetRequest,
1212
+ output: PolicyAttachmentListResponse,
1213
+ errors: [],
1214
+ protocol: LitellmProtocol,
1215
+ retry: Retry.Retry,
1216
+ }));
1217
+
1218
+ export type ListPolicyVersionsPoliciesNamePolicyNameVersionsGetError =
1219
+ | UnprocessableEntity
1220
+ | LitellmOpError;
1221
+ /** List Policy Versions List all versions of a policy by name, ordered by version_number descending. */
1222
+ export const listPolicyVersionsPoliciesNamePolicyNameVersionsGet: API.OperationMethod<
1223
+ ListPolicyVersionsPoliciesNamePolicyNameVersionsGetRequest,
1224
+ PolicyVersionListResponse,
1225
+ ListPolicyVersionsPoliciesNamePolicyNameVersionsGetError,
1226
+ LitellmOpContext
1227
+ > = /*@__PURE__*/ API.make(() => ({
1228
+ input: ListPolicyVersionsPoliciesNamePolicyNameVersionsGetRequest,
1229
+ output: PolicyVersionListResponse,
1230
+ errors: [UnprocessableEntity],
1231
+ protocol: LitellmProtocol,
1232
+ retry: Retry.Retry,
1233
+ }));
1234
+
1235
+ export type PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactError =
1236
+ | UnprocessableEntity
1237
+ | LitellmOpError;
1238
+ /** Estimate Attachment Impact Estimate how many keys and teams would be affected by a policy attachment. Use this before creating an attachment to preview the blast radius. Example Request: ```bash curl -X POST "http://localhost:4000/policies/attachments/estimate-impact" \ -H "Authorization: Bearer <your_api_key>" \ -H "Content-Type: application/json" \ -d '{ "policy_name": "hipaa-compliance", "tags": ["healthcare", "health-*"] }' ``` */
1239
+ export const postEstimateAttachmentImpactPoliciesAttachmentsEstimateImpact: API.OperationMethod<
1240
+ PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequest,
1241
+ AttachmentImpactResponse,
1242
+ PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactError,
1243
+ LitellmOpContext
1244
+ > = /*@__PURE__*/ API.make(() => ({
1245
+ input: PostEstimateAttachmentImpactPoliciesAttachmentsEstimateImpactRequest,
1246
+ output: AttachmentImpactResponse,
1247
+ errors: [UnprocessableEntity],
1248
+ protocol: LitellmProtocol,
1249
+ retry: Retry.Retry,
1250
+ }));
1251
+
1252
+ export type PostResolvePoliciesForContextPoliciesResolveError =
1253
+ | UnprocessableEntity
1254
+ | LitellmOpError;
1255
+ /** Resolve Policies For Context Resolve which policies and guardrails apply for a given context. Use this endpoint to debug "what guardrails would apply to a request with this team/key/model/tags combination?" Example Request: ```bash curl -X POST "http://localhost:4000/policies/resolve" \ -H "Authorization: Bearer <your_api_key>" \ -H "Content-Type: application/json" \ -d '{ "tags": ["healthcare"], "model": "gpt-4" }' ``` */
1256
+ export const postResolvePoliciesForContextPoliciesResolve: API.OperationMethod<
1257
+ PostResolvePoliciesForContextPoliciesResolveRequest,
1258
+ PolicyResolveResponse,
1259
+ PostResolvePoliciesForContextPoliciesResolveError,
1260
+ LitellmOpContext
1261
+ > = /*@__PURE__*/ API.make(() => ({
1262
+ input: PostResolvePoliciesForContextPoliciesResolveRequest,
1263
+ output: PolicyResolveResponse,
1264
+ errors: [UnprocessableEntity],
1265
+ protocol: LitellmProtocol,
1266
+ retry: Retry.Retry,
1267
+ }));
1268
+
1269
+ export type PostTestPipelinePoliciesTestPipelineError =
1270
+ | UnprocessableEntity
1271
+ | LitellmOpError;
1272
+ /** Test Pipeline Test a guardrail pipeline with sample messages. Executes the pipeline steps against the provided test messages and returns step-by-step results showing which guardrails passed/failed, actions taken, and timing information. Example Request: ```bash curl -X POST "http://localhost:4000/policies/test-pipeline" \ -H "Authorization: Bearer <your_api_key>" \ -H "Content-Type: application/json" \ -d '{ "pipeline": { "mode": "pre_call", "steps": [ {"guardrail": "pii-guard", "on_pass": "next", "on_fail": "block"} ] }, "test_messages": [{"role": "user", "content": "My SSN is 123-45-6789"}] }' ``` */
1273
+ export const postTestPipelinePoliciesTestPipeline: API.OperationMethod<
1274
+ PostTestPipelinePoliciesTestPipelineRequest,
1275
+ PostTestPipelinePoliciesTestPipelineResponse,
1276
+ PostTestPipelinePoliciesTestPipelineError,
1277
+ LitellmOpContext
1278
+ > = /*@__PURE__*/ API.make(() => ({
1279
+ input: PostTestPipelinePoliciesTestPipelineRequest,
1280
+ output: PostTestPipelinePoliciesTestPipelineResponse,
1281
+ errors: [UnprocessableEntity],
1282
+ protocol: LitellmProtocol,
1283
+ retry: Retry.Retry,
1284
+ }));
1285
+
1286
+ export type UpdatePolicyPoliciesPolicyIdPutError =
1287
+ | UnprocessableEntity
1288
+ | LitellmOpError;
1289
+ /** Update Policy Update an existing policy. Example Request: ```bash curl -X PUT "http://localhost:4000/policies/123e4567-e89b-12d3-a456-426614174000" \ -H "Authorization: Bearer <your_api_key>" \ -H "Content-Type: application/json" \ -d '{ "description": "Updated description", "guardrails_add": ["pii_masking", "toxicity_filter"] }' ``` */
1290
+ export const updatePolicyPoliciesPolicyIdPut: API.OperationMethod<
1291
+ UpdatePolicyPoliciesPolicyIdPutRequest,
1292
+ PolicyDBResponse,
1293
+ UpdatePolicyPoliciesPolicyIdPutError,
1294
+ LitellmOpContext
1295
+ > = /*@__PURE__*/ API.make(() => ({
1296
+ input: UpdatePolicyPoliciesPolicyIdPutRequest,
1297
+ output: PolicyDBResponse,
1298
+ errors: [UnprocessableEntity],
1299
+ protocol: LitellmProtocol,
1300
+ retry: Retry.Retry,
1301
+ }));
1302
+
1303
+ export type UpdatePolicyVersionStatusPoliciesPolicyIdStatusPutError =
1304
+ | UnprocessableEntity
1305
+ | LitellmOpError;
1306
+ /** Update Policy Version Status Update a policy version's status. Valid transitions: - draft -> published - published -> production (demotes current production to published) - production -> published (demotes, policy becomes inactive) */
1307
+ export const updatePolicyVersionStatusPoliciesPolicyIdStatusPut: API.OperationMethod<
1308
+ UpdatePolicyVersionStatusPoliciesPolicyIdStatusPutRequest,
1309
+ PolicyDBResponse,
1310
+ UpdatePolicyVersionStatusPoliciesPolicyIdStatusPutError,
1311
+ LitellmOpContext
1312
+ > = /*@__PURE__*/ API.make(() => ({
1313
+ input: UpdatePolicyVersionStatusPoliciesPolicyIdStatusPutRequest,
1314
+ output: PolicyDBResponse,
1315
+ errors: [UnprocessableEntity],
1316
+ protocol: LitellmProtocol,
1317
+ retry: Retry.Retry,
1318
+ }));