gcore 0.2.0__py3-none-any.whl → 0.4.0__py3-none-any.whl

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.

Potentially problematic release.


This version of gcore might be problematic. Click here for more details.

Files changed (315) hide show
  1. gcore/__init__.py +2 -1
  2. gcore/_base_client.py +44 -2
  3. gcore/_client.py +9 -0
  4. gcore/_models.py +2 -0
  5. gcore/_types.py +2 -0
  6. gcore/_version.py +1 -1
  7. gcore/pagination.py +61 -1
  8. gcore/resources/__init__.py +14 -0
  9. gcore/resources/cloud/baremetal/flavors.py +11 -137
  10. gcore/resources/cloud/baremetal/images.py +10 -12
  11. gcore/resources/cloud/baremetal/servers.py +75 -78
  12. gcore/resources/cloud/billing_reservations.py +2 -2
  13. gcore/resources/cloud/file_shares/file_shares.py +7 -8
  14. gcore/resources/cloud/floating_ips.py +9 -14
  15. gcore/resources/cloud/gpu_baremetal_clusters/gpu_baremetal_clusters.py +39 -28
  16. gcore/resources/cloud/gpu_baremetal_clusters/images.py +11 -12
  17. gcore/resources/cloud/gpu_baremetal_clusters/interfaces.py +2 -2
  18. gcore/resources/cloud/gpu_baremetal_clusters/servers.py +12 -8
  19. gcore/resources/cloud/inference/deployments/deployments.py +16 -8
  20. gcore/resources/cloud/inference/registry_credentials.py +2 -2
  21. gcore/resources/cloud/inference/secrets.py +8 -8
  22. gcore/resources/cloud/instances/flavors.py +9 -233
  23. gcore/resources/cloud/instances/images.py +47 -37
  24. gcore/resources/cloud/instances/instances.py +107 -100
  25. gcore/resources/cloud/instances/interfaces.py +6 -6
  26. gcore/resources/cloud/ip_ranges.py +34 -2
  27. gcore/resources/cloud/load_balancers/flavors.py +2 -2
  28. gcore/resources/cloud/load_balancers/l7_policies/l7_policies.py +30 -22
  29. gcore/resources/cloud/load_balancers/listeners.py +31 -22
  30. gcore/resources/cloud/load_balancers/load_balancers.py +99 -43
  31. gcore/resources/cloud/load_balancers/metrics.py +2 -2
  32. gcore/resources/cloud/load_balancers/pools/health_monitors.py +2 -2
  33. gcore/resources/cloud/load_balancers/pools/members.py +12 -8
  34. gcore/resources/cloud/networks/networks.py +83 -19
  35. gcore/resources/cloud/networks/routers.py +18 -18
  36. gcore/resources/cloud/networks/subnets.py +55 -15
  37. gcore/resources/cloud/projects.py +38 -24
  38. gcore/resources/cloud/quotas/quotas.py +6 -6
  39. gcore/resources/cloud/quotas/requests.py +8 -8
  40. gcore/resources/cloud/registries/artifacts.py +4 -4
  41. gcore/resources/cloud/registries/registries.py +14 -20
  42. gcore/resources/cloud/registries/repositories.py +4 -4
  43. gcore/resources/cloud/registries/tags.py +2 -2
  44. gcore/resources/cloud/registries/users.py +25 -32
  45. gcore/resources/cloud/reserved_fixed_ips/reserved_fixed_ips.py +26 -26
  46. gcore/resources/cloud/reserved_fixed_ips/vip.py +10 -10
  47. gcore/resources/cloud/security_groups/rules.py +6 -6
  48. gcore/resources/cloud/security_groups/security_groups.py +70 -31
  49. gcore/resources/cloud/ssh_keys.py +2 -2
  50. gcore/resources/cloud/tasks.py +102 -94
  51. gcore/resources/cloud/users/role_assignments.py +16 -18
  52. gcore/resources/cloud/volumes.py +155 -65
  53. gcore/resources/iam/__init__.py +47 -0
  54. gcore/resources/iam/api_tokens.py +521 -0
  55. gcore/resources/iam/iam.py +199 -0
  56. gcore/resources/iam/users.py +642 -0
  57. gcore/resources/waap/__init__.py +84 -0
  58. gcore/resources/waap/advanced_rules.py +135 -0
  59. gcore/resources/waap/custom_page_sets.py +805 -0
  60. gcore/resources/waap/domains/__init__.py +140 -0
  61. gcore/resources/waap/domains/advanced_rules.py +876 -0
  62. gcore/resources/waap/domains/analytics/__init__.py +33 -0
  63. gcore/resources/waap/domains/analytics/analytics.py +676 -0
  64. gcore/resources/waap/domains/analytics/requests.py +378 -0
  65. gcore/resources/waap/domains/api_discovery/__init__.py +33 -0
  66. gcore/resources/waap/domains/api_discovery/api_discovery.py +530 -0
  67. gcore/resources/waap/domains/api_discovery/scan_results.py +352 -0
  68. gcore/resources/waap/domains/api_path_groups.py +163 -0
  69. gcore/resources/waap/domains/api_paths.py +771 -0
  70. gcore/resources/waap/domains/custom_rules.py +889 -0
  71. gcore/resources/waap/domains/domains.py +399 -0
  72. gcore/resources/waap/domains/firewall_rules.py +884 -0
  73. gcore/resources/waap/domains/insight_silences.py +689 -0
  74. gcore/resources/waap/domains/insights.py +425 -0
  75. gcore/resources/waap/domains/policies.py +173 -0
  76. gcore/resources/waap/domains/settings.py +5 -5
  77. gcore/resources/waap/ip_info.py +1017 -0
  78. gcore/resources/waap/organizations.py +217 -0
  79. gcore/resources/waap/statistics.py +225 -0
  80. gcore/resources/waap/tags.py +233 -0
  81. gcore/resources/waap/waap.py +257 -0
  82. gcore/types/cloud/allowed_address_pairs.py +2 -2
  83. gcore/types/cloud/baremetal/__init__.py +0 -1
  84. gcore/types/cloud/baremetal/baremetal_server.py +1 -1
  85. gcore/types/cloud/baremetal/image_list_params.py +1 -5
  86. gcore/types/cloud/baremetal/server_create_params.py +13 -17
  87. gcore/types/cloud/baremetal/server_list_params.py +8 -12
  88. gcore/types/cloud/baremetal/server_rebuild_params.py +1 -1
  89. gcore/types/cloud/baremetal_flavor.py +3 -3
  90. gcore/types/cloud/container_probe_config.py +1 -1
  91. gcore/types/cloud/container_probe_config_create_param.py +1 -1
  92. gcore/types/cloud/container_scale_triggers.py +2 -2
  93. gcore/types/cloud/ddos_profile.py +9 -3
  94. gcore/types/cloud/file_share_create_params.py +3 -5
  95. gcore/types/cloud/floating_ip_create_params.py +2 -4
  96. gcore/types/cloud/floating_ip_detailed.py +1 -1
  97. gcore/types/cloud/floating_ip_list_params.py +2 -6
  98. gcore/types/cloud/gpu_baremetal_cluster.py +1 -1
  99. gcore/types/cloud/gpu_baremetal_cluster_create_params.py +4 -5
  100. gcore/types/cloud/gpu_baremetal_cluster_delete_params.py +1 -1
  101. gcore/types/cloud/gpu_baremetal_cluster_rebuild_params.py +1 -1
  102. gcore/types/cloud/gpu_baremetal_cluster_server.py +1 -1
  103. gcore/types/cloud/gpu_baremetal_clusters/image_upload_params.py +3 -5
  104. gcore/types/cloud/gpu_baremetal_clusters/server_attach_interface_params.py +10 -10
  105. gcore/types/cloud/gpu_baremetal_flavor.py +3 -3
  106. gcore/types/cloud/health_monitor.py +6 -1
  107. gcore/types/cloud/image.py +1 -1
  108. gcore/types/cloud/inference/deployment_create_params.py +4 -4
  109. gcore/types/cloud/inference/deployment_update_params.py +6 -6
  110. gcore/types/cloud/inference/inference.py +2 -4
  111. gcore/types/cloud/instance.py +1 -1
  112. gcore/types/cloud/instance_create_params.py +15 -18
  113. gcore/types/cloud/instance_list_params.py +8 -12
  114. gcore/types/cloud/instances/__init__.py +0 -2
  115. gcore/types/cloud/instances/image_create_from_volume_params.py +2 -4
  116. gcore/types/cloud/instances/image_list_params.py +1 -5
  117. gcore/types/cloud/instances/image_upload_params.py +2 -4
  118. gcore/types/cloud/instances/instance_flavor.py +3 -3
  119. gcore/types/cloud/instances/interface_attach_params.py +10 -10
  120. gcore/types/cloud/load_balancer_create_params.py +25 -19
  121. gcore/types/cloud/load_balancer_flavor_detail.py +3 -3
  122. gcore/types/cloud/load_balancer_l7_policy.py +5 -5
  123. gcore/types/cloud/load_balancer_list_params.py +5 -9
  124. gcore/types/cloud/load_balancer_listener_detail.py +4 -4
  125. gcore/types/cloud/load_balancer_update_params.py +24 -0
  126. gcore/types/cloud/load_balancers/l7_policy_create_params.py +5 -5
  127. gcore/types/cloud/load_balancers/l7_policy_replace_params.py +5 -5
  128. gcore/types/cloud/load_balancers/listener_create_params.py +4 -4
  129. gcore/types/cloud/load_balancers/listener_update_params.py +3 -3
  130. gcore/types/cloud/load_balancers/pool_create_params.py +10 -5
  131. gcore/types/cloud/load_balancers/pool_update_params.py +10 -5
  132. gcore/types/cloud/load_balancers/pools/member_add_params.py +9 -4
  133. gcore/types/cloud/member.py +8 -3
  134. gcore/types/cloud/network.py +2 -2
  135. gcore/types/cloud/network_create_params.py +2 -3
  136. gcore/types/cloud/network_details.py +2 -2
  137. gcore/types/cloud/network_list_params.py +5 -6
  138. gcore/types/cloud/network_update_params.py +28 -2
  139. gcore/types/cloud/networks/router_list_params.py +2 -2
  140. gcore/types/cloud/networks/subnet_create_params.py +3 -4
  141. gcore/types/cloud/networks/subnet_list_params.py +2 -6
  142. gcore/types/cloud/networks/subnet_update_params.py +25 -0
  143. gcore/types/cloud/region.py +4 -4
  144. gcore/types/cloud/registries/__init__.py +1 -0
  145. gcore/types/cloud/registries/user_create_multiple_params.py +3 -5
  146. gcore/types/cloud/registries/user_create_params.py +3 -5
  147. gcore/types/cloud/registries/user_refresh_secret_response.py +31 -0
  148. gcore/types/cloud/registry_create_params.py +3 -5
  149. gcore/types/cloud/reserved_fixed_ip_create_params.py +2 -2
  150. gcore/types/cloud/reserved_fixed_ip_list_params.py +3 -3
  151. gcore/types/cloud/security_group_list_params.py +3 -7
  152. gcore/types/cloud/security_group_update_params.py +25 -0
  153. gcore/types/cloud/session_persistence.py +1 -1
  154. gcore/types/cloud/ssh_key_created.py +3 -6
  155. gcore/types/cloud/tag_update_map_param.py +2 -2
  156. gcore/types/cloud/task.py +1 -1
  157. gcore/types/cloud/task_list_params.py +49 -45
  158. gcore/types/cloud/users/role_assignment_create_params.py +1 -1
  159. gcore/types/cloud/users/role_assignment_update_params.py +1 -1
  160. gcore/types/cloud/volume_create_params.py +6 -6
  161. gcore/types/cloud/volume_list_params.py +3 -7
  162. gcore/types/cloud/volume_update_params.py +29 -3
  163. gcore/types/iam/__init__.py +17 -0
  164. gcore/types/iam/account_overview.py +488 -0
  165. gcore/types/iam/api_token.py +78 -0
  166. gcore/types/iam/api_token_create.py +15 -0
  167. gcore/types/iam/api_token_create_params.py +42 -0
  168. gcore/types/iam/api_token_list.py +81 -0
  169. gcore/types/iam/api_token_list_params.py +41 -0
  170. gcore/types/iam/user.py +86 -0
  171. gcore/types/iam/user_detailed.py +104 -0
  172. gcore/types/iam/user_invite.py +15 -0
  173. gcore/types/iam/user_invite_params.py +37 -0
  174. gcore/types/iam/user_list_params.py +15 -0
  175. gcore/types/iam/user_update.py +104 -0
  176. gcore/types/iam/user_update_params.py +52 -0
  177. gcore/types/waap/__init__.py +97 -2
  178. gcore/types/waap/custom_page_set_create_params.py +35 -0
  179. gcore/types/waap/custom_page_set_list_params.py +25 -0
  180. gcore/types/waap/custom_page_set_preview_params.py +34 -0
  181. gcore/types/waap/custom_page_set_update_params.py +35 -0
  182. gcore/types/waap/domain_list_rule_sets_response.py +10 -0
  183. gcore/types/waap/domains/__init__.py +42 -0
  184. gcore/types/waap/domains/advanced_rule_create_params.py +80 -0
  185. gcore/types/waap/domains/advanced_rule_list_params.py +58 -0
  186. gcore/types/waap/domains/advanced_rule_update_params.py +83 -0
  187. gcore/types/waap/domains/analytics/__init__.py +5 -0
  188. gcore/types/waap/domains/analytics/request_list_params.py +53 -0
  189. gcore/types/waap/domains/analytics_get_event_statistics_params.py +34 -0
  190. gcore/types/waap/domains/analytics_list_ddos_attacks_params.py +28 -0
  191. gcore/types/waap/domains/analytics_list_ddos_info_params.py +31 -0
  192. gcore/types/waap/domains/analytics_list_event_traffic_params.py +26 -0
  193. gcore/types/waap/domains/analytics_list_event_traffic_response.py +10 -0
  194. gcore/types/waap/domains/api_discovery/__init__.py +7 -0
  195. gcore/types/waap/domains/api_discovery/scan_result_get_response.py +29 -0
  196. gcore/types/waap/domains/api_discovery/scan_result_list_params.py +41 -0
  197. gcore/types/waap/domains/api_discovery/scan_result_list_response.py +29 -0
  198. gcore/types/waap/domains/api_discovery_get_settings_response.py +36 -0
  199. gcore/types/waap/domains/api_discovery_scan_openapi_response.py +10 -0
  200. gcore/types/waap/domains/api_discovery_update_settings_params.py +34 -0
  201. gcore/types/waap/domains/api_discovery_update_settings_response.py +36 -0
  202. gcore/types/waap/domains/api_discovery_upload_openapi_params.py +19 -0
  203. gcore/types/waap/domains/api_discovery_upload_openapi_response.py +10 -0
  204. gcore/types/waap/domains/api_path_create_params.py +31 -0
  205. gcore/types/waap/domains/api_path_create_response.py +50 -0
  206. gcore/types/waap/domains/api_path_get_response.py +50 -0
  207. gcore/types/waap/domains/api_path_group_list_response.py +12 -0
  208. gcore/types/waap/domains/api_path_list_params.py +62 -0
  209. gcore/types/waap/domains/api_path_list_response.py +50 -0
  210. gcore/types/waap/domains/api_path_update_params.py +29 -0
  211. gcore/types/waap/domains/custom_rule_create_params.py +372 -0
  212. gcore/types/waap/domains/custom_rule_delete_multiple_params.py +13 -0
  213. gcore/types/waap/domains/custom_rule_list_params.py +35 -0
  214. gcore/types/waap/domains/custom_rule_update_params.py +375 -0
  215. gcore/types/waap/domains/firewall_rule_create_params.py +75 -0
  216. gcore/types/waap/domains/firewall_rule_delete_multiple_params.py +13 -0
  217. gcore/types/waap/domains/firewall_rule_list_params.py +33 -0
  218. gcore/types/waap/domains/firewall_rule_update_params.py +78 -0
  219. gcore/types/waap/domains/insight_list_params.py +34 -0
  220. gcore/types/waap/domains/insight_replace_params.py +17 -0
  221. gcore/types/waap/domains/insight_silence_create_params.py +28 -0
  222. gcore/types/waap/domains/insight_silence_list_params.py +33 -0
  223. gcore/types/waap/domains/insight_silence_update_params.py +28 -0
  224. gcore/types/waap/domains/setting_update_params.py +7 -0
  225. gcore/types/waap/ip_info_get_attack_time_series_params.py +12 -0
  226. gcore/types/waap/ip_info_get_attack_time_series_response.py +10 -0
  227. gcore/types/waap/ip_info_get_blocked_requests_params.py +15 -0
  228. gcore/types/waap/ip_info_get_blocked_requests_response.py +10 -0
  229. gcore/types/waap/ip_info_get_counts_params.py +19 -0
  230. gcore/types/waap/ip_info_get_ddos_attack_series_params.py +12 -0
  231. gcore/types/waap/ip_info_get_params.py +12 -0
  232. gcore/types/waap/ip_info_get_top_sessions_params.py +15 -0
  233. gcore/types/waap/ip_info_get_top_sessions_response.py +10 -0
  234. gcore/types/waap/ip_info_get_top_urls_params.py +15 -0
  235. gcore/types/waap/ip_info_get_top_urls_response.py +10 -0
  236. gcore/types/waap/ip_info_get_top_user_agents_params.py +15 -0
  237. gcore/types/waap/ip_info_get_top_user_agents_response.py +10 -0
  238. gcore/types/waap/ip_info_list_attacked_countries_params.py +12 -0
  239. gcore/types/waap/ip_info_list_attacked_countries_response.py +10 -0
  240. gcore/types/waap/organization_list_params.py +22 -0
  241. gcore/types/waap/statistic_get_usage_series_params.py +25 -0
  242. gcore/types/waap/tag_list_params.py +28 -0
  243. gcore/types/waap/waap_advanced_rule.py +83 -0
  244. gcore/types/waap/waap_advanced_rule_descriptor.py +49 -0
  245. gcore/types/waap/waap_advanced_rule_descriptor_list.py +15 -0
  246. gcore/types/waap/waap_block_csrf_page_data.py +28 -0
  247. gcore/types/waap/waap_block_csrf_page_data_param.py +28 -0
  248. gcore/types/waap/waap_block_page_data.py +28 -0
  249. gcore/types/waap/waap_block_page_data_param.py +28 -0
  250. gcore/types/waap/waap_blocked_statistics.py +36 -0
  251. gcore/types/waap/waap_captcha_page_data.py +31 -0
  252. gcore/types/waap/waap_captcha_page_data_param.py +31 -0
  253. gcore/types/waap/waap_common_tag.py +16 -0
  254. gcore/types/waap/waap_cookie_disabled_page_data.py +18 -0
  255. gcore/types/waap/waap_cookie_disabled_page_data_param.py +18 -0
  256. gcore/types/waap/waap_count_statistics.py +36 -0
  257. gcore/types/waap/waap_custom_page_preview.py +10 -0
  258. gcore/types/waap/waap_custom_page_set.py +36 -0
  259. gcore/types/waap/waap_custom_rule.py +377 -0
  260. gcore/types/waap/waap_customer_rule_state.py +7 -0
  261. gcore/types/waap/waap_ddos_attack.py +16 -0
  262. gcore/types/waap/waap_ddos_info.py +17 -0
  263. gcore/types/waap/{waap_api_urls.py → waap_domain_api_settings.py} +9 -2
  264. gcore/types/waap/waap_domain_policy.py +29 -0
  265. gcore/types/waap/{waap_domain_settings.py → waap_domain_settings_model.py} +4 -4
  266. gcore/types/waap/waap_event_statistics.py +15 -0
  267. gcore/types/waap/waap_firewall_rule.py +78 -0
  268. gcore/types/waap/waap_get_account_overview_response.py +34 -0
  269. gcore/types/waap/waap_handshake_page_data.py +25 -0
  270. gcore/types/waap/waap_handshake_page_data_param.py +25 -0
  271. gcore/types/waap/waap_insight.py +38 -0
  272. gcore/types/waap/waap_insight_silence.py +28 -0
  273. gcore/types/waap/waap_insight_silence_sort_by.py +9 -0
  274. gcore/types/waap/waap_insight_sort_by.py +20 -0
  275. gcore/types/waap/waap_insight_status.py +7 -0
  276. gcore/types/waap/waap_ip_country_attack.py +16 -0
  277. gcore/types/waap/waap_ip_ddos_info_model.py +23 -0
  278. gcore/types/waap/waap_ip_info.py +57 -0
  279. gcore/types/waap/waap_ip_info_counts.py +16 -0
  280. gcore/types/waap/waap_javascript_disabled_page_data.py +18 -0
  281. gcore/types/waap/waap_javascript_disabled_page_data_param.py +18 -0
  282. gcore/types/waap/waap_network_details.py +17 -0
  283. gcore/types/waap/waap_organization.py +13 -0
  284. gcore/types/waap/waap_page_type.py +9 -0
  285. gcore/types/waap/waap_paginated_custom_page_set.py +22 -0
  286. gcore/types/waap/waap_paginated_ddos_attack.py +22 -0
  287. gcore/types/waap/waap_paginated_ddos_info.py +22 -0
  288. gcore/types/waap/waap_paginated_request_summary.py +22 -0
  289. gcore/types/waap/waap_pattern_matched_tag.py +37 -0
  290. gcore/types/waap/waap_policy_action.py +7 -0
  291. gcore/types/waap/waap_policy_mode.py +10 -0
  292. gcore/types/waap/waap_request_details.py +92 -0
  293. gcore/types/waap/waap_request_organization.py +13 -0
  294. gcore/types/waap/waap_request_summary.py +59 -0
  295. gcore/types/waap/waap_resolution.py +7 -0
  296. gcore/types/waap/waap_rule_action_type.py +7 -0
  297. gcore/types/waap/waap_rule_blocked_requests.py +16 -0
  298. gcore/types/waap/waap_rule_set.py +41 -0
  299. gcore/types/waap/waap_statistic_item.py +18 -0
  300. gcore/types/waap/waap_statistics_series.py +16 -0
  301. gcore/types/waap/waap_tag.py +16 -0
  302. gcore/types/waap/waap_time_series_attack.py +23 -0
  303. gcore/types/waap/waap_top_session.py +24 -0
  304. gcore/types/waap/waap_top_url.py +13 -0
  305. gcore/types/waap/waap_top_user_agent.py +13 -0
  306. gcore/types/waap/waap_traffic_metrics.py +68 -0
  307. gcore/types/waap/waap_traffic_type.py +28 -0
  308. gcore/types/waap/waap_user_agent_details.py +40 -0
  309. {gcore-0.2.0.dist-info → gcore-0.4.0.dist-info}/METADATA +40 -3
  310. {gcore-0.2.0.dist-info → gcore-0.4.0.dist-info}/RECORD +312 -149
  311. gcore/types/cloud/baremetal/flavor_list_suitable_params.py +0 -22
  312. gcore/types/cloud/instances/flavor_list_for_resize_params.py +0 -16
  313. gcore/types/cloud/instances/flavor_list_suitable_params.py +0 -56
  314. {gcore-0.2.0.dist-info → gcore-0.4.0.dist-info}/WHEEL +0 -0
  315. {gcore-0.2.0.dist-info → gcore-0.4.0.dist-info}/licenses/LICENSE +0 -0
