anthropic 1.70.0 → 1.71.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 (668) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +44 -0
  3. data/README.md +1 -1
  4. data/lib/anthropic/client.rb +6 -0
  5. data/lib/anthropic/internal/transport/base_client.rb +12 -8
  6. data/lib/anthropic/internal/transport/pooled_net_requester.rb +63 -4
  7. data/lib/anthropic/internal/type/union.rb +6 -2
  8. data/lib/anthropic/internal/util.rb +3 -1
  9. data/lib/anthropic/models/anthropic_beta.rb +7 -4
  10. data/lib/anthropic/models/beta/agent_archive_params.rb +2 -2
  11. data/lib/anthropic/models/beta/agent_create_params.rb +8 -8
  12. data/lib/anthropic/models/beta/agent_list_params.rb +2 -2
  13. data/lib/anthropic/models/beta/agent_retrieve_params.rb +2 -2
  14. data/lib/anthropic/models/beta/agent_update_params.rb +8 -8
  15. data/lib/anthropic/models/beta/agents/version_list_params.rb +2 -2
  16. data/lib/anthropic/models/beta/beta_browser_state_change.rb +0 -6
  17. data/lib/anthropic/models/beta/beta_code_execution_tool_result_block.rb +1 -4
  18. data/lib/anthropic/models/beta/beta_code_execution_tool_result_block_content.rb +0 -1
  19. data/lib/anthropic/models/beta/beta_code_execution_tool_result_block_param.rb +1 -2
  20. data/lib/anthropic/models/beta/beta_code_execution_tool_result_block_param_content.rb +0 -1
  21. data/lib/anthropic/models/beta/beta_compaction_block.rb +9 -1
  22. data/lib/anthropic/models/beta/beta_compaction_block_param.rb +9 -1
  23. data/lib/anthropic/models/beta/beta_compaction_capability.rb +32 -0
  24. data/lib/anthropic/models/beta/beta_compaction_config.rb +40 -0
  25. data/lib/anthropic/models/beta/beta_content_block.rb +3 -4
  26. data/lib/anthropic/models/beta/beta_content_block_param.rb +4 -5
  27. data/lib/anthropic/models/beta/beta_context_management_config.rb +0 -2
  28. data/lib/anthropic/models/beta/beta_dream.rb +1 -4
  29. data/lib/anthropic/models/beta/beta_dream_input.rb +0 -3
  30. data/lib/anthropic/models/beta/beta_dreaming_error.rb +0 -7
  31. data/lib/anthropic/models/beta/beta_fallback_message_iteration_usage.rb +5 -4
  32. data/lib/anthropic/models/beta/beta_fallbacks_param.rb +3 -3
  33. data/lib/anthropic/models/beta/beta_input_transformation.rb +62 -0
  34. data/lib/anthropic/models/beta/beta_iterations_usage.rb +7 -6
  35. data/lib/anthropic/models/beta/beta_managed_agents_agent_with_overrides_params.rb +6 -6
  36. data/lib/anthropic/models/beta/beta_managed_agents_multiagent_coordinator_params.rb +2 -2
  37. data/lib/anthropic/models/beta/beta_managed_agents_multiagent_params.rb +2 -2
  38. data/lib/anthropic/models/beta/beta_managed_agents_multiagent_roster_entry_params.rb +3 -3
  39. data/lib/anthropic/models/beta/beta_managed_agents_user_tool_result_event.rb +3 -3
  40. data/lib/anthropic/models/beta/beta_message.rb +21 -18
  41. data/lib/anthropic/models/beta/beta_message_iteration_usage.rb +3 -3
  42. data/lib/anthropic/models/beta/beta_model_capabilities.rb +14 -1
  43. data/lib/anthropic/models/beta/beta_output_behavior.rb +0 -3
  44. data/lib/anthropic/models/beta/beta_raw_content_block_start_event.rb +4 -9
  45. data/lib/anthropic/models/beta/beta_raw_message_delta_event.rb +20 -17
  46. data/lib/anthropic/models/beta/beta_raw_message_stream_event.rb +2 -2
  47. data/lib/anthropic/models/beta/beta_request_tool_addition_block.rb +1 -11
  48. data/lib/anthropic/models/beta/beta_request_tool_removal_block.rb +1 -11
  49. data/lib/anthropic/models/beta/beta_server_tool_use_block.rb +1 -8
  50. data/lib/anthropic/models/beta/beta_server_tool_use_block_param.rb +1 -4
  51. data/lib/anthropic/models/beta/beta_summarize_compaction.rb +40 -0
  52. data/lib/anthropic/models/beta/beta_thinking_mismatch_allowed_input_transformation.rb +73 -0
  53. data/lib/anthropic/models/beta/beta_tool_result_block_param.rb +0 -1
  54. data/lib/anthropic/models/beta/beta_tool_union.rb +0 -2
  55. data/lib/anthropic/models/beta/beta_tool_use_block.rb +1 -4
  56. data/lib/anthropic/models/beta/beta_tool_use_block_param.rb +1 -4
  57. data/lib/anthropic/models/beta/beta_web_fetch_tool_20250910.rb +14 -1
  58. data/lib/anthropic/models/beta/beta_web_fetch_tool_20260209.rb +14 -1
  59. data/lib/anthropic/models/beta/beta_web_fetch_tool_20260309.rb +14 -1
  60. data/lib/anthropic/models/beta/beta_web_fetch_tool_20260318.rb +14 -1
  61. data/lib/anthropic/models/beta/beta_web_fetch_tool_result_block.rb +1 -7
  62. data/lib/anthropic/models/beta/beta_web_fetch_tool_result_block_param.rb +1 -4
  63. data/lib/anthropic/models/beta/beta_web_fetch_url_source_all.rb +22 -0
  64. data/lib/anthropic/models/beta/beta_web_fetch_url_source_except.rb +29 -0
  65. data/lib/anthropic/models/beta/beta_web_fetch_url_source_none.rb +22 -0
  66. data/lib/anthropic/models/beta/beta_web_fetch_url_source_only.rb +28 -0
  67. data/lib/anthropic/models/beta/beta_web_fetch_url_source_tool_reference.rb +28 -0
  68. data/lib/anthropic/models/beta/beta_web_fetch_url_sources.rb +234 -0
  69. data/lib/anthropic/models/beta/beta_web_search_tool_result_block.rb +1 -7
  70. data/lib/anthropic/models/beta/beta_web_search_tool_result_block_param.rb +3 -6
  71. data/lib/anthropic/models/beta/beta_web_search_tool_result_block_param_content.rb +3 -3
  72. data/lib/anthropic/models/beta/deployment_archive_params.rb +2 -2
  73. data/lib/anthropic/models/beta/deployment_create_params.rb +7 -7
  74. data/lib/anthropic/models/beta/deployment_list_params.rb +2 -2
  75. data/lib/anthropic/models/beta/deployment_pause_params.rb +2 -2
  76. data/lib/anthropic/models/beta/deployment_retrieve_params.rb +2 -2
  77. data/lib/anthropic/models/beta/deployment_run_list_params.rb +2 -2
  78. data/lib/anthropic/models/beta/deployment_run_params.rb +2 -2
  79. data/lib/anthropic/models/beta/deployment_run_retrieve_params.rb +2 -2
  80. data/lib/anthropic/models/beta/deployment_unpause_params.rb +2 -2
  81. data/lib/anthropic/models/beta/deployment_update_params.rb +7 -7
  82. data/lib/anthropic/models/beta/dream_archive_params.rb +2 -2
  83. data/lib/anthropic/models/beta/dream_cancel_params.rb +2 -2
  84. data/lib/anthropic/models/beta/dream_create_params.rb +8 -16
  85. data/lib/anthropic/models/beta/dream_list_params.rb +2 -2
  86. data/lib/anthropic/models/beta/dream_retrieve_params.rb +2 -2
  87. data/lib/anthropic/models/beta/environment_archive_params.rb +2 -2
  88. data/lib/anthropic/models/beta/environment_create_params.rb +2 -2
  89. data/lib/anthropic/models/beta/environment_delete_params.rb +2 -2
  90. data/lib/anthropic/models/beta/environment_list_params.rb +2 -2
  91. data/lib/anthropic/models/beta/environment_retrieve_params.rb +2 -2
  92. data/lib/anthropic/models/beta/environment_update_params.rb +2 -2
  93. data/lib/anthropic/models/beta/environments/work_ack_params.rb +2 -2
  94. data/lib/anthropic/models/beta/environments/work_heartbeat_params.rb +2 -2
  95. data/lib/anthropic/models/beta/environments/work_list_params.rb +2 -2
  96. data/lib/anthropic/models/beta/environments/work_poll_params.rb +2 -2
  97. data/lib/anthropic/models/beta/environments/work_retrieve_params.rb +2 -2
  98. data/lib/anthropic/models/beta/environments/work_stats_params.rb +2 -2
  99. data/lib/anthropic/models/beta/environments/work_stop_params.rb +2 -2
  100. data/lib/anthropic/models/beta/environments/work_update_params.rb +2 -2
  101. data/lib/anthropic/models/beta/file_delete_params.rb +2 -2
  102. data/lib/anthropic/models/beta/file_download_params.rb +2 -2
  103. data/lib/anthropic/models/beta/file_list_params.rb +2 -2
  104. data/lib/anthropic/models/beta/file_retrieve_metadata_params.rb +2 -2
  105. data/lib/anthropic/models/beta/file_upload_params.rb +2 -2
  106. data/lib/anthropic/models/beta/memory_store_archive_params.rb +2 -2
  107. data/lib/anthropic/models/beta/memory_store_create_params.rb +2 -2
  108. data/lib/anthropic/models/beta/memory_store_delete_params.rb +2 -2
  109. data/lib/anthropic/models/beta/memory_store_list_params.rb +2 -2
  110. data/lib/anthropic/models/beta/memory_store_retrieve_params.rb +2 -2
  111. data/lib/anthropic/models/beta/memory_store_update_params.rb +2 -2
  112. data/lib/anthropic/models/beta/memory_stores/memory_create_params.rb +2 -2
  113. data/lib/anthropic/models/beta/memory_stores/memory_delete_params.rb +2 -2
  114. data/lib/anthropic/models/beta/memory_stores/memory_list_params.rb +2 -2
  115. data/lib/anthropic/models/beta/memory_stores/memory_retrieve_params.rb +2 -2
  116. data/lib/anthropic/models/beta/memory_stores/memory_update_params.rb +2 -2
  117. data/lib/anthropic/models/beta/memory_stores/memory_version_list_params.rb +2 -2
  118. data/lib/anthropic/models/beta/memory_stores/memory_version_redact_params.rb +2 -2
  119. data/lib/anthropic/models/beta/memory_stores/memory_version_retrieve_params.rb +2 -2
  120. data/lib/anthropic/models/beta/message_count_tokens_params.rb +18 -5
  121. data/lib/anthropic/models/beta/message_create_params.rb +26 -11
  122. data/lib/anthropic/models/beta/messages/batch_cancel_params.rb +2 -2
  123. data/lib/anthropic/models/beta/messages/batch_create_params.rb +26 -11
  124. data/lib/anthropic/models/beta/messages/batch_delete_params.rb +2 -2
  125. data/lib/anthropic/models/beta/messages/batch_list_params.rb +2 -2
  126. data/lib/anthropic/models/beta/messages/batch_results_params.rb +2 -2
  127. data/lib/anthropic/models/beta/messages/batch_retrieve_params.rb +2 -2
  128. data/lib/anthropic/models/beta/model_list_params.rb +2 -2
  129. data/lib/anthropic/models/beta/model_retrieve_params.rb +2 -2
  130. data/lib/anthropic/models/beta/organization/beta_data_residency.rb +41 -12
  131. data/lib/anthropic/models/beta/organization/beta_data_residency_create_config.rb +5 -5
  132. data/lib/anthropic/models/beta/organization/beta_data_residency_update_config.rb +5 -5
  133. data/lib/anthropic/models/beta/organization/federation/issuer_archive_params.rb +2 -2
  134. data/lib/anthropic/models/beta/organization/federation/issuer_create_params.rb +2 -2
  135. data/lib/anthropic/models/beta/organization/federation/issuer_list_params.rb +2 -2
  136. data/lib/anthropic/models/beta/organization/federation/issuer_retrieve_params.rb +2 -2
  137. data/lib/anthropic/models/beta/organization/federation/issuer_update_params.rb +2 -2
  138. data/lib/anthropic/models/beta/organization/federation/rule_archive_params.rb +2 -2
  139. data/lib/anthropic/models/beta/organization/federation/rule_create_params.rb +2 -2
  140. data/lib/anthropic/models/beta/organization/federation/rule_list_params.rb +2 -2
  141. data/lib/anthropic/models/beta/organization/federation/rule_retrieve_params.rb +2 -2
  142. data/lib/anthropic/models/beta/organization/federation/rule_update_params.rb +2 -2
  143. data/lib/anthropic/models/beta/organization/federation/rules/workspace_add_params.rb +2 -2
  144. data/lib/anthropic/models/beta/organization/federation/rules/workspace_list_params.rb +2 -2
  145. data/lib/anthropic/models/beta/organization/federation/rules/workspace_remove_params.rb +2 -2
  146. data/lib/anthropic/models/beta/organization/service_account_archive_params.rb +2 -2
  147. data/lib/anthropic/models/beta/organization/service_account_create_params.rb +2 -2
  148. data/lib/anthropic/models/beta/organization/service_account_list_params.rb +2 -2
  149. data/lib/anthropic/models/beta/organization/service_account_retrieve_params.rb +2 -2
  150. data/lib/anthropic/models/beta/organization/service_account_update_params.rb +2 -2
  151. data/lib/anthropic/models/beta/organization/service_accounts/workspace_add_params.rb +2 -2
  152. data/lib/anthropic/models/beta/organization/service_accounts/workspace_list_params.rb +2 -2
  153. data/lib/anthropic/models/beta/organization/service_accounts/workspace_remove_params.rb +2 -2
  154. data/lib/anthropic/models/beta/organization/workspace_create_params.rb +2 -2
  155. data/lib/anthropic/models/beta/organization/workspaces/service_account_add_params.rb +2 -2
  156. data/lib/anthropic/models/beta/organization/workspaces/service_account_list_params.rb +2 -2
  157. data/lib/anthropic/models/beta/organization/workspaces/service_account_remove_params.rb +2 -2
  158. data/lib/anthropic/models/beta/organization/workspaces/service_account_retrieve_params.rb +2 -2
  159. data/lib/anthropic/models/beta/organization/workspaces/service_account_update_params.rb +2 -2
  160. data/lib/anthropic/models/beta/session_archive_params.rb +2 -2
  161. data/lib/anthropic/models/beta/session_create_params.rb +7 -7
  162. data/lib/anthropic/models/beta/session_delete_params.rb +2 -2
  163. data/lib/anthropic/models/beta/session_list_params.rb +2 -2
  164. data/lib/anthropic/models/beta/session_retrieve_params.rb +2 -2
  165. data/lib/anthropic/models/beta/session_update_params.rb +2 -2
  166. data/lib/anthropic/models/beta/sessions/beta_managed_agents_agent_custom_tool_use_event.rb +3 -1
  167. data/lib/anthropic/models/beta/sessions/beta_managed_agents_agent_mcp_tool_use_event.rb +2 -2
  168. data/lib/anthropic/models/beta/sessions/beta_managed_agents_agent_tool_use_event.rb +3 -2
  169. data/lib/anthropic/models/beta/sessions/beta_managed_agents_session_error_event.rb +1 -12
  170. data/lib/anthropic/models/beta/sessions/beta_managed_agents_session_event.rb +2 -2
  171. data/lib/anthropic/models/beta/sessions/beta_managed_agents_session_resource.rb +0 -2
  172. data/lib/anthropic/models/beta/sessions/beta_managed_agents_session_status_idle_event.rb +1 -4
  173. data/lib/anthropic/models/beta/sessions/beta_managed_agents_session_thread_status_idle_event.rb +1 -4
  174. data/lib/anthropic/models/beta/sessions/beta_managed_agents_stream_session_events.rb +2 -2
  175. data/lib/anthropic/models/beta/sessions/beta_managed_agents_stream_session_thread_events.rb +2 -2
  176. data/lib/anthropic/models/beta/sessions/beta_managed_agents_user_custom_tool_result_event.rb +3 -3
  177. data/lib/anthropic/models/beta/sessions/beta_managed_agents_user_tool_confirmation_event.rb +3 -4
  178. data/lib/anthropic/models/beta/sessions/event_list_params.rb +2 -2
  179. data/lib/anthropic/models/beta/sessions/event_send_params.rb +2 -2
  180. data/lib/anthropic/models/beta/sessions/event_stream_params.rb +2 -2
  181. data/lib/anthropic/models/beta/sessions/resource_add_params.rb +2 -2
  182. data/lib/anthropic/models/beta/sessions/resource_delete_params.rb +2 -2
  183. data/lib/anthropic/models/beta/sessions/resource_list_params.rb +2 -2
  184. data/lib/anthropic/models/beta/sessions/resource_retrieve_params.rb +2 -2
  185. data/lib/anthropic/models/beta/sessions/resource_update_params.rb +2 -2
  186. data/lib/anthropic/models/beta/sessions/thread_archive_params.rb +2 -2
  187. data/lib/anthropic/models/beta/sessions/thread_list_params.rb +2 -2
  188. data/lib/anthropic/models/beta/sessions/thread_retrieve_params.rb +2 -2
  189. data/lib/anthropic/models/beta/sessions/threads/event_list_params.rb +2 -2
  190. data/lib/anthropic/models/beta/sessions/threads/event_stream_params.rb +2 -2
  191. data/lib/anthropic/models/beta/skill_create_params.rb +2 -2
  192. data/lib/anthropic/models/beta/skill_delete_params.rb +2 -2
  193. data/lib/anthropic/models/beta/skill_list_params.rb +2 -2
  194. data/lib/anthropic/models/beta/skill_retrieve_params.rb +2 -2
  195. data/lib/anthropic/models/beta/skills/version_create_params.rb +2 -2
  196. data/lib/anthropic/models/beta/skills/version_delete_params.rb +2 -2
  197. data/lib/anthropic/models/beta/skills/version_download_params.rb +2 -2
  198. data/lib/anthropic/models/beta/skills/version_list_params.rb +2 -2
  199. data/lib/anthropic/models/beta/skills/version_retrieve_params.rb +2 -2
  200. data/lib/anthropic/models/beta/tunnel_archive_params.rb +2 -2
  201. data/lib/anthropic/models/beta/tunnel_create_params.rb +2 -2
  202. data/lib/anthropic/models/beta/tunnel_list_params.rb +2 -2
  203. data/lib/anthropic/models/beta/tunnel_retrieve_params.rb +2 -2
  204. data/lib/anthropic/models/beta/tunnel_reveal_token_params.rb +2 -2
  205. data/lib/anthropic/models/beta/tunnel_rotate_token_params.rb +2 -2
  206. data/lib/anthropic/models/beta/tunnels/certificate_archive_params.rb +2 -2
  207. data/lib/anthropic/models/beta/tunnels/certificate_create_params.rb +2 -2
  208. data/lib/anthropic/models/beta/tunnels/certificate_list_params.rb +2 -2
  209. data/lib/anthropic/models/beta/tunnels/certificate_retrieve_params.rb +2 -2
  210. data/lib/anthropic/models/beta/user_profile_create_enrollment_url_params.rb +10 -3
  211. data/lib/anthropic/models/beta/user_profile_create_params.rb +10 -3
  212. data/lib/anthropic/models/beta/user_profile_list_params.rb +10 -3
  213. data/lib/anthropic/models/beta/user_profile_retrieve_params.rb +10 -3
  214. data/lib/anthropic/models/beta/user_profile_update_params.rb +10 -3
  215. data/lib/anthropic/models/beta/vault_archive_params.rb +2 -2
  216. data/lib/anthropic/models/beta/vault_create_params.rb +2 -2
  217. data/lib/anthropic/models/beta/vault_delete_params.rb +2 -2
  218. data/lib/anthropic/models/beta/vault_list_params.rb +2 -2
  219. data/lib/anthropic/models/beta/vault_retrieve_params.rb +2 -2
  220. data/lib/anthropic/models/beta/vault_update_params.rb +2 -2
  221. data/lib/anthropic/models/beta/vaults/beta_managed_agents_credential_networking_params.rb +0 -3
  222. data/lib/anthropic/models/beta/vaults/beta_managed_agents_mcp_oauth_refresh_params.rb +1 -4
  223. data/lib/anthropic/models/beta/vaults/beta_managed_agents_mcp_oauth_refresh_response.rb +1 -4
  224. data/lib/anthropic/models/beta/vaults/beta_managed_agents_mcp_oauth_refresh_update_params.rb +1 -4
  225. data/lib/anthropic/models/beta/vaults/credential_archive_params.rb +2 -2
  226. data/lib/anthropic/models/beta/vaults/credential_create_params.rb +2 -2
  227. data/lib/anthropic/models/beta/vaults/credential_delete_params.rb +2 -2
  228. data/lib/anthropic/models/beta/vaults/credential_list_params.rb +2 -2
  229. data/lib/anthropic/models/beta/vaults/credential_mcp_oauth_validate_params.rb +2 -2
  230. data/lib/anthropic/models/beta/vaults/credential_retrieve_params.rb +2 -2
  231. data/lib/anthropic/models/beta/vaults/credential_update_params.rb +2 -2
  232. data/lib/anthropic/models/browser_state_change.rb +0 -6
  233. data/lib/anthropic/models/code_execution_tool_result_block.rb +1 -4
  234. data/lib/anthropic/models/code_execution_tool_result_block_content.rb +0 -1
  235. data/lib/anthropic/models/code_execution_tool_result_block_param.rb +1 -2
  236. data/lib/anthropic/models/code_execution_tool_result_block_param_content.rb +0 -1
  237. data/lib/anthropic/models/completion_create_params.rb +3 -3
  238. data/lib/anthropic/models/content_block.rb +2 -3
  239. data/lib/anthropic/models/content_block_param.rb +2 -3
  240. data/lib/anthropic/models/message_count_tokens_tool.rb +0 -2
  241. data/lib/anthropic/models/message_create_params.rb +1 -1
  242. data/lib/anthropic/models/messages/batch_create_params.rb +1 -1
  243. data/lib/anthropic/models/model_list_params.rb +2 -2
  244. data/lib/anthropic/models/model_retrieve_params.rb +2 -2
  245. data/lib/anthropic/models/raw_content_block_start_event.rb +3 -8
  246. data/lib/anthropic/models/raw_message_stream_event.rb +1 -1
  247. data/lib/anthropic/models/server_tool_use_block.rb +1 -8
  248. data/lib/anthropic/models/server_tool_use_block_param.rb +1 -4
  249. data/lib/anthropic/models/tool_result_block_param.rb +0 -1
  250. data/lib/anthropic/models/tool_union.rb +0 -2
  251. data/lib/anthropic/models/tool_use_block.rb +2 -4
  252. data/lib/anthropic/models/tool_use_block_param.rb +1 -4
  253. data/lib/anthropic/models/web_fetch_tool_20250910.rb +14 -1
  254. data/lib/anthropic/models/web_fetch_tool_20260209.rb +14 -1
  255. data/lib/anthropic/models/web_fetch_tool_20260309.rb +14 -1
  256. data/lib/anthropic/models/web_fetch_tool_20260318.rb +14 -1
  257. data/lib/anthropic/models/web_fetch_tool_result_block.rb +1 -7
  258. data/lib/anthropic/models/web_fetch_tool_result_block_param.rb +1 -4
  259. data/lib/anthropic/models/web_fetch_url_source_all.rb +18 -0
  260. data/lib/anthropic/models/web_fetch_url_source_except.rb +24 -0
  261. data/lib/anthropic/models/web_fetch_url_source_none.rb +18 -0
  262. data/lib/anthropic/models/web_fetch_url_source_only.rb +23 -0
  263. data/lib/anthropic/models/web_fetch_url_source_tool_reference.rb +24 -0
  264. data/lib/anthropic/models/web_fetch_url_sources.rb +230 -0
  265. data/lib/anthropic/models/web_search_tool_result_block.rb +1 -7
  266. data/lib/anthropic/models/web_search_tool_result_block_param.rb +3 -6
  267. data/lib/anthropic/models/web_search_tool_result_block_param_content.rb +3 -3
  268. data/lib/anthropic/models.rb +12 -0
  269. data/lib/anthropic/resources/beta/agents/versions.rb +1 -1
  270. data/lib/anthropic/resources/beta/agents.rb +7 -7
  271. data/lib/anthropic/resources/beta/deployment_runs.rb +2 -2
  272. data/lib/anthropic/resources/beta/deployments.rb +10 -10
  273. data/lib/anthropic/resources/beta/dreams.rb +7 -7
  274. data/lib/anthropic/resources/beta/environments/work.rb +8 -8
  275. data/lib/anthropic/resources/beta/environments.rb +6 -6
  276. data/lib/anthropic/resources/beta/files.rb +5 -5
  277. data/lib/anthropic/resources/beta/memory_stores/memories.rb +5 -5
  278. data/lib/anthropic/resources/beta/memory_stores/memory_versions.rb +3 -3
  279. data/lib/anthropic/resources/beta/memory_stores.rb +6 -6
  280. data/lib/anthropic/resources/beta/messages/batches.rb +6 -6
  281. data/lib/anthropic/resources/beta/messages.rb +22 -14
  282. data/lib/anthropic/resources/beta/models.rb +2 -2
  283. data/lib/anthropic/resources/beta/organization/federation/issuers.rb +5 -5
  284. data/lib/anthropic/resources/beta/organization/federation/rules/workspaces.rb +3 -3
  285. data/lib/anthropic/resources/beta/organization/federation/rules.rb +5 -5
  286. data/lib/anthropic/resources/beta/organization/service_accounts/workspaces.rb +3 -3
  287. data/lib/anthropic/resources/beta/organization/service_accounts.rb +5 -5
  288. data/lib/anthropic/resources/beta/organization/workspaces/service_accounts.rb +5 -5
  289. data/lib/anthropic/resources/beta/organization/workspaces.rb +1 -1
  290. data/lib/anthropic/resources/beta/sessions/events.rb +3 -3
  291. data/lib/anthropic/resources/beta/sessions/resources.rb +5 -5
  292. data/lib/anthropic/resources/beta/sessions/threads/events.rb +2 -2
  293. data/lib/anthropic/resources/beta/sessions/threads.rb +3 -3
  294. data/lib/anthropic/resources/beta/sessions.rb +7 -7
  295. data/lib/anthropic/resources/beta/skills/versions.rb +5 -5
  296. data/lib/anthropic/resources/beta/skills.rb +4 -4
  297. data/lib/anthropic/resources/beta/tunnels/certificates.rb +4 -4
  298. data/lib/anthropic/resources/beta/tunnels.rb +6 -6
  299. data/lib/anthropic/resources/beta/user_profiles.rb +38 -15
  300. data/lib/anthropic/resources/beta/vaults/credentials.rb +7 -7
  301. data/lib/anthropic/resources/beta/vaults.rb +6 -6
  302. data/lib/anthropic/resources/completions.rb +2 -2
  303. data/lib/anthropic/resources/models.rb +2 -2
  304. data/lib/anthropic/version.rb +1 -1
  305. data/lib/anthropic.rb +17 -1
  306. data/manifest.yaml +0 -1
  307. data/rbi/anthropic/client.rbi +5 -0
  308. data/rbi/anthropic/internal/transport/base_client.rbi +2 -0
  309. data/rbi/anthropic/internal/transport/pooled_net_requester.rbi +27 -5
  310. data/rbi/anthropic/models/anthropic_beta.rbi +3 -1
  311. data/rbi/anthropic/models/beta/agent_archive_params.rbi +4 -4
  312. data/rbi/anthropic/models/beta/agent_create_params.rbi +12 -12
  313. data/rbi/anthropic/models/beta/agent_list_params.rbi +4 -4
  314. data/rbi/anthropic/models/beta/agent_retrieve_params.rbi +4 -4
  315. data/rbi/anthropic/models/beta/agent_update_params.rbi +14 -14
  316. data/rbi/anthropic/models/beta/agents/version_list_params.rbi +4 -4
  317. data/rbi/anthropic/models/beta/beta_browser_state_change.rbi +0 -6
  318. data/rbi/anthropic/models/beta/beta_code_execution_tool_result_block.rbi +1 -7
  319. data/rbi/anthropic/models/beta/beta_code_execution_tool_result_block_content.rbi +0 -1
  320. data/rbi/anthropic/models/beta/beta_code_execution_tool_result_block_param.rbi +0 -2
  321. data/rbi/anthropic/models/beta/beta_code_execution_tool_result_block_param_content.rbi +0 -1
  322. data/rbi/anthropic/models/beta/beta_compaction_block.rbi +9 -1
  323. data/rbi/anthropic/models/beta/beta_compaction_block_param.rbi +9 -1
  324. data/rbi/anthropic/models/beta/beta_compaction_capability.rbi +60 -0
  325. data/rbi/anthropic/models/beta/beta_compaction_config.rbi +54 -0
  326. data/rbi/anthropic/models/beta/beta_content_block.rbi +2 -4
  327. data/rbi/anthropic/models/beta/beta_content_block_param.rbi +4 -9
  328. data/rbi/anthropic/models/beta/beta_context_management_config.rbi +0 -2
  329. data/rbi/anthropic/models/beta/beta_dream.rbi +0 -6
  330. data/rbi/anthropic/models/beta/beta_dream_input.rbi +0 -3
  331. data/rbi/anthropic/models/beta/beta_dreaming_error.rbi +0 -7
  332. data/rbi/anthropic/models/beta/beta_fallback_message_iteration_usage.rbi +5 -4
  333. data/rbi/anthropic/models/beta/beta_fallbacks_param.rbi +1 -1
  334. data/rbi/anthropic/models/beta/beta_input_transformation.rbi +99 -0
  335. data/rbi/anthropic/models/beta/beta_iterations_usage.rbi +5 -2
  336. data/rbi/anthropic/models/beta/beta_managed_agents_agent_with_overrides_params.rbi +10 -10
  337. data/rbi/anthropic/models/beta/beta_managed_agents_multiagent_coordinator_params.rbi +6 -6
  338. data/rbi/anthropic/models/beta/beta_managed_agents_multiagent_params.rbi +6 -6
  339. data/rbi/anthropic/models/beta/beta_managed_agents_multiagent_roster_entry_params.rbi +2 -2
  340. data/rbi/anthropic/models/beta/beta_managed_agents_user_tool_result_event.rbi +4 -4
  341. data/rbi/anthropic/models/beta/beta_message.rbi +40 -29
  342. data/rbi/anthropic/models/beta/beta_message_iteration_usage.rbi +3 -3
  343. data/rbi/anthropic/models/beta/beta_model_capabilities.rbi +21 -0
  344. data/rbi/anthropic/models/beta/beta_output_behavior.rbi +0 -3
  345. data/rbi/anthropic/models/beta/beta_raw_content_block_start_event.rbi +3 -11
  346. data/rbi/anthropic/models/beta/beta_raw_message_delta_event.rbi +40 -29
  347. data/rbi/anthropic/models/beta/beta_raw_message_stream_event.rbi +21 -14
  348. data/rbi/anthropic/models/beta/beta_request_tool_addition_block.rbi +0 -9
  349. data/rbi/anthropic/models/beta/beta_request_tool_removal_block.rbi +0 -9
  350. data/rbi/anthropic/models/beta/beta_server_tool_use_block.rbi +1 -10
  351. data/rbi/anthropic/models/beta/beta_server_tool_use_block_param.rbi +0 -3
  352. data/rbi/anthropic/models/beta/beta_summarize_compaction.rbi +54 -0
  353. data/rbi/anthropic/models/beta/beta_thinking_mismatch_allowed_input_transformation.rbi +140 -0
  354. data/rbi/anthropic/models/beta/beta_tool_result_block_param.rbi +0 -1
  355. data/rbi/anthropic/models/beta/beta_tool_union.rbi +0 -2
  356. data/rbi/anthropic/models/beta/beta_tool_use_block.rbi +0 -3
  357. data/rbi/anthropic/models/beta/beta_tool_use_block_param.rbi +0 -3
  358. data/rbi/anthropic/models/beta/beta_web_fetch_tool_20250910.rbi +28 -1
  359. data/rbi/anthropic/models/beta/beta_web_fetch_tool_20260209.rbi +28 -1
  360. data/rbi/anthropic/models/beta/beta_web_fetch_tool_20260309.rbi +27 -0
  361. data/rbi/anthropic/models/beta/beta_web_fetch_tool_20260318.rbi +27 -0
  362. data/rbi/anthropic/models/beta/beta_web_fetch_tool_result_block.rbi +0 -3
  363. data/rbi/anthropic/models/beta/beta_web_fetch_tool_result_block_param.rbi +0 -3
  364. data/rbi/anthropic/models/beta/beta_web_fetch_url_source_all.rbi +32 -0
  365. data/rbi/anthropic/models/beta/beta_web_fetch_url_source_except.rbi +53 -0
  366. data/rbi/anthropic/models/beta/beta_web_fetch_url_source_none.rbi +32 -0
  367. data/rbi/anthropic/models/beta/beta_web_fetch_url_source_only.rbi +52 -0
  368. data/rbi/anthropic/models/beta/beta_web_fetch_url_source_tool_reference.rbi +36 -0
  369. data/rbi/anthropic/models/beta/beta_web_fetch_url_sources.rbi +412 -0
  370. data/rbi/anthropic/models/beta/beta_web_search_tool_result_block.rbi +0 -3
  371. data/rbi/anthropic/models/beta/beta_web_search_tool_result_block_param.rbi +6 -11
  372. data/rbi/anthropic/models/beta/beta_web_search_tool_result_block_param_content.rbi +2 -2
  373. data/rbi/anthropic/models/beta/deployment_archive_params.rbi +4 -4
  374. data/rbi/anthropic/models/beta/deployment_create_params.rbi +9 -9
  375. data/rbi/anthropic/models/beta/deployment_list_params.rbi +4 -4
  376. data/rbi/anthropic/models/beta/deployment_pause_params.rbi +4 -4
  377. data/rbi/anthropic/models/beta/deployment_retrieve_params.rbi +4 -4
  378. data/rbi/anthropic/models/beta/deployment_run_list_params.rbi +4 -4
  379. data/rbi/anthropic/models/beta/deployment_run_params.rbi +4 -4
  380. data/rbi/anthropic/models/beta/deployment_run_retrieve_params.rbi +4 -4
  381. data/rbi/anthropic/models/beta/deployment_unpause_params.rbi +4 -4
  382. data/rbi/anthropic/models/beta/deployment_update_params.rbi +11 -11
  383. data/rbi/anthropic/models/beta/dream_archive_params.rbi +4 -4
  384. data/rbi/anthropic/models/beta/dream_cancel_params.rbi +4 -4
  385. data/rbi/anthropic/models/beta/dream_create_params.rbi +8 -17
  386. data/rbi/anthropic/models/beta/dream_list_params.rbi +4 -4
  387. data/rbi/anthropic/models/beta/dream_retrieve_params.rbi +4 -4
  388. data/rbi/anthropic/models/beta/environment_archive_params.rbi +4 -4
  389. data/rbi/anthropic/models/beta/environment_create_params.rbi +4 -4
  390. data/rbi/anthropic/models/beta/environment_delete_params.rbi +4 -4
  391. data/rbi/anthropic/models/beta/environment_list_params.rbi +4 -4
  392. data/rbi/anthropic/models/beta/environment_retrieve_params.rbi +4 -4
  393. data/rbi/anthropic/models/beta/environment_update_params.rbi +4 -4
  394. data/rbi/anthropic/models/beta/environments/work_ack_params.rbi +4 -4
  395. data/rbi/anthropic/models/beta/environments/work_heartbeat_params.rbi +4 -4
  396. data/rbi/anthropic/models/beta/environments/work_list_params.rbi +4 -4
  397. data/rbi/anthropic/models/beta/environments/work_poll_params.rbi +4 -4
  398. data/rbi/anthropic/models/beta/environments/work_retrieve_params.rbi +4 -4
  399. data/rbi/anthropic/models/beta/environments/work_stats_params.rbi +4 -4
  400. data/rbi/anthropic/models/beta/environments/work_stop_params.rbi +4 -4
  401. data/rbi/anthropic/models/beta/environments/work_update_params.rbi +4 -4
  402. data/rbi/anthropic/models/beta/file_delete_params.rbi +4 -4
  403. data/rbi/anthropic/models/beta/file_download_params.rbi +4 -4
  404. data/rbi/anthropic/models/beta/file_list_params.rbi +4 -4
  405. data/rbi/anthropic/models/beta/file_retrieve_metadata_params.rbi +4 -4
  406. data/rbi/anthropic/models/beta/file_upload_params.rbi +4 -4
  407. data/rbi/anthropic/models/beta/memory_store_archive_params.rbi +4 -4
  408. data/rbi/anthropic/models/beta/memory_store_create_params.rbi +4 -4
  409. data/rbi/anthropic/models/beta/memory_store_delete_params.rbi +4 -4
  410. data/rbi/anthropic/models/beta/memory_store_list_params.rbi +4 -4
  411. data/rbi/anthropic/models/beta/memory_store_retrieve_params.rbi +4 -4
  412. data/rbi/anthropic/models/beta/memory_store_update_params.rbi +4 -4
  413. data/rbi/anthropic/models/beta/memory_stores/memory_create_params.rbi +4 -4
  414. data/rbi/anthropic/models/beta/memory_stores/memory_delete_params.rbi +4 -4
  415. data/rbi/anthropic/models/beta/memory_stores/memory_list_params.rbi +4 -4
  416. data/rbi/anthropic/models/beta/memory_stores/memory_retrieve_params.rbi +4 -4
  417. data/rbi/anthropic/models/beta/memory_stores/memory_update_params.rbi +4 -4
  418. data/rbi/anthropic/models/beta/memory_stores/memory_version_list_params.rbi +4 -4
  419. data/rbi/anthropic/models/beta/memory_stores/memory_version_redact_params.rbi +4 -4
  420. data/rbi/anthropic/models/beta/memory_stores/memory_version_retrieve_params.rbi +4 -4
  421. data/rbi/anthropic/models/beta/message_count_tokens_params.rbi +34 -6
  422. data/rbi/anthropic/models/beta/message_create_params.rbi +43 -13
  423. data/rbi/anthropic/models/beta/messages/batch_cancel_params.rbi +4 -4
  424. data/rbi/anthropic/models/beta/messages/batch_create_params.rbi +47 -15
  425. data/rbi/anthropic/models/beta/messages/batch_delete_params.rbi +4 -4
  426. data/rbi/anthropic/models/beta/messages/batch_list_params.rbi +4 -4
  427. data/rbi/anthropic/models/beta/messages/batch_results_params.rbi +4 -4
  428. data/rbi/anthropic/models/beta/messages/batch_retrieve_params.rbi +4 -4
  429. data/rbi/anthropic/models/beta/model_list_params.rbi +4 -4
  430. data/rbi/anthropic/models/beta/model_retrieve_params.rbi +4 -4
  431. data/rbi/anthropic/models/beta/organization/beta_data_residency.rbi +103 -10
  432. data/rbi/anthropic/models/beta/organization/beta_data_residency_create_config.rbi +8 -8
  433. data/rbi/anthropic/models/beta/organization/beta_data_residency_update_config.rbi +8 -8
  434. data/rbi/anthropic/models/beta/organization/federation/issuer_archive_params.rbi +4 -4
  435. data/rbi/anthropic/models/beta/organization/federation/issuer_create_params.rbi +4 -4
  436. data/rbi/anthropic/models/beta/organization/federation/issuer_list_params.rbi +4 -4
  437. data/rbi/anthropic/models/beta/organization/federation/issuer_retrieve_params.rbi +4 -4
  438. data/rbi/anthropic/models/beta/organization/federation/issuer_update_params.rbi +4 -4
  439. data/rbi/anthropic/models/beta/organization/federation/rule_archive_params.rbi +4 -4
  440. data/rbi/anthropic/models/beta/organization/federation/rule_create_params.rbi +4 -4
  441. data/rbi/anthropic/models/beta/organization/federation/rule_list_params.rbi +4 -4
  442. data/rbi/anthropic/models/beta/organization/federation/rule_retrieve_params.rbi +4 -4
  443. data/rbi/anthropic/models/beta/organization/federation/rule_update_params.rbi +4 -4
  444. data/rbi/anthropic/models/beta/organization/federation/rules/workspace_add_params.rbi +4 -4
  445. data/rbi/anthropic/models/beta/organization/federation/rules/workspace_list_params.rbi +4 -4
  446. data/rbi/anthropic/models/beta/organization/federation/rules/workspace_remove_params.rbi +4 -4
  447. data/rbi/anthropic/models/beta/organization/service_account_archive_params.rbi +4 -4
  448. data/rbi/anthropic/models/beta/organization/service_account_create_params.rbi +4 -4
  449. data/rbi/anthropic/models/beta/organization/service_account_list_params.rbi +4 -4
  450. data/rbi/anthropic/models/beta/organization/service_account_retrieve_params.rbi +4 -4
  451. data/rbi/anthropic/models/beta/organization/service_account_update_params.rbi +4 -4
  452. data/rbi/anthropic/models/beta/organization/service_accounts/workspace_add_params.rbi +4 -4
  453. data/rbi/anthropic/models/beta/organization/service_accounts/workspace_list_params.rbi +4 -4
  454. data/rbi/anthropic/models/beta/organization/service_accounts/workspace_remove_params.rbi +4 -4
  455. data/rbi/anthropic/models/beta/organization/workspace_create_params.rbi +4 -4
  456. data/rbi/anthropic/models/beta/organization/workspaces/service_account_add_params.rbi +4 -4
  457. data/rbi/anthropic/models/beta/organization/workspaces/service_account_list_params.rbi +4 -4
  458. data/rbi/anthropic/models/beta/organization/workspaces/service_account_remove_params.rbi +4 -4
  459. data/rbi/anthropic/models/beta/organization/workspaces/service_account_retrieve_params.rbi +4 -4
  460. data/rbi/anthropic/models/beta/organization/workspaces/service_account_update_params.rbi +4 -4
  461. data/rbi/anthropic/models/beta/session_archive_params.rbi +4 -4
  462. data/rbi/anthropic/models/beta/session_create_params.rbi +12 -12
  463. data/rbi/anthropic/models/beta/session_delete_params.rbi +4 -4
  464. data/rbi/anthropic/models/beta/session_list_params.rbi +4 -4
  465. data/rbi/anthropic/models/beta/session_retrieve_params.rbi +4 -4
  466. data/rbi/anthropic/models/beta/session_update_params.rbi +4 -4
  467. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_agent_custom_tool_use_event.rbi +6 -2
  468. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_agent_mcp_tool_use_event.rbi +4 -4
  469. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_agent_tool_use_event.rbi +6 -4
  470. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_session_error_event.rbi +0 -9
  471. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_session_event.rbi +0 -4
  472. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_session_resource.rbi +0 -1
  473. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_session_status_idle_event.rbi +0 -3
  474. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_session_thread_status_idle_event.rbi +0 -3
  475. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_stream_session_events.rbi +0 -4
  476. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_stream_session_thread_events.rbi +0 -4
  477. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_user_custom_tool_result_event.rbi +4 -4
  478. data/rbi/anthropic/models/beta/sessions/beta_managed_agents_user_tool_confirmation_event.rbi +4 -6
  479. data/rbi/anthropic/models/beta/sessions/event_list_params.rbi +4 -4
  480. data/rbi/anthropic/models/beta/sessions/event_send_params.rbi +4 -4
  481. data/rbi/anthropic/models/beta/sessions/event_stream_params.rbi +4 -4
  482. data/rbi/anthropic/models/beta/sessions/resource_add_params.rbi +4 -4
  483. data/rbi/anthropic/models/beta/sessions/resource_delete_params.rbi +4 -4
  484. data/rbi/anthropic/models/beta/sessions/resource_list_params.rbi +4 -4
  485. data/rbi/anthropic/models/beta/sessions/resource_retrieve_params.rbi +4 -4
  486. data/rbi/anthropic/models/beta/sessions/resource_update_params.rbi +4 -4
  487. data/rbi/anthropic/models/beta/sessions/thread_archive_params.rbi +4 -4
  488. data/rbi/anthropic/models/beta/sessions/thread_list_params.rbi +4 -4
  489. data/rbi/anthropic/models/beta/sessions/thread_retrieve_params.rbi +4 -4
  490. data/rbi/anthropic/models/beta/sessions/threads/event_list_params.rbi +4 -4
  491. data/rbi/anthropic/models/beta/sessions/threads/event_stream_params.rbi +4 -4
  492. data/rbi/anthropic/models/beta/skill_create_params.rbi +4 -4
  493. data/rbi/anthropic/models/beta/skill_delete_params.rbi +4 -4
  494. data/rbi/anthropic/models/beta/skill_list_params.rbi +4 -4
  495. data/rbi/anthropic/models/beta/skill_retrieve_params.rbi +4 -4
  496. data/rbi/anthropic/models/beta/skills/version_create_params.rbi +4 -4
  497. data/rbi/anthropic/models/beta/skills/version_delete_params.rbi +4 -4
  498. data/rbi/anthropic/models/beta/skills/version_download_params.rbi +4 -4
  499. data/rbi/anthropic/models/beta/skills/version_list_params.rbi +4 -4
  500. data/rbi/anthropic/models/beta/skills/version_retrieve_params.rbi +4 -4
  501. data/rbi/anthropic/models/beta/tunnel_archive_params.rbi +4 -4
  502. data/rbi/anthropic/models/beta/tunnel_create_params.rbi +4 -4
  503. data/rbi/anthropic/models/beta/tunnel_list_params.rbi +4 -4
  504. data/rbi/anthropic/models/beta/tunnel_retrieve_params.rbi +4 -4
  505. data/rbi/anthropic/models/beta/tunnel_reveal_token_params.rbi +4 -4
  506. data/rbi/anthropic/models/beta/tunnel_rotate_token_params.rbi +4 -4
  507. data/rbi/anthropic/models/beta/tunnels/certificate_archive_params.rbi +4 -4
  508. data/rbi/anthropic/models/beta/tunnels/certificate_create_params.rbi +4 -4
  509. data/rbi/anthropic/models/beta/tunnels/certificate_list_params.rbi +4 -4
  510. data/rbi/anthropic/models/beta/tunnels/certificate_retrieve_params.rbi +4 -4
  511. data/rbi/anthropic/models/beta/user_profile_create_enrollment_url_params.rbi +13 -4
  512. data/rbi/anthropic/models/beta/user_profile_create_params.rbi +13 -4
  513. data/rbi/anthropic/models/beta/user_profile_list_params.rbi +13 -4
  514. data/rbi/anthropic/models/beta/user_profile_retrieve_params.rbi +13 -4
  515. data/rbi/anthropic/models/beta/user_profile_update_params.rbi +13 -4
  516. data/rbi/anthropic/models/beta/vault_archive_params.rbi +4 -4
  517. data/rbi/anthropic/models/beta/vault_create_params.rbi +4 -4
  518. data/rbi/anthropic/models/beta/vault_delete_params.rbi +4 -4
  519. data/rbi/anthropic/models/beta/vault_list_params.rbi +4 -4
  520. data/rbi/anthropic/models/beta/vault_retrieve_params.rbi +4 -4
  521. data/rbi/anthropic/models/beta/vault_update_params.rbi +4 -4
  522. data/rbi/anthropic/models/beta/vaults/beta_managed_agents_credential_networking_params.rbi +0 -3
  523. data/rbi/anthropic/models/beta/vaults/beta_managed_agents_mcp_oauth_refresh_params.rbi +0 -3
  524. data/rbi/anthropic/models/beta/vaults/beta_managed_agents_mcp_oauth_refresh_response.rbi +0 -3
  525. data/rbi/anthropic/models/beta/vaults/beta_managed_agents_mcp_oauth_refresh_update_params.rbi +0 -3
  526. data/rbi/anthropic/models/beta/vaults/credential_archive_params.rbi +4 -4
  527. data/rbi/anthropic/models/beta/vaults/credential_create_params.rbi +4 -4
  528. data/rbi/anthropic/models/beta/vaults/credential_delete_params.rbi +4 -4
  529. data/rbi/anthropic/models/beta/vaults/credential_list_params.rbi +4 -4
  530. data/rbi/anthropic/models/beta/vaults/credential_mcp_oauth_validate_params.rbi +4 -4
  531. data/rbi/anthropic/models/beta/vaults/credential_retrieve_params.rbi +4 -4
  532. data/rbi/anthropic/models/beta/vaults/credential_update_params.rbi +4 -4
  533. data/rbi/anthropic/models/browser_state_change.rbi +0 -6
  534. data/rbi/anthropic/models/code_execution_tool_result_block.rbi +1 -7
  535. data/rbi/anthropic/models/code_execution_tool_result_block_content.rbi +0 -1
  536. data/rbi/anthropic/models/code_execution_tool_result_block_param.rbi +0 -2
  537. data/rbi/anthropic/models/code_execution_tool_result_block_param_content.rbi +0 -1
  538. data/rbi/anthropic/models/completion_create_params.rbi +4 -4
  539. data/rbi/anthropic/models/content_block.rbi +0 -3
  540. data/rbi/anthropic/models/content_block_param.rbi +2 -5
  541. data/rbi/anthropic/models/message_count_tokens_tool.rbi +0 -2
  542. data/rbi/anthropic/models/model_list_params.rbi +4 -4
  543. data/rbi/anthropic/models/model_retrieve_params.rbi +4 -4
  544. data/rbi/anthropic/models/raw_content_block_start_event.rbi +1 -10
  545. data/rbi/anthropic/models/raw_message_stream_event.rbi +0 -1
  546. data/rbi/anthropic/models/server_tool_use_block.rbi +1 -10
  547. data/rbi/anthropic/models/server_tool_use_block_param.rbi +0 -3
  548. data/rbi/anthropic/models/tool_result_block_param.rbi +0 -1
  549. data/rbi/anthropic/models/tool_union.rbi +0 -2
  550. data/rbi/anthropic/models/tool_use_block.rbi +0 -3
  551. data/rbi/anthropic/models/tool_use_block_param.rbi +0 -3
  552. data/rbi/anthropic/models/web_fetch_tool_20250910.rbi +26 -1
  553. data/rbi/anthropic/models/web_fetch_tool_20260209.rbi +26 -1
  554. data/rbi/anthropic/models/web_fetch_tool_20260309.rbi +25 -0
  555. data/rbi/anthropic/models/web_fetch_tool_20260318.rbi +25 -0
  556. data/rbi/anthropic/models/web_fetch_tool_result_block.rbi +0 -3
  557. data/rbi/anthropic/models/web_fetch_tool_result_block_param.rbi +0 -3
  558. data/rbi/anthropic/models/web_fetch_url_source_all.rbi +25 -0
  559. data/rbi/anthropic/models/web_fetch_url_source_except.rbi +43 -0
  560. data/rbi/anthropic/models/web_fetch_url_source_none.rbi +25 -0
  561. data/rbi/anthropic/models/web_fetch_url_source_only.rbi +39 -0
  562. data/rbi/anthropic/models/web_fetch_url_source_tool_reference.rbi +31 -0
  563. data/rbi/anthropic/models/web_fetch_url_sources.rbi +386 -0
  564. data/rbi/anthropic/models/web_search_tool_result_block.rbi +0 -3
  565. data/rbi/anthropic/models/web_search_tool_result_block_param.rbi +6 -9
  566. data/rbi/anthropic/models/web_search_tool_result_block_param_content.rbi +2 -2
  567. data/rbi/anthropic/models.rbi +13 -0
  568. data/rbi/anthropic/resources/beta/agents/versions.rbi +1 -1
  569. data/rbi/anthropic/resources/beta/agents.rbi +9 -9
  570. data/rbi/anthropic/resources/beta/deployment_runs.rbi +2 -2
  571. data/rbi/anthropic/resources/beta/deployments.rbi +12 -12
  572. data/rbi/anthropic/resources/beta/dreams.rbi +8 -10
  573. data/rbi/anthropic/resources/beta/environments/work.rbi +8 -8
  574. data/rbi/anthropic/resources/beta/environments.rbi +6 -6
  575. data/rbi/anthropic/resources/beta/files.rbi +5 -5
  576. data/rbi/anthropic/resources/beta/memory_stores/memories.rbi +5 -5
  577. data/rbi/anthropic/resources/beta/memory_stores/memory_versions.rbi +3 -3
  578. data/rbi/anthropic/resources/beta/memory_stores.rbi +6 -6
  579. data/rbi/anthropic/resources/beta/messages/batches.rbi +6 -6
  580. data/rbi/anthropic/resources/beta/messages.rbi +60 -16
  581. data/rbi/anthropic/resources/beta/models.rbi +2 -2
  582. data/rbi/anthropic/resources/beta/organization/federation/issuers.rbi +5 -5
  583. data/rbi/anthropic/resources/beta/organization/federation/rules/workspaces.rbi +3 -3
  584. data/rbi/anthropic/resources/beta/organization/federation/rules.rbi +5 -5
  585. data/rbi/anthropic/resources/beta/organization/service_accounts/workspaces.rbi +3 -3
  586. data/rbi/anthropic/resources/beta/organization/service_accounts.rbi +5 -5
  587. data/rbi/anthropic/resources/beta/organization/workspaces/service_accounts.rbi +5 -5
  588. data/rbi/anthropic/resources/beta/organization/workspaces.rbi +1 -1
  589. data/rbi/anthropic/resources/beta/sessions/events.rbi +3 -3
  590. data/rbi/anthropic/resources/beta/sessions/resources.rbi +5 -5
  591. data/rbi/anthropic/resources/beta/sessions/threads/events.rbi +2 -2
  592. data/rbi/anthropic/resources/beta/sessions/threads.rbi +3 -3
  593. data/rbi/anthropic/resources/beta/sessions.rbi +8 -8
  594. data/rbi/anthropic/resources/beta/skills/versions.rbi +5 -5
  595. data/rbi/anthropic/resources/beta/skills.rbi +4 -4
  596. data/rbi/anthropic/resources/beta/tunnels/certificates.rbi +4 -4
  597. data/rbi/anthropic/resources/beta/tunnels.rbi +6 -6
  598. data/rbi/anthropic/resources/beta/user_profiles.rbi +45 -5
  599. data/rbi/anthropic/resources/beta/vaults/credentials.rbi +7 -7
  600. data/rbi/anthropic/resources/beta/vaults.rbi +6 -6
  601. data/rbi/anthropic/resources/completions.rbi +2 -2
  602. data/rbi/anthropic/resources/models.rbi +2 -2
  603. data/sig/anthropic/client.rbs +1 -0
  604. data/sig/anthropic/internal/transport/base_client.rbs +1 -0
  605. data/sig/anthropic/internal/transport/pooled_net_requester.rbs +10 -2
  606. data/sig/anthropic/models/anthropic_beta.rbs +4 -2
  607. data/sig/anthropic/models/beta/agent_create_params.rbs +2 -2
  608. data/sig/anthropic/models/beta/agent_update_params.rbs +2 -2
  609. data/sig/anthropic/models/beta/beta_compaction_block.rbs +11 -2
  610. data/sig/anthropic/models/beta/beta_compaction_block_param.rbs +7 -2
  611. data/sig/anthropic/models/beta/beta_compaction_capability.rbs +26 -0
  612. data/sig/anthropic/models/beta/beta_compaction_config.rbs +19 -0
  613. data/sig/anthropic/models/beta/beta_content_block.rbs +3 -2
  614. data/sig/anthropic/models/beta/beta_content_block_param.rbs +3 -2
  615. data/sig/anthropic/models/beta/beta_fallbacks_param.rbs +1 -1
  616. data/sig/anthropic/models/beta/beta_input_transformation.rbs +46 -0
  617. data/sig/anthropic/models/beta/beta_iterations_usage.rbs +2 -2
  618. data/sig/anthropic/models/beta/beta_managed_agents_agent_with_overrides_params.rbs +2 -2
  619. data/sig/anthropic/models/beta/beta_managed_agents_multiagent_roster_entry_params.rbs +2 -2
  620. data/sig/anthropic/models/beta/beta_message.rbs +4 -4
  621. data/sig/anthropic/models/beta/beta_message_iteration_usage.rbs +4 -4
  622. data/sig/anthropic/models/beta/beta_model_capabilities.rbs +5 -0
  623. data/sig/anthropic/models/beta/beta_raw_content_block_start_event.rbs +3 -2
  624. data/sig/anthropic/models/beta/beta_raw_message_delta_event.rbs +4 -4
  625. data/sig/anthropic/models/beta/beta_raw_message_stream_event.rbs +2 -2
  626. data/sig/anthropic/models/beta/beta_summarize_compaction.rbs +20 -0
  627. data/sig/anthropic/models/beta/beta_thinking_mismatch_allowed_input_transformation.rbs +51 -0
  628. data/sig/anthropic/models/beta/beta_web_fetch_tool_20250910.rbs +7 -2
  629. data/sig/anthropic/models/beta/beta_web_fetch_tool_20260209.rbs +7 -2
  630. data/sig/anthropic/models/beta/beta_web_fetch_tool_20260309.rbs +5 -0
  631. data/sig/anthropic/models/beta/beta_web_fetch_tool_20260318.rbs +5 -0
  632. data/sig/anthropic/models/beta/beta_web_fetch_url_source_all.rbs +17 -0
  633. data/sig/anthropic/models/beta/beta_web_fetch_url_source_except.rbs +29 -0
  634. data/sig/anthropic/models/beta/beta_web_fetch_url_source_none.rbs +17 -0
  635. data/sig/anthropic/models/beta/beta_web_fetch_url_source_only.rbs +29 -0
  636. data/sig/anthropic/models/beta/beta_web_fetch_url_source_tool_reference.rbs +20 -0
  637. data/sig/anthropic/models/beta/beta_web_fetch_url_sources.rbs +162 -0
  638. data/sig/anthropic/models/beta/beta_web_search_tool_result_block_param_content.rbs +2 -2
  639. data/sig/anthropic/models/beta/deployment_create_params.rbs +1 -1
  640. data/sig/anthropic/models/beta/deployment_update_params.rbs +1 -1
  641. data/sig/anthropic/models/beta/dream_create_params.rbs +1 -1
  642. data/sig/anthropic/models/beta/message_count_tokens_params.rbs +5 -0
  643. data/sig/anthropic/models/beta/message_create_params.rbs +6 -1
  644. data/sig/anthropic/models/beta/messages/batch_create_params.rbs +6 -1
  645. data/sig/anthropic/models/beta/organization/beta_data_residency.rbs +33 -10
  646. data/sig/anthropic/models/beta/organization/beta_data_residency_create_config.rbs +2 -2
  647. data/sig/anthropic/models/beta/organization/beta_data_residency_update_config.rbs +2 -2
  648. data/sig/anthropic/models/beta/session_create_params.rbs +2 -2
  649. data/sig/anthropic/models/beta/user_profile_create_enrollment_url_params.rbs +8 -1
  650. data/sig/anthropic/models/beta/user_profile_create_params.rbs +8 -1
  651. data/sig/anthropic/models/beta/user_profile_list_params.rbs +8 -1
  652. data/sig/anthropic/models/beta/user_profile_retrieve_params.rbs +8 -1
  653. data/sig/anthropic/models/beta/user_profile_update_params.rbs +8 -1
  654. data/sig/anthropic/models/web_fetch_tool_20250910.rbs +7 -2
  655. data/sig/anthropic/models/web_fetch_tool_20260209.rbs +7 -2
  656. data/sig/anthropic/models/web_fetch_tool_20260309.rbs +5 -0
  657. data/sig/anthropic/models/web_fetch_tool_20260318.rbs +5 -0
  658. data/sig/anthropic/models/web_fetch_url_source_all.rbs +13 -0
  659. data/sig/anthropic/models/web_fetch_url_source_except.rbs +25 -0
  660. data/sig/anthropic/models/web_fetch_url_source_none.rbs +13 -0
  661. data/sig/anthropic/models/web_fetch_url_source_only.rbs +22 -0
  662. data/sig/anthropic/models/web_fetch_url_source_tool_reference.rbs +16 -0
  663. data/sig/anthropic/models/web_fetch_url_sources.rbs +151 -0
  664. data/sig/anthropic/models/web_search_tool_result_block_param_content.rbs +2 -2
  665. data/sig/anthropic/models.rbs +12 -0
  666. data/sig/anthropic/resources/beta/messages.rbs +4 -0
  667. data/sig/anthropic/resources/beta/user_profiles.rbs +5 -0
  668. metadata +53 -16
