capo-datasync 0.1.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.
Files changed (370) hide show
  1. capo_datasync/__init__.py +70 -0
  2. capo_datasync/_async.py +25 -0
  3. capo_datasync/_auth/_identity.py +16 -0
  4. capo_datasync/_auth/_providers.py +886 -0
  5. capo_datasync/_auth/_signers.py +88 -0
  6. capo_datasync/_auth/_sigv4.py +434 -0
  7. capo_datasync/_auth/_zapros_handler.py +80 -0
  8. capo_datasync/_iter.py +113 -0
  9. capo_datasync/_operations/fmrs_service/cancel_task_execution.py +147 -0
  10. capo_datasync/_operations/fmrs_service/create_agent.py +154 -0
  11. capo_datasync/_operations/fmrs_service/create_location_azure_blob.py +159 -0
  12. capo_datasync/_operations/fmrs_service/create_location_efs.py +156 -0
  13. capo_datasync/_operations/fmrs_service/create_location_fsx_lustre.py +153 -0
  14. capo_datasync/_operations/fmrs_service/create_location_fsx_ontap.py +154 -0
  15. capo_datasync/_operations/fmrs_service/create_location_fsx_open_zfs.py +154 -0
  16. capo_datasync/_operations/fmrs_service/create_location_fsx_windows.py +155 -0
  17. capo_datasync/_operations/fmrs_service/create_location_hdfs.py +158 -0
  18. capo_datasync/_operations/fmrs_service/create_location_nfs.py +156 -0
  19. capo_datasync/_operations/fmrs_service/create_location_object_storage.py +157 -0
  20. capo_datasync/_operations/fmrs_service/create_location_s3.py +157 -0
  21. capo_datasync/_operations/fmrs_service/create_location_smb.py +162 -0
  22. capo_datasync/_operations/fmrs_service/create_task.py +158 -0
  23. capo_datasync/_operations/fmrs_service/delete_agent.py +143 -0
  24. capo_datasync/_operations/fmrs_service/delete_location.py +143 -0
  25. capo_datasync/_operations/fmrs_service/delete_task.py +143 -0
  26. capo_datasync/_operations/fmrs_service/describe_agent.py +156 -0
  27. capo_datasync/_operations/fmrs_service/describe_location_azure_blob.py +159 -0
  28. capo_datasync/_operations/fmrs_service/describe_location_efs.py +154 -0
  29. capo_datasync/_operations/fmrs_service/describe_location_fsx_lustre.py +153 -0
  30. capo_datasync/_operations/fmrs_service/describe_location_fsx_ontap.py +154 -0
  31. capo_datasync/_operations/fmrs_service/describe_location_fsx_open_zfs.py +154 -0
  32. capo_datasync/_operations/fmrs_service/describe_location_fsx_windows.py +156 -0
  33. capo_datasync/_operations/fmrs_service/describe_location_hdfs.py +159 -0
  34. capo_datasync/_operations/fmrs_service/describe_location_nfs.py +154 -0
  35. capo_datasync/_operations/fmrs_service/describe_location_object_storage.py +158 -0
  36. capo_datasync/_operations/fmrs_service/describe_location_s3.py +153 -0
  37. capo_datasync/_operations/fmrs_service/describe_location_smb.py +159 -0
  38. capo_datasync/_operations/fmrs_service/describe_task.py +162 -0
  39. capo_datasync/_operations/fmrs_service/describe_task_execution.py +164 -0
  40. capo_datasync/_operations/fmrs_service/list_agents.py +152 -0
  41. capo_datasync/_operations/fmrs_service/list_locations.py +153 -0
  42. capo_datasync/_operations/fmrs_service/list_tags_for_resource.py +152 -0
  43. capo_datasync/_operations/fmrs_service/list_task_executions.py +150 -0
  44. capo_datasync/_operations/fmrs_service/list_tasks.py +149 -0
  45. capo_datasync/_operations/fmrs_service/start_task_execution.py +154 -0
  46. capo_datasync/_operations/fmrs_service/tag_resource.py +144 -0
  47. capo_datasync/_operations/fmrs_service/untag_resource.py +144 -0
  48. capo_datasync/_operations/fmrs_service/update_agent.py +143 -0
  49. capo_datasync/_operations/fmrs_service/update_location_azure_blob.py +154 -0
  50. capo_datasync/_operations/fmrs_service/update_location_efs.py +146 -0
  51. capo_datasync/_operations/fmrs_service/update_location_fsx_lustre.py +147 -0
  52. capo_datasync/_operations/fmrs_service/update_location_fsx_ontap.py +148 -0
  53. capo_datasync/_operations/fmrs_service/update_location_fsx_open_zfs.py +148 -0
  54. capo_datasync/_operations/fmrs_service/update_location_fsx_windows.py +149 -0
  55. capo_datasync/_operations/fmrs_service/update_location_hdfs.py +153 -0
  56. capo_datasync/_operations/fmrs_service/update_location_nfs.py +147 -0
  57. capo_datasync/_operations/fmrs_service/update_location_object_storage.py +152 -0
  58. capo_datasync/_operations/fmrs_service/update_location_s3.py +147 -0
  59. capo_datasync/_operations/fmrs_service/update_location_smb.py +153 -0
  60. capo_datasync/_operations/fmrs_service/update_task.py +148 -0
  61. capo_datasync/_operations/fmrs_service/update_task_execution.py +148 -0
  62. capo_datasync/_pagination.py +21 -0
  63. capo_datasync/_protocol/__init__.py +1 -0
  64. capo_datasync/_protocol/errors.py +93 -0
  65. capo_datasync/_protocol/eventstream.py +238 -0
  66. capo_datasync/_protocol/serialize.py +47 -0
  67. capo_datasync/_protocol/xml.py +33 -0
  68. capo_datasync/_rule_engine/__init__.py +0 -0
  69. capo_datasync/_rule_engine/_aws_partition.py +160 -0
  70. capo_datasync/_rule_engine/_endpoint_rule_set.py +136 -0
  71. capo_datasync/_rule_engine/_endpoint_runtime.py +389 -0
  72. capo_datasync/_services/_aws_config.py +160 -0
  73. capo_datasync/_services/_pipeline.py +198 -0
  74. capo_datasync/_services/async_data_sync.py +3793 -0
  75. capo_datasync/_services/data_sync.py +3742 -0
  76. capo_datasync/errors/__init__.py +27 -0
  77. capo_datasync/errors/_base.py +94 -0
  78. capo_datasync/errors/internal_exception.py +56 -0
  79. capo_datasync/errors/invalid_request_exception.py +61 -0
  80. capo_datasync/py.typed +0 -0
  81. capo_datasync/types/_prelude/blob.py +12 -0
  82. capo_datasync/types/_prelude/timestamp.py +17 -0
  83. capo_datasync/types/activation_key.py +5 -0
  84. capo_datasync/types/agent_arn.py +5 -0
  85. capo_datasync/types/agent_arn_list.py +17 -0
  86. capo_datasync/types/agent_list.py +29 -0
  87. capo_datasync/types/agent_list_entry.py +65 -0
  88. capo_datasync/types/agent_status.py +17 -0
  89. capo_datasync/types/agent_version.py +5 -0
  90. capo_datasync/types/atime.py +17 -0
  91. capo_datasync/types/azure_access_tier.py +18 -0
  92. capo_datasync/types/azure_blob_authentication_type.py +17 -0
  93. capo_datasync/types/azure_blob_container_url.py +5 -0
  94. capo_datasync/types/azure_blob_sas_configuration.py +31 -0
  95. capo_datasync/types/azure_blob_sas_token.py +5 -0
  96. capo_datasync/types/azure_blob_subdirectory.py +5 -0
  97. capo_datasync/types/azure_blob_type.py +14 -0
  98. capo_datasync/types/bytes_per_second.py +5 -0
  99. capo_datasync/types/cancel_task_execution_request.py +33 -0
  100. capo_datasync/types/cancel_task_execution_response.py +18 -0
  101. capo_datasync/types/cmk_secret_config.py +35 -0
  102. capo_datasync/types/create_agent_request.py +100 -0
  103. capo_datasync/types/create_agent_response.py +28 -0
  104. capo_datasync/types/create_location_azure_blob_request.py +193 -0
  105. capo_datasync/types/create_location_azure_blob_response.py +28 -0
  106. capo_datasync/types/create_location_efs_request.py +110 -0
  107. capo_datasync/types/create_location_efs_response.py +28 -0
  108. capo_datasync/types/create_location_fsx_lustre_request.py +81 -0
  109. capo_datasync/types/create_location_fsx_lustre_response.py +28 -0
  110. capo_datasync/types/create_location_fsx_ontap_request.py +98 -0
  111. capo_datasync/types/create_location_fsx_ontap_response.py +28 -0
  112. capo_datasync/types/create_location_fsx_open_zfs_request.py +97 -0
  113. capo_datasync/types/create_location_fsx_open_zfs_response.py +28 -0
  114. capo_datasync/types/create_location_fsx_windows_request.py +145 -0
  115. capo_datasync/types/create_location_fsx_windows_response.py +28 -0
  116. capo_datasync/types/create_location_hdfs_request.py +249 -0
  117. capo_datasync/types/create_location_hdfs_response.py +28 -0
  118. capo_datasync/types/create_location_nfs_request.py +91 -0
  119. capo_datasync/types/create_location_nfs_response.py +28 -0
  120. capo_datasync/types/create_location_object_storage_request.py +193 -0
  121. capo_datasync/types/create_location_object_storage_response.py +28 -0
  122. capo_datasync/types/create_location_s3_request.py +102 -0
  123. capo_datasync/types/create_location_s3_response.py +28 -0
  124. capo_datasync/types/create_location_smb_request.py +241 -0
  125. capo_datasync/types/create_location_smb_response.py +28 -0
  126. capo_datasync/types/create_task_request.py +185 -0
  127. capo_datasync/types/create_task_response.py +28 -0
  128. capo_datasync/types/custom_secret_config.py +37 -0
  129. capo_datasync/types/delete_agent_request.py +31 -0
  130. capo_datasync/types/delete_agent_response.py +18 -0
  131. capo_datasync/types/delete_location_request.py +31 -0
  132. capo_datasync/types/delete_location_response.py +18 -0
  133. capo_datasync/types/delete_task_request.py +31 -0
  134. capo_datasync/types/delete_task_response.py +18 -0
  135. capo_datasync/types/describe_agent_request.py +31 -0
  136. capo_datasync/types/describe_agent_response.py +132 -0
  137. capo_datasync/types/describe_location_azure_blob_request.py +33 -0
  138. capo_datasync/types/describe_location_azure_blob_response.py +183 -0
  139. capo_datasync/types/describe_location_efs_request.py +31 -0
  140. capo_datasync/types/describe_location_efs_response.py +103 -0
  141. capo_datasync/types/describe_location_fsx_lustre_request.py +33 -0
  142. capo_datasync/types/describe_location_fsx_lustre_response.py +71 -0
  143. capo_datasync/types/describe_location_fsx_ontap_request.py +33 -0
  144. capo_datasync/types/describe_location_fsx_ontap_response.py +103 -0
  145. capo_datasync/types/describe_location_fsx_open_zfs_request.py +33 -0
  146. capo_datasync/types/describe_location_fsx_open_zfs_response.py +86 -0
  147. capo_datasync/types/describe_location_fsx_windows_request.py +33 -0
  148. capo_datasync/types/describe_location_fsx_windows_response.py +148 -0
  149. capo_datasync/types/describe_location_hdfs_request.py +31 -0
  150. capo_datasync/types/describe_location_hdfs_response.py +230 -0
  151. capo_datasync/types/describe_location_nfs_request.py +31 -0
  152. capo_datasync/types/describe_location_nfs_response.py +85 -0
  153. capo_datasync/types/describe_location_object_storage_request.py +33 -0
  154. capo_datasync/types/describe_location_object_storage_response.py +188 -0
  155. capo_datasync/types/describe_location_s3_request.py +31 -0
  156. capo_datasync/types/describe_location_s3_response.py +98 -0
  157. capo_datasync/types/describe_location_smb_request.py +31 -0
  158. capo_datasync/types/describe_location_smb_response.py +208 -0
  159. capo_datasync/types/describe_task_execution_request.py +33 -0
  160. capo_datasync/types/describe_task_execution_response.py +435 -0
  161. capo_datasync/types/describe_task_request.py +31 -0
  162. capo_datasync/types/describe_task_response.py +288 -0
  163. capo_datasync/types/destination_network_interface_arns.py +19 -0
  164. capo_datasync/types/dns_ip_list.py +17 -0
  165. capo_datasync/types/duration.py +5 -0
  166. capo_datasync/types/ec2_config.py +53 -0
  167. capo_datasync/types/ec2_security_group_arn.py +5 -0
  168. capo_datasync/types/ec2_security_group_arn_list.py +19 -0
  169. capo_datasync/types/ec2_subnet_arn.py +5 -0
  170. capo_datasync/types/efs_access_point_arn.py +5 -0
  171. capo_datasync/types/efs_filesystem_arn.py +5 -0
  172. capo_datasync/types/efs_in_transit_encryption.py +17 -0
  173. capo_datasync/types/efs_subdirectory.py +5 -0
  174. capo_datasync/types/endpoint.py +5 -0
  175. capo_datasync/types/endpoint_type.py +19 -0
  176. capo_datasync/types/filter_attribute_value.py +5 -0
  177. capo_datasync/types/filter_list.py +29 -0
  178. capo_datasync/types/filter_rule.py +43 -0
  179. capo_datasync/types/filter_type.py +14 -0
  180. capo_datasync/types/filter_value.py +5 -0
  181. capo_datasync/types/filter_values.py +19 -0
  182. capo_datasync/types/fsx_filesystem_arn.py +5 -0
  183. capo_datasync/types/fsx_lustre_subdirectory.py +5 -0
  184. capo_datasync/types/fsx_ontap_subdirectory.py +5 -0
  185. capo_datasync/types/fsx_open_zfs_subdirectory.py +5 -0
  186. capo_datasync/types/fsx_protocol.py +51 -0
  187. capo_datasync/types/fsx_protocol_nfs.py +39 -0
  188. capo_datasync/types/fsx_protocol_smb.py +127 -0
  189. capo_datasync/types/fsx_update_protocol.py +52 -0
  190. capo_datasync/types/fsx_update_protocol_smb.py +102 -0
  191. capo_datasync/types/fsx_windows_subdirectory.py +5 -0
  192. capo_datasync/types/gid.py +19 -0
  193. capo_datasync/types/hdfs_authentication_type.py +17 -0
  194. capo_datasync/types/hdfs_block_size.py +5 -0
  195. capo_datasync/types/hdfs_data_transfer_protection.py +19 -0
  196. capo_datasync/types/hdfs_name_node.py +39 -0
  197. capo_datasync/types/hdfs_name_node_list.py +29 -0
  198. capo_datasync/types/hdfs_replication_factor.py +5 -0
  199. capo_datasync/types/hdfs_rpc_protection.py +19 -0
  200. capo_datasync/types/hdfs_server_hostname.py +5 -0
  201. capo_datasync/types/hdfs_server_port.py +5 -0
  202. capo_datasync/types/hdfs_subdirectory.py +5 -0
  203. capo_datasync/types/hdfs_user.py +5 -0
  204. capo_datasync/types/iam_role_arn.py +5 -0
  205. capo_datasync/types/iam_role_arn_or_empty_string.py +5 -0
  206. capo_datasync/types/input_tag_list.py +29 -0
  207. capo_datasync/types/item_count.py +5 -0
  208. capo_datasync/types/kerberos_keytab_file.py +15 -0
  209. capo_datasync/types/kerberos_krb5_conf_file.py +15 -0
  210. capo_datasync/types/kerberos_principal.py +5 -0
  211. capo_datasync/types/kms_key_arn.py +5 -0
  212. capo_datasync/types/kms_key_provider_uri.py +5 -0
  213. capo_datasync/types/list_agents_request.py +35 -0
  214. capo_datasync/types/list_agents_response.py +43 -0
  215. capo_datasync/types/list_locations_request.py +50 -0
  216. capo_datasync/types/list_locations_response.py +43 -0
  217. capo_datasync/types/list_tags_for_resource_request.py +45 -0
  218. capo_datasync/types/list_tags_for_resource_response.py +43 -0
  219. capo_datasync/types/list_task_executions_request.py +42 -0
  220. capo_datasync/types/list_task_executions_response.py +49 -0
  221. capo_datasync/types/list_tasks_request.py +50 -0
  222. capo_datasync/types/list_tasks_response.py +43 -0
  223. capo_datasync/types/location_arn.py +5 -0
  224. capo_datasync/types/location_filter.py +71 -0
  225. capo_datasync/types/location_filter_name.py +18 -0
  226. capo_datasync/types/location_filters.py +29 -0
  227. capo_datasync/types/location_list.py +33 -0
  228. capo_datasync/types/location_list_entry.py +35 -0
  229. capo_datasync/types/location_uri.py +5 -0
  230. capo_datasync/types/log_group_arn.py +5 -0
  231. capo_datasync/types/log_level.py +18 -0
  232. capo_datasync/types/long.py +5 -0
  233. capo_datasync/types/managed_secret_config.py +28 -0
  234. capo_datasync/types/manifest_action.py +14 -0
  235. capo_datasync/types/manifest_config.py +72 -0
  236. capo_datasync/types/manifest_format.py +14 -0
  237. capo_datasync/types/max_results.py +5 -0
  238. capo_datasync/types/mtime.py +17 -0
  239. capo_datasync/types/network_interface_arn.py +5 -0
  240. capo_datasync/types/next_token.py +5 -0
  241. capo_datasync/types/nfs_mount_options.py +36 -0
  242. capo_datasync/types/nfs_subdirectory.py +5 -0
  243. capo_datasync/types/nfs_version.py +19 -0
  244. capo_datasync/types/object_storage_access_key.py +5 -0
  245. capo_datasync/types/object_storage_bucket_name.py +5 -0
  246. capo_datasync/types/object_storage_certificate.py +15 -0
  247. capo_datasync/types/object_storage_secret_key.py +5 -0
  248. capo_datasync/types/object_storage_server_port.py +5 -0
  249. capo_datasync/types/object_storage_server_protocol.py +17 -0
  250. capo_datasync/types/object_tags.py +17 -0
  251. capo_datasync/types/object_version_ids.py +17 -0
  252. capo_datasync/types/on_prem_config.py +39 -0
  253. capo_datasync/types/operator.py +25 -0
  254. capo_datasync/types/options.py +254 -0
  255. capo_datasync/types/output_tag_list.py +29 -0
  256. capo_datasync/types/overwrite_mode.py +17 -0
  257. capo_datasync/types/phase_status.py +18 -0
  258. capo_datasync/types/pl_security_group_arn_list.py +19 -0
  259. capo_datasync/types/pl_subnet_arn_list.py +17 -0
  260. capo_datasync/types/platform.py +28 -0
  261. capo_datasync/types/posix_permissions.py +17 -0
  262. capo_datasync/types/preserve_deleted_files.py +17 -0
  263. capo_datasync/types/preserve_devices.py +17 -0
  264. capo_datasync/types/private_link_config.py +75 -0
  265. capo_datasync/types/qop_configuration.py +63 -0
  266. capo_datasync/types/report_destination.py +36 -0
  267. capo_datasync/types/report_destination_s3.py +48 -0
  268. capo_datasync/types/report_level.py +17 -0
  269. capo_datasync/types/report_output_type.py +17 -0
  270. capo_datasync/types/report_override.py +36 -0
  271. capo_datasync/types/report_overrides.py +80 -0
  272. capo_datasync/types/report_result.py +49 -0
  273. capo_datasync/types/s3_bucket_arn.py +5 -0
  274. capo_datasync/types/s3_config.py +31 -0
  275. capo_datasync/types/s3_manifest_config.py +56 -0
  276. capo_datasync/types/s3_object_version_id.py +5 -0
  277. capo_datasync/types/s3_storage_class.py +23 -0
  278. capo_datasync/types/s3_subdirectory.py +5 -0
  279. capo_datasync/types/schedule_disabled_by.py +17 -0
  280. capo_datasync/types/schedule_disabled_reason.py +5 -0
  281. capo_datasync/types/schedule_expression_cron.py +5 -0
  282. capo_datasync/types/schedule_status.py +17 -0
  283. capo_datasync/types/secret_arn.py +5 -0
  284. capo_datasync/types/server_hostname.py +5 -0
  285. capo_datasync/types/server_ip_address.py +5 -0
  286. capo_datasync/types/smb_authentication_type.py +17 -0
  287. capo_datasync/types/smb_domain.py +5 -0
  288. capo_datasync/types/smb_mount_options.py +36 -0
  289. capo_datasync/types/smb_password.py +5 -0
  290. capo_datasync/types/smb_security_descriptor_copy_flags.py +18 -0
  291. capo_datasync/types/smb_subdirectory.py +5 -0
  292. capo_datasync/types/smb_user.py +5 -0
  293. capo_datasync/types/smb_version.py +20 -0
  294. capo_datasync/types/source_manifest_config.py +39 -0
  295. capo_datasync/types/source_network_interface_arns.py +19 -0
  296. capo_datasync/types/start_task_execution_request.py +129 -0
  297. capo_datasync/types/start_task_execution_response.py +30 -0
  298. capo_datasync/types/storage_virtual_machine_arn.py +5 -0
  299. capo_datasync/types/string.py +5 -0
  300. capo_datasync/types/tag_key.py +5 -0
  301. capo_datasync/types/tag_key_list.py +17 -0
  302. capo_datasync/types/tag_list_entry.py +38 -0
  303. capo_datasync/types/tag_resource_request.py +47 -0
  304. capo_datasync/types/tag_resource_response.py +18 -0
  305. capo_datasync/types/tag_value.py +5 -0
  306. capo_datasync/types/taggable_resource_arn.py +5 -0
  307. capo_datasync/types/task_arn.py +5 -0
  308. capo_datasync/types/task_execution_arn.py +5 -0
  309. capo_datasync/types/task_execution_files_failed_detail.py +50 -0
  310. capo_datasync/types/task_execution_files_listed_detail.py +36 -0
  311. capo_datasync/types/task_execution_folders_failed_detail.py +57 -0
  312. capo_datasync/types/task_execution_folders_listed_detail.py +36 -0
  313. capo_datasync/types/task_execution_list.py +35 -0
  314. capo_datasync/types/task_execution_list_entry.py +64 -0
  315. capo_datasync/types/task_execution_result_detail.py +108 -0
  316. capo_datasync/types/task_execution_status.py +23 -0
  317. capo_datasync/types/task_filter.py +71 -0
  318. capo_datasync/types/task_filter_name.py +17 -0
  319. capo_datasync/types/task_filters.py +29 -0
  320. capo_datasync/types/task_list.py +29 -0
  321. capo_datasync/types/task_list_entry.py +65 -0
  322. capo_datasync/types/task_mode.py +17 -0
  323. capo_datasync/types/task_queueing.py +17 -0
  324. capo_datasync/types/task_report_config.py +112 -0
  325. capo_datasync/types/task_schedule.py +48 -0
  326. capo_datasync/types/task_schedule_details.py +66 -0
  327. capo_datasync/types/task_status.py +20 -0
  328. capo_datasync/types/time.py +20 -0
  329. capo_datasync/types/transfer_mode.py +17 -0
  330. capo_datasync/types/uid.py +19 -0
  331. capo_datasync/types/untag_resource_request.py +45 -0
  332. capo_datasync/types/untag_resource_response.py +18 -0
  333. capo_datasync/types/update_agent_request.py +38 -0
  334. capo_datasync/types/update_agent_response.py +18 -0
  335. capo_datasync/types/update_location_azure_blob_request.py +175 -0
  336. capo_datasync/types/update_location_azure_blob_response.py +18 -0
  337. capo_datasync/types/update_location_efs_request.py +77 -0
  338. capo_datasync/types/update_location_efs_response.py +18 -0
  339. capo_datasync/types/update_location_fsx_lustre_request.py +40 -0
  340. capo_datasync/types/update_location_fsx_lustre_response.py +18 -0
  341. capo_datasync/types/update_location_fsx_ontap_request.py +61 -0
  342. capo_datasync/types/update_location_fsx_ontap_response.py +18 -0
  343. capo_datasync/types/update_location_fsx_open_zfs_request.py +54 -0
  344. capo_datasync/types/update_location_fsx_open_zfs_response.py +18 -0
  345. capo_datasync/types/update_location_fsx_windows_request.py +105 -0
  346. capo_datasync/types/update_location_fsx_windows_response.py +18 -0
  347. capo_datasync/types/update_location_hdfs_request.py +239 -0
  348. capo_datasync/types/update_location_hdfs_response.py +18 -0
  349. capo_datasync/types/update_location_nfs_request.py +79 -0
  350. capo_datasync/types/update_location_nfs_response.py +18 -0
  351. capo_datasync/types/update_location_object_storage_request.py +173 -0
  352. capo_datasync/types/update_location_object_storage_response.py +18 -0
  353. capo_datasync/types/update_location_s3_request.py +71 -0
  354. capo_datasync/types/update_location_s3_response.py +18 -0
  355. capo_datasync/types/update_location_smb_request.py +230 -0
  356. capo_datasync/types/update_location_smb_response.py +18 -0
  357. capo_datasync/types/update_smb_domain.py +5 -0
  358. capo_datasync/types/update_task_execution_request.py +48 -0
  359. capo_datasync/types/update_task_execution_response.py +18 -0
  360. capo_datasync/types/update_task_request.py +145 -0
  361. capo_datasync/types/update_task_response.py +18 -0
  362. capo_datasync/types/updated_efs_access_point_arn.py +5 -0
  363. capo_datasync/types/updated_efs_iam_role_arn.py +5 -0
  364. capo_datasync/types/verify_mode.py +18 -0
  365. capo_datasync/types/vpc_endpoint_id.py +5 -0
  366. capo_datasync-0.1.0.dist-info/METADATA +101 -0
  367. capo_datasync-0.1.0.dist-info/RECORD +370 -0
  368. capo_datasync-0.1.0.dist-info/WHEEL +5 -0
  369. capo_datasync-0.1.0.dist-info/licenses/LICENSE +21 -0
  370. capo_datasync-0.1.0.dist-info/top_level.txt +1 -0