@@ -78,17 +78,19 @@ class MembersResource(SyncAPIResource):
78
78
 
79
79
  protocol_port: Member IP port
80
80
 
81
- admin_state_up: true if enabled. Defaults to true
81
+ admin_state_up: Administrative state of the resource. When set to true, the resource is enabled
82
+ and operational. When set to false, the resource is disabled and will not
83
+ process traffic. When null is passed, the value is skipped and defaults to true.
82
84
 
83
- instance_id: Either subnet_id or instance_id should be provided
85
+ instance_id: Either `subnet_id` or `instance_id` should be provided
84
86
 
85
87
  monitor_address: An alternate IP address used for health monitoring of a backend member. Default
86
88
  is null which monitors the member address.
87
89
 
88
90
  monitor_port: An alternate protocol port used for health monitoring of a backend member.
89
- Default is null which monitors the member protocol_port.
91
+ Default is null which monitors the member `protocol_port`.
90
92
 
91
- subnet_id: Either subnet_id or instance_id should be provided
93
+ subnet_id: Either `subnet_id` or `instance_id` should be provided
92
94
 
93
95
  weight: Member weight. Valid values: 0 to 256, defaults to 1
94
96
 
@@ -233,17 +235,19 @@ class AsyncMembersResource(AsyncAPIResource):
233
235
 