@@ -27,7 +27,13 @@ module Anthropic
27
27
  # @return [String, nil]
28
28
  optional :encrypted_content, String, nil?: true
29
29
 
30
- # @!method initialize(cache_control: nil, content: nil, encrypted_content: nil, type: :compaction)
30
+ # @!attribute signature
31
+ # The block's signature as returned, to be sent back verbatim
32
+ #
33
+ # @return [String, nil]
34
+ optional :signature, String, nil?: true
35
+
36
+ # @!method initialize(cache_control: nil, content: nil, encrypted_content: nil, signature: nil, type: :compaction)
31
37
  # A compaction block containing summary of previous context.
32
38
  #
33
39
  # Users should round-trip these blocks from responses to subsequent requests to
@@ -42,6 +48,8 @@ module Anthropic
42
48
  #
43
49
  # @param encrypted_content [String, nil] Opaque metadata from prior compaction, to be round-tripped verbatim
44
50
  #
51
+ # @param signature [String, nil] The block's signature as returned, to be sent back verbatim
52
+ #
45
53
  # @param type [Symbol, :compaction]
46
54
  end
47
55
  end
@@ -0,0 +1,32 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ class BetaCompactionCapability < Anthropic::Internal::Type::BaseModel
7
+ # @!attribute summarize
8
+ # Whether the summarize compaction type is supported.
9
+ #
10
+ # @return [Anthropic::Models::Beta::BetaCapabilitySupport]
11
+ required :summarize, -> { Anthropic::Beta::BetaCapabilitySupport }
12
+
13
+ # @!attribute supported
14
+ # Whether this capability is supported by the model.
15
+ #
16
+ # @return [Boolean]
17
+ required :supported, Anthropic::Internal::Type::Boolean
18
+
19
+ # @!method initialize(summarize:, supported:)
20
+ # Compaction capability details: whether the model accepts the top-level
21
+ # `compaction` request parameter, with one entry per supported `compaction.type`
22
+ # value.
23
+ #
24
+ # @param summarize [Anthropic::Models::Beta::BetaCapabilitySupport] Whether the summarize compaction type is supported.
25
+ #
26
+ # @param supported [Boolean] Whether this capability is supported by the model.
27
+ end
28
+ end
29
+
30
+ BetaCompactionCapability = Beta::BetaCompactionCapability
31
+ end
32
+ end
@@ -0,0 +1,40 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ class BetaCompactionConfig < Anthropic::Internal::Type::BaseModel
7
+ # @!attribute type
8
+ #
9
+ # @return [Symbol, :summarize]
10
+ required :type, const: :summarize
11
+
12
+ # @!attribute instructions
13
+ # Replaces the server's default summarization prompt for this request. An empty or
14
+ # whitespace-only value counts as absent.
15
+ #
16
+ # @return [String, nil]
17
+ optional :instructions, String, nil?: true
18
+
19
+ # @!method initialize(instructions: nil, type: :summarize)
20
+ # Compact the whole conversation and return a signed `compaction` block, alone,
21
+ # that a later request sends back first in `messages`, in place of the messages it
22
+ # summarizes. There is no trigger and no pause flag: sending the parameter
23
+ # compacts, and nothing is sampled after the block.
24
+ #
25
+ # The summarization prompt is the server's own unless `instructions` are given,
26
+ # which then replace it for this request; a value that is empty or only whitespace
27
+ # counts as absent.
28
+ #
29
+ # Some parameter documentations has been truncated, see
30
+ # {Anthropic::Models::Beta::BetaCompactionConfig} for more details.
31
+ #
32
+ # @param instructions [String, nil] Replaces the server's default summarization prompt for this request. An empty or
33
+ #
34
+ # @param type [Symbol, :summarize]
35
+ end
36
+ end
37
+
38
+ BetaCompactionConfig = Beta::BetaCompactionConfig
39
+ end
40
+ end
@@ -3,7 +3,6 @@
3
3
  module Anthropic
