anthropic 2.10.0 → 2.12.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 (218) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +39 -0
  3. data/README.md +1 -1
  4. data/lib/anthropic/error_classes.rb +8 -0
  5. data/lib/anthropic/helpers/bedrock/client.rb +12 -2
  6. data/lib/anthropic/internal/tracing.rb +16 -0
  7. data/lib/anthropic/internal/transport/base_client.rb +5 -1
  8. data/lib/anthropic/internal/util.rb +5 -4
  9. data/lib/anthropic/models/anthropic_beta.rb +3 -0
  10. data/lib/anthropic/models/beta/message_create_params.rb +6 -0
  11. data/lib/anthropic/models/beta/messages/batch_create_params.rb +6 -0
  12. data/lib/anthropic/models/beta/organization/analytics/beta_analytics_cost_group.rb +2 -1
  13. data/lib/anthropic/models/beta/organization/analytics/beta_analytics_usage_group.rb +2 -1
  14. data/lib/anthropic/models/beta/organization/beta_analytics_cost_bucketed_result.rb +2 -1
  15. data/lib/anthropic/models/beta/organization/beta_analytics_cost_users_item.rb +2 -1
  16. data/lib/anthropic/models/beta/organization/beta_analytics_usage_bucketed_result.rb +2 -1
  17. data/lib/anthropic/models/beta/organization/beta_analytics_usage_users_item.rb +2 -1
  18. data/lib/anthropic/models/beta/organization/beta_organization_rate_limit_value.rb +1 -1
  19. data/lib/anthropic/models/beta/organization/beta_rbac_group_not_found_error.rb +23 -0
  20. data/lib/anthropic/models/beta/organization/beta_rbac_group_not_found_error_details.rb +21 -0
  21. data/lib/anthropic/models/beta/organization/claude_code/beta_cmek_feature_unsupported_error.rb +27 -0
  22. data/lib/anthropic/models/beta/organization/claude_code/beta_cmek_feature_unsupported_error_details.rb +25 -0
  23. data/lib/anthropic/models/beta/organization/claude_code/beta_rbac_group_managed_settings_not_found_error.rb +25 -0
  24. data/lib/anthropic/models/beta/organization/claude_code/beta_rbac_group_managed_settings_not_found_error_details.rb +23 -0
  25. data/lib/anthropic/models/beta/organization/claude_code/beta_rbac_group_order_limit_exceeded_error.rb +26 -0
  26. data/lib/anthropic/models/beta/organization/claude_code/beta_rbac_group_order_limit_exceeded_error_details.rb +24 -0
  27. data/lib/anthropic/models/beta/organization/claude_code/beta_settings_document_limit_exceeded_error.rb +29 -0
  28. data/lib/anthropic/models/beta/organization/claude_code/beta_settings_document_limit_exceeded_error_details.rb +27 -0
  29. data/lib/anthropic/models/beta/organization/claude_code/beta_settings_history_limit_exceeded_error.rb +29 -0
  30. data/lib/anthropic/models/beta/organization/claude_code/beta_settings_history_limit_exceeded_error_details.rb +27 -0
  31. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_configuration.rb +68 -0
  32. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_mode.rb +62 -0
  33. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_mode_param.rb +62 -0
  34. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_organization_mode.rb +24 -0
  35. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_organization_mode_param.rb +23 -0
  36. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_rbac_groups_mode.rb +24 -0
  37. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_rbac_groups_mode_param.rb +23 -0
  38. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_default_managed_settings.rb +50 -0
  39. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_managed_settings.rb +80 -0
  40. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_managed_settings_summary.rb +69 -0
  41. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status.rb +70 -0
  42. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status_active.rb +24 -0
  43. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status_deleted.rb +24 -0
  44. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status_unknown.rb +24 -0
  45. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/beta_deleted_claude_code_rbac_group_managed_settings.rb +33 -0
  46. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/configuration_retrieve_params.rb +35 -0
  47. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/configuration_update_params.rb +62 -0
  48. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_default_retrieve_params.rb +35 -0
  49. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_default_update_params.rb +47 -0
  50. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_delete_params.rb +43 -0
  51. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_list_params.rb +53 -0
  52. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_retrieve_params.rb +43 -0
  53. data/lib/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_set_params.rb +53 -0
  54. data/lib/anthropic/models/beta/organization/workspaces/beta_workspace_rate_limit_type.rb +7 -1
  55. data/lib/anthropic/models/beta/organization/workspaces/beta_workspace_rate_limit_update_value.rb +8 -2
  56. data/lib/anthropic/models/beta/organization/workspaces/beta_workspace_rate_limit_value.rb +1 -1
  57. data/lib/anthropic/models/beta_request_body_timeout_error.rb +20 -0
  58. data/lib/anthropic/models/beta_request_body_timeout_error_details.rb +18 -0
  59. data/lib/anthropic/models/error_details.rb +62 -5
  60. data/lib/anthropic/models/image_dimensions_too_large_error.rb +21 -0
  61. data/lib/anthropic/models/image_dimensions_too_large_error_details.rb +41 -0
  62. data/lib/anthropic/models/organization/organization_rate_limit_value.rb +1 -1
  63. data/lib/anthropic/models/organization/workspaces/workspace_rate_limit_type.rb +7 -1
  64. data/lib/anthropic/models/organization/workspaces/workspace_rate_limit_update_value.rb +8 -2
  65. data/lib/anthropic/models/organization/workspaces/workspace_rate_limit_value.rb +1 -1
  66. data/lib/anthropic/models/sandbox_egress_restricted_error.rb +1 -1
  67. data/lib/anthropic/models/sandbox_egress_restricted_error_details.rb +1 -1
  68. data/lib/anthropic/models/user_profile_billing_not_authorized_error.rb +1 -1
  69. data/lib/anthropic/models/user_profile_billing_not_authorized_error_details.rb +1 -1
  70. data/lib/anthropic/models/user_profile_not_billable_error.rb +2 -2
  71. data/lib/anthropic/models/user_profile_not_billable_error_details.rb +2 -2
  72. data/lib/anthropic/models.rb +8 -0
  73. data/lib/anthropic/resources/beta/messages.rb +3 -0
  74. data/lib/anthropic/resources/beta/organization/analytics/user_cost_report.rb +4 -3
  75. data/lib/anthropic/resources/beta/organization/analytics/user_usage_report.rb +3 -2
  76. data/lib/anthropic/resources/beta/organization/claude_code/managed_settings/configuration.rb +141 -0
  77. data/lib/anthropic/resources/beta/organization/claude_code/managed_settings/rbac_group_default.rb +126 -0
  78. data/lib/anthropic/resources/beta/organization/claude_code/managed_settings/rbac_groups.rb +252 -0
  79. data/lib/anthropic/resources/beta/organization/claude_code/managed_settings.rb +35 -0
  80. data/lib/anthropic/resources/beta/organization/claude_code.rb +23 -0
  81. data/lib/anthropic/resources/beta/organization/external_keys.rb +2 -2
  82. data/lib/anthropic/resources/beta/organization/plugin_marketplaces.rb +5 -0
  83. data/lib/anthropic/resources/beta/organization/plugins/installation_settings.rb +4 -0
  84. data/lib/anthropic/resources/beta/organization/plugins/versions.rb +2 -0
  85. data/lib/anthropic/resources/beta/organization/plugins.rb +3 -0
  86. data/lib/anthropic/resources/beta/organization.rb +4 -0
  87. data/lib/anthropic/resources/messages.rb +3 -0
  88. data/lib/anthropic/resources/organization/external_keys.rb +2 -2
  89. data/lib/anthropic/version.rb +1 -1
  90. data/lib/anthropic.rb +44 -0
  91. data/rbi/anthropic/internal/tracing.rbi +16 -0
  92. data/rbi/anthropic/internal/util.rbi +8 -2
  93. data/rbi/anthropic/models/anthropic_beta.rbi +5 -0
  94. data/rbi/anthropic/models/beta/message_create_params.rbi +12 -0
  95. data/rbi/anthropic/models/beta/messages/batch_create_params.rbi +12 -0
  96. data/rbi/anthropic/models/beta/organization/analytics/beta_analytics_cost_group.rbi +4 -2
  97. data/rbi/anthropic/models/beta/organization/analytics/beta_analytics_usage_group.rbi +4 -2
  98. data/rbi/anthropic/models/beta/organization/beta_analytics_cost_bucketed_result.rbi +4 -2
  99. data/rbi/anthropic/models/beta/organization/beta_analytics_cost_users_item.rbi +4 -2
  100. data/rbi/anthropic/models/beta/organization/beta_analytics_usage_bucketed_result.rbi +4 -2
  101. data/rbi/anthropic/models/beta/organization/beta_analytics_usage_users_item.rbi +4 -2
  102. data/rbi/anthropic/models/beta/organization/beta_organization_rate_limit_value.rbi +2 -2
  103. data/rbi/anthropic/models/beta/organization/beta_rbac_group_not_found_error.rbi +24 -0
  104. data/rbi/anthropic/models/beta/organization/beta_rbac_group_not_found_error_details.rbi +31 -0
  105. data/rbi/anthropic/models/beta/organization/claude_code/beta_cmek_feature_unsupported_error.rbi +28 -0
  106. data/rbi/anthropic/models/beta/organization/claude_code/beta_cmek_feature_unsupported_error_details.rbi +35 -0
  107. data/rbi/anthropic/models/beta/organization/claude_code/beta_rbac_group_managed_settings_not_found_error.rbi +26 -0
  108. data/rbi/anthropic/models/beta/organization/claude_code/beta_rbac_group_managed_settings_not_found_error_details.rbi +33 -0
  109. data/rbi/anthropic/models/beta/organization/claude_code/beta_rbac_group_order_limit_exceeded_error.rbi +27 -0
  110. data/rbi/anthropic/models/beta/organization/claude_code/beta_rbac_group_order_limit_exceeded_error_details.rbi +34 -0
  111. data/rbi/anthropic/models/beta/organization/claude_code/beta_settings_document_limit_exceeded_error.rbi +30 -0
  112. data/rbi/anthropic/models/beta/organization/claude_code/beta_settings_document_limit_exceeded_error_details.rbi +37 -0
  113. data/rbi/anthropic/models/beta/organization/claude_code/beta_settings_history_limit_exceeded_error.rbi +30 -0
  114. data/rbi/anthropic/models/beta/organization/claude_code/beta_settings_history_limit_exceeded_error_details.rbi +37 -0
  115. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_configuration.rbi +101 -0
  116. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_mode.rbi +82 -0
  117. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_mode_param.rbi +82 -0
  118. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_organization_mode.rbi +38 -0
  119. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_organization_mode_param.rbi +34 -0
  120. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_rbac_groups_mode.rbi +38 -0
  121. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_rbac_groups_mode_param.rbi +34 -0
  122. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_default_managed_settings.rbi +70 -0
  123. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_managed_settings.rbi +114 -0
  124. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_managed_settings_summary.rbi +104 -0
  125. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status.rbi +88 -0
  126. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status_active.rbi +38 -0
  127. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status_deleted.rbi +38 -0
  128. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status_unknown.rbi +38 -0
  129. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/beta_deleted_claude_code_rbac_group_managed_settings.rbi +48 -0
  130. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/configuration_retrieve_params.rbi +74 -0
  131. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/configuration_update_params.rbi +136 -0
  132. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_default_retrieve_params.rbi +74 -0
  133. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_default_update_params.rbi +86 -0
  134. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_delete_params.rbi +82 -0
  135. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_list_params.rbi +97 -0
  136. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_retrieve_params.rbi +82 -0
  137. data/rbi/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_set_params.rbi +94 -0
  138. data/rbi/anthropic/models/beta/organization/workspaces/beta_workspace_rate_limit_type.rbi +7 -1
  139. data/rbi/anthropic/models/beta/organization/workspaces/beta_workspace_rate_limit_update_value.rbi +14 -2
  140. data/rbi/anthropic/models/beta/organization/workspaces/beta_workspace_rate_limit_value.rbi +2 -2
  141. data/rbi/anthropic/models/beta_request_body_timeout_error.rbi +17 -0
  142. data/rbi/anthropic/models/beta_request_body_timeout_error_details.rbi +28 -0
  143. data/rbi/anthropic/models/error_details.rbi +57 -0
  144. data/rbi/anthropic/models/image_dimensions_too_large_error.rbi +18 -0
  145. data/rbi/anthropic/models/image_dimensions_too_large_error_details.rbi +63 -0
  146. data/rbi/anthropic/models/organization/organization_rate_limit_value.rbi +2 -2
  147. data/rbi/anthropic/models/organization/workspaces/workspace_rate_limit_type.rbi +7 -1
  148. data/rbi/anthropic/models/organization/workspaces/workspace_rate_limit_update_value.rbi +14 -2
  149. data/rbi/anthropic/models/organization/workspaces/workspace_rate_limit_value.rbi +2 -2
  150. data/rbi/anthropic/models/sandbox_egress_restricted_error.rbi +1 -1
  151. data/rbi/anthropic/models/sandbox_egress_restricted_error_details.rbi +1 -1
  152. data/rbi/anthropic/models/user_profile_billing_not_authorized_error.rbi +1 -1
  153. data/rbi/anthropic/models/user_profile_billing_not_authorized_error_details.rbi +1 -1
  154. data/rbi/anthropic/models/user_profile_not_billable_error.rbi +2 -2
  155. data/rbi/anthropic/models/user_profile_not_billable_error_details.rbi +2 -2
  156. data/rbi/anthropic/models.rbi +10 -0
  157. data/rbi/anthropic/resources/beta/messages.rbi +18 -0
  158. data/rbi/anthropic/resources/beta/organization/analytics/user_cost_report.rbi +4 -3
  159. data/rbi/anthropic/resources/beta/organization/analytics/user_usage_report.rbi +3 -2
  160. data/rbi/anthropic/resources/beta/organization/claude_code/managed_settings/configuration.rbi +112 -0
  161. data/rbi/anthropic/resources/beta/organization/claude_code/managed_settings/rbac_group_default.rbi +86 -0
  162. data/rbi/anthropic/resources/beta/organization/claude_code/managed_settings/rbac_groups.rbi +180 -0
  163. data/rbi/anthropic/resources/beta/organization/claude_code/managed_settings.rbi +39 -0
  164. data/rbi/anthropic/resources/beta/organization/claude_code.rbi +23 -0
  165. data/rbi/anthropic/resources/beta/organization/external_keys.rbi +2 -2
  166. data/rbi/anthropic/resources/beta/organization.rbi +3 -0
  167. data/rbi/anthropic/resources/organization/external_keys.rbi +2 -2
  168. data/sig/anthropic/internal/tracing.rbs +8 -0
  169. data/sig/anthropic/internal/util.rbs +2 -1
  170. data/sig/anthropic/models/anthropic_beta.rbs +2 -0
  171. data/sig/anthropic/models/beta/organization/beta_rbac_group_not_found_error.rbs +13 -0
  172. data/sig/anthropic/models/beta/organization/beta_rbac_group_not_found_error_details.rbs +18 -0
  173. data/sig/anthropic/models/beta/organization/claude_code/beta_cmek_feature_unsupported_error.rbs +15 -0
  174. data/sig/anthropic/models/beta/organization/claude_code/beta_cmek_feature_unsupported_error_details.rbs +20 -0
  175. data/sig/anthropic/models/beta/organization/claude_code/beta_rbac_group_managed_settings_not_found_error.rbs +15 -0
  176. data/sig/anthropic/models/beta/organization/claude_code/beta_rbac_group_managed_settings_not_found_error_details.rbs +24 -0
  177. data/sig/anthropic/models/beta/organization/claude_code/beta_rbac_group_order_limit_exceeded_error.rbs +15 -0
  178. data/sig/anthropic/models/beta/organization/claude_code/beta_rbac_group_order_limit_exceeded_error_details.rbs +22 -0
  179. data/sig/anthropic/models/beta/organization/claude_code/beta_settings_document_limit_exceeded_error.rbs +15 -0
  180. data/sig/anthropic/models/beta/organization/claude_code/beta_settings_document_limit_exceeded_error_details.rbs +22 -0
  181. data/sig/anthropic/models/beta/organization/claude_code/beta_settings_history_limit_exceeded_error.rbs +15 -0
  182. data/sig/anthropic/models/beta/organization/claude_code/beta_settings_history_limit_exceeded_error_details.rbs +22 -0
  183. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_configuration.rbs +48 -0
  184. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_mode.rbs +44 -0
  185. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_mode_param.rbs +44 -0
  186. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_organization_mode.rbs +22 -0
  187. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_organization_mode_param.rbs +22 -0
  188. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_rbac_groups_mode.rbs +22 -0
  189. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_managed_settings_rbac_groups_mode_param.rbs +22 -0
  190. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_default_managed_settings.rbs +38 -0
  191. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_managed_settings.rbs +53 -0
  192. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_managed_settings_summary.rbs +48 -0
  193. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status.rbs +49 -0
  194. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status_active.rbs +21 -0
  195. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status_deleted.rbs +21 -0
  196. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_claude_code_rbac_group_status_unknown.rbs +21 -0
  197. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/beta_deleted_claude_code_rbac_group_managed_settings.rbs +33 -0
  198. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/configuration_retrieve_params.rbs +36 -0
  199. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/configuration_update_params.rbs +61 -0
  200. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_default_retrieve_params.rbs +36 -0
  201. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_default_update_params.rbs +43 -0
  202. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_delete_params.rbs +43 -0
  203. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_list_params.rbs +50 -0
  204. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_retrieve_params.rbs +43 -0
  205. data/sig/anthropic/models/beta/organization/claude_code/managed_settings/rbac_group_set_params.rbs +48 -0
  206. data/sig/anthropic/models/beta_request_body_timeout_error.rbs +9 -0
  207. data/sig/anthropic/models/beta_request_body_timeout_error_details.rbs +14 -0
  208. data/sig/anthropic/models/error_details.rbs +57 -0
  209. data/sig/anthropic/models/image_dimensions_too_large_error.rbs +9 -0
  210. data/sig/anthropic/models/image_dimensions_too_large_error_details.rbs +30 -0
  211. data/sig/anthropic/models.rbs +8 -0
  212. data/sig/anthropic/resources/beta/organization/claude_code/managed_settings/configuration.rbs +28 -0
  213. data/sig/anthropic/resources/beta/organization/claude_code/managed_settings/rbac_group_default.rbs +26 -0
  214. data/sig/anthropic/resources/beta/organization/claude_code/managed_settings/rbac_groups.rbs +41 -0
  215. data/sig/anthropic/resources/beta/organization/claude_code/managed_settings.rbs +19 -0
  216. data/sig/anthropic/resources/beta/organization/claude_code.rbs +13 -0
  217. data/sig/anthropic/resources/beta/organization.rbs +2 -0
  218. metadata +134 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c95b436e737195df72142c842d05ed099068cd446fa0043cc407cb6cf5451deb