capo_datasync/_iter.py ADDED
@@ -0,0 +1,113 @@
1
+ """Iterator helpers used by generated streaming operations.
2
+
3
+ Hand-written, not regenerated.
4
+ """
5
+
6
+ from __future__ import annotations
7
+
8
+ from collections.abc import AsyncIterable, AsyncIterator, Callable, Iterable, Iterator
9
+ from typing import Generic, TypeVar, cast
10
+
11
+ T = TypeVar("T")
12
+ U = TypeVar("U")
13
+
14
+
15
+ class AnyIterator(AsyncIterator[T], Iterator[T], Generic[T]):
16
+ """A type that is both a synchronous and asynchronous iterator.
17
+
18
+ Streaming output fields use this so the same TypedDict type works for
19
+ both sync and async operation variants.
20
+ """
21
+
22
+ ...
23
+
24
+
25
+ class StaticAnyIterator(AnyIterator[T], Generic[T]):
26
+ """An :class:`AnyIterator` backed by static, in-memory content.
27
+
28
+ Used when streaming output is produced from already-materialized bytes
29
+ rather than a live stream. The ``content`` is yielded once and remains
30
+ accessible as a public attribute.
31
+ """
32
+
33
+ def __init__(self, content: T) -> None:
34
+ self.content = content
35
+ self._consumed = False
36
+
37
+ def __next__(self) -> T:
38
+ if self._consumed:
39
+ raise StopIteration
40
+ self._consumed = True
41
+ return self.content
42
+
43
+ async def __anext__(self) -> T:
44
+ if self._consumed:
45
+ raise StopAsyncIteration
46
+ self._consumed = True
47
+ return self.content
48
+
49
+
50
+ def map_sync_iterator(iterable: Iterable[T], fn: Callable[[T], U]) -> Iterator[U]:
51
+ """Map ``fn`` over a synchronous iterable, yielding results lazily."""
52
+ for item in iterable:
53
+ yield fn(item)
54
+
55
+
56
+ async def map_async_iterator(
57
+ async_iterable: AsyncIterable[T], fn: Callable[[T], U]
58
+ ) -> AsyncIterator[U]:
59
+ """Map ``fn`` over an asynchronous iterable, yielding results lazily."""
60
+ async for item in async_iterable:
61
+ yield fn(item)
62
+
63
+
64
+ def chain_sync_iterator(*iterables: Iterable[T]) -> Iterator[T]:
65
+ """Yield items from each iterable in order."""
66
+ for iterable in iterables:
67
+ yield from iterable
68
+
69
+
70
+ async def chain_async_iterator(
71
+ prefix: Iterable[T], rest: AsyncIterable[T]
72
+ ) -> AsyncIterator[T]:
73
+ """Yield the synchronous ``prefix`` items, then the async ``rest`` items."""
74
+ for item in prefix:
75
+ yield item
76
+ async for item in rest:
77
+ yield item
78
+
79
+
80
+ def ensure_async_iterator(value: AsyncIterator[T] | T) -> AnyIterator[T]:
81
+ """Return ``value`` as an :class:`AnyIterator`.
82
+
83
+ An async iterator is returned unchanged; a single value is wrapped in a
84
+ fresh single-item async iterator.
85
+ """
86
+ if isinstance(value, AsyncIterator):
87
+ return cast(AnyIterator[T], value)
88
+
89
+ return StaticAnyIterator(value)
90
+
91
+
92
+ def ensure_sync_iterator(value: Iterator[T] | T) -> AnyIterator[T]:
93
+ """Return ``value`` as an :class:`AnyIterator`.
94
+
95
+ A sync iterator is returned unchanged; a single value is wrapped in a
96
+ fresh single-item sync iterator.
97
+ """
98
+ if isinstance(value, Iterator):
99
+ return cast(AnyIterator[T], value)
100
+
101
+ return StaticAnyIterator(value)
102
+
103
+
104
+ __all__ = [
105
+ "AnyIterator",
106
+ "StaticAnyIterator",
107
+ "chain_async_iterator",
108
+ "chain_sync_iterator",
109
+ "ensure_async_iterator",
110
+ "ensure_sync_iterator",
111
+ "map_async_iterator",
112
+ "map_sync_iterator",
113
+ ]
@@ -0,0 +1,147 @@
1
+ """Generated from Smithy shape ``com.amazonaws.datasync#CancelTaskExecution``."""
2
+
3
+ from __future__ import annotations
4
+
5
+ import json
6
+ from typing import Any
7
+
8
+ import zapros
9
+ from typing_extensions import Never
10
+
11
+ import capo_datasync._auth._signers
12
+ import capo_datasync._auth._sigv4
13
+ import capo_datasync._protocol.eventstream
14
+ import capo_datasync.errors.internal_exception
15
+ import capo_datasync.errors.invalid_request_exception
16
+ import capo_datasync.types.cancel_task_execution_request
17
+ import capo_datasync.types.cancel_task_execution_response
18
+ from capo_datasync._protocol.errors import parse_error_metadata_json
19
+ from capo_datasync._rule_engine._endpoint_rule_set import EndpointParams, resolve
20
+ from capo_datasync._services._pipeline import AsyncOperationOptions, OperationOptions
21
+ from capo_datasync.errors import UnknownServiceError
22
+
23
+
24
+ def handle_error(response: zapros.Response) -> Never:
25
+ data = json.loads(response.read())
26
+ code, message = parse_error_metadata_json(response, data)
27
+ match code:
28
+ case "InternalException":
29
+ raise capo_datasync.errors.internal_exception.InternalException.from_aws_json_1_1(
30
+ data, message
31
+ )
32
+ case "InvalidRequestException":
33
+ raise capo_datasync.errors.invalid_request_exception.InvalidRequestException.from_aws_json_1_1(
34
+ data, message
35
+ )
36
+ case _:
37
+ raise UnknownServiceError(code=code, message=message, response=response)
38
+
39
+
40
+ def handle_response(
41
+ response: zapros.Response,
42
+ ) -> capo_datasync.types.cancel_task_execution_response.CancelTaskExecutionResponse:
43
+ out: capo_datasync.types.cancel_task_execution_response.CancelTaskExecutionResponse = {} # type: ignore[typeddict-item]
44
+ return out
45
+
46
+
47
+ async def async_handle_response(
48
+ response: zapros.Response,
49
+ ) -> capo_datasync.types.cancel_task_execution_response.CancelTaskExecutionResponse:
50
+ out: capo_datasync.types.cancel_task_execution_response.CancelTaskExecutionResponse = {} # type: ignore[typeddict-item]
51
+ return out
52
+
53
+
54
+ def get_signer(
55
+ options: AsyncOperationOptions | OperationOptions,
56
+ auth_schemes: list[dict[str, Any]] | None = None,
57
+ ) -> capo_datasync._auth._signers.Signer | None:
58
+ name_to_schema = {s["name"]: s for s in (auth_schemes or [])} # noqa: F841
59
+ if (
60
+ options.credentials_provider is not None
61
+ and name_to_schema
62
+ and not name_to_schema.keys() & {"sigv4", "sigv4-s3express"}
63
+ ):
64
+ raise RuntimeError(
65
+ "Endpoint requires an unsupported auth scheme: " + ", ".join(name_to_schema)
66
+ )
67
+ if options.credentials_provider is not None:
68
+ endpoint_scheme = name_to_schema.get("sigv4") or name_to_schema.get(
69
+ "sigv4-s3express"
70
+ )
71
+ if endpoint_scheme is not None or not name_to_schema:
72
+ sigv4_config = capo_datasync._auth._sigv4.build_sigv4_auth_scheme(
73
+ "datasync", options.region, endpoint_scheme
74
+ )
75
+ if sigv4_config is not None:
76
+ return capo_datasync._auth._signers.SigV4Signer(
77
+ options.credentials_provider, auth_scheme=sigv4_config
78
+ )
79
+ raise RuntimeError("Auth was not resolved")
80
+
81
+
82
+ def build_request(
83
+ options: OperationOptions | AsyncOperationOptions,
84
+ input_: capo_datasync.types.cancel_task_execution_request.CancelTaskExecutionRequest,
85
+ ) -> zapros.Request:
86
+ endpoint = resolve(
87
+ EndpointParams(
88
+ Region=options.region,
89
+ UseDualStack=options.use_dual_stack,
90
+ UseFIPS=options.use_fips,
91
+ Endpoint=options.endpoint,
92
+ )
93
+ ) # noqa: F841
94
+ url = endpoint.url.rstrip("/") + ""
95
+ params: list[tuple[str, str]] = []
96
+ headers: dict[str, str] = {k: ", ".join(v) for k, v in endpoint.headers.items()}
97
+ headers["X-Amz-Target"] = "FmrsService.CancelTaskExecution"
98
+ body: bytes | None = json.dumps(
99
+ capo_datasync.types.cancel_task_execution_request.serialize_aws_json_1_1(
100
+ input_
101
+ ),
102
+ allow_nan=False,
103
+ ).encode()
104
+ headers["content-type"] = "application/x-amz-json-1.1"
105
+ signer = get_signer(options, auth_schemes=endpoint.properties.get("authSchemes"))
106
+ normalized_url = zapros.URL(url)
107
+ for k, v in params:
108
+ normalized_url.search_params.append(k, v)
109
+ return zapros.Request(
110
+ normalized_url, "POST", headers=headers, body=body, context={"signer": signer}
111
+ )
112
+
113
+
114
+ def cancel_task_execution(
115
+ options: OperationOptions,
116
+ input_: capo_datasync.types.cancel_task_execution_request.CancelTaskExecutionRequest,
117
+ ) -> tuple[
118
+ capo_datasync.types.cancel_task_execution_response.CancelTaskExecutionResponse,
119
+ zapros.Response,
120
+ ]:
121
+ response = options.client.handler.handle(build_request(options, input_))
122
+ try:
123
+ if response.status >= 300:
124
+ response.read()
125
+ handle_error(response)
126
+ return handle_response(response), response
127
+ except BaseException:
128
+ response.close()
129
+ raise
130
+
131
+
132
+ async def async_cancel_task_execution(
133
+ options: AsyncOperationOptions,
134
+ input_: capo_datasync.types.cancel_task_execution_request.CancelTaskExecutionRequest,
135
+ ) -> tuple[
136
+ capo_datasync.types.cancel_task_execution_response.CancelTaskExecutionResponse,
137
+ zapros.Response,
138
+ ]:
139
+ response = await options.client.handler.ahandle(build_request(options, input_))
140
+ try:
141
+ if response.status >= 300:
142
+ await response.aread()
143
+ handle_error(response)
144
+ return await async_handle_response(response), response
145
+ except BaseException:
146
+ await response.aclose()
147
+ raise
@@ -0,0 +1,154 @@
1
+ """Generated from Smithy shape ``com.amazonaws.datasync#CreateAgent``."""
2
+
3
+ from __future__ import annotations
4
+
5
+ import json
6
+ from typing import Any
7
+
8
+ import zapros
9
+ from typing_extensions import Never
10
+
11
+ import capo_datasync._auth._signers
12
+ import capo_datasync._auth._sigv4
13
+ import capo_datasync._protocol.eventstream
14
+ import capo_datasync.errors.internal_exception
15
+ import capo_datasync.errors.invalid_request_exception
16
+ import capo_datasync.types.create_agent_request
17
+ import capo_datasync.types.create_agent_response
18
+ import capo_datasync.types.input_tag_list
19
+ import capo_datasync.types.pl_security_group_arn_list
20
+ import capo_datasync.types.pl_subnet_arn_list
21
+ from capo_datasync._protocol.errors import parse_error_metadata_json
22
+ from capo_datasync._rule_engine._endpoint_rule_set import EndpointParams, resolve
23
+ from capo_datasync._services._pipeline import AsyncOperationOptions, OperationOptions
24
+ from capo_datasync.errors import UnknownServiceError
25
+
26
+
27
+ def handle_error(response: zapros.Response) -> Never:
28
+ data = json.loads(response.read())
29
+ code, message = parse_error_metadata_json(response, data)
30
+ match code:
31
+ case "InternalException":
32
+ raise capo_datasync.errors.internal_exception.InternalException.from_aws_json_1_1(
33
+ data, message
34
+ )
35
+ case "InvalidRequestException":
36
+ raise capo_datasync.errors.invalid_request_exception.InvalidRequestException.from_aws_json_1_1(
37
+ data, message
38
+ )
39
+ case _:
40
+ raise UnknownServiceError(code=code, message=message, response=response)
41
+
42
+
43
+ def handle_response(
44
+ response: zapros.Response,
45
+ ) -> capo_datasync.types.create_agent_response.CreateAgentResponse:
46
+ out: capo_datasync.types.create_agent_response.CreateAgentResponse = (
47
+ capo_datasync.types.create_agent_response.deserialize_aws_json_1_1(
48
+ json.loads(response.read())
49
+ )
50
+ )
51
+ return out
52
+
53
+
54
+ async def async_handle_response(
55
+ response: zapros.Response,
56
+ ) -> capo_datasync.types.create_agent_response.CreateAgentResponse:
57
+ out: capo_datasync.types.create_agent_response.CreateAgentResponse = (
58
+ capo_datasync.types.create_agent_response.deserialize_aws_json_1_1(
59
+ json.loads(await response.aread())
60
+ )
61
+ )
62
+ return out
63
+
64
+
65
+ def get_signer(
66
+ options: AsyncOperationOptions | OperationOptions,
67
+ auth_schemes: list[dict[str, Any]] | None = None,
68
+ ) -> capo_datasync._auth._signers.Signer | None:
69
+ name_to_schema = {s["name"]: s for s in (auth_schemes or [])} # noqa: F841
70
+ if (
71
+ options.credentials_provider is not None
72
+ and name_to_schema
73
+ and not name_to_schema.keys() & {"sigv4", "sigv4-s3express"}
74
+ ):
75
+ raise RuntimeError(
76
+ "Endpoint requires an unsupported auth scheme: " + ", ".join(name_to_schema)
77
+ )
78
+ if options.credentials_provider is not None:
79
+ endpoint_scheme = name_to_schema.get("sigv4") or name_to_schema.get(
80
+ "sigv4-s3express"
81
+ )
82
+ if endpoint_scheme is not None or not name_to_schema:
83
+ sigv4_config = capo_datasync._auth._sigv4.build_sigv4_auth_scheme(
84
+ "datasync", options.region, endpoint_scheme
85
+ )
86
+ if sigv4_config is not None:
87
+ return capo_datasync._auth._signers.SigV4Signer(
88
+ options.credentials_provider, auth_scheme=sigv4_config
89
+ )
90
+ raise RuntimeError("Auth was not resolved")
91
+
92
+
93
+ def build_request(
94
+ options: OperationOptions | AsyncOperationOptions,
95
+ input_: capo_datasync.types.create_agent_request.CreateAgentRequest,
96
+ ) -> zapros.Request:
97
+ endpoint = resolve(
98
+ EndpointParams(
99
+ Region=options.region,
100
+ UseDualStack=options.use_dual_stack,
101
+ UseFIPS=options.use_fips,
102
+ Endpoint=options.endpoint,
103
+ )
104
+ ) # noqa: F841
105
+ url = endpoint.url.rstrip("/") + ""
106
+ params: list[tuple[str, str]] = []
107
+ headers: dict[str, str] = {k: ", ".join(v) for k, v in endpoint.headers.items()}
108
+ headers["X-Amz-Target"] = "FmrsService.CreateAgent"
109
+ body: bytes | None = json.dumps(
110
+ capo_datasync.types.create_agent_request.serialize_aws_json_1_1(input_),
111
+ allow_nan=False,
112
+ ).encode()
113
+ headers["content-type"] = "application/x-amz-json-1.1"
114
+ signer = get_signer(options, auth_schemes=endpoint.properties.get("authSchemes"))
115
+ normalized_url = zapros.URL(url)
116
+ for k, v in params:
117
+ normalized_url.search_params.append(k, v)
118
+ return zapros.Request(
119
+ normalized_url, "POST", headers=headers, body=body, context={"signer": signer}
120
+ )
121
+
122
+
123
+ def create_agent(
124
+ options: OperationOptions,
125
+ input_: capo_datasync.types.create_agent_request.CreateAgentRequest,
126
+ ) -> tuple[
127
+ capo_datasync.types.create_agent_response.CreateAgentResponse, zapros.Response
128
+ ]:
129
+ response = options.client.handler.handle(build_request(options, input_))
130
+ try:
131
+ if response.status >= 300:
132
+ response.read()
133
+ handle_error(response)
134
+ return handle_response(response), response
135
+ except BaseException:
136
+ response.close()
137
+ raise
138
+
139
+
140
+ async def async_create_agent(
141
+ options: AsyncOperationOptions,
142
+ input_: capo_datasync.types.create_agent_request.CreateAgentRequest,
143
+ ) -> tuple[
144
+ capo_datasync.types.create_agent_response.CreateAgentResponse, zapros.Response
145
+ ]:
146
+ response = await options.client.handler.ahandle(build_request(options, input_))
147
+ try:
148
+ if response.status >= 300:
149
+ await response.aread()
150
+ handle_error(response)
151
+ return await async_handle_response(response), response
152
+ except BaseException:
153
+ await response.aclose()
154
+ raise
@@ -0,0 +1,159 @@
1
+ """Generated from Smithy shape ``com.amazonaws.datasync#CreateLocationAzureBlob``."""
2
+
3
+ from __future__ import annotations
4
+
5
+ import json
6
+ from typing import Any
7
+
8
+ import zapros
9
+ from typing_extensions import Never
10
+
11
+ import capo_datasync._auth._signers
12
+ import capo_datasync._auth._sigv4
13
+ import capo_datasync._protocol.eventstream
14
+ import capo_datasync.errors.internal_exception
15
+ import capo_datasync.errors.invalid_request_exception
16
+ import capo_datasync.types.agent_arn_list
17
+ import capo_datasync.types.azure_access_tier
18
+ import capo_datasync.types.azure_blob_authentication_type
19
+ import capo_datasync.types.azure_blob_sas_configuration
20
+ import capo_datasync.types.azure_blob_type
21
+ import capo_datasync.types.cmk_secret_config
22
+ import capo_datasync.types.create_location_azure_blob_request
23
+ import capo_datasync.types.create_location_azure_blob_response
24
+ import capo_datasync.types.custom_secret_config
25
+ import capo_datasync.types.input_tag_list
26
+ from capo_datasync._protocol.errors import parse_error_metadata_json
27
+ from capo_datasync._rule_engine._endpoint_rule_set import EndpointParams, resolve
28
+ from capo_datasync._services._pipeline import AsyncOperationOptions, OperationOptions
29
+ from capo_datasync.errors import UnknownServiceError
30
+
31
+
32
+ def handle_error(response: zapros.Response) -> Never:
33
+ data = json.loads(response.read())
34
+ code, message = parse_error_metadata_json(response, data)
35
+ match code:
36
+ case "InternalException":
37
+ raise capo_datasync.errors.internal_exception.InternalException.from_aws_json_1_1(
38
+ data, message
39
+ )
40
+ case "InvalidRequestException":
41
+ raise capo_datasync.errors.invalid_request_exception.InvalidRequestException.from_aws_json_1_1(
42
+ data, message
43
+ )
44
+ case _:
45
+ raise UnknownServiceError(code=code, message=message, response=response)
46
+
47
+
48
+ def handle_response(
49
+ response: zapros.Response,
50
+ ) -> capo_datasync.types.create_location_azure_blob_response.CreateLocationAzureBlobResponse:
51
+ out: capo_datasync.types.create_location_azure_blob_response.CreateLocationAzureBlobResponse = capo_datasync.types.create_location_azure_blob_response.deserialize_aws_json_1_1(
52
+ json.loads(response.read())
53
+ )
54
+ return out
55
+
56
+
57
+ async def async_handle_response(
58
+ response: zapros.Response,
59
+ ) -> capo_datasync.types.create_location_azure_blob_response.CreateLocationAzureBlobResponse:
60
+ out: capo_datasync.types.create_location_azure_blob_response.CreateLocationAzureBlobResponse = capo_datasync.types.create_location_azure_blob_response.deserialize_aws_json_1_1(
61
+ json.loads(await response.aread())
62
+ )
63
+ return out
64
+
65
+
66
+ def get_signer(
67
+ options: AsyncOperationOptions | OperationOptions,
68
+ auth_schemes: list[dict[str, Any]] | None = None,
69
+ ) -> capo_datasync._auth._signers.Signer | None:
70
+ name_to_schema = {s["name"]: s for s in (auth_schemes or [])} # noqa: F841
71
+ if (
72
+ options.credentials_provider is not None
73
+ and name_to_schema
74
+ and not name_to_schema.keys() & {"sigv4", "sigv4-s3express"}
75
+ ):
76
+ raise RuntimeError(
77
+ "Endpoint requires an unsupported auth scheme: " + ", ".join(name_to_schema)
78
+ )
79
+ if options.credentials_provider is not None:
80
+ endpoint_scheme = name_to_schema.get("sigv4") or name_to_schema.get(
81
+ "sigv4-s3express"
82
+ )
83
+ if endpoint_scheme is not None or not name_to_schema:
84
+ sigv4_config = capo_datasync._auth._sigv4.build_sigv4_auth_scheme(
85
+ "datasync", options.region, endpoint_scheme
86
+ )
87
+ if sigv4_config is not None:
88
+ return capo_datasync._auth._signers.SigV4Signer(
89
+ options.credentials_provider, auth_scheme=sigv4_config
90
+ )
91
+ raise RuntimeError("Auth was not resolved")
92
+
93
+
94
+ def build_request(
95
+ options: OperationOptions | AsyncOperationOptions,
96
+ input_: capo_datasync.types.create_location_azure_blob_request.CreateLocationAzureBlobRequest,
97
+ ) -> zapros.Request:
98
+ endpoint = resolve(
99
+ EndpointParams(
100
+ Region=options.region,
101
+ UseDualStack=options.use_dual_stack,
102
+ UseFIPS=options.use_fips,
103
+ Endpoint=options.endpoint,
104
+ )
105
+ ) # noqa: F841
106
+ url = endpoint.url.rstrip("/") + ""
107
+ params: list[tuple[str, str]] = []
108
+ headers: dict[str, str] = {k: ", ".join(v) for k, v in endpoint.headers.items()}
109
+ headers["X-Amz-Target"] = "FmrsService.CreateLocationAzureBlob"
110
+ body: bytes | None = json.dumps(
111
+ capo_datasync.types.create_location_azure_blob_request.serialize_aws_json_1_1(
112
+ input_
113
+ ),
114
+ allow_nan=False,
115
+ ).encode()
116
+ headers["content-type"] = "application/x-amz-json-1.1"
117
+ signer = get_signer(options, auth_schemes=endpoint.properties.get("authSchemes"))
118
+ normalized_url = zapros.URL(url)
119
+ for k, v in params:
120
+ normalized_url.search_params.append(k, v)
121
+ return zapros.Request(
122
+ normalized_url, "POST", headers=headers, body=body, context={"signer": signer}
123
+ )
124
+
125
+
126
+ def create_location_azure_blob(
127
+ options: OperationOptions,
128
+ input_: capo_datasync.types.create_location_azure_blob_request.CreateLocationAzureBlobRequest,
129
+ ) -> tuple[
130
+ capo_datasync.types.create_location_azure_blob_response.CreateLocationAzureBlobResponse,
131
+ zapros.Response,
132
+ ]:
133
+ response = options.client.handler.handle(build_request(options, input_))
134
+ try:
135
+ if response.status >= 300:
136
+ response.read()
137
+ handle_error(response)
138
+ return handle_response(response), response
139
+ except BaseException:
140
+ response.close()
141
+ raise
142
+
143
+
144
+ async def async_create_location_azure_blob(
145
+ options: AsyncOperationOptions,
146
+ input_: capo_datasync.types.create_location_azure_blob_request.CreateLocationAzureBlobRequest,
147
+ ) -> tuple[
148
+ capo_datasync.types.create_location_azure_blob_response.CreateLocationAzureBlobResponse,
149
+ zapros.Response,
150
+ ]:
151
+ response = await options.client.handler.ahandle(build_request(options, input_))
152
+ try:
153
+ if response.status >= 300:
154
+ await response.aread()
155
+ handle_error(response)
156
+ return await async_handle_response(response), response
157
+ except BaseException:
158
+ await response.aclose()
159
+ raise