4
4
  module Models
5
5
  module Beta
6
- # Response model for a file uploaded to the container.
7
6
  module BetaContentBlock
8
7
  extend Anthropic::Internal::Type::Union
9
8
 
@@ -103,7 +102,7 @@ module Anthropic
103
102
  #
104
103
  # @option args [String] :text
105
104
  #
106
- # @option args [String] :signature A value used to verify that this thinking block was generated by Claude when it
105
+ # @option args [String, String, nil] :signature A value used to verify that this thinking block was generated by Claude when it
107
106
  #
108
107
  # @option args [String] :thinking The text of Claude's thinking process for this block.
109
108
  #
@@ -115,11 +114,11 @@ module Anthropic
115
114
  #
116
115
  # @option args [String, Symbol, Anthropic::Models::Beta::BetaServerToolUseBlock::Name] :name The name of the MCP tool
117
116
  #
118
- # @option args [Anthropic::Models::Beta::BetaDirectCaller, Anthropic::Models::Beta::BetaServerToolCaller, Anthropic::Models::Beta::BetaServerToolCaller20260120] :caller_ Tool invocation directly from the model.
117
+ # @option args [Anthropic::Models::Beta::BetaDirectCaller, Anthropic::Models::Beta::BetaServerToolCaller, Anthropic::Models::Beta::BetaServerToolCaller20260120] :caller_
119
118
  #