4
- data.tar.gz: dd5f8d0bd460c4dc19208454a06e751bacffc2d10c7a93806564926e5bfce304
3
+ metadata.gz: ca693e130ca3c70963ee708a047dfbcd349a065d1d2f808e7f548eb8d528b84b
4
+ data.tar.gz: e9e90a26c4386c28a4cd69444d94364b7e1cb6962bdbf4dbbb88646ed7fe3c19
5
5
  SHA512:
6
- metadata.gz: 07c30931b22e14a6e041a2c8cabfc28962efe35d70ab9d0a4e1d5bb18f4184237b30378fe0f34ccd47dfd385cf7ca95b8c8d0d0162086251ffb9165f6306df6e
7
- data.tar.gz: 675521144c16c141961c6b06405e8d5542eed2a0db0ef6a2013aea25ccf21f48e8222efa3fcc0dfa55cafcb0cd7cbdbefc0f95fa04d995192206165f74c6c7a6
6
+ metadata.gz: 7dd986e8a4371209157a478aa2a0b0bfb6a10070d002cf0a38ad30258f55a1649403dc197475577dab928d94a0152bd7427ed3a9e59c7d823fee51a48487b4dd
7
+ data.tar.gz: 85900815be3754949039e871fc1f56c64773251187d655e595571281668cc2184bd8e6e4c02cd709eb7cdeb217d03bbb8efc823591c48b4136d53a33d41fd29f
data/CHANGELOG.md CHANGED
@@ -1,5 +1,44 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.12.0](https://github.com/anthropics/anthropic-sdk-ruby/compare/v2.11.0...v2.12.0) (2026-11-20)
4
+
5
+ ### Features
6
+
7
+ * **api:** add the image_dimensions_too_large error code
8
+
9
+
10
+ ### Bug Fixes
11
+
12
+ * **bedrock:** send the user profile ID in the request body
13
+
14
+ Amazon Bedrock reads `user_profile_id` from the request body and ignores the `anthropic-user-profile-id` header, so a profile ID given to `Anthropic::BedrockClient` was not applied. `Anthropic::BedrockClient` now moves it into the body of Messages requests and no longer sends the header. A `user_profile_id` already in the body takes priority over the header.
15
+
16
+ Some models on Bedrock do not support user profiles. A request to one of them with a profile ID now fails with a 400 error; before, the ID was ignored. Leave the ID off requests to those models.
17
+
18
+
19
+ ### Chores
20
+
21
+ * **docs:** clarify billing_policy in batches and two billing errors
22
+
23
+ ## [2.11.0](https://github.com/anthropics/anthropic-sdk-ruby/compare/v2.10.0...v2.11.0) (2026-11-19)
24
+
25
+ ### Features
26
+
27
+ * **api:** add Claude Code managed settings to the Admin API
28
+ * **api:** add the sandbox_egress_restricted error to Admin API plugin methods
29
+
30
+
31
+ ### Bug Fixes
32
+
33
+ * **client:** return the bytes of downloaded JSON and JSONL files
34
+
35
+
36
+ ### Chores
37
+
38
+ * **docs:** explain how the input-token rate limit types differ
39
+ * **docs:** name Claude Security in the usage and cost report descriptions
40
+ * **docs:** note that a Google Cloud external key's provider and key_name can't be changed
41
+
3
42
  ## [2.10.0](https://github.com/anthropics/anthropic-sdk-ruby/compare/v2.9.0...v2.10.0) (2026-11-17)
4
43
 
5
44
  ### Features
data/README.md CHANGED
@@ -15,7 +15,7 @@ Add to your application's Gemfile:
15
15
  <!-- x-release-please-start-version -->
16
16
 
17
17
  ```ruby
18
- gem "anthropic", "~> 2.10.0"
18
+ gem "anthropic", "~> 2.12.0"
19
19
  ```
20
20
 
21
21
  <!-- x-release-please-end -->
@@ -34,6 +34,7 @@ module Anthropic
34
34
  [400, "cannot_sign_out_self"] => Anthropic::Models::Beta::Organization::BetaCannotSignOutSelfError,
35
35
  [400, "claude_code_key_creator_not_member"] => Anthropic::Models::ClaudeCodeKeyCreatorNotMemberError,
36
36
  [400, "claude_code_version_too_old"] => Anthropic::Models::ClaudeCodeVersionTooOldError,
37
+ [400, "cmek_feature_unsupported"] => Anthropic::Models::Beta::Organization::ClaudeCode::BetaCMEKFeatureUnsupportedError,
37
38
  [400, "cmek_key_disabled"] => Anthropic::Models::CMEKKeyDisabledError,
38
39
  [400, "cmek_key_network_blocked"] => Anthropic::Models::CMEKKeyNetworkBlockedError,
39
40
  [400, "compaction_block_ambiguous"] => Anthropic::Models::CompactionBlockAmbiguousError,
@@ -50,6 +51,7 @@ module Anthropic
50
51
  [400, "external_key_validation_failed"] => Anthropic::Models::Organization::ExternalKeyValidationFailedError,
51
52
  [400, "external_key_validation_timed_out"] => Anthropic::Models::Organization::ExternalKeyValidationTimedOutError,
52
53
  [400, "file_not_downloadable"] => Anthropic::Models::FileNotDownloadableError,
54
+ [400, "image_dimensions_too_large"] => Anthropic::Models::ImageDimensionsTooLargeError,
53
55
  [400, "invalid_config_type_change"] => Anthropic::Models::Beta::BetaInvalidConfigTypeChangeError,
54
56
  [400, "invalid_metadata"] => Anthropic::Models::Beta::BetaInvalidMetadataError,
55
57
  [400, "invite_already_exists"] => Anthropic::Models::Organization::InviteAlreadyExistsError,
@@ -61,10 +63,14 @@ module Anthropic
61
63
  [400, "organization_type_not_supported"] => Anthropic::Models::OrganizationTypeNotSupportedError,
62
64
  [400, "parent_organization_required"] => Anthropic::Models::ParentOrganizationRequiredError,
63
65
  [400, "rbac_group_grants_owner_access"] => Anthropic::Models::Organization::RBACGroupGrantsOwnerAccessError,
66
+ [400, "rbac_group_order_limit_exceeded"] => Anthropic::Models::Beta::Organization::ClaudeCode::BetaRBACGroupOrderLimitExceededError,
64
67
  [400, "rbac_group_owner_access_unconfirmed"] => Anthropic::Models::Organization::RBACGroupOwnerAccessUnconfirmedError,
65
68
  [400, "request_body_encoding_invalid"] => Anthropic::Models::RequestBodyEncodingInvalidError,
66
69
  [400, "request_body_encoding_unsupported"] => Anthropic::Models::RequestBodyEncodingUnsupportedError,
70
+ [400, "request_body_timeout"] => Anthropic::Models::BetaRequestBodyTimeoutError,
67
71
  [400, "scan_failed"] => Anthropic::Models::Beta::Organization::BetaScanFailedError,
72
+ [400, "settings_document_limit_exceeded"] => Anthropic::Models::Beta::Organization::ClaudeCode::BetaSettingsDocumentLimitExceededError,
73
+ [400, "settings_history_limit_exceeded"] => Anthropic::Models::Beta::Organization::ClaudeCode::BetaSettingsHistoryLimitExceededError,
68
74
  [400, "slack_channel_set_up_settings_refused"] => Anthropic::Models::Beta::Organization::BetaSlackChannelSetUpSettingsRefusedError,
69
75
  [400, "storage_quota_exceeded"] => Anthropic::Models::StorageQuotaExceededError,
70
76
  [400, "thread_already_continued"] => Anthropic::Models::ThreadAlreadyContinuedError,
@@ -97,6 +103,8 @@ module Anthropic
97
103
  [403, "user_profile_not_billable"] => Anthropic::Models::UserProfileNotBillableError,
98
104
  [404, "environment_not_found"] => Anthropic::Models::Beta::BetaEnvironmentNotFoundError,
99
105
  [404, "file_expired"] => Anthropic::Models::FileExpiredError,
106
+ [404, "rbac_group_managed_settings_not_found"] => Anthropic::Models::Beta::Organization::ClaudeCode::BetaRBACGroupManagedSettingsNotFoundError,
107
+ [404, "rbac_group_not_found"] => Anthropic::Models::Beta::Organization::BetaRBACGroupNotFoundError,
100
108
  [404, "rbac_role_not_found"] => Anthropic::Models::RBACRoleNotFoundError,
101
109
  [404, "slack_channel_set_up_environment_not_found"] => Anthropic::Models::Beta::Organization::BetaSlackChannelSetUpEnvironmentNotFoundError,
102
110
  [404, "thread_not_found"] => Anthropic::Models::ThreadNotFoundError,
@@ -333,8 +333,9 @@ module Anthropic
333
333
  # @api private
334
334
  #
335
335
  # Rewrites the canonical Anthropic request into Bedrock's shape — moves
336
- # the `anthropic-version` header into the body, drops
337
- # `:model`/`:stream` from the body and retargets the URL to
336
+ # the `anthropic-version` header into the body, moves the
337
+ # `anthropic-user-profile-id` header of a Messages request into the
338
+ # body, drops `:model`/`:stream` from the body and retargets the URL to
338
339
  # `/model/{model}/invoke[-with-response-stream]`. Called from
339
340
  # {#provider_middleware}, so user middleware sees the canonical
340
341
  # request. Pure: the incoming request, its body, and its URI are never
@@ -357,6 +358,15 @@ module Anthropic
357
358
 
358
359
  return req.with(body: body) unless req.method == :post && messages_route
359
360
 
361
+ profile_headers, headers = req.headers.partition do |name, _|
362
+ name.to_s.casecmp?("anthropic-user-profile-id")
363
+ end
364
+ user_profile_id = profile_headers.last&.last
365
+ unless user_profile_id.to_s.empty?
366
+ body[:user_profile_id] = user_profile_id unless body.keys.any? { _1.to_s == "user_profile_id" }
367
+ req = req.with(headers: headers.to_h)
368
+ end
369
+
360
370
  model = Anthropic::Internal::Util.encode_path(body.delete(:model).to_s)
361
371
  stream = body.delete(:stream) || false
362
372
  invoke_path = stream ? "model/#{model}/invoke-with-response-stream" : "model/#{model}/invoke"
@@ -354,6 +354,22 @@ module Anthropic
354
354
  ORGANIZATION_WEBHOOKS_DELETE = "anthropic.organization.webhooks.delete"
355
355
  ORGANIZATION_WEBHOOKS_REGENERATE_SIGNING_SECRET =
356
356
  "anthropic.organization.webhooks.regenerate_signing_secret"
357
+ ORGANIZATION_CLAUDE_CODE_MANAGED_SETTINGS_CONFIGURATION_RETRIEVE =
358
+ "anthropic.organization.claude_code.managed_settings.configuration.retrieve"
359
+ ORGANIZATION_CLAUDE_CODE_MANAGED_SETTINGS_CONFIGURATION_UPDATE =
360
+ "anthropic.organization.claude_code.managed_settings.configuration.update"
361
+ ORGANIZATION_CLAUDE_CODE_MANAGED_SETTINGS_RBAC_GROUPS_RETRIEVE =
362
+ "anthropic.organization.claude_code.managed_settings.rbac_groups.retrieve"
363
+ ORGANIZATION_CLAUDE_CODE_MANAGED_SETTINGS_RBAC_GROUPS_LIST =
364
+ "anthropic.organization.claude_code.managed_settings.rbac_groups.list"
365
+ ORGANIZATION_CLAUDE_CODE_MANAGED_SETTINGS_RBAC_GROUPS_DELETE =
366
+ "anthropic.organization.claude_code.managed_settings.rbac_groups.delete"
367
+ ORGANIZATION_CLAUDE_CODE_MANAGED_SETTINGS_RBAC_GROUPS_SET =
368
+ "anthropic.organization.claude_code.managed_settings.rbac_groups.set"
369
+ ORGANIZATION_CLAUDE_CODE_MANAGED_SETTINGS_RBAC_GROUP_DEFAULT_RETRIEVE =
370
+ "anthropic.organization.claude_code.managed_settings.rbac_group_default.retrieve"
371
+ ORGANIZATION_CLAUDE_CODE_MANAGED_SETTINGS_RBAC_GROUP_DEFAULT_UPDATE =
372
+ "anthropic.organization.claude_code.managed_settings.rbac_group_default.update"
357
373
  ORGANIZATION_CLAUDE_TAG_SLACK_CHANNELS_CREATE = "anthropic.organization.claude_tag.slack_channels.create"
358
374
  ORGANIZATION_CLAUDE_TAG_SLACK_CHANNELS_RETRIEVE =
359
375
  "anthropic.organization.claude_tag.slack_channels.retrieve"
@@ -866,7 +866,11 @@ module Anthropic
866
866
  )
