@google/adk 1.2.0 → 1.4.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 (294) hide show
  1. package/dist/cjs/agents/active_streaming_tool.js +6 -1
  2. package/dist/cjs/agents/base_agent.js +19 -1
  3. package/dist/cjs/agents/context.js +1 -11
  4. package/dist/cjs/agents/functions.js +35 -16
  5. package/dist/cjs/agents/instructions.js +99 -33
  6. package/dist/cjs/agents/invocation_context.js +2 -6
  7. package/dist/cjs/agents/llm_agent.js +60 -11
  8. package/dist/cjs/agents/processors/agent_transfer_llm_request_processor.js +7 -0
  9. package/dist/cjs/agents/processors/basic_llm_request_processor.js +8 -1
  10. package/dist/cjs/agents/processors/code_execution_request_processor.js +0 -3
  11. package/dist/cjs/agents/processors/content_processor_utils.js +51 -25
  12. package/dist/cjs/agents/processors/content_request_processor.js +7 -0
  13. package/dist/cjs/agents/processors/context_compactor_request_processor.js +16 -2
  14. package/dist/cjs/agents/processors/identity_llm_request_processor.js +7 -0
  15. package/dist/cjs/agents/processors/instructions_llm_request_processor.js +5 -0
  16. package/dist/cjs/agents/processors/interactions_request_processor.js +63 -0
  17. package/dist/cjs/agents/processors/request_confirmation_llm_request_processor.js +9 -1
  18. package/dist/cjs/agents/processors/tool_filter_request_processor.js +7 -1
  19. package/dist/cjs/apps/app.js +79 -0
  20. package/dist/cjs/apps/resumability_config.js +44 -0
  21. package/dist/cjs/artifacts/file_artifact_service.js +14 -1
  22. package/dist/cjs/artifacts/gcs_artifact_service.js +57 -15
  23. package/dist/cjs/artifacts/in_memory_artifact_service.js +5 -1
  24. package/dist/cjs/artifacts/scoped_artifact_service.js +101 -0
  25. package/dist/cjs/artifacts/session_artifact_service.js +27 -0
  26. package/dist/cjs/auth/auth_preprocessor.js +12 -10
  27. package/dist/cjs/auth/oauth2/oauth2_discovery.js +17 -5
  28. package/dist/cjs/auth/oauth2/oauth2_utils.js +12 -1
  29. package/dist/cjs/code_executors/code_executor_context.js +7 -7
  30. package/dist/cjs/common.js +86 -0
  31. package/dist/cjs/context/agent_controlled_context_compactor.js +109 -0
  32. package/dist/cjs/context/summarizers/llm_summarizer.js +11 -0
  33. package/dist/cjs/context/token_based_context_compactor.js +43 -11
  34. package/dist/cjs/context/trajectory_thought_pruning_compactor.js +71 -0
  35. package/dist/cjs/events/event.js +25 -1
  36. package/dist/cjs/integrations/agent_registry/agent_registry_mcp_toolset.js +21 -2
  37. package/dist/cjs/models/gemini_llm_connection.js +62 -19
  38. package/dist/cjs/models/google_llm.js +51 -18
  39. package/dist/cjs/models/interactions_utils.js +732 -0
  40. package/dist/cjs/plugins/base_plugin.js +1 -0
  41. package/dist/cjs/plugins/security_plugin.js +16 -0
  42. package/dist/cjs/runner/in_memory_runner.js +13 -2
  43. package/dist/cjs/runner/runner.js +93 -72
  44. package/dist/cjs/sessions/base_session_service.js +19 -3
  45. package/dist/cjs/sessions/database_session_service.js +26 -9
  46. package/dist/cjs/sessions/db/schema.js +45 -10
  47. package/dist/cjs/sessions/in_memory_session_service.js +2 -1
  48. package/dist/cjs/sessions/vertex_ai_session_service.js +21 -5
  49. package/dist/cjs/skills/gcp_skill_registry.js +104 -0
  50. package/dist/cjs/skills/loader.js +67 -2
  51. package/dist/cjs/skills/skill_registry.js +27 -0
  52. package/dist/cjs/tools/base_toolset.js +1 -1
  53. package/dist/cjs/tools/consolidate_context_tool.js +79 -0
  54. package/dist/cjs/tools/forwarding_artifact_service.js +16 -28
  55. package/dist/cjs/tools/openapi_tool/openapi_spec_parser/openapi_spec_parser.js +232 -0
  56. package/dist/cjs/tools/openapi_tool/openapi_spec_parser/operation_parser.js +224 -0
  57. package/dist/cjs/tools/openapi_tool/openapi_spec_parser/tool_auth_handler.js +117 -0
  58. package/dist/cjs/tools/openapi_tool/openapi_toolset.js +133 -0
  59. package/dist/cjs/tools/openapi_tool/rest_api_tool.js +256 -0
  60. package/dist/cjs/tools/skill/load_skill_resource_tool.js +25 -3
  61. package/dist/cjs/tools/skill/load_skill_tool.js +12 -1
  62. package/dist/cjs/tools/skill/run_skill_script_tool.js +12 -1
  63. package/dist/cjs/tools/skill/search_skills_tool.js +108 -0
  64. package/dist/cjs/tools/skill/skill_toolset.js +40 -5
  65. package/dist/cjs/utils/async_hooks_shim.js +52 -0
  66. package/dist/cjs/utils/async_queue.js +88 -0
  67. package/dist/cjs/utils/case_utils.js +53 -0
  68. package/dist/cjs/utils/client_labels.js +41 -3
  69. package/dist/cjs/utils/env_aware_utils.js +14 -1
  70. package/dist/cjs/utils/live_connection_utils.js +284 -0
  71. package/dist/cjs/utils/model_name.js +9 -0
  72. package/dist/cjs/utils/streaming_utils.js +18 -11
  73. package/dist/cjs/utils/task.js +62 -0
  74. package/dist/cjs/version.js +1 -1
  75. package/dist/esm/agents/active_streaming_tool.js +6 -1
  76. package/dist/esm/agents/base_agent.js +19 -1
  77. package/dist/esm/agents/context.js +1 -11
  78. package/dist/esm/agents/functions.js +36 -15
  79. package/dist/esm/agents/instructions.js +99 -33
  80. package/dist/esm/agents/invocation_context.js +2 -6
  81. package/dist/esm/agents/llm_agent.js +61 -11
  82. package/dist/esm/agents/processors/agent_transfer_llm_request_processor.js +7 -0
  83. package/dist/esm/agents/processors/basic_llm_request_processor.js +8 -1
  84. package/dist/esm/agents/processors/code_execution_request_processor.js +0 -3
  85. package/dist/esm/agents/processors/content_processor_utils.js +48 -24
  86. package/dist/esm/agents/processors/content_request_processor.js +7 -0
  87. package/dist/esm/agents/processors/context_compactor_request_processor.js +16 -2
  88. package/dist/esm/agents/processors/identity_llm_request_processor.js +7 -0
  89. package/dist/esm/agents/processors/instructions_llm_request_processor.js +5 -0
  90. package/dist/esm/agents/processors/interactions_request_processor.js +34 -0
  91. package/dist/esm/agents/processors/request_confirmation_llm_request_processor.js +9 -1
  92. package/dist/esm/agents/processors/tool_filter_request_processor.js +7 -1
  93. package/dist/esm/apps/app.js +49 -0
  94. package/dist/esm/apps/resumability_config.js +16 -0
  95. package/dist/esm/artifacts/file_artifact_service.js +14 -1
  96. package/dist/esm/artifacts/gcs_artifact_service.js +57 -15
  97. package/dist/esm/artifacts/in_memory_artifact_service.js +5 -1
  98. package/dist/esm/artifacts/scoped_artifact_service.js +73 -0
  99. package/dist/esm/artifacts/session_artifact_service.js +7 -0
  100. package/dist/esm/auth/auth_preprocessor.js +12 -10
  101. package/dist/esm/auth/oauth2/oauth2_discovery.js +14 -4
  102. package/dist/esm/auth/oauth2/oauth2_utils.js +12 -1
  103. package/dist/esm/code_executors/code_executor_context.js +7 -7
  104. package/dist/esm/common.js +75 -3
  105. package/dist/esm/context/agent_controlled_context_compactor.js +81 -0
  106. package/dist/esm/context/summarizers/llm_summarizer.js +11 -0
  107. package/dist/esm/context/token_based_context_compactor.js +43 -11
  108. package/dist/esm/context/trajectory_thought_pruning_compactor.js +43 -0
  109. package/dist/esm/events/event.js +23 -1
  110. package/dist/esm/integrations/agent_registry/agent_registry_mcp_toolset.js +21 -2
  111. package/dist/esm/models/gemini_llm_connection.js +62 -19
  112. package/dist/esm/models/google_llm.js +49 -17
  113. package/dist/esm/models/interactions_utils.js +697 -0
  114. package/dist/esm/plugins/base_plugin.js +1 -0
  115. package/dist/esm/plugins/security_plugin.js +16 -0
  116. package/dist/esm/runner/in_memory_runner.js +13 -2
  117. package/dist/esm/runner/runner.js +91 -73
  118. package/dist/esm/sessions/base_session_service.js +17 -2
  119. package/dist/esm/sessions/database_session_service.js +26 -9
  120. package/dist/esm/sessions/db/schema.js +44 -10
  121. package/dist/esm/sessions/in_memory_session_service.js +4 -2
  122. package/dist/esm/sessions/vertex_ai_session_service.js +21 -5
  123. package/dist/esm/skills/gcp_skill_registry.js +78 -0
  124. package/dist/esm/skills/loader.js +66 -2
  125. package/dist/esm/skills/skill_registry.js +7 -0
  126. package/dist/esm/tools/base_toolset.js +1 -1
  127. package/dist/esm/tools/consolidate_context_tool.js +51 -0
  128. package/dist/esm/tools/forwarding_artifact_service.js +16 -28
  129. package/dist/esm/tools/openapi_tool/openapi_spec_parser/openapi_spec_parser.js +206 -0
  130. package/dist/esm/tools/openapi_tool/openapi_spec_parser/operation_parser.js +198 -0
  131. package/dist/esm/tools/openapi_tool/openapi_spec_parser/tool_auth_handler.js +91 -0
  132. package/dist/esm/tools/openapi_tool/openapi_toolset.js +97 -0
  133. package/dist/esm/tools/openapi_tool/rest_api_tool.js +229 -0
  134. package/dist/esm/tools/skill/load_skill_resource_tool.js +25 -3
  135. package/dist/esm/tools/skill/load_skill_tool.js +12 -1
  136. package/dist/esm/tools/skill/run_skill_script_tool.js +12 -1
  137. package/dist/esm/tools/skill/search_skills_tool.js +82 -0
  138. package/dist/esm/tools/skill/skill_toolset.js +40 -5
  139. package/dist/esm/utils/async_hooks_shim.js +24 -0
  140. package/dist/esm/utils/async_queue.js +60 -0
  141. package/dist/esm/utils/case_utils.js +25 -0
  142. package/dist/esm/utils/client_labels.js +38 -2
  143. package/dist/esm/utils/env_aware_utils.js +14 -1
  144. package/dist/esm/utils/live_connection_utils.js +256 -0
  145. package/dist/esm/utils/model_name.js +8 -0
  146. package/dist/esm/utils/streaming_utils.js +18 -11
  147. package/dist/esm/utils/task.js +34 -0
  148. package/dist/esm/version.js +1 -1
  149. package/dist/types/a2a/a2a_remote_agent_utils.d.ts +29 -4
  150. package/dist/types/a2a/event_converter_utils.d.ts +14 -1
  151. package/dist/types/a2a/metadata_converter_utils.d.ts +18 -0
  152. package/dist/types/a2a/part_converter_utils.d.ts +51 -6
  153. package/dist/types/agents/active_streaming_tool.d.ts +3 -4
  154. package/dist/types/agents/functions.d.ts +12 -9
  155. package/dist/types/agents/invocation_context.d.ts +7 -12
  156. package/dist/types/agents/llm_agent.d.ts +14 -0
  157. package/dist/types/agents/processors/agent_transfer_llm_request_processor.d.ts +14 -0
  158. package/dist/types/agents/processors/basic_llm_request_processor.d.ts +7 -0
  159. package/dist/types/agents/processors/content_processor_utils.d.ts +34 -0
  160. package/dist/types/agents/processors/content_request_processor.d.ts +16 -0
  161. package/dist/types/agents/processors/context_compactor_request_processor.d.ts +12 -0
  162. package/dist/types/agents/processors/identity_llm_request_processor.d.ts +7 -0
  163. package/dist/types/agents/processors/interactions_request_processor.d.ts +17 -0
  164. package/dist/types/agents/processors/request_confirmation_llm_request_processor.d.ts +9 -1
  165. package/dist/types/agents/processors/tool_filter_request_processor.d.ts +12 -1
  166. package/dist/types/apps/app.d.ts +52 -0
  167. package/dist/types/apps/resumability_config.d.ts +27 -0
  168. package/dist/types/artifacts/base_artifact_service.d.ts +6 -36
  169. package/dist/types/artifacts/gcs_artifact_service.d.ts +2 -1
  170. package/dist/types/artifacts/scoped_artifact_service.d.ts +25 -0
  171. package/dist/types/artifacts/session_artifact_service.d.ts +25 -0
  172. package/dist/types/auth/oauth2/oauth2_discovery.d.ts +11 -0
  173. package/dist/types/common.d.ts +35 -4
  174. package/dist/types/context/agent_controlled_context_compactor.d.ts +24 -0
  175. package/dist/types/context/base_context_compactor.d.ts +3 -0
  176. package/dist/types/context/summarizers/llm_summarizer.d.ts +17 -0
  177. package/dist/types/context/token_based_context_compactor.d.ts +6 -1
  178. package/dist/types/context/trajectory_thought_pruning_compactor.d.ts +27 -0
  179. package/dist/types/events/event.d.ts +8 -0
  180. package/dist/types/events/event_actions.d.ts +1 -2
  181. package/dist/types/integrations/agent_registry/agent_registry_mcp_toolset.d.ts +21 -2
  182. package/dist/types/models/base_llm_connection.d.ts +10 -0
  183. package/dist/types/models/gemini_llm_connection.d.ts +15 -4
  184. package/dist/types/models/google_llm.d.ts +15 -1
  185. package/dist/types/models/interactions_utils.d.ts +92 -0
  186. package/dist/types/models/llm_request.d.ts +4 -0
  187. package/dist/types/models/llm_response.d.ts +14 -1
  188. package/dist/types/plugins/base_plugin.d.ts +2 -1
  189. package/dist/types/plugins/security_plugin.d.ts +30 -0
  190. package/dist/types/runner/in_memory_runner.d.ts +7 -1
  191. package/dist/types/runner/runner.d.ts +43 -9
  192. package/dist/types/sessions/base_session_service.d.ts +7 -16
  193. package/dist/types/sessions/db/schema.d.ts +1 -0
  194. package/dist/types/sessions/session.d.ts +11 -0
  195. package/dist/types/sessions/vertex_ai_session_service.d.ts +9 -1
  196. package/dist/types/skills/gcp_skill_registry.d.ts +24 -0
  197. package/dist/types/skills/loader.d.ts +7 -0
  198. package/dist/types/skills/skill.d.ts +1 -1
  199. package/dist/types/skills/skill_registry.d.ts +29 -0
  200. package/dist/types/tools/consolidate_context_tool.d.ts +19 -0
  201. package/dist/types/tools/forwarding_artifact_service.d.ts +3 -2
  202. package/dist/types/tools/openapi_tool/openapi_spec_parser/openapi_spec_parser.d.ts +34 -0
  203. package/dist/types/tools/openapi_tool/openapi_spec_parser/operation_parser.d.ts +59 -0
  204. package/dist/types/tools/openapi_tool/openapi_spec_parser/tool_auth_handler.d.ts +23 -0
  205. package/dist/types/tools/openapi_tool/openapi_toolset.d.ts +27 -0
  206. package/dist/types/tools/openapi_tool/rest_api_tool.d.ts +50 -0
  207. package/dist/types/tools/skill/load_skill_resource_tool.d.ts +1 -1
  208. package/dist/types/tools/skill/search_skills_tool.d.ts +14 -0
  209. package/dist/types/tools/skill/skill_toolset.d.ts +5 -0
  210. package/dist/types/utils/async_hooks_shim.d.ts +10 -0
  211. package/dist/types/utils/async_queue.d.ts +18 -0
  212. package/dist/types/utils/case_utils.d.ts +12 -0
  213. package/dist/types/utils/client_labels.d.ts +10 -0
  214. package/dist/types/utils/env_aware_utils.d.ts +3 -3
  215. package/dist/types/utils/live_connection_utils.d.ts +30 -0
  216. package/dist/types/utils/model_name.d.ts +7 -0
  217. package/dist/types/utils/streaming_utils.d.ts +0 -1
  218. package/dist/types/utils/task.d.ts +24 -0
  219. package/dist/types/version.d.ts +1 -1
  220. package/dist/web/agents/active_streaming_tool.js +6 -1
  221. package/dist/web/agents/base_agent.js +31 -1
  222. package/dist/web/agents/context.js +1 -11
  223. package/dist/web/agents/functions.js +36 -15
  224. package/dist/web/agents/instructions.js +99 -33
  225. package/dist/web/agents/invocation_context.js +2 -6
  226. package/dist/web/agents/llm_agent.js +61 -11
  227. package/dist/web/agents/processors/agent_transfer_llm_request_processor.js +7 -0
  228. package/dist/web/agents/processors/basic_llm_request_processor.js +8 -1
  229. package/dist/web/agents/processors/code_execution_request_processor.js +0 -3
  230. package/dist/web/agents/processors/content_processor_utils.js +66 -24
  231. package/dist/web/agents/processors/content_request_processor.js +7 -0
  232. package/dist/web/agents/processors/context_compactor_request_processor.js +16 -2
  233. package/dist/web/agents/processors/identity_llm_request_processor.js +7 -0
  234. package/dist/web/agents/processors/instructions_llm_request_processor.js +5 -0
  235. package/dist/web/agents/processors/interactions_request_processor.js +52 -0
  236. package/dist/web/agents/processors/request_confirmation_llm_request_processor.js +9 -1
  237. package/dist/web/agents/processors/tool_filter_request_processor.js +7 -1
  238. package/dist/web/apps/app.js +49 -0
  239. package/dist/web/apps/resumability_config.js +31 -0
  240. package/dist/web/artifacts/file_artifact_service.js +14 -1
  241. package/dist/web/artifacts/gcs_artifact_service.js +55 -15
  242. package/dist/web/artifacts/in_memory_artifact_service.js +5 -1
  243. package/dist/web/artifacts/scoped_artifact_service.js +86 -0
  244. package/dist/web/artifacts/session_artifact_service.js +7 -0
  245. package/dist/web/auth/auth_preprocessor.js +12 -10
  246. package/dist/web/auth/oauth2/oauth2_discovery.js +14 -4
  247. package/dist/web/auth/oauth2/oauth2_utils.js +12 -1
  248. package/dist/web/code_executors/code_executor_context.js +7 -7
  249. package/dist/web/common.js +75 -3
  250. package/dist/web/context/agent_controlled_context_compactor.js +81 -0
  251. package/dist/web/context/summarizers/llm_summarizer.js +11 -0
  252. package/dist/web/context/token_based_context_compactor.js +43 -11
  253. package/dist/web/context/trajectory_thought_pruning_compactor.js +43 -0
  254. package/dist/web/events/event.js +21 -1
  255. package/dist/web/integrations/agent_registry/agent_registry_mcp_toolset.js +21 -2
  256. package/dist/web/models/gemini_llm_connection.js +75 -19
  257. package/dist/web/models/google_llm.js +80 -17
  258. package/dist/web/models/interactions_utils.js +728 -0
  259. package/dist/web/plugins/base_plugin.js +1 -0
  260. package/dist/web/plugins/security_plugin.js +16 -0
  261. package/dist/web/runner/in_memory_runner.js +13 -2
  262. package/dist/web/runner/runner.js +111 -75
  263. package/dist/web/sessions/base_session_service.js +17 -2
  264. package/dist/web/sessions/database_session_service.js +26 -9
  265. package/dist/web/sessions/db/schema.js +44 -10
  266. package/dist/web/sessions/in_memory_session_service.js +4 -2
  267. package/dist/web/sessions/vertex_ai_session_service.js +21 -5
  268. package/dist/web/skills/gcp_skill_registry.js +78 -0
  269. package/dist/web/skills/loader.js +66 -2
  270. package/dist/web/skills/skill_registry.js +7 -0
  271. package/dist/web/tools/base_toolset.js +1 -1
  272. package/dist/web/tools/consolidate_context_tool.js +51 -0
  273. package/dist/web/tools/forwarding_artifact_service.js +16 -28
  274. package/dist/web/tools/openapi_tool/openapi_spec_parser/openapi_spec_parser.js +221 -0
  275. package/dist/web/tools/openapi_tool/openapi_spec_parser/operation_parser.js +198 -0
  276. package/dist/web/tools/openapi_tool/openapi_spec_parser/tool_auth_handler.js +91 -0
  277. package/dist/web/tools/openapi_tool/openapi_toolset.js +97 -0
  278. package/dist/web/tools/openapi_tool/rest_api_tool.js +229 -0
  279. package/dist/web/tools/skill/load_skill_resource_tool.js +25 -3
  280. package/dist/web/tools/skill/load_skill_tool.js +12 -1
  281. package/dist/web/tools/skill/run_skill_script_tool.js +12 -1
  282. package/dist/web/tools/skill/search_skills_tool.js +82 -0
  283. package/dist/web/tools/skill/skill_toolset.js +40 -5
  284. package/dist/web/utils/async_hooks_shim.js +24 -0
  285. package/dist/web/utils/async_queue.js +60 -0
  286. package/dist/web/utils/case_utils.js +25 -0
  287. package/dist/web/utils/client_labels.js +38 -2
  288. package/dist/web/utils/env_aware_utils.js +14 -1
  289. package/dist/web/utils/live_connection_utils.js +254 -0
  290. package/dist/web/utils/model_name.js +8 -0
  291. package/dist/web/utils/streaming_utils.js +18 -11
  292. package/dist/web/utils/task.js +34 -0
  293. package/dist/web/version.js +1 -1
  294. package/package.json +4 -2