120
119
  # @option args [String, nil] :toolset_name For a toolset member tool_use, the toolset family.
121
120
  #
122
- # @option args [Anthropic::Models::Beta::BetaWebSearchToolResultError, Array<Anthropic::Models::Beta::BetaWebSearchResultBlock>, Anthropic::Models::Beta::BetaWebFetchToolResultErrorBlock, Anthropic::Models::Beta::BetaWebFetchBlock, Anthropic::Models::Beta::BetaAdvisorToolResultError, Anthropic::Models::Beta::BetaAdvisorResultBlock, Anthropic::Models::Beta::BetaAdvisorRedactedResultBlock, Anthropic::Models::Beta::BetaCodeExecutionToolResultError, Anthropic::Models::Beta::BetaCodeExecutionResultBlock, Anthropic::Models::Beta::BetaEncryptedCodeExecutionResultBlock, Anthropic::Models::Beta::BetaBashCodeExecutionToolResultError, Anthropic::Models::Beta::BetaBashCodeExecutionResultBlock, Anthropic::Models::Beta::BetaTextEditorCodeExecutionToolResultError, Anthropic::Models::Beta::BetaTextEditorCodeExecutionViewResultBlock, Anthropic::Models::Beta::BetaTextEditorCodeExecutionCreateResultBlock, Anthropic::Models::Beta::BetaTextEditorCodeExecutionStrReplaceResultBlock, Anthropic::Models::Beta::BetaToolSearchToolResultError, Anthropic::Models::Beta::BetaToolSearchToolSearchResultBlock, String, Array<Anthropic::Models::Beta::BetaTextBlock>, String, nil] :content Code execution result with encrypted stdout for PFC + web_search results.
121
+ # @option args [Anthropic::Models::Beta::BetaWebSearchToolResultError, Array<Anthropic::Models::Beta::BetaWebSearchResultBlock>, Anthropic::Models::Beta::BetaWebFetchToolResultErrorBlock, Anthropic::Models::Beta::BetaWebFetchBlock, Anthropic::Models::Beta::BetaAdvisorToolResultError, Anthropic::Models::Beta::BetaAdvisorResultBlock, Anthropic::Models::Beta::BetaAdvisorRedactedResultBlock, Anthropic::Models::Beta::BetaCodeExecutionToolResultError, Anthropic::Models::Beta::BetaCodeExecutionResultBlock, Anthropic::Models::Beta::BetaEncryptedCodeExecutionResultBlock, Anthropic::Models::Beta::BetaBashCodeExecutionToolResultError, Anthropic::Models::Beta::BetaBashCodeExecutionResultBlock, Anthropic::Models::Beta::BetaTextEditorCodeExecutionToolResultError, Anthropic::Models::Beta::BetaTextEditorCodeExecutionViewResultBlock, Anthropic::Models::Beta::BetaTextEditorCodeExecutionCreateResultBlock, Anthropic::Models::Beta::BetaTextEditorCodeExecutionStrReplaceResultBlock, Anthropic::Models::Beta::BetaToolSearchToolResultError, Anthropic::Models::Beta::BetaToolSearchToolSearchResultBlock, String, Array<Anthropic::Models::Beta::BetaTextBlock>, String, nil] :content Summary of compacted content, or null if compaction failed
123
122
  #