867
867
  yield(status, headers) if block_given?
868
868
 
869
- decoded = Anthropic::Internal::Util.decode_content(headers, stream: stream)
869
+ decoded = Anthropic::Internal::Util.decode_content(
870
+ headers,
871
+ stream: stream,
872
+ binary: model == StringIO
873
+ )
870
874
  case req
871
875
  in {stream: Class => st}
872
876
  st.new(
@@ -806,12 +806,13 @@ module Anthropic
806
806
  # @param headers [Hash{String=>String}]
807
807
  # @param stream [Enumerable<String>]
808
808
  # @param suppress_error [Boolean]
809
+ # @param binary [Boolean]
809
810
  #
810
811
  # @raise [JSON::ParserError]
811
812
  # @return [Object]
812
- def decode_content(headers, stream:, suppress_error: false)
813
+ def decode_content(headers, stream:, suppress_error: false, binary: false)
813
814
  case (content_type = headers["content-type"])
814
- in Anthropic::Internal::Util::JSON_CONTENT
815
+ in Anthropic::Internal::Util::JSON_CONTENT unless binary
815
816
  return nil if (json = stream.to_a.join).empty?
816
817
 
817
818
  begin
@@ -820,7 +821,7 @@ module Anthropic
820
821
  raise e unless suppress_error
821
822
  json
822
823
  end
823
- in Anthropic::Internal::Util::JSONL_CONTENT
824
+ in Anthropic::Internal::Util::JSONL_CONTENT unless binary
824
825
  lines = decode_lines(stream)
825
826
  chain_fused(lines) do |y|
826
827
  lines.each do
@@ -829,7 +830,7 @@ module Anthropic
829
830
  y << JSON.parse(_1, symbolize_names: true)
830
831
  end
831
832
  end
832
- in %r{^text/event-stream}
833
+ in %r{^text/event-stream} unless binary
833
834
  lines = decode_lines(stream)
834
835
  decode_sse(lines)
835
836
  else
@@ -121,6 +121,8 @@ module Anthropic
121
121
 
122
122
  variant const: -> { Anthropic::Models::AnthropicBeta::CE_USER_MANAGEMENT_2026_07_13 }
123
123
 
124
+ variant const: -> { Anthropic::Models::AnthropicBeta::CE_CLAUDE_CODE_MANAGED_SETTINGS_2026_10_06 }
125
+
124
126
  variant const: -> { Anthropic::Models::AnthropicBeta::USER_PROFILES_BILLING_2026_10_01 }
125
127
 
126
128
  variant String
@@ -204,6 +206,7 @@ module Anthropic
204
206
  CACHE_DIAGNOSIS_2026_04_07 = :"cache-diagnosis-2026-04-07"
205
207
  # @deprecated This value is no longer needed. Remove it from your requests.
206
208
  CE_USER_MANAGEMENT_2026_07_13 = :"ce-user-management-2026-07-13"
209
+ CE_CLAUDE_CODE_MANAGED_SETTINGS_2026_10_06 = :"ce-claude-code-managed-settings-2026-10-06"
207
210
  USER_PROFILES_BILLING_2026_10_01 = :"user-profiles-billing-2026-10-01"
208
211
 
209
212
  # @!endgroup
@@ -119,6 +119,12 @@ module Anthropic
119
119
  # rejected rather than billed to you. Omit the field, or send `"bill_to": "self"`
120
120
  # (the default), to be billed as usual.
121
121
  #
122
+ # Message Batches does not currently support billing the customer behind a user
123
+ # profile. In a batch, omit the field or send `"bill_to": "self"`. A request in a
124
+ # batch that sets `"bill_to": "user_profile"` gets an `errored` result with an
125
+ # `invalid_request_error`, nobody is billed for it, and the batch's other requests
126
+ # run as usual.
127
+ #
122
128
  # @return [Anthropic::Models::Beta::BetaBillingPolicy, nil]
123
129
  optional :billing_policy, -> { Anthropic::Beta::BetaBillingPolicy }, nil?: true
124
130
 
@@ -197,6 +197,12 @@ module Anthropic
197
197
  # rejected rather than billed to you. Omit the field, or send `"bill_to": "self"`
198
198
  # (the default), to be billed as usual.
199
199
  #
200
+ # Message Batches does not currently support billing the customer behind a user
201
+ # profile. In a batch, omit the field or send `"bill_to": "self"`. A request in a
202
+ # batch that sets `"bill_to": "user_profile"` gets an `errored` result with an
203
+ # `invalid_request_error`, nobody is billed for it, and the batch's other requests
204
+ # run as usual.
205
+ #
200
206
  # @return [Anthropic::Models::Beta::BetaBillingPolicy, nil]
201
207
  optional :billing_policy, -> { Anthropic::Beta::BetaBillingPolicy }, nil?: true
202
208
 
@@ -138,7 +138,8 @@ module Anthropic
138
138
  # `chat_cowork_unified` is Chat and Cowork unified, Cowork's features inside
139
139
  # claude.ai chat: chat and Cowork usage by a member who has it turned on is
140
140
  # reported under this value instead of `chat` or `cowork`. It is accepted as a
141
- # filter only where Chat and Cowork unified is available. Some unattributed usage
141
+ # filter only where Chat and Cowork unified is available. `cc_security_autopatch`
142
+ # is work that Claude Security runs for the organization. Some unattributed usage
142
143
  # is reported as "other".
143
144
  #
144
145
  # @return [String, nil]
@@ -128,7 +128,8 @@ module Anthropic
128
128
  # `chat_cowork_unified` is Chat and Cowork unified, Cowork's features inside
129
129
  # claude.ai chat: chat and Cowork usage by a member who has it turned on is
130
130
  # reported under this value instead of `chat` or `cowork`. It is accepted as a
131
- # filter only where Chat and Cowork unified is available. Some unattributed usage
131
+ # filter only where Chat and Cowork unified is available. `cc_security_autopatch`
132
+ # is work that Claude Security runs for the organization. Some unattributed usage
132
133
  # is reported as "other".
133
134
  #
134
135
  # @return [String, nil]
@@ -93,7 +93,8 @@ module Anthropic
93
93
  # `chat_cowork_unified` is Chat and Cowork unified, Cowork's features inside
94
94
  # claude.ai chat: chat and Cowork usage by a member who has it turned on is
95
95
  # reported under this value instead of `chat` or `cowork`. It is accepted as a
96
- # filter only where Chat and Cowork unified is available. Some unattributed usage
96
+ # filter only where Chat and Cowork unified is available. `cc_security_autopatch`
97
+ # is work that Claude Security runs for the organization. Some unattributed usage
97
98
  # is reported as "other".
98
99
  #
99
100
  # @return [String, nil]
@@ -105,7 +105,8 @@ module Anthropic
105
105
  # `chat_cowork_unified` is Chat and Cowork unified, Cowork's features inside
106
106
  # claude.ai chat: chat and Cowork usage by a member who has it turned on is
107
107
  # reported under this value instead of `chat` or `cowork`. It is accepted as a
108
- # filter only where Chat and Cowork unified is available. Some unattributed usage
108
+ # filter only where Chat and Cowork unified is available. `cc_security_autopatch`
109
+ # is work that Claude Security runs for the organization. Some unattributed usage
109
110
  # is reported as "other".
110
111
  #
111
112
  # @return [String, nil]
@@ -86,7 +86,8 @@ module Anthropic
86
86
  # `chat_cowork_unified` is Chat and Cowork unified, Cowork's features inside
87
87
  # claude.ai chat: chat and Cowork usage by a member who has it turned on is
88
88
  # reported under this value instead of `chat` or `cowork`. It is accepted as a
89
- # filter only where Chat and Cowork unified is available. Some unattributed usage
89
+ # filter only where Chat and Cowork unified is available. `cc_security_autopatch`
90
+ # is work that Claude Security runs for the organization. Some unattributed usage
90
91
  # is reported as "other".
91
92
  #
92
93
  # @return [String, nil]
@@ -99,7 +99,8 @@ module Anthropic
99
99
  # `chat_cowork_unified` is Chat and Cowork unified, Cowork's features inside
100
100
  # claude.ai chat: chat and Cowork usage by a member who has it turned on is
101
101
  # reported under this value instead of `chat` or `cowork`. It is accepted as a
102
- # filter only where Chat and Cowork unified is available. Some unattributed usage
102
+ # filter only where Chat and Cowork unified is available. `cc_security_autopatch`
103
+ # is work that Claude Security runs for the organization. Some unattributed usage
103
104
  # is reported as "other".
104
105
  #
105
106
  # @return [String, nil]
@@ -7,7 +7,7 @@ module Anthropic
7
7
  class BetaOrganizationRateLimitValue < Anthropic::Internal::Type::BaseModel
8
8
  # @!attribute type
9
9
  # The limiter type (for example, `requests_per_minute` or
10
- # `input_tokens_per_minute`).
10
+ # `input_tokens_per_minute_cache_aware`).
11
11
  #
12
12
  # @return [String]
13
13
  required :type, String
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ # The RBAC Group is not one of the organization's groups.
8
+ class BetaRBACGroupNotFoundError < Anthropic::Errors::NotFoundError
9
+ # @!method error_code
10
+ # @return [Symbol, :rbac_group_not_found]
11
+
12
+ # @return [Anthropic::Models::Beta::Organization::BetaRBACGroupNotFoundErrorDetails]
13
+ def details
14
+ Anthropic::Internal::Type::Converter.coerce(
15
+ Anthropic::Beta::Organization::BetaRBACGroupNotFoundErrorDetails,
16
+ Anthropic::Internal::Util.dig(body, [:error, :details])
17
+ )
18
+ end
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,21 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ class BetaRBACGroupNotFoundErrorDetails < Anthropic::Internal::Type::BaseModel
8
+ # @!attribute error_code
9
+ #
10
+ # @return [Symbol, :rbac_group_not_found]
11
+ required :error_code, const: :rbac_group_not_found
12
+
13
+ # @!method initialize(error_code: :rbac_group_not_found)
14
+ # The RBAC Group is not one of the organization's groups.
15
+ #
16
+ # @param error_code [Symbol, :rbac_group_not_found]
17
+ end
18
+ end
19
+ end
20
+ end
21
+ end
@@ -0,0 +1,27 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ module ClaudeCode
8
+ # This stored settings document currently cannot be read or replaced. Contact
9
+ # support, or, if you no longer need these settings, delete the group's settings
10
+ # or clear the default.
11
+ class BetaCMEKFeatureUnsupportedError < Anthropic::Errors::BadRequestError
12
+ # @!method error_code
13
+ # @return [Symbol, :cmek_feature_unsupported]
14
+
15
+ # @return [Anthropic::Models::Beta::Organization::ClaudeCode::BetaCMEKFeatureUnsupportedErrorDetails]
16
+ def details
17
+ Anthropic::Internal::Type::Converter.coerce(
18
+ Anthropic::Beta::Organization::ClaudeCode::BetaCMEKFeatureUnsupportedErrorDetails,
19
+ Anthropic::Internal::Util.dig(body, [:error, :details])
20
+ )
21
+ end
22
+ end
23
+ end
24
+ end
25
+ end
26
+ end
27
+ end
@@ -0,0 +1,25 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ module ClaudeCode
8
+ class BetaCMEKFeatureUnsupportedErrorDetails < Anthropic::Internal::Type::BaseModel
9
+ # @!attribute error_code
10
+ #
11
+ # @return [Symbol, :cmek_feature_unsupported]
12
+ required :error_code, const: :cmek_feature_unsupported
13
+
14
+ # @!method initialize(error_code: :cmek_feature_unsupported)
15
+ # This stored settings document currently cannot be read or replaced. Contact
16
+ # support, or, if you no longer need these settings, delete the group's settings
17
+ # or clear the default.
18
+ #
19
+ # @param error_code [Symbol, :cmek_feature_unsupported]
20
+ end
21
+ end
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,25 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ module ClaudeCode
8
+ # This RBAC Group has no Claude Code managed settings.
9
+ class BetaRBACGroupManagedSettingsNotFoundError < Anthropic::Errors::NotFoundError
10
+ # @!method error_code
11
+ # @return [Symbol, :rbac_group_managed_settings_not_found]
12
+
13
+ # @return [Anthropic::Models::Beta::Organization::ClaudeCode::BetaRBACGroupManagedSettingsNotFoundErrorDetails]
14
+ def details
15
+ Anthropic::Internal::Type::Converter.coerce(
16
+ Anthropic::Beta::Organization::ClaudeCode::BetaRBACGroupManagedSettingsNotFoundErrorDetails,
17
+ Anthropic::Internal::Util.dig(body, [:error, :details])
18
+ )
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ module ClaudeCode
8
+ class BetaRBACGroupManagedSettingsNotFoundErrorDetails < Anthropic::Internal::Type::BaseModel
9
+ # @!attribute error_code
10
+ #
11
+ # @return [Symbol, :rbac_group_managed_settings_not_found]
12
+ required :error_code, const: :rbac_group_managed_settings_not_found
13
+
14
+ # @!method initialize(error_code: :rbac_group_managed_settings_not_found)
15
+ # This RBAC Group has no Claude Code managed settings.
16
+ #
17
+ # @param error_code [Symbol, :rbac_group_managed_settings_not_found]
18
+ end
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,26 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ module ClaudeCode
8
+ # The RBAC Group order already has the most groups allowed. Delete another group's
9
+ # settings first.
10
+ class BetaRBACGroupOrderLimitExceededError < Anthropic::Errors::BadRequestError
11
+ # @!method error_code
12
+ # @return [Symbol, :rbac_group_order_limit_exceeded]
13
+
14
+ # @return [Anthropic::Models::Beta::Organization::ClaudeCode::BetaRBACGroupOrderLimitExceededErrorDetails]
15
+ def details
16
+ Anthropic::Internal::Type::Converter.coerce(
17
+ Anthropic::Beta::Organization::ClaudeCode::BetaRBACGroupOrderLimitExceededErrorDetails,
18
+ Anthropic::Internal::Util.dig(body, [:error, :details])
19
+ )
20
+ end
21
+ end
22
+ end
23
+ end
24
+ end
25
+ end
26
+ end
@@ -0,0 +1,24 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ module ClaudeCode
8
+ class BetaRBACGroupOrderLimitExceededErrorDetails < Anthropic::Internal::Type::BaseModel
9
+ # @!attribute error_code
10
+ #
11
+ # @return [Symbol, :rbac_group_order_limit_exceeded]
12
+ required :error_code, const: :rbac_group_order_limit_exceeded
13
+
14
+ # @!method initialize(error_code: :rbac_group_order_limit_exceeded)
15
+ # The RBAC Group order already has the most groups allowed. Delete another group's
16
+ # settings first.
17
+ #
18
+ # @param error_code [Symbol, :rbac_group_order_limit_exceeded]
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
24
+ end
@@ -0,0 +1,29 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ module ClaudeCode
8
+ # The organization has reached its limit of settings documents, counting unused
9
+ # ones. An owner can remove unused documents in claude.ai. Deleting a group's
10
+ # settings or clearing the default settings also frees a document, if nothing else
11
+ # uses it. None of these works once the organization has also reached its settings
12
+ # history limit.
13
+ class BetaSettingsDocumentLimitExceededError < Anthropic::Errors::BadRequestError
14
+ # @!method error_code
15
+ # @return [Symbol, :settings_document_limit_exceeded]
16
+
17
+ # @return [Anthropic::Models::Beta::Organization::ClaudeCode::BetaSettingsDocumentLimitExceededErrorDetails]
18
+ def details
19
+ Anthropic::Internal::Type::Converter.coerce(
20
+ Anthropic::Beta::Organization::ClaudeCode::BetaSettingsDocumentLimitExceededErrorDetails,
21
+ Anthropic::Internal::Util.dig(body, [:error, :details])
22
+ )
23
+ end
24
+ end
25
+ end
26
+ end
27
+ end
28
+ end
29
+ end
@@ -0,0 +1,27 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ module ClaudeCode
8
+ class BetaSettingsDocumentLimitExceededErrorDetails < Anthropic::Internal::Type::BaseModel
9
+ # @!attribute error_code
10
+ #
11
+ # @return [Symbol, :settings_document_limit_exceeded]
12
+ required :error_code, const: :settings_document_limit_exceeded
13
+
14
+ # @!method initialize(error_code: :settings_document_limit_exceeded)
15
+ # The organization has reached its limit of settings documents, counting unused
16
+ # ones. An owner can remove unused documents in claude.ai. Deleting a group's
17
+ # settings or clearing the default settings also frees a document, if nothing else
18
+ # uses it. None of these works once the organization has also reached its settings
19
+ # history limit.
20
+ #
21
+ # @param error_code [Symbol, :settings_document_limit_exceeded]
22
+ end
23
+ end
24
+ end
25
+ end
26
+ end
27
+ end
@@ -0,0 +1,29 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Anthropic
4
+ module Models
5
+ module Beta
6
+ module Organization
7
+ module ClaudeCode
8
+ # The organization has reached its settings history limit, a cap on stored
9
+ # versions of its settings documents. Nothing in the API or claude.ai lowers the
10
+ # count, so contact support. Creating or deleting group settings, creating or
11
+ # clearing the default settings, and reordering are refused. Changing the mode
12
+ # still works, unless it would copy the organization settings into a new default.
13
+ class BetaSettingsHistoryLimitExceededError < Anthropic::Errors::BadRequestError
14
+ # @!method error_code
15
+ # @return [Symbol, :settings_history_limit_exceeded]
16
+
17
+ # @return [Anthropic::Models::Beta::Organization::ClaudeCode::BetaSettingsHistoryLimitExceededErrorDetails]
18
+ def details
19
+ Anthropic::Internal::Type::Converter.coerce(
20
+ Anthropic::Beta::Organization::ClaudeCode::BetaSettingsHistoryLimitExceededErrorDetails,
21
+ Anthropic::Internal::Util.dig(body, [:error, :details])
22
+ )
23
+ end
24
+ end
25
+ end
26
+ end
27
+ end
28
+ end
29
+ end