234
236
  protocol_port: Member IP port
235
237
 
236
- admin_state_up: true if enabled. Defaults to true
238
+ admin_state_up: Administrative state of the resource. When set to true, the resource is enabled
239
+ and operational. When set to false, the resource is disabled and will not
240
+ process traffic. When null is passed, the value is skipped and defaults to true.
237
241
 
238
- instance_id: Either subnet_id or instance_id should be provided
242
+ instance_id: Either `subnet_id` or `instance_id` should be provided
239
243
 
240
244
  monitor_address: An alternate IP address used for health monitoring of a backend member. Default
241
245
  is null which monitors the member address.
242
246
 
243
247
  monitor_port: An alternate protocol port used for health monitoring of a backend member.
244
- Default is null which monitors the member protocol_port.
248
+ Default is null which monitors the member `protocol_port`.
245
249
 
246
- subnet_id: Either subnet_id or instance_id should be provided
250
+ subnet_id: Either `subnet_id` or `instance_id` should be provided
247
251
 
248
252
  weight: Member weight. Valid values: 0 to 256, defaults to 1
249
253
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  from __future__ import annotations
4
4
 
5
- from typing import List
5
+ from typing import Dict, List, Optional
6
6
  from typing_extensions import Literal
7
7
 
8
8
  import httpx