124
123
  # @option args [String] :tool_use_id
125
124
  #
@@ -3,7 +3,6 @@
3
3
  module Anthropic
4
4
  module Models
5
5
  module Beta
6
- # Regular text content.
7
6
  module BetaContentBlockParam
8
7
  extend Anthropic::Internal::Type::Union
9
8
 
@@ -155,9 +154,9 @@ module Anthropic
155
154
  #
156
155
  # @option args [String, nil, String] :title
157
156
  #
158
- # @option args [Array<Anthropic::Models::Beta::BetaTextBlockParam>, String, Array<Anthropic::Models::Beta::BetaTextBlockParam, Anthropic::Models::Beta::BetaImageBlockParam, Anthropic::Models::Beta::BetaSearchResultBlockParam, Anthropic::Models::Beta::BetaRequestDocumentBlock, Anthropic::Models::Beta::BetaToolReferenceBlockParam, Anthropic::Models::Beta::BetaBrowserStateBlockParam>, Array<Anthropic::Models::Beta::BetaWebSearchResultBlockParam>, Anthropic::Models::Beta::BetaWebSearchToolRequestError, Anthropic::Models::Beta::BetaWebFetchToolResultErrorBlockParam, Anthropic::Models::Beta::BetaWebFetchBlockParam, Anthropic::Models::Beta::BetaAdvisorToolResultErrorParam, Anthropic::Models::Beta::BetaAdvisorResultBlockParam, Anthropic::Models::Beta::BetaAdvisorRedactedResultBlockParam, Anthropic::Models::Beta::BetaCodeExecutionToolResultErrorParam, Anthropic::Models::Beta::BetaCodeExecutionResultBlockParam, Anthropic::Models::Beta::BetaEncryptedCodeExecutionResultBlockParam, Anthropic::Models::Beta::BetaBashCodeExecutionToolResultErrorParam, Anthropic::Models::Beta::BetaBashCodeExecutionResultBlockParam, Anthropic::Models::Beta::BetaTextEditorCodeExecutionToolResultErrorParam, Anthropic::Models::Beta::BetaTextEditorCodeExecutionViewResultBlockParam, Anthropic::Models::Beta::BetaTextEditorCodeExecutionCreateResultBlockParam, Anthropic::Models::Beta::BetaTextEditorCodeExecutionStrReplaceResultBlockParam, Anthropic::Models::Beta::BetaToolSearchToolResultErrorParam, Anthropic::Models::Beta::BetaToolSearchToolSearchResultBlockParam, String, Array<Anthropic::Models::Beta::BetaTextBlockParam>, String, nil] :content Code execution result with encrypted stdout for PFC + web_search results.
157
+ # @option args [Array<Anthropic::Models::Beta::BetaTextBlockParam>, String, Array<Anthropic::Models::Beta::BetaTextBlockParam, Anthropic::Models::Beta::BetaImageBlockParam, Anthropic::Models::Beta::BetaSearchResultBlockParam, Anthropic::Models::Beta::BetaRequestDocumentBlock, Anthropic::Models::Beta::BetaToolReferenceBlockParam, Anthropic::Models::Beta::BetaBrowserStateBlockParam>, Anthropic::Models::Beta::BetaWebSearchToolRequestError, Array<Anthropic::Models::Beta::BetaWebSearchResultBlockParam>, Anthropic::Models::Beta::BetaWebFetchToolResultErrorBlockParam, Anthropic::Models::Beta::BetaWebFetchBlockParam, Anthropic::Models::Beta::BetaAdvisorToolResultErrorParam, Anthropic::Models::Beta::BetaAdvisorResultBlockParam, Anthropic::Models::Beta::BetaAdvisorRedactedResultBlockParam, Anthropic::Models::Beta::BetaCodeExecutionToolResultErrorParam, Anthropic::Models::Beta::BetaCodeExecutionResultBlockParam, Anthropic::Models::Beta::BetaEncryptedCodeExecutionResultBlockParam, Anthropic::Models::Beta::BetaBashCodeExecutionToolResultErrorParam, Anthropic::Models::Beta::BetaBashCodeExecutionResultBlockParam, Anthropic::Models::Beta::BetaTextEditorCodeExecutionToolResultErrorParam, Anthropic::Models::Beta::BetaTextEditorCodeExecutionViewResultBlockParam, Anthropic::Models::Beta::BetaTextEditorCodeExecutionCreateResultBlockParam, Anthropic::Models::Beta::BetaTextEditorCodeExecutionStrReplaceResultBlockParam, Anthropic::Models::Beta::BetaToolSearchToolResultErrorParam, Anthropic::Models::Beta::BetaToolSearchToolSearchResultBlockParam, String, Array<Anthropic::Models::Beta::BetaTextBlockParam>, String, nil] :content Summary of previously compacted content, or null if compaction failed
159
158
  #