@@ -39,20 +39,33 @@ export interface GeminiParams {
39
39
  * Headers to merge with internally crafted headers.
40
40
  */
41
41
  headers?: Record<string, string>;
42
+ /**
43
+ * Whether to use the Interactions API for stateful conversations.
44
+ */
45
+ useInteractionsApi?: boolean;
42
46
  }
47
+ declare const GEMINI_MODEL_SYMBOL: unique symbol;
48
+ /**
49
+ * Type guard to check if an object is an instance of Gemini.
50
+ * @param obj The object to check.
51
+ * @returns True if the object is an instance of Gemini, false otherwise.
52
+ */
53
+ export declare function isGemini(obj: unknown): obj is Gemini;
43
54
  /**
44
55
  * Integration for Gemini models.
45
56
  */
46
57
  export declare class Gemini extends BaseLlm {
58
+ readonly [GEMINI_MODEL_SYMBOL] = true;
47
59
  private readonly apiKey?;
48
60
  protected readonly vertexai: boolean;
49
61
  private readonly project?;
50
62
  private readonly location?;
51
63
  private readonly headers?;
64
+ readonly useInteractionsApi: boolean;
52
65
  /**
53
66
  * @param params The parameters for creating a Gemini instance.
54
67
  */
55
- constructor({ model, apiKey, vertexai, project, location, headers, }: GeminiParams);
68
+ constructor({ model, apiKey, vertexai, project, location, headers, useInteractionsApi, }: GeminiParams);
56
69
  /**
57
70
  * A list of model name patterns that are supported by this LLM.
58
71
  *
@@ -88,3 +101,4 @@ export declare class Gemini extends BaseLlm {
88
101
  private preprocessRequest;
89
102
  }
90
103
  export declare function geminiInitParams({ model, vertexai, project, location, apiKey, }: GeminiParams): GeminiParams;
104
+ export {};
@@ -0,0 +1,92 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2026 Google LLC
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ import { Content, GenerateContentConfig, GoogleGenAI, Interactions, Part } from '@google/genai';
7
+ import { LlmRequest } from './llm_request.js';
8
+ import { LlmResponse } from './llm_response.js';
9
+ export interface ExtendedInteraction extends Interactions.Interaction {
10
+ error?: {
11
+ code: string;
12
+ message: string;
13
+ };
14
+ }
15
+ export interface ExtendedInteractionStatusUpdate extends Omit<Interactions.InteractionStatusUpdate, 'error'> {
16
+ error?: {
17
+ code: string;
18
+ message: string;
19
+ };
20
+ }
21
+ export interface ExtendedFunctionCallStep extends Interactions.FunctionCallStep {
22
+ signature?: string;
23
+ }
24
+ export interface ExtendedInteractionSSEEvent extends Omit<Interactions.InteractionSSEEvent, 'error' | 'interaction_id' | 'status' | 'event_type'> {
25
+ event_type?: string;
26
+ eventType?: string;
27
+ delta?: {
28
+ type: string;
29
+ text?: string;
30
+ name?: string;
31
+ id?: string;
32
+ arguments?: Record<string, unknown>;
33
+ thought_signature?: string;
34
+ signature?: string;
35
+ data?: string;
36
+ uri?: string;
37
+ mime_type: string;
38
+ };
39
+ status?: string;
40
+ error?: {
41
+ code: string;
42
+ message: string;
43
+ };
44
+ code?: string;
45
+ message?: string;
46
+ interaction_id?: string;
47
+ interactionId?: string;
48
+ interaction?: {
49
+ id: string;
50
+ };
51
+ id?: string;
52
+ }
53
+ /**
54
+ * Extracts the latest turn contents for interactions API.
55
+ */
56
+ export declare function getLatestUserContents(contents: Content[]): Content[];
57
+ /**
58
+ * Convert a Content to a list of Steps.
59
+ */
60
+ export declare function convertContentToSteps(content: Content): Interactions.Step[];
61
+ /**
62
+ * Convert a Step to a list of Parts.
63
+ */
64
+ export declare function convertStepToParts(step: Interactions.Step): Part[];
65
+ /**
66
+ * Convert tools config to interactions format.
67
+ */
68
+ export declare function convertToolsConfigToInteractionsFormat(config: GenerateContentConfig): Interactions.Tool[];
69
+ /**
70
+ * Extract the latest model generated parts from a list of steps.
71
+ */
72
+ export declare function getLatestModelParts(steps: Interactions.Step[]): Part[];
73
+ /**
74
+ * Convert Interaction response to an LlmResponse.
75
+ */
76
+ export declare function convertInteractionToLlmResponse(interaction: ExtendedInteraction): LlmResponse;
77
+ /**
78
+ * Convert InteractionSSEEvent to LlmResponse.
79
+ */
80
+ export declare function convertInteractionEventToLlmResponse(event: ExtendedInteractionSSEEvent, aggregatedParts: Part[], interactionId?: string): LlmResponse | null;
81
+ /**
82
+ * Build generation config.
83
+ */
84
+ export declare function buildGenerationConfig(config: GenerateContentConfig): Record<string, unknown>;
85
+ /**
86
+ * Extract system instruction.
87
+ */
88
+ export declare function extractSystemInstruction(config: GenerateContentConfig): string | undefined;
89
+ /**
90
+ * Generate content using the interactions API.
91
+ */
92
+ export declare function generateContentViaInteractions(apiClient: GoogleGenAI, llmRequest: LlmRequest, stream: boolean): AsyncGenerator<LlmResponse, void, void>;
@@ -34,6 +34,10 @@ export interface LlmRequest {
34
34
  * The set of allowed tools, populated by request processors.
35
35
  */
36
36
  allowedTools?: string[];
37
+ /**
38
+ * The interaction ID from the previous turn, if any.
39
+ */
40
+ previousInteractionId?: string;
37
41
  }
38
42
  /**
39
43
  * Appends instructions to the system instruction.
@@ -3,7 +3,7 @@
3
3
  * Copyright 2025 Google LLC
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
- import { CitationMetadata, Content, FinishReason, GenerateContentResponse, GenerateContentResponseUsageMetadata, GroundingMetadata, LiveServerSessionResumptionUpdate, Transcription } from '@google/genai';
6
+ import { CitationMetadata, Content, FinishReason, GenerateContentResponse, GenerateContentResponseUsageMetadata, GroundingMetadata, LiveServerGoAway, LiveServerSessionResumptionUpdate, Transcription } from '@google/genai';
7
7
  /**
8
8
  * LLM response class that provides the first candidate response from the
9
9
  * model if available. Otherwise, returns error code and message.
@@ -64,6 +64,11 @@ export interface LlmResponse {
64
64
  * The session resumption update of the LlmResponse
65
65
  */
66
66
  liveSessionResumptionUpdate?: LiveServerSessionResumptionUpdate;
67
+ /**
68
+ * Server-side signal that the live connection will be closed soon. The
69
+ * caller should reconnect using the latest session resumption handle.
70
+ */
71
+ goAway?: LiveServerGoAway;
67
72
  /**
68
73
  * Audio transcription of user input.
69
74
  */
@@ -72,6 +77,14 @@ export interface LlmResponse {
72
77
  * Audio transcription of model output.
73
78
  */
74
79
  outputTranscription?: Transcription;
80
+ /**
81
+ * The interaction ID returned by the model, if any.
82
+ */
83
+ interactionId?: string;
84
+ /** The model version used to generate the response. */
85
+ modelVersion?: string;
86
+ /** The session ID of the Live session. */
87
+ liveSessionId?: string;
75
88
  }
76
89
  /**
77
90
  * Creates an LlmResponse from a GenerateContentResponse.
@@ -16,7 +16,8 @@ import { BaseTool } from '../tools/base_tool.js';
16
16
  */
17
17
  export declare enum ContextCompactionTrigger {
18
18
  Manual = "Manual",
19
- Auto = "Auto"
19
+ Auto = "Auto",
20
+ AgentControlled = "AgentControlled"
20
21
  }
21
22
  /**
22
23
  * Base class for creating plugins.
@@ -17,18 +17,37 @@ export declare enum PolicyOutcome {
17
17
  CONFIRM = "CONFIRM",
18
18
  ALLOW = "ALLOW"
19
19
  }
20
+ /** The result returned by a policy engine after evaluating a tool call. */
20
21
  export interface PolicyCheckResult {
22
+ /** The policy decision: `ALLOW`, `DENY`, or `CONFIRM`. */
21
23
  outcome: string;
24
+ /** Optional human-readable explanation of the decision. */
22
25
  reason?: string;
23
26
  }
27
+ /** Context passed to a policy engine when evaluating a tool call. */
24
28
  export interface ToolCallPolicyContext {
29
+ /** The tool being invoked. */
25
30
  tool: BaseTool;
31
+ /** The arguments supplied to the tool call. */
26
32
  toolArgs: Record<string, unknown>;
27
33
  }
34
+ /** Interface for policy engines that gate tool call execution. */
28
35
  export interface BasePolicyEngine {
36
+ /**
37
+ * Evaluates whether a tool call should be allowed, denied, or confirmed.
38
+ *
39
+ * @param context - The tool and its arguments to evaluate.
40
+ * @returns A promise resolving to the policy decision.
41
+ */
29
42
  evaluate(context: ToolCallPolicyContext): Promise<PolicyCheckResult>;
30
43
  }
44
+ /** In-memory policy engine that permits all tool calls. Intended for prototyping. */
31
45
  export declare class InMemoryPolicyEngine implements BasePolicyEngine {
46
+ /**
47
+ * Always returns {@link PolicyOutcome.ALLOW} for every tool call.
48
+ *
49
+ * @returns A promise resolving to an ALLOW result.
50
+ */
32
51
  evaluate(): Promise<PolicyCheckResult>;
33
52
  }
34
53
  /**
@@ -36,9 +55,20 @@ export declare class InMemoryPolicyEngine implements BasePolicyEngine {
36
55
  */
37
56
  export declare class SecurityPlugin extends BasePlugin {
38
57
  private readonly policyEngine;
58
+ /**
59
+ * @param params - Optional configuration. Defaults to {@link InMemoryPolicyEngine}
60
+ * when no policy engine is provided.
61
+ */
39
62
  constructor(params?: {
40
63
  policyEngine?: BasePolicyEngine;
41
64
  });
65
+ /**
66
+ * Intercepts tool calls, evaluating them against the policy engine before
67
+ * execution and handling confirmation flows for calls that require it.
68
+ *
69
+ * @returns A partial or error response object if the call is blocked or
70
+ * awaiting confirmation, or `undefined` to allow execution to proceed.
71
+ */
42
72
  beforeToolCallback({ tool, toolArgs, toolContext, }: {
43
73
  tool: BaseTool;
44
74
  toolArgs: {
@@ -4,6 +4,8 @@
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
6
  import { BaseAgent } from '../agents/base_agent.js';
7
+ import { App } from '../apps/app.js';
8
+ import { ResumabilityConfig } from '../apps/resumability_config.js';
7
9
  import { BasePlugin } from '../plugins/base_plugin.js';
8
10
  import { Runner } from './runner.js';
9
11
  /**
@@ -30,13 +32,17 @@ export declare class InMemoryRunner extends Runner {
30
32
  * Creates a new InMemoryRunner instance.
31
33
  *
32
34
  * @param params The configuration for the runner.
35
+ * @param params.app An optional application instance to run.
33
36
  * @param params.agent The root agent to run.
34
37
  * @param params.appName The application name. Defaults to `'InMemoryRunner'`.
35
38
  * @param params.plugins An optional list of plugins.
39
+ * @param params.resumabilityConfig An optional resumability configuration.
36
40
  */
37
41
  constructor(params: {
38
- agent: BaseAgent;
42
+ app?: App;
43
+ agent?: BaseAgent;
39
44
  appName?: string;
40
45
  plugins?: BasePlugin[];
46
+ resumabilityConfig?: ResumabilityConfig;
41
47
  });
42
48
  }
@@ -6,6 +6,8 @@
6
6
  import { Content } from '@google/genai';
7
7
  import { BaseAgent } from '../agents/base_agent.js';
8
8
  import { RunConfig } from '../agents/run_config.js';
9
+ import { App } from '../apps/app.js';
10
+ import { ResumabilityConfig } from '../apps/resumability_config.js';
9
11
  import { BaseArtifactService } from '../artifacts/base_artifact_service.js';
10
12
  import { BaseCredentialService } from '../auth/credential_service/base_credential_service.js';
11
13
  import { Event } from '../events/event.js';
@@ -13,18 +15,23 @@ import { BaseMemoryService } from '../memory/base_memory_service.js';
13
15
  import { BasePlugin } from '../plugins/base_plugin.js';
14
16
  import { PluginManager } from '../plugins/plugin_manager.js';
15
17
  import { BaseSessionService } from '../sessions/base_session_service.js';
18
+ import { Session } from '../sessions/session.js';
16
19
  /**
17
20
  * The configuration parameters for the Runner.
18
21
  */
19
22
  export interface RunnerConfig {
20
23
  /**
21
- * The application name.
24
+ * The application object. If provided, `appName`, `agent`, and `plugins` will default from this app.
22
25
  */
23
- appName: string;
26
+ app?: App;
24
27
  /**
25
- * The agent to run.
28
+ * The application name. Required if `app` is not provided.
26
29
  */
27
- agent: BaseAgent;
30
+ appName?: string;
31
+ /**
32
+ * The agent to run. Required if `app` is not provided.
33
+ */
34
+ agent?: BaseAgent;
28
35
  /**
29
36
  * An optional list of plugins to apply globally across all agents.
30
37
  */
@@ -45,6 +52,10 @@ export interface RunnerConfig {
45
52
  * An optional service for managing authentication credentials.
46
53
  */
47
54
  credentialService?: BaseCredentialService;
55
+ /**
56
+ * An optional resumability configuration applied to the runner.
57
+ */
58
+ resumabilityConfig?: ResumabilityConfig;
48
59
  }
49
60
  /**
50
61
  * A unique symbol to identify ADK agent classes.
@@ -91,6 +102,7 @@ export declare class Runner {
91
102
  readonly sessionService: BaseSessionService;
92
103
  readonly memoryService?: BaseMemoryService;
93
104
  readonly credentialService?: BaseCredentialService;
105
+ readonly resumabilityConfig?: ResumabilityConfig;
94
106
  /**
95
107
  * Creates a new Runner instance.
96
108
  *
@@ -147,18 +159,40 @@ export declare class Runner {
147
159
  * Determines the next agent to run to continue the session. This is primarily
148
160
  * used for session resumption.
149
161
  */
162
+ /**
163
+ * Determines the next agent to run to continue the session. This is primarily
164
+ * used for session resumption across tool and LRO boundaries.
165
+ */
150
166
  private determineAgentForResumption;
151
167
  /**
152
168
  * Whether the agent to run can transfer to any other agent in the agent tree.
153
169
  *
154
- * An agent is transferable if:
155
- * - It is an instance of `LlmAgent`.
156
- * - All its ancestors are also transferable (i.e., they have
157
- * `disallowTransferToParent` set to false).
158
- *
159
170
  * @param agentToRun The agent to check for transferability.
160
171
  * @returns True if the agent can transfer, False otherwise.
161
172
  */
162
173
  private isRoutableLlmAgent;
163
174
  }
175
+ /**
176
+ * Determines the next agent to run to continue the session. This is primarily
177
+ * used for session resumption across tool and LRO boundaries.
178
+ */
179
+ export declare function determineAgentForResumption(session: Session, rootAgent: BaseAgent, resumabilityConfig?: ResumabilityConfig): BaseAgent;
180
+ /**
181
+ * Whether the agent to run can transfer to any other agent in the agent tree.
182
+ *
183
+ * An agent is transferable if:
184
+ * - It is an instance of `LlmAgent`.
185
+ * - All its ancestors are also transferable (i.e., they have
186
+ * `disallowTransferToParent` set to false).
187
+ *
188
+ * @param agentToRun The agent to check for transferability.
189
+ * @returns True if the agent can transfer, False otherwise.
190
+ */
191
+ export declare function isRoutableLlmAgent(agentToRun: BaseAgent): boolean;
192
+ /**
193
+ * It iterates through the events in reverse order, and returns the event
194
+ * containing a function call with a functionCall.id matching the
195
+ * functionResponse.id from the last event in the session.
196
+ */
197
+ export declare function findEventByLastFunctionResponseId(events: Event[]): Event | null;
164
198
  export {};
@@ -4,7 +4,7 @@
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
6
  import { Event } from '../events/event.js';
7
- import { Session } from './session.js';
7
+ import { CompositeSessionKey, Session } from './session.js';
8
8
  /**
9
9
  * The configuration of getting a session.
10
10
  */
@@ -30,13 +30,7 @@ export interface CreateSessionRequest {
30
30
  /**
31
31
  * The parameters for `getSession`.
32
32
  */
33
- export interface GetSessionRequest {
34
- /** The name of the application. */
35
- appName: string;
36
- /** The ID of the user. */
37
- userId: string;
38
- /** The ID of the session. */
39
- sessionId: string;
33
+ export interface GetSessionRequest extends CompositeSessionKey {
40
34
  /** The configurations for getting the session. */
41
35
  config?: GetSessionConfig;
42
36
  }
@@ -60,14 +54,7 @@ export interface ListSessionsRequest {
60
54
  /**
61
55
  * The parameters for `deleteSession`.
62
56
  */
63
- export interface DeleteSessionRequest {
64
- /** The name of the application. */
65
- appName: string;
66
- /** The ID of the user. */
67
- userId: string;
68
- /** The ID of the session. */
69
- sessionId: string;
70
- }
57
+ export type DeleteSessionRequest = CompositeSessionKey;
71
58
  /**
72
59
  * The parameters for `appendEvent`.
73
60
  */
@@ -156,6 +143,10 @@ export declare abstract class BaseSessionService {
156
143
  * Removes temporary state delta keys from the event.
157
144
  */
158
145
  export declare function trimTempDeltaState(event: Event): Event;
146
+ /**
147
+ * Removes temporary state keys from the state.
148
+ */
149
+ export declare function trimTempState(state: Record<string, unknown>): Record<string, unknown>;
159
150
  /**
160
151
  * Merges app state, user state, and session state.
161
152
  *
@@ -7,6 +7,7 @@ import { PrimaryKey } from '@mikro-orm/core';
7
7
  import { Event } from '../../events/event.js';
8
8
  export declare const SCHEMA_VERSION_KEY = "schema_version";
9
9
  export declare const SCHEMA_VERSION_1_JSON = "1";
10
+ export declare const STORAGE_KEY_COLUMN_LENGTH = 191;
10
11
  export declare class StorageMetadata {
11
12
  key: string;
12
13
  value: string;
@@ -4,6 +4,17 @@
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
6
  import { Event } from '../events/event.js';
7
+ /**
8
+ * Represents a unified composite session key grouping application, user, and session identifiers.
9
+ */
10
+ export interface CompositeSessionKey {
11
+ /** The name of the application. */
12
+ appName: string;
13
+ /** The ID of the user. */
14
+ userId: string;
15
+ /** The ID of the session. */
16
+ sessionId: string;
17
+ }
7
18
  /**
8
19
  * Represents a session in a conversation between agents and users.
9
20
  */
@@ -11,6 +11,14 @@ import { Session } from './session.js';
11
11
  * Checks if the given URI is a Vertex AI session service URI.
12
12
  */
13
13
  export declare function isVertexAiConnectionString(uri?: string): boolean;
14
+ /**
15
+ * Quotes a value for safe use as a Google AIP-160 filter string literal.
16
+ *
17
+ * Backslashes are escaped first, then double quotes, so that caller-controlled
18
+ * input stays inside the quoted value and cannot break out to inject additional
19
+ * filter predicates. See https://google.aip.dev/160.
20
+ */
21
+ export declare function quoteFilterLiteral(value: string): string;
14
22
  export interface VertexAiSessionServiceOptions {
15
23
  projectId?: string;
16
24
  location?: string;
@@ -32,6 +40,6 @@ export declare class VertexAiSessionService extends BaseSessionService {
32
40
  createSession({ appName, userId, state, sessionId, }: CreateSessionRequest): Promise<Session>;
33
41
  getSession({ appName, userId, sessionId, config, }: GetSessionRequest): Promise<Session | undefined>;
34
42
  listSessions({ appName, userId, limit, offset, page, order, }: ListSessionsRequest): Promise<ListSessionsResponse>;
35
- deleteSession({ appName, userId: _userId, sessionId, }: DeleteSessionRequest): Promise<void>;
43
+ deleteSession({ appName, userId, sessionId, }: DeleteSessionRequest): Promise<void>;
36
44
  appendEvent({ session, event, }: AppendEventRequest): Promise<Event>;
37
45
  }
@@ -0,0 +1,24 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2026 Google LLC
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ import { Client } from '@google-cloud/vertexai';
7
+ import { Frontmatter, Skill } from './skill.js';
8
+ import { SkillRegistry } from './skill_registry.js';
9
+ export interface GCPSkillRegistryOptions {
10
+ projectId?: string;
11
+ location?: string;
12
+ client?: Client;
13
+ }
14
+ /**
15
+ * GCP implementation of SkillRegistry using GCP Skill Registry API.
16
+ */
17
+ export declare class GCPSkillRegistry implements SkillRegistry {
18
+ private readonly projectId?;
19
+ private readonly location?;
20
+ private readonly client;
21
+ constructor(options?: GCPSkillRegistryOptions);
22
+ getSkill(name: string): Promise<Skill>;
23
+ searchSkills(query: string): Promise<Frontmatter[]>;
24
+ }
@@ -36,3 +36,10 @@ export declare function validateSkillDir(skillDir: string): Promise<string[]>;
36
36
  * @returns A promise that resolves to a map of skill names to their corresponding Skill objects.
37
37
  */
38
38
  export declare function loadAllSkillsInDir(skillsBasePath: string): Promise<Record<string, Skill>>;
39
+ /**
40
+ * Loads a complete skill directly from in-memory zip file buffer.
41
+ *
42
+ * @param zipBuffer - The raw Buffer of the zip file containing the skill.
43
+ * @returns A Skill object with all components loaded.
44
+ */
45
+ export declare function loadSkillFromZipBuffer(zipBuffer: Buffer): Skill;
@@ -8,7 +8,7 @@ export declare const SNAKE_OR_KEBAB_NAME_PATTERN: RegExp;
8
8
  /**
9
9
  * Schema and Type for Skill Frontmatter metadata.
10
10
  */
11
- export declare const FrontmatterSchema: z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodObject<{
11
+ export declare const FrontmatterSchema: z.ZodPreprocess<z.ZodObject<{
12
12
  name: z.ZodString;
13
13
  description: z.ZodString;
14
14
  license: z.ZodOptional<z.ZodString>;
@@ -0,0 +1,29 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2026 Google LLC
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ import { Frontmatter, Skill } from './skill.js';
7
+ /**
8
+ * Interface for a skill registry.
9
+ */
10
+ export interface SkillRegistry {
11
+ /**
12
+ * Fetches a skill from the registry.
13
+ *
14
+ * @param name The name of the skill.
15
+ * @returns A Promise resolving to a Skill object.
16
+ */
17
+ getSkill(name: string): Promise<Skill>;
18
+ /**
19
+ * Searches for skills in the registry.
20
+ *
21
+ * @param query The search query.
22
+ * @returns A Promise resolving to a list of Frontmatter objects for discovery.
23
+ */
24
+ searchSkills(query: string): Promise<Frontmatter[]>;
25
+ /**
26
+ * Returns the description for the search_skills tool.
27
+ */
28
+ searchToolDescription?(): string | undefined;
29
+ }
@@ -0,0 +1,19 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2026 Google LLC
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ import { FunctionDeclaration } from '@google/genai';
7
+ import { BaseTool, RunAsyncToolRequest } from './base_tool.js';
8
+ /**
9
+ * Tool for requesting context consolidation (compaction).
10
+ *
11
+ * When called by an LLM agent, this tool sets the state flags
12
+ * `temp:consolidate_context` and optionally `temp:consolidate_context_detail`,
13
+ * signalling the context compactor to trigger compaction.
14
+ */
15
+ export declare class ConsolidateContextTool extends BaseTool {
16
+ constructor();
17
+ _getDeclaration(): FunctionDeclaration;
18
+ runAsync({ args, toolContext, }: RunAsyncToolRequest): Promise<unknown>;
19
+ }
@@ -4,7 +4,7 @@
4
4
  * SPDX-License-Identifier: Apache-2.0
5
5
  */
6
6
  import { Part } from '@google/genai';
7
- import { ArtifactVersion, BaseArtifactService, DeleteArtifactRequest, ListVersionsRequest, LoadArtifactRequest, SaveArtifactRequest } from '../artifacts/base_artifact_service.js';
7
+ import { ArtifactVersion, BaseArtifactService, DeleteArtifactRequest, ListArtifactKeysRequest, ListVersionsRequest, LoadArtifactRequest, SaveArtifactRequest } from '../artifacts/base_artifact_service.js';
8
8
  import { Context } from '../agents/context.js';
9
9
  /**
10
10
  * Artifact service that forwards to the parent tool context.
@@ -15,7 +15,8 @@ export declare class ForwardingArtifactService implements BaseArtifactService {
15
15
  constructor(toolContext: Context);
16
16
  saveArtifact(request: SaveArtifactRequest): Promise<number>;
17
17
  loadArtifact(request: LoadArtifactRequest): Promise<Part | undefined>;
18
- listArtifactKeys(): Promise<string[]>;
18
+ listArtifactKeys(_request: ListArtifactKeysRequest): Promise<string[]>;
19
+ private getArtifactService;
19
20
  deleteArtifact(request: DeleteArtifactRequest): Promise<void>;
20
21
  listVersions(request: ListVersionsRequest): Promise<number[]>;
21
22
  listArtifactVersions(request: ListVersionsRequest): Promise<ArtifactVersion[]>;
@@ -0,0 +1,34 @@
1
+ /**
2
+ * @license
3
+ * Copyright 2026 Google LLC
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+ import { OpenAPIV3 } from 'openapi-types';
7
+ import { ApiParameter } from './operation_parser.js';
8
+ export interface OperationEndpoint {
9
+ baseUrl: string;
10
+ path: string;
11
+ method: string;
12
+ }
13
+ export interface ParsedOperation {
14
+ name: string;
15
+ description: string;
16
+ endpoint: OperationEndpoint;
17
+ operation: OpenAPIV3.OperationObject;
18
+ parameters: ApiParameter[];
19
+ returnValue?: ApiParameter;
20
+ authScheme?: OpenAPIV3.SecuritySchemeObject;
21
+ }
22
+ export declare class OpenApiSpecParser {
23
+ private preservePropertyNames;
24
+ constructor(options?: {
25
+ preservePropertyNames?: boolean;
26
+ });
27
+ /**
28
+ * Parses an OpenAPI specification document and extracts a list of operations.
29
+ *
30
+ * @param openapiSpec The OpenAPI V3 document to parse.
31
+ * @returns An array of parsed operations.
32
+ */
33
+ parse(openapiSpec: OpenAPIV3.Document): ParsedOperation[];
34
+ }