@@ -78,7 +78,7 @@ class NetworksResource(SyncAPIResource):
78
78
  region_id: int | None = None,
79
79
  name: str,
80
80
  create_router: bool | NotGiven = NOT_GIVEN,
81
- tags: TagUpdateMapParam | NotGiven = NOT_GIVEN,
81
+ tags: Dict[str, str] | NotGiven = NOT_GIVEN,
82
82
  type: Literal["vlan", "vxlan"] | NotGiven = NOT_GIVEN,
83
83
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
84
84
  # The extra values given here take precedence over values defined on the client or passed to this method.
@@ -142,7 +142,8 @@ class NetworksResource(SyncAPIResource):
142
142
  *,
143
143
  project_id: int | None = None,
144
144
  region_id: int | None = None,
145
- name: str,
145
+ name: str | NotGiven = NOT_GIVEN,
146
+ tags: Optional[TagUpdateMapParam] | NotGiven = NOT_GIVEN,
146
147
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
147
148
  # The extra values given here take precedence over values defined on the client or passed to this method.
148
149
  extra_headers: Headers | None = None,
@@ -150,8 +151,11 @@ class NetworksResource(SyncAPIResource):
150
151
  extra_body: Body | None = None,
151
152
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
152
153
  ) -> Network:
153
- """
154
- Change network name
154
+ """Rename network and/or update network tags.
155
+
156
+ The request will only process the
157
+ fields that are provided in the request body. Any fields that are not included
158
+ will remain unchanged.
155
159
 