160
- # @option args [String] :signature The `signature` value of this thinking block, exactly as returned by the API in
159
+ # @option args [String, String, nil] :signature The `signature` value of this thinking block, exactly as returned by the API in
161
160
  #
162
161
  # @option args [String] :thinking The `thinking` text of this block as returned by the API.
163
162
  #
@@ -169,7 +168,7 @@ module Anthropic
169
168
  #
170
169
  # @option args [String, Symbol, Anthropic::Models::Beta::BetaServerToolUseBlockParam::Name] :name
171
170
  #
172
- # @option args [Anthropic::Models::Beta::BetaDirectCaller, Anthropic::Models::Beta::BetaServerToolCaller, Anthropic::Models::Beta::BetaServerToolCaller20260120] :caller_ Tool invocation directly from the model.
171
+ # @option args [Anthropic::Models::Beta::BetaDirectCaller, Anthropic::Models::Beta::BetaServerToolCaller, Anthropic::Models::Beta::BetaServerToolCaller20260120] :caller_
173
172
  #
174
173
  # @option args [String, nil] :toolset_name For a toolset member tool_use, the toolset family this member belongs to.
175
174
  #
@@ -183,7 +182,7 @@ module Anthropic
183
182
  #
184
183
  # @option args [String, nil] :encrypted_content Opaque metadata from prior compaction, to be round-tripped verbatim
185
184
  #
186
- # @option args [Anthropic::Models::Beta::BetaToolChangeToolReference, Anthropic::Models::Beta::BetaToolChangeMCPToolReference, Anthropic::Models::Beta::BetaToolChangeMCPToolsetReference] :tool Reference to a single tool the caller declared directly in
185
+ # @option args [Anthropic::Models::Beta::BetaToolChangeToolReference, Anthropic::Models::Beta::BetaToolChangeMCPToolReference, Anthropic::Models::Beta::BetaToolChangeMCPToolsetReference] :tool
187
186
  #
188
187
  # @option args [Anthropic::Models::Beta::BetaFallbackInfoParam] :from Identifies one hop of a fallback transition.
189
188
  #
@@ -14,8 +14,6 @@ module Anthropic
14
14
  # @!method initialize(edits: nil)
15
15
  # @param edits [Array<Anthropic::Models::Beta::BetaClearToolUses20250919Edit, Anthropic::Models::Beta::BetaClearThinking20251015Edit, Anthropic::Models::Beta::BetaCompact20260112Edit>] List of context management edits to apply
16
16
 
17
- # Automatically compact older context when reaching the configured trigger
18
- # threshold.
19
17
  module Edit
20
18
  extend Anthropic::Internal::Type::Union
21
19
 
@@ -52,9 +52,6 @@ module Anthropic
52
52
  required :model, -> { Anthropic::Beta::BetaDreamModelConfig }
53
53
 
54
54
  # @!attribute output_behavior
55
- # The default destination: the job creates a new output memory store as a clone of
56
- # the memory_store input and writes the consolidated memories into it. The input
57
- # store is never mutated.
58
55
  #
59
56
  # @return [Anthropic::Models::Beta::BetaOutputBehaviorCreateNew, Anthropic::Models::Beta::BetaOutputBehaviorUpdateExisting]
60
57
  required :output_behavior, union: -> { Anthropic::Beta::BetaOutputBehavior }
@@ -113,7 +110,7 @@ module Anthropic
113
110
  #
114
111
  # @param model [Anthropic::Models::Beta::BetaDreamModelConfig] Model identifier and configuration applied to every pipeline stage. Same wire sh
115
112
  #
116
- # @param output_behavior [Anthropic::Models::Beta::BetaOutputBehaviorCreateNew, Anthropic::Models::Beta::BetaOutputBehaviorUpdateExisting] The default destination: the job creates a new output memory store as a clone of
113
+ # @param output_behavior [Anthropic::Models::Beta::BetaOutputBehaviorCreateNew, Anthropic::Models::Beta::BetaOutputBehaviorUpdateExisting]
117
114
  #
118
115
  # @param outputs [Array<Anthropic::Models::Beta::BetaDreamOutput>]
119
116
  #
@@ -3,9 +3,6 @@
3
3
  module Anthropic
4
4
  module Models
5
5
  module Beta
6
- # An input memory store the dream reads from. The dream never mutates this store
7
- # unless it is also the destination: with output_behavior {type:
8
- # "update_existing"} the job consolidates this store in place.
9
6
  module BetaDreamInput
10
7
  extend Anthropic::Internal::Type::Union
11
8
 
@@ -3,13 +3,6 @@
3
3
  module Anthropic
4
4
  module Models
5
5
  module Beta
6
- # The `output_behavior.memory_store_id` target is still held by a prior
7
- # `{type: "update_existing"}` dream — one that is `pending` or `running`, or was
8
- # canceled with its final writes still landing. Rarely the named dream has just
9
- # finished (`completed`/`failed`) and its execution is still closing; an immediate
10
- # retry then almost always succeeds. The message names the holding dream when the
11
- # server can identify it (rarely omitted); poll it to a terminal state or cancel
12
- # it, then retry. Carried with `x-should-retry: false`.
13
6
  module BetaDreamingError
14
7
  extend Anthropic::Internal::Type::Union
15
8
 
@@ -52,10 +52,11 @@ module Anthropic
52
52
  # @!method initialize(cache_creation:, cache_creation_input_tokens:, cache_read_input_tokens:, input_tokens:, model:, output_tokens:, type: :fallback_message)
53
53
  # Token usage for the fallback-model attempt of a server-side fallback request.
54
54
  #
55
- # Produced in place of a `message` entry for whichever hop served the response. A
56
- # declined hop produces the existing `message` entry. Whether a fallback model
57
- # served the response is signalled by the presence of this entry in
58
- # `usage.iterations`.
55
+ # The terminal entry of a fallback-served turn: when a fallback hop's output is
56
+ # the returned message, the entry for the iteration that completed it carries this
57
+ # type in place of `message`. A declined hop and the serving hop's earlier
58
+ # tool-loop iterations produce `message` entries. Whether a fallback model served
59
+ # the response is signalled by the presence of this entry in `usage.iterations`.
59
60
  #
60
61
  # Some parameter documentations has been truncated, see
61
62
  # {Anthropic::Models::Beta::BetaFallbackMessageIterationUsage} for more details.
@@ -10,12 +10,12 @@ module Anthropic
10
10
  module BetaFallbacksParam
11
11
  extend Anthropic::Internal::Type::Union
12
12
 
13
- variant -> { Anthropic::Models::Beta::BetaFallbacksParam::BetaFallbackParamArray }
14
-
15
13
  variant const: :default
16
14
 
15
+ variant -> { Anthropic::Models::Beta::BetaFallbacksParam::BetaFallbackParamArray }
16
+
17
17
  # @!method self.variants
18
- # @return [Array(Array<Anthropic::Models::Beta::BetaFallbackParam>, Symbol, :default)]
18
+ # @return [Array(Symbol, :default, Array<Anthropic::Models::Beta::BetaFallbackParam>)]
19
19
 
20
20
  # @type [Anthropic::Internal::Type::Converter]
21
21
  BetaFallbackParamArray = Anthropic::Internal::Type::ArrayOf[-> { Anthropic::Beta::BetaFallbackParam }]
@@ -0,0 +1,62 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ # One entry of `input_transformations`: either a change the API made to the
7
+ # request's input before showing it to the model, or a block that failed a binding
8
+ # check and was still shown to the model unchanged. The `type` field says which.
9
+ module BetaInputTransformation
10
+ extend Anthropic::Internal::Type::Union
11
+
12
+ discriminator :type
13
+
14
+ variant :thinking_dropped, -> { Anthropic::Beta::BetaThinkingDroppedInputTransformation }
15
+
16
+ variant :thinking_mismatch_allowed, -> { Anthropic::Beta::BetaThinkingMismatchAllowedInputTransformation }
17
+
18
+ module Type
19
+ extend Anthropic::Internal::Type::Enum
20
+
21
+ THINKING_DROPPED = :thinking_dropped
22
+ THINKING_MISMATCH_ALLOWED = :thinking_mismatch_allowed
23
+
24
+ # @!method self.values
25
+ # @return [Array<Symbol>]
26
+ end
27
+
28
+ # @!method self.variants
29
+ # @return [Array(Anthropic::Models::Beta::BetaThinkingDroppedInputTransformation, Anthropic::Models::Beta::BetaThinkingMismatchAllowedInputTransformation)]
30
+
31
+ # Creates a new instance of the variant class whose `type` matches the given
32
+ # value, passing the remaining arguments to its constructor.
33
+ #
34
+ # Some parameter documentations has been truncated, see
35
+ # {Anthropic::Models::Beta::BetaInputTransformation} for more details.
36
+ #
37
+ # @param type [Symbol, String]
38
+ #
39
+ # @param args [Hash{Symbol=>Object}] Attributes for the chosen variant.
40
+ #
41
+ # @option args [String] :path Where the removed block was in your request, as `messages.{i}.content.{j}`:
42
+ #
43
+ # @option args [Symbol, Anthropic::Models::Beta::BetaThinkingDroppedInputTransformation::Reason, Symbol, Anthropic::Models::Beta::BetaThinkingMismatchAllowedInputTransformation::Reason] :reason Which binding check removed the block: `model_binding_mismatch` — it was
44
+ #
45
+ # @raise [ArgumentError]
46
+ # @return [Anthropic::Models::Beta::BetaThinkingDroppedInputTransformation, Anthropic::Models::Beta::BetaThinkingMismatchAllowedInputTransformation]
47
+ def self.new(type:, **args)
48
+ case type.to_sym
49
+ when :thinking_dropped
50
+ Anthropic::Beta::BetaThinkingDroppedInputTransformation.new(**args)
51
+ when :thinking_mismatch_allowed
52
+ Anthropic::Beta::BetaThinkingMismatchAllowedInputTransformation.new(**args)
53
+ else
54
+ raise ArgumentError, "unknown type: #{type}"
55
+ end
56
+ end
57
+ end
58
+ end
59
+
60
+ BetaInputTransformation = Beta::BetaInputTransformation
61
+ end
62
+ end
@@ -3,7 +3,6 @@
3
3
  module Anthropic
4
4
  module Models
5
5
  module Beta
6
- # Token usage for a sampling iteration.
7
6
  module BetaIterationsUsageItem
8
7
  extend Anthropic::Internal::Type::Union
9
8
 
@@ -20,10 +19,12 @@ module Anthropic
20
19
 
21
20
  # Token usage for the fallback-model attempt of a server-side fallback request.
22
21
  #
23
- # Produced in place of a `message` entry for whichever hop served the
24
- # response. A declined hop produces the existing `message` entry. Whether
25
- # a fallback model served the response is signalled by the presence of this
26
- # entry in `usage.iterations`.
22
+ # The terminal entry of a fallback-served turn: when a fallback hop's
23
+ # output is the returned message, the entry for the iteration that
24
+ # completed it carries this type in place of `message`. A declined hop
25
+ # and the serving hop's earlier tool-loop iterations produce `message`
26
+ # entries. Whether a fallback model served the response is signalled by
27
+ # the presence of this entry in `usage.iterations`.
27
28
  variant :fallback_message, -> { Anthropic::Beta::BetaFallbackMessageIterationUsage }
28
29
 
29
30
  module Type
@@ -59,7 +60,7 @@ module Anthropic
59
60
  #
60
61
  # @option args [Integer] :input_tokens The number of input tokens which were used.
61
62
  #
62
- # @option args [Symbol, String, Anthropic::Models::Model] :model The model that will complete your prompt.
63
+ # @option args [Symbol, String, Anthropic::Models::Model, nil, Symbol, String, Anthropic::Models::Model] :model The model that will complete your prompt.
63
64
  #
64
65
  # @option args [Integer] :output_tokens The number of output tokens which were used.
65
66
  #
@@ -27,7 +27,7 @@ module Anthropic
27
27
  # Replacement model. Accepts the model string, e.g. `claude-opus-5`, or a
28
28
  # `model_config` object. Omit to use the agent's model.
29
29
  #
30
- # @return [Symbol, String, Anthropic::Models::Beta::BetaManagedAgentsModel, Anthropic::Models::Beta::BetaManagedAgentsModelConfigParams, nil]
30
+ # @return [Anthropic::Models::Beta::BetaManagedAgentsModelConfigParams, Symbol, String, Anthropic::Models::Beta::BetaManagedAgentsModel, nil]
31
31
  optional :model, union: -> { Anthropic::Beta::BetaManagedAgentsAgentWithOverridesParams::Model }
32
32
 
33
33
  # @!attribute skills
@@ -74,7 +74,7 @@ module Anthropic
74
74
  #
75
75
  # @param mcp_servers [Array<Anthropic::Models::Beta::BetaManagedAgentsURLMCPServerParams>] Replacement MCP server list. Full replacement: the provided array becomes the MC
76
76
  #
77
- # @param model [Symbol, String, Anthropic::Models::Beta::BetaManagedAgentsModel, Anthropic::Models::Beta::BetaManagedAgentsModelConfigParams] Replacement model. Accepts the model string, e.g. `claude-opus-5`, or a `model_c
77
+ # @param model [Anthropic::Models::Beta::BetaManagedAgentsModelConfigParams, Symbol, String, Anthropic::Models::Beta::BetaManagedAgentsModel] Replacement model. Accepts the model string, e.g. `claude-opus-5`, or a `model_c
78
78
  #
79
79
  # @param skills [Array<Anthropic::Models::Beta::BetaManagedAgentsAnthropicSkillParams, Anthropic::Models::Beta::BetaManagedAgentsCustomSkillParams>] Replacement skill list. Full replacement: the provided array becomes the skills.
80
80
  #
@@ -101,16 +101,16 @@ module Anthropic
101
101
  module Model
102
102
  extend Anthropic::Internal::Type::Union
103
103
 
104
+ # An object that defines additional configuration control over model use
105
+ variant -> { Anthropic::Beta::BetaManagedAgentsModelConfigParams }
106
+
104
107
  # The model that will power your agent.
105
108
  #
106
109
  # See [models](https://docs.anthropic.com/en/docs/models-overview) for additional details and options.
107
110
  variant union: -> { Anthropic::Beta::BetaManagedAgentsModel }
108
111
 
109
- # An object that defines additional configuration control over model use
110
- variant -> { Anthropic::Beta::BetaManagedAgentsModelConfigParams }
111
-
112
112
  # @!method self.variants
113
- # @return [Array(Symbol, String, Anthropic::Models::Beta::BetaManagedAgentsModel, Anthropic::Models::Beta::BetaManagedAgentsModelConfigParams)]
113
+ # @return [Array(Anthropic::Models::Beta::BetaManagedAgentsModelConfigParams, Symbol, String, Anthropic::Models::Beta::BetaManagedAgentsModel)]
114
114
  end
115
115
 
116
116
  # Union type for tool configurations in the tools array.
@@ -12,7 +12,7 @@ module Anthropic
12
12
  # Referenced agents must exist, must not be archived, and must not themselves have
13
13
  # `multiagent` set (depth limit 1).
14
14
  #
15
- # @return [Array<String, Anthropic::Models::Beta::BetaManagedAgentsAgentParams, Anthropic::Models::Beta::BetaManagedAgentsMultiagentSelfParams, Anthropic::Models::Beta::BetaManagedAgentsAdvisorParams>]
15
+ # @return [Array<Anthropic::Models::Beta::BetaManagedAgentsAgentParams, Anthropic::Models::Beta::BetaManagedAgentsMultiagentSelfParams, Anthropic::Models::Beta::BetaManagedAgentsAdvisorParams, String>]
16
16
  required :agents,
17
17
  -> { Anthropic::Internal::Type::ArrayOf[union: Anthropic::Beta::BetaManagedAgentsMultiagentRosterEntryParams] }
18
18
 
@@ -29,7 +29,7 @@ module Anthropic
29
29
  # {Anthropic::Models::Beta::BetaManagedAgentsMultiagentCoordinatorParams} for more
30
30
  # details.
31
31
  #