156
160
  Args:
157
161
  project_id: Project ID
@@ -162,6 +166,26 @@ class NetworksResource(SyncAPIResource):
162
166
 
163
167
  name: Name.
164
168
 
169
+ tags: Update key-value tags using JSON Merge Patch semantics (RFC 7386). Provide
170
+ key-value pairs to add or update tags. Set tag values to `null` to remove tags.
171
+ Unspecified tags remain unchanged. Read-only tags are always preserved and
172
+ cannot be modified. **Examples:**
173
+
174
+ - **Add/update tags:**
175
+ `{'tags': {'environment': 'production', 'team': 'backend'}}` adds new tags or
176
+ updates existing ones.
177
+ - **Delete tags:** `{'tags': {'`old_tag`': null}}` removes specific tags.
178
+ - **Remove all tags:** `{'tags': null}` removes all user-managed tags (read-only
179
+ tags are preserved).
180
+ - **Partial update:** `{'tags': {'environment': 'staging'}}` only updates
181
+ specified tags.
182
+ - **Mixed operations:**
183
+ `{'tags': {'environment': 'production', '`cost_center`': 'engineering', '`deprecated_tag`': null}}`
184
+ adds/updates 'environment' and '`cost_center`' while removing
185
+ '`deprecated_tag`', preserving other existing tags.
186
+ - **Replace all:** first delete existing tags with null values, then add new
187
+ ones in the same request.
188
+
165
189
  extra_headers: Send extra headers
166
190
 
167
191
  extra_query: Add additional query parameters to the request
@@ -178,7 +202,13 @@ class NetworksResource(SyncAPIResource):
178
202
  raise ValueError(f"Expected a non-empty value for `network_id` but received {network_id!r}")