32
- # @param agents [Array<String, Anthropic::Models::Beta::BetaManagedAgentsAgentParams, Anthropic::Models::Beta::BetaManagedAgentsMultiagentSelfParams, Anthropic::Models::Beta::BetaManagedAgentsAdvisorParams>] Agents the coordinator may spawn as session threads. 1–20 entries. Each entry is
32
+ # @param agents [Array<Anthropic::Models::Beta::BetaManagedAgentsAgentParams, Anthropic::Models::Beta::BetaManagedAgentsMultiagentSelfParams, Anthropic::Models::Beta::BetaManagedAgentsAdvisorParams, String>] Agents the coordinator may spawn as session threads. 1–20 entries. Each entry is
33
33
  #
34
34
  # @param type [Symbol, Anthropic::Models::Beta::BetaManagedAgentsMultiagentCoordinatorParams::Type]
35
35
 
@@ -12,7 +12,7 @@ module Anthropic
12
12
  # Referenced agents must exist, must not be archived, and must not themselves have
13
13
  # `multiagent` set (depth limit 1).
14
14
  #
15
- # @return [Array<String, Anthropic::Models::Beta::BetaManagedAgentsAgentParams, Anthropic::Models::Beta::BetaManagedAgentsMultiagentSelfParams, Anthropic::Models::Beta::BetaManagedAgentsAdvisorParams>]
15
+ # @return [Array<Anthropic::Models::Beta::BetaManagedAgentsAgentParams, Anthropic::Models::Beta::BetaManagedAgentsMultiagentSelfParams, Anthropic::Models::Beta::BetaManagedAgentsAdvisorParams, String>]
16
16
  required :agents,
17
17
  -> { Anthropic::Internal::Type::ArrayOf[union: Anthropic::Beta::BetaManagedAgentsMultiagentRosterEntryParams] }
18
18
 
@@ -28,7 +28,7 @@ module Anthropic
28
28
  # Some parameter documentations has been truncated, see
29
29
  # {Anthropic::Models::Beta::BetaManagedAgentsMultiagentParams} for more details.
30
30
  #
31
- # @param agents [Array<String, Anthropic::Models::Beta::BetaManagedAgentsAgentParams, Anthropic::Models::Beta::BetaManagedAgentsMultiagentSelfParams, Anthropic::Models::Beta::BetaManagedAgentsAdvisorParams>] Agents the coordinator may spawn as session threads. 1–20 entries. Each entry is
31
+ # @param agents [Array<Anthropic::Models::Beta::BetaManagedAgentsAgentParams, Anthropic::Models::Beta::BetaManagedAgentsMultiagentSelfParams, Anthropic::Models::Beta::BetaManagedAgentsAdvisorParams, String>] Agents the coordinator may spawn as session threads. 1–20 entries. Each entry is
32
32
  #
33
33
  # @param type [Symbol, Anthropic::Models::Beta::BetaManagedAgentsMultiagentParams::Type]
34
34
 
@@ -8,8 +8,6 @@ module Anthropic
8
8
  module BetaManagedAgentsMultiagentRosterEntryParams
9
9
  extend Anthropic::Internal::Type::Union
10
10
 
11
- variant String
12
-
13
11
  # Specification for an Agent. Provide a specific `version` or use the short-form `agent="agent_id"` for the most recent version
14
12
  variant -> { Anthropic::Beta::BetaManagedAgentsAgentParams }
15
13
 
@@ -19,8 +17,10 @@ module Anthropic
19
17
  # Platform advisor roster entry: a model the session's primary thread may consult mid-turn. At most one per roster; the entry occupies the roster name `anthropic.advisor`.
20
18
  variant -> { Anthropic::Beta::BetaManagedAgentsAdvisorParams }
21
19
 
20
+ variant String
21
+
22
22
  # @!method self.variants
23
- # @return [Array(String, Anthropic::Models::Beta::BetaManagedAgentsAgentParams, Anthropic::Models::Beta::BetaManagedAgentsMultiagentSelfParams, Anthropic::Models::Beta::BetaManagedAgentsAdvisorParams)]
23
+ # @return [Array(Anthropic::Models::Beta::BetaManagedAgentsAgentParams, Anthropic::Models::Beta::BetaManagedAgentsMultiagentSelfParams, Anthropic::Models::Beta::BetaManagedAgentsAdvisorParams, String)]
24
24
  end
25
25
  end
26
26
 
@@ -44,8 +44,8 @@ module Anthropic
44
44
  optional :processed_at, Time, nil?: true
45
45
 
46
46
  # @!attribute session_thread_id
47
- # Routes this result to a subagent thread. Copy from the `agent.tool_use` event's
48
- # `session_thread_id`.
47
+ # Set by the server to the subagent thread this result was routed to. Omitted when
48
+ # it was routed to the primary thread.
49
49
  #
50
50
  # @return [String, nil]
51
51
  optional :session_thread_id, String, nil?: true
@@ -71,7 +71,7 @@ module Anthropic
71
71
  #
72
72
  # @param processed_at [Time, nil] A timestamp in RFC 3339 format
73
73
  #
74
- # @param session_thread_id [String, nil] Routes this result to a subagent thread. Copy from the `agent.tool_use` event's
74
+ # @param session_thread_id [String, nil] Set by the server to the subagent thread this result was routed to. Omitted when
75
75
 
76
76
  # @see Anthropic::Models::Beta::BetaManagedAgentsUserToolResultEvent#type
77
77
  module Type
@@ -168,27 +168,30 @@ module Anthropic
168
168
  required :usage, -> { Anthropic::Beta::BetaUsage }
169
169
 
170
170
  # @!attribute input_transformations
171
- # Changes the API made to the request's input before showing it to the model: one
172
- # entry per change, in request order. Today the only entry type is
173
- # `thinking_dropped` — a `thinking`, `redacted_thinking` or `connector_text` block
174
- # from the request's `messages` that was removed from the prompt instead of being
175
- # shown to the model because it failed a binding check. More entry types may be
176
- # added over time; ignore types you do not recognize.
171
+ # Changes the API made to the request's input before showing it to the model, and
172
+ # blocks that failed a binding check but were left unchanged: one entry per block,
173
+ # in request order. Two entry types today. `thinking_dropped` — a `thinking`,
174
+ # `redacted_thinking` or `connector_text` block from the request's `messages` that
175
+ # was removed from the prompt instead of being shown to the model because it
176
+ # failed a binding check. `thinking_mismatch_allowed` — a `thinking` or
177
+ # `redacted_thinking` block that failed the conversation check (the conversation
178
+ # before it differs from the one it was created in, or it carries no record of one
179
+ # on a model that requires it) and was shown to the model all the same, because
180
+ # that check is not enforced for this request. More entry types may be added over
181
+ # time; ignore types you do not recognize.
177
182
  #
178
183
  # Requires `anthropic-beta: thinking-binding-controls-2026-08-01`. Present on
179
184
  # every such response from a model that supports extended thinking, as `[]` when
180
- # nothing was changed; without the beta, blocks are removed all the same but
181
- # nothing is reported. Removed blocks contribute nothing to `usage.input_tokens`.
182
- # When streaming, the array is final in `message_start`; the final `message_delta`
183
- # event carries it only when a server-side model fallback happened mid-stream, in
184
- # which case it holds the serving model's entries and replaces the one in
185
- # `message_start`.
186
- #
187
- # @return [Array<Anthropic::Models::Beta::BetaThinkingDroppedInputTransformation>, nil]
185
+ # there is no entry to report; without the beta, blocks are removed or left in
186
+ # place all the same but nothing is reported. Removed blocks contribute nothing to
187
+ # `usage.input_tokens`; blocks left in place count as sent. When streaming, the
188
+ # array is final in `message_start`; the final `message_delta` event carries it
189
+ # only when a server-side model fallback happened mid-stream, in which case it
190
+ # holds the serving model's entries and replaces the one in `message_start`.
191
+ #
192
+ # @return [Array<Anthropic::Models::Beta::BetaThinkingDroppedInputTransformation, Anthropic::Models::Beta::BetaThinkingMismatchAllowedInputTransformation>, nil]
188
193
  optional :input_transformations,
189
- -> {
190
- Anthropic::Internal::Type::ArrayOf[Anthropic::Beta::BetaThinkingDroppedInputTransformation]
191
- },
194
+ -> { Anthropic::Internal::Type::ArrayOf[union: Anthropic::Beta::BetaInputTransformation] },
192
195
  nil?: true
193
196
 
194
197
  # @!method initialize(id:, container:, content:, context_management:, diagnostics:, model:, stop_details:, stop_reason:, stop_sequence:, usage:, input_transformations: nil, role: :assistant, type: :message)
@@ -215,7 +218,7 @@ module Anthropic
215
218
  #
216
219
  # @param usage [Anthropic::Models::Beta::BetaUsage] Billing and rate-limit usage.
217
220
  #
218
- # @param input_transformations [Array<Anthropic::Models::Beta::BetaThinkingDroppedInputTransformation>, nil] Changes the API made to the request's input before showing it to the model:
221
+ # @param input_transformations [Array<Anthropic::Models::Beta::BetaThinkingDroppedInputTransformation, Anthropic::Models::Beta::BetaThinkingMismatchAllowedInputTransformation>, nil] Changes the API made to the request's input before showing it to the model,
219
222
  #
220
223
  # @param role [Symbol, :assistant] Conversational role of the generated message.
221
224
  #
@@ -34,8 +34,8 @@ module Anthropic
34
34
  # See [models](https://docs.anthropic.com/en/docs/models-overview) for additional
35
35
  # details and options.
36
36
  #
37
- # @return [Symbol, String, Anthropic::Models::Model]
38
- required :model, union: -> { Anthropic::Model }
37
+ # @return [Symbol, String, Anthropic::Models::Model, nil]
38
+ required :model, union: -> { Anthropic::Model }, nil?: true
39
39
 
40
40
  # @!attribute output_tokens
41
41
  # The number of output tokens which were used.
@@ -63,7 +63,7 @@ module Anthropic
63
63
  #
64
64
  # @param input_tokens [Integer] The number of input tokens which were used.
65
65
  #
66
- # @param model [Symbol, String, Anthropic::Models::Model] The model that will complete your prompt.
66
+ # @param model [Symbol, String, Anthropic::Models::Model, nil] The model that will complete your prompt.
67
67
  #
68
68
  # @param output_tokens [Integer] The number of output tokens which were used.
69
69
  #
@@ -22,6 +22,14 @@ module Anthropic
22
22
  # @return [Anthropic::Models::Beta::BetaCapabilitySupport]
23
23
  required :code_execution, -> { Anthropic::Beta::BetaCapabilitySupport }
24
24
 
25
+ # @!attribute compaction
26
+ # Compaction capability details: whether the model accepts the top-level
27
+ # `compaction` request parameter, with one entry per supported `compaction.type`
28
+ # value.
29
+ #
30
+ # @return [Anthropic::Models::Beta::BetaCompactionCapability, nil]
31
+ required :compaction, -> { Anthropic::Beta::BetaCompactionCapability }, nil?: true
32
+
25
33
  # @!attribute context_management
26
34
  # Context management support and available strategies.
27
35
  #
@@ -58,15 +66,20 @@ module Anthropic
58
66
  # @return [Anthropic::Models::Beta::BetaThinkingCapability]
59
67
  required :thinking, -> { Anthropic::Beta::BetaThinkingCapability }
60
68
 
61
- # @!method initialize(batch:, citations:, code_execution:, context_management:, effort:, image_input:, pdf_input:, structured_outputs:, thinking:)
69
+ # @!method initialize(batch:, citations:, code_execution:, compaction:, context_management:, effort:, image_input:, pdf_input:, structured_outputs:, thinking:)
62
70
  # Model capability information.
63
71
  #
72
+ # Some parameter documentations has been truncated, see
73
+ # {Anthropic::Models::Beta::BetaModelCapabilities} for more details.
74
+ #
64
75
  # @param batch [Anthropic::Models::Beta::BetaCapabilitySupport] Whether the model supports the Batch API.
65
76
  #
66
77
  # @param citations [Anthropic::Models::Beta::BetaCapabilitySupport] Whether the model supports citation generation.
67
78
  #
68
79
  # @param code_execution [Anthropic::Models::Beta::BetaCapabilitySupport] Whether the model supports code execution tools.
69
80
  #
81
+ # @param compaction [Anthropic::Models::Beta::BetaCompactionCapability, nil] Compaction capability details: whether the model accepts the top-level
82
+ #
70
83
  # @param context_management [Anthropic::Models::Beta::BetaContextManagementCapability] Context management support and available strategies.
71
84
  #
72
85
  # @param effort [Anthropic::Models::Beta::BetaEffortCapability] Effort (reasoning_effort) support and available levels.
@@ -3,9 +3,6 @@
3
3
  module Anthropic
4
4
  module Models
5
5
  module Beta
6
- # The default destination: the job creates a new output memory store as a clone of
7
- # the memory_store input and writes the consolidated memories into it. The input
8
- # store is never mutated.
9
6
  module BetaOutputBehavior
10
7
  extend Anthropic::Internal::Type::Union
11
8