179
203
  return self._patch(
180
204
  f"/cloud/v1/networks/{project_id}/{region_id}/{network_id}",
181
- body=maybe_transform({"name": name}, network_update_params.NetworkUpdateParams),
205
+ body=maybe_transform(
206
+ {
207
+ "name": name,
208
+ "tags": tags,
209
+ },
210
+ network_update_params.NetworkUpdateParams,
211
+ ),
182
212
  options=make_request_options(
183
213
  extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
184
214
  ),
@@ -191,6 +221,7 @@ class NetworksResource(SyncAPIResource):
191
221
  project_id: int | None = None,
192
222
  region_id: int | None = None,
193
223
  limit: int | NotGiven = NOT_GIVEN,
224
+ name: str | NotGiven = NOT_GIVEN,
194
225
  offset: int | NotGiven = NOT_GIVEN,
195
226
  order_by: Literal["created_at.asc", "created_at.desc", "name.asc", "name.desc"] | NotGiven = NOT_GIVEN,
196
227
  tag_key: List[str] | NotGiven = NOT_GIVEN,
@@ -212,17 +243,17 @@ class NetworksResource(SyncAPIResource):
212
243
 
213
244
  limit: Optional. Limit the number of returned items
214
245
 
246
+ name: Filter networks by name
247
+
215
248
  offset: Optional. Offset value is used to exclude the first set of records from the
216
249
  result
217
250
 
218
251
  order_by: Ordering networks list result by `name`, `created_at` fields of the network and
219
252
  directions (`created_at.desc`).
220
253
 
221
- tag_key: Optional. Filter by tag keys. ?tag_key=key1&tag_key=key2
254
+ tag_key: Optional. Filter by tag keys. ?`tag_key`=key1&`tag_key`=key2
222
255
 
223
- tag_key_value: Optional. Filter by tag key-value pairs. curl -G --data-urlencode
224
- "tag_key_value={"key": "value"}" --url
225
- "https://example.com/cloud/v1/resource/1/1"
256
+ tag_key_value: Optional. Filter by tag key-value pairs.
226
257
 
227
258
  extra_headers: Send extra headers
228
259
 
@@ -247,6 +278,7 @@ class NetworksResource(SyncAPIResource):
247
278
  query=maybe_transform(
248
279
  {
249
280
  "limit": limit,
281
+ "name": name,
250
282
  "offset": offset,
251
283
  "order_by": order_by,
252
284
  "tag_key": tag_key,
@@ -384,7 +416,7 @@ class AsyncNetworksResource(AsyncAPIResource):
384
416
  region_id: int | None = None,
385
417
  name: str,
386
418
  create_router: bool | NotGiven = NOT_GIVEN,
387
- tags: TagUpdateMapParam | NotGiven = NOT_GIVEN,
419
+ tags: Dict[str, str] | NotGiven = NOT_GIVEN,
388
420
  type: Literal["vlan", "vxlan"] | NotGiven = NOT_GIVEN,
389
421
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
390
422
  # The extra values given here take precedence over values defined on the client or passed to this method.
@@ -448,7 +480,8 @@ class AsyncNetworksResource(AsyncAPIResource):
448
480
  *,
449
481
  project_id: int | None = None,
450
482
  region_id: int | None = None,
451
- name: str,
483
+ name: str | NotGiven = NOT_GIVEN,
484
+ tags: Optional[TagUpdateMapParam] | NotGiven = NOT_GIVEN,
452
485
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
453
486
  # The extra values given here take precedence over values defined on the client or passed to this method.
454
487
  extra_headers: Headers | None = None,
@@ -456,8 +489,11 @@ class AsyncNetworksResource(AsyncAPIResource):
456
489
  extra_body: Body | None = None,
457
490
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
458
491
  ) -> Network:
459
- """
460
- Change network name
492
+ """Rename network and/or update network tags.
493
+
494
+ The request will only process the
495
+ fields that are provided in the request body. Any fields that are not included
496
+ will remain unchanged.
461
497
 
462
498
  Args:
463
499
  project_id: Project ID
@@ -468,6 +504,26 @@ class AsyncNetworksResource(AsyncAPIResource):
468
504
 
469
505
  name: Name.
470
506
 
507
+ tags: Update key-value tags using JSON Merge Patch semantics (RFC 7386). Provide
508
+ key-value pairs to add or update tags. Set tag values to `null` to remove tags.
509
+ Unspecified tags remain unchanged. Read-only tags are always preserved and
510
+ cannot be modified. **Examples:**
511
+
512
+ - **Add/update tags:**
513
+ `{'tags': {'environment': 'production', 'team': 'backend'}}` adds new tags or
514
+ updates existing ones.
515
+ - **Delete tags:** `{'tags': {'`old_tag`': null}}` removes specific tags.
516
+ - **Remove all tags:** `{'tags': null}` removes all user-managed tags (read-only
517
+ tags are preserved).
518
+ - **Partial update:** `{'tags': {'environment': 'staging'}}` only updates
519
+ specified tags.
520
+ - **Mixed operations:**
521
+ `{'tags': {'environment': 'production', '`cost_center`': 'engineering', '`deprecated_tag`': null}}`
522
+ adds/updates 'environment' and '`cost_center`' while removing
523
+ '`deprecated_tag`', preserving other existing tags.
524
+ - **Replace all:** first delete existing tags with null values, then add new
525
+ ones in the same request.
526
+
471
527
  extra_headers: Send extra headers
472
528
 
473
529
  extra_query: Add additional query parameters to the request
@@ -484,7 +540,13 @@ class AsyncNetworksResource(AsyncAPIResource):
484
540
  raise ValueError(f"Expected a non-empty value for `network_id` but received {network_id!r}")
485
541
  return await self._patch(
486
542
  f"/cloud/v1/networks/{project_id}/{region_id}/{network_id}",
487
- body=await async_maybe_transform({"name": name}, network_update_params.NetworkUpdateParams),
543
+ body=await async_maybe_transform(
544
+ {
545
+ "name": name,
546
+ "tags": tags,
547
+ },
548
+ network_update_params.NetworkUpdateParams,
549
+ ),
488
550
  options=make_request_options(
489
551
  extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
490
552
  ),
@@ -497,6 +559,7 @@ class AsyncNetworksResource(AsyncAPIResource):
497
559
  project_id: int | None = None,
498
560
  region_id: int | None = None,
499
561
  limit: int | NotGiven = NOT_GIVEN,
562
+ name: str | NotGiven = NOT_GIVEN,
500
563
  offset: int | NotGiven = NOT_GIVEN,
501
564
  order_by: Literal["created_at.asc", "created_at.desc", "name.asc", "name.desc"] | NotGiven = NOT_GIVEN,
502
565
  tag_key: List[str] | NotGiven = NOT_GIVEN,
@@ -518,17 +581,17 @@ class AsyncNetworksResource(AsyncAPIResource):
518
581
 
519
582
  limit: Optional. Limit the number of returned items
520
583
 
584
+ name: Filter networks by name
585
+
521
586
  offset: Optional. Offset value is used to exclude the first set of records from the
522
587
  result
523
588
 
524
589
  order_by: Ordering networks list result by `name`, `created_at` fields of the network and
525
590
  directions (`created_at.desc`).
526
591
 
527
- tag_key: Optional. Filter by tag keys. ?tag_key=key1&tag_key=key2
592
+ tag_key: Optional. Filter by tag keys. ?`tag_key`=key1&`tag_key`=key2
528
593
 
529
- tag_key_value: Optional. Filter by tag key-value pairs. curl -G --data-urlencode
530
- "tag_key_value={"key": "value"}" --url
531
- "https://example.com/cloud/v1/resource/1/1"
594
+ tag_key_value: Optional. Filter by tag key-value pairs.
532
595
 
533
596
  extra_headers: Send extra headers
534
597
 
@@ -553,6 +616,7 @@ class AsyncNetworksResource(AsyncAPIResource):
553
616
  query=maybe_transform(
554
617
  {
555
618
  "limit": limit,
619
+ "name": name,
556
620
  "offset": offset,
557
621
  "order_by": order_by,
558
622
  "tag_key": tag_key,
@@ -68,7 +68,7 @@ class RoutersResource(SyncAPIResource):
68
68
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
69
69
  ) -> TaskIDList:
70
70
  """
71
- Create router
71
+ Create a new router with the specified configuration.
72
72
 
73
73
  Args:
74
74
  name: name of router
@@ -125,7 +125,7 @@ class RoutersResource(SyncAPIResource):
125
125
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
126
126
  ) -> Router:
127
127
  """
128
- Update router
128
+ Update the configuration of an existing router.
129
129
 
130
130
  Args:
131
131
  external_gateway_info: New external gateway.
@@ -179,12 +179,12 @@ class RoutersResource(SyncAPIResource):
179
179
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
180
180
  ) -> SyncOffsetPage[Router]:
181
181
  """
182
- List routers
182
+ List all routers in the specified project and region.
183
183
 
184
184
  Args:
185
- limit: Limit the number of returned limit request entities.
185
+ limit: Limit the number of returned routers
186
186
 
187
- offset: Offset value is used to exclude the first set of records from the result.
187
+ offset: Offset value is used to exclude the first set of records from the result
188
188
 
189
189
  extra_headers: Send extra headers
190
190
 
@@ -231,7 +231,7 @@ class RoutersResource(SyncAPIResource):
231
231
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
232
232
  ) -> TaskIDList:
233
233
  """
234
- Delete router
234
+ Delete a specific router and all its associated resources.
235
235
 
236
236
  Args:
237
237
  extra_headers: Send extra headers
@@ -272,7 +272,7 @@ class RoutersResource(SyncAPIResource):
272
272
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
273
273
  ) -> Router:
274
274
  """
275
- Attach subnet to router
275
+ Attach a subnet to an existing router.
276
276
 
277
277
  Args:
278
278
  project_id: Project ID
@@ -330,7 +330,7 @@ class RoutersResource(SyncAPIResource):
330
330
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
331
331
  ) -> Router:
332
332
  """
333
- Detach subnet from router
333
+ Detach a subnet from an existing router.
334
334
 
335
335
  Args:
336
336
  subnet_id: Target IP is identified by it's subnet
@@ -372,7 +372,7 @@ class RoutersResource(SyncAPIResource):
372
372
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
373
373
  ) -> Router:
374
374
  """
375
- Get specific router
375
+ Get detailed information about a specific router.
376
376
 
377
377
  Args:
378
378
  extra_headers: Send extra headers
@@ -435,7 +435,7 @@ class AsyncRoutersResource(AsyncAPIResource):
435
435
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
436
436
  ) -> TaskIDList:
437
437
  """
438
- Create router
438
+ Create a new router with the specified configuration.
439
439
 
440
440
  Args:
441
441
  name: name of router
@@ -492,7 +492,7 @@ class AsyncRoutersResource(AsyncAPIResource):
492
492
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
493
493
  ) -> Router:
494
494
  """
495
- Update router
495
+ Update the configuration of an existing router.
496
496
 
497
497
  Args:
498
498
  external_gateway_info: New external gateway.
@@ -546,12 +546,12 @@ class AsyncRoutersResource(AsyncAPIResource):
546
546
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
547
547
  ) -> AsyncPaginator[Router, AsyncOffsetPage[Router]]:
548
548
  """
549
- List routers
549
+ List all routers in the specified project and region.
550
550
 
551
551
  Args:
552
- limit: Limit the number of returned limit request entities.
552
+ limit: Limit the number of returned routers
553
553
 
554
- offset: Offset value is used to exclude the first set of records from the result.
554
+ offset: Offset value is used to exclude the first set of records from the result
555
555
 
556
556
  extra_headers: Send extra headers
557
557
 
@@ -598,7 +598,7 @@ class AsyncRoutersResource(AsyncAPIResource):
598
598
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
599
599
  ) -> TaskIDList:
600
600
  """
601
- Delete router
601
+ Delete a specific router and all its associated resources.
602
602
 
603
603
  Args:
604
604
  extra_headers: Send extra headers
@@ -639,7 +639,7 @@ class AsyncRoutersResource(AsyncAPIResource):
639
639
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
640
640
  ) -> Router:
641
641
  """
642
- Attach subnet to router
642
+ Attach a subnet to an existing router.
643
643
 
644
644
  Args:
645
645
  project_id: Project ID
@@ -697,7 +697,7 @@ class AsyncRoutersResource(AsyncAPIResource):
697
697
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
698
698
  ) -> Router:
699
699
  """
700
- Detach subnet from router
700
+ Detach a subnet from an existing router.
701
701
 
702
702
  Args:
703
703
  subnet_id: Target IP is identified by it's subnet
@@ -741,7 +741,7 @@ class AsyncRoutersResource(AsyncAPIResource):
741
741
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
742
742
  ) -> Router:
743
743
  """
744
- Get specific router
744
+ Get detailed information about a specific router.
745
745
 
746
746
  Args:
747
747
  extra_headers: Send extra headers
@@ -2,7 +2,7 @@
2
2
 
3
3
  from __future__ import annotations
4
4
 
5
- from typing import List, Iterable, Optional
5
+ from typing import Dict, List, Iterable, Optional
6
6
  from typing_extensions import Literal
7
7
 
8
8
  import httpx
@@ -64,7 +64,7 @@ class SubnetsResource(SyncAPIResource):
64
64
  host_routes: Optional[Iterable[subnet_create_params.HostRoute]] | NotGiven = NOT_GIVEN,
65
65
  ip_version: IPVersion | NotGiven = NOT_GIVEN,
66
66
  router_id_to_connect: Optional[str] | NotGiven = NOT_GIVEN,
67
- tags: TagUpdateMapParam | NotGiven = NOT_GIVEN,
67
+ tags: Dict[str, str] | NotGiven = NOT_GIVEN,
68
68
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
69
69
  # The extra values given here take precedence over values defined on the client or passed to this method.
70
70
  extra_headers: Headers | None = None,
@@ -87,7 +87,7 @@ class SubnetsResource(SyncAPIResource):
87
87
  network_id: Network ID
88
88
 
89
89
  connect_to_network_router: True if the network's router should get a gateway in this subnet. Must be
90
- explicitly 'false' when gateway_ip is null.
90
+ explicitly 'false' when `gateway_ip` is null.
91
91
 
92
92
  dns_nameservers: List IP addresses of DNS servers to advertise via DHCP.
93
93
 
@@ -159,6 +159,7 @@ class SubnetsResource(SyncAPIResource):
159
159
  gateway_ip: Optional[str] | NotGiven = NOT_GIVEN,
160
160
  host_routes: Optional[Iterable[subnet_update_params.HostRoute]] | NotGiven = NOT_GIVEN,
161
161
  name: Optional[str] | NotGiven = NOT_GIVEN,
162
+ tags: Optional[TagUpdateMapParam] | NotGiven = NOT_GIVEN,
162
163
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
163
164
  # The extra values given here take precedence over values defined on the client or passed to this method.
164
165
  extra_headers: Headers | None = None,
@@ -167,7 +168,7 @@ class SubnetsResource(SyncAPIResource):
167
168
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
168
169
  ) -> Subnet:
169
170
  """
170
- Change subnet properties
171
+ Update subnet
171
172
 
172
173
  Args:
173
174
  project_id: Project ID
@@ -189,6 +190,26 @@ class SubnetsResource(SyncAPIResource):
189
190
 
190
191
  name: Name
191
192
 
193
+ tags: Update key-value tags using JSON Merge Patch semantics (RFC 7386). Provide
194
+ key-value pairs to add or update tags. Set tag values to `null` to remove tags.
195
+ Unspecified tags remain unchanged. Read-only tags are always preserved and
196
+ cannot be modified. **Examples:**
197
+
198
+ - **Add/update tags:**
199
+ `{'tags': {'environment': 'production', 'team': 'backend'}}` adds new tags or
200
+ updates existing ones.
201
+ - **Delete tags:** `{'tags': {'`old_tag`': null}}` removes specific tags.
202
+ - **Remove all tags:** `{'tags': null}` removes all user-managed tags (read-only
203
+ tags are preserved).
204
+ - **Partial update:** `{'tags': {'environment': 'staging'}}` only updates
205
+ specified tags.
206
+ - **Mixed operations:**
207
+ `{'tags': {'environment': 'production', '`cost_center`': 'engineering', '`deprecated_tag`': null}}`
208
+ adds/updates 'environment' and '`cost_center`' while removing
209
+ '`deprecated_tag`', preserving other existing tags.
210
+ - **Replace all:** first delete existing tags with null values, then add new
211
+ ones in the same request.
212
+
192
213
  extra_headers: Send extra headers
193
214
 
194
215
  extra_query: Add additional query parameters to the request
@@ -212,6 +233,7 @@ class SubnetsResource(SyncAPIResource):
212
233
  "gateway_ip": gateway_ip,
213
234
  "host_routes": host_routes,
214
235
  "name": name,
236
+ "tags": tags,
215
237
  },
216
238
  subnet_update_params.SubnetUpdateParams,
217
239
  ),
@@ -272,11 +294,9 @@ class SubnetsResource(SyncAPIResource):
272
294
  `available_ips`, `total_ips`, and `cidr` (default) fields of the subnet and
273
295
  directions (`name.asc`).
274
296
 
275
- tag_key: Optional. Filter by tag keys. ?tag_key=key1&tag_key=key2
297
+ tag_key: Optional. Filter by tag keys. ?`tag_key`=key1&`tag_key`=key2
276
298
 
277
- tag_key_value: Optional. Filter by tag key-value pairs. curl -G --data-urlencode
278
- "tag_key_value={"key": "value"}" --url
279
- "https://example.com/cloud/v1/resource/1/1"
299
+ tag_key_value: Optional. Filter by tag key-value pairs.
280
300
 
281
301
  extra_headers: Send extra headers
282
302
 
@@ -440,7 +460,7 @@ class AsyncSubnetsResource(AsyncAPIResource):
440
460
  host_routes: Optional[Iterable[subnet_create_params.HostRoute]] | NotGiven = NOT_GIVEN,
441
461
  ip_version: IPVersion | NotGiven = NOT_GIVEN,
442
462
  router_id_to_connect: Optional[str] | NotGiven = NOT_GIVEN,
443
- tags: TagUpdateMapParam | NotGiven = NOT_GIVEN,
463
+ tags: Dict[str, str] | NotGiven = NOT_GIVEN,
444
464
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
445
465
  # The extra values given here take precedence over values defined on the client or passed to this method.
446
466
  extra_headers: Headers | None = None,
@@ -463,7 +483,7 @@ class AsyncSubnetsResource(AsyncAPIResource):
463
483
  network_id: Network ID
464
484
 
465
485
  connect_to_network_router: True if the network's router should get a gateway in this subnet. Must be
466
- explicitly 'false' when gateway_ip is null.
486
+ explicitly 'false' when `gateway_ip` is null.
467
487
 
468
488
  dns_nameservers: List IP addresses of DNS servers to advertise via DHCP.
469
489
 
@@ -535,6 +555,7 @@ class AsyncSubnetsResource(AsyncAPIResource):
535
555
  gateway_ip: Optional[str] | NotGiven = NOT_GIVEN,
536
556
  host_routes: Optional[Iterable[subnet_update_params.HostRoute]] | NotGiven = NOT_GIVEN,
537
557
  name: Optional[str] | NotGiven = NOT_GIVEN,
558
+ tags: Optional[TagUpdateMapParam] | NotGiven = NOT_GIVEN,
538
559
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
539
560
  # The extra values given here take precedence over values defined on the client or passed to this method.
540
561
  extra_headers: Headers | None = None,
@@ -543,7 +564,7 @@ class AsyncSubnetsResource(AsyncAPIResource):
543
564
  timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
544
565
  ) -> Subnet:
545
566
  """
546
- Change subnet properties
567
+ Update subnet
547
568
 
548
569
  Args:
549
570
  project_id: Project ID
@@ -565,6 +586,26 @@ class AsyncSubnetsResource(AsyncAPIResource):
565
586
 
566
587
  name: Name
567
588
 
589
+ tags: Update key-value tags using JSON Merge Patch semantics (RFC 7386). Provide
590
+ key-value pairs to add or update tags. Set tag values to `null` to remove tags.
591
+ Unspecified tags remain unchanged. Read-only tags are always preserved and
592
+ cannot be modified. **Examples:**
593
+
594
+ - **Add/update tags:**
595
+ `{'tags': {'environment': 'production', 'team': 'backend'}}` adds new tags or
596
+ updates existing ones.
597
+ - **Delete tags:** `{'tags': {'`old_tag`': null}}` removes specific tags.
598
+ - **Remove all tags:** `{'tags': null}` removes all user-managed tags (read-only
599
+ tags are preserved).
600
+ - **Partial update:** `{'tags': {'environment': 'staging'}}` only updates
601
+ specified tags.
602
+ - **Mixed operations:**
603
+ `{'tags': {'environment': 'production', '`cost_center`': 'engineering', '`deprecated_tag`': null}}`
604
+ adds/updates 'environment' and '`cost_center`' while removing
605
+ '`deprecated_tag`', preserving other existing tags.
606
+ - **Replace all:** first delete existing tags with null values, then add new
607
+ ones in the same request.
608
+
568
609
  extra_headers: Send extra headers
569
610
 
570
611
  extra_query: Add additional query parameters to the request
@@ -588,6 +629,7 @@ class AsyncSubnetsResource(AsyncAPIResource):
588
629
  "gateway_ip": gateway_ip,
589
630
  "host_routes": host_routes,
590
631
  "name": name,
632
+ "tags": tags,
591
633
  },
592
634
  subnet_update_params.SubnetUpdateParams,
593
635
  ),
@@ -648,11 +690,9 @@ class AsyncSubnetsResource(AsyncAPIResource):
648
690
  `available_ips`, `total_ips`, and `cidr` (default) fields of the subnet and
649
691
  directions (`name.asc`).
650
692
 
651
- tag_key: Optional. Filter by tag keys. ?tag_key=key1&tag_key=key2
693
+ tag_key: Optional. Filter by tag keys. ?`tag_key`=key1&`tag_key`=key2
652
694
 
653
- tag_key_value: Optional. Filter by tag key-value pairs. curl -G --data-urlencode
654
- "tag_key_value={"key": "value"}" --url
655
- "https://example.com/cloud/v1/resource/1/1"
695
+ tag_key_value: Optional. Filter by tag key-value pairs.
656
696
 
657
697
  extra_headers: Send extra headers
658
698