aws-sdk-s3 1.48.0 → 1.169.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (134) hide show
  1. checksums.yaml +5 -5
  2. data/CHANGELOG.md +1270 -0
  3. data/LICENSE.txt +202 -0
  4. data/VERSION +1 -0
  5. data/lib/aws-sdk-s3/access_grants_credentials.rb +57 -0
  6. data/lib/aws-sdk-s3/access_grants_credentials_provider.rb +250 -0
  7. data/lib/aws-sdk-s3/bucket.rb +959 -106
  8. data/lib/aws-sdk-s3/bucket_acl.rb +64 -18
  9. data/lib/aws-sdk-s3/bucket_cors.rb +79 -18
  10. data/lib/aws-sdk-s3/bucket_lifecycle.rb +66 -20
  11. data/lib/aws-sdk-s3/bucket_lifecycle_configuration.rb +106 -21
  12. data/lib/aws-sdk-s3/bucket_logging.rb +68 -16
  13. data/lib/aws-sdk-s3/bucket_notification.rb +52 -20
  14. data/lib/aws-sdk-s3/bucket_policy.rb +107 -17
  15. data/lib/aws-sdk-s3/bucket_region_cache.rb +11 -5
  16. data/lib/aws-sdk-s3/bucket_request_payment.rb +60 -15
  17. data/lib/aws-sdk-s3/bucket_tagging.rb +71 -18
  18. data/lib/aws-sdk-s3/bucket_versioning.rb +133 -17
  19. data/lib/aws-sdk-s3/bucket_website.rb +78 -21
  20. data/lib/aws-sdk-s3/client.rb +13765 -1019
  21. data/lib/aws-sdk-s3/client_api.rb +1137 -197
  22. data/lib/aws-sdk-s3/customizations/bucket.rb +56 -37
  23. data/lib/aws-sdk-s3/customizations/errors.rb +40 -0
  24. data/lib/aws-sdk-s3/customizations/multipart_upload.rb +2 -0
  25. data/lib/aws-sdk-s3/customizations/object.rb +288 -68
  26. data/lib/aws-sdk-s3/customizations/object_summary.rb +10 -0
  27. data/lib/aws-sdk-s3/customizations/object_version.rb +13 -0
  28. data/lib/aws-sdk-s3/customizations/types/list_object_versions_output.rb +2 -0
  29. data/lib/aws-sdk-s3/customizations/types/permanent_redirect.rb +26 -0
  30. data/lib/aws-sdk-s3/customizations.rb +27 -28
  31. data/lib/aws-sdk-s3/encryption/client.rb +28 -7
  32. data/lib/aws-sdk-s3/encryption/decrypt_handler.rb +71 -29
  33. data/lib/aws-sdk-s3/encryption/default_cipher_provider.rb +43 -5
  34. data/lib/aws-sdk-s3/encryption/default_key_provider.rb +2 -0
  35. data/lib/aws-sdk-s3/encryption/encrypt_handler.rb +13 -2
  36. data/lib/aws-sdk-s3/encryption/errors.rb +2 -0
  37. data/lib/aws-sdk-s3/encryption/io_auth_decrypter.rb +2 -0
  38. data/lib/aws-sdk-s3/encryption/io_decrypter.rb +11 -3
  39. data/lib/aws-sdk-s3/encryption/io_encrypter.rb +2 -0
  40. data/lib/aws-sdk-s3/encryption/key_provider.rb +2 -0
  41. data/lib/aws-sdk-s3/encryption/kms_cipher_provider.rb +46 -11
  42. data/lib/aws-sdk-s3/encryption/materials.rb +8 -6
  43. data/lib/aws-sdk-s3/encryption/utils.rb +25 -0
  44. data/lib/aws-sdk-s3/encryption.rb +4 -0
  45. data/lib/aws-sdk-s3/encryptionV2/client.rb +570 -0
  46. data/lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb +223 -0
  47. data/lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb +170 -0
  48. data/lib/aws-sdk-s3/encryptionV2/default_key_provider.rb +40 -0
  49. data/lib/aws-sdk-s3/encryptionV2/encrypt_handler.rb +65 -0
  50. data/lib/aws-sdk-s3/encryptionV2/errors.rb +37 -0
  51. data/lib/aws-sdk-s3/encryptionV2/io_auth_decrypter.rb +58 -0
  52. data/lib/aws-sdk-s3/encryptionV2/io_decrypter.rb +37 -0
  53. data/lib/aws-sdk-s3/encryptionV2/io_encrypter.rb +73 -0
  54. data/lib/aws-sdk-s3/encryptionV2/key_provider.rb +31 -0
  55. data/lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb +173 -0
  56. data/lib/aws-sdk-s3/encryptionV2/materials.rb +60 -0
  57. data/lib/aws-sdk-s3/encryptionV2/utils.rb +103 -0
  58. data/lib/aws-sdk-s3/encryption_v2.rb +23 -0
  59. data/lib/aws-sdk-s3/endpoint_parameters.rb +181 -0
  60. data/lib/aws-sdk-s3/endpoint_provider.rb +592 -0
  61. data/lib/aws-sdk-s3/endpoints.rb +1392 -0
  62. data/lib/aws-sdk-s3/errors.rb +126 -1
  63. data/lib/aws-sdk-s3/event_streams.rb +8 -1
  64. data/lib/aws-sdk-s3/express_credentials.rb +55 -0
  65. data/lib/aws-sdk-s3/express_credentials_provider.rb +59 -0
  66. data/lib/aws-sdk-s3/file_downloader.rb +176 -44
  67. data/lib/aws-sdk-s3/file_part.rb +11 -6
  68. data/lib/aws-sdk-s3/file_uploader.rb +39 -18
  69. data/lib/aws-sdk-s3/legacy_signer.rb +17 -25
  70. data/lib/aws-sdk-s3/multipart_file_uploader.rb +82 -23
  71. data/lib/aws-sdk-s3/multipart_stream_uploader.rb +61 -21
  72. data/lib/aws-sdk-s3/multipart_upload.rb +265 -32
  73. data/lib/aws-sdk-s3/multipart_upload_error.rb +2 -0
  74. data/lib/aws-sdk-s3/multipart_upload_part.rb +367 -45
  75. data/lib/aws-sdk-s3/object.rb +2475 -228
  76. data/lib/aws-sdk-s3/object_acl.rb +103 -25
  77. data/lib/aws-sdk-s3/object_copier.rb +9 -5
  78. data/lib/aws-sdk-s3/object_multipart_copier.rb +48 -22
  79. data/lib/aws-sdk-s3/object_summary.rb +2075 -203
  80. data/lib/aws-sdk-s3/object_version.rb +492 -80
  81. data/lib/aws-sdk-s3/plugins/accelerate.rb +17 -64
  82. data/lib/aws-sdk-s3/plugins/access_grants.rb +178 -0
  83. data/lib/aws-sdk-s3/plugins/arn.rb +70 -0
  84. data/lib/aws-sdk-s3/plugins/bucket_dns.rb +7 -43
  85. data/lib/aws-sdk-s3/plugins/bucket_name_restrictions.rb +20 -3
  86. data/lib/aws-sdk-s3/plugins/dualstack.rb +7 -50
  87. data/lib/aws-sdk-s3/plugins/endpoints.rb +86 -0
  88. data/lib/aws-sdk-s3/plugins/expect_100_continue.rb +5 -4
  89. data/lib/aws-sdk-s3/plugins/express_session_auth.rb +97 -0
  90. data/lib/aws-sdk-s3/plugins/get_bucket_location_fix.rb +3 -1
  91. data/lib/aws-sdk-s3/plugins/http_200_errors.rb +60 -15
  92. data/lib/aws-sdk-s3/plugins/iad_regional_endpoint.rb +44 -0
  93. data/lib/aws-sdk-s3/plugins/location_constraint.rb +5 -1
  94. data/lib/aws-sdk-s3/plugins/md5s.rb +35 -30
  95. data/lib/aws-sdk-s3/plugins/redirects.rb +2 -0
  96. data/lib/aws-sdk-s3/plugins/s3_host_id.rb +2 -0
  97. data/lib/aws-sdk-s3/plugins/s3_signer.rb +63 -94
  98. data/lib/aws-sdk-s3/plugins/skip_whole_multipart_get_checksums.rb +31 -0
  99. data/lib/aws-sdk-s3/plugins/sse_cpk.rb +3 -1
  100. data/lib/aws-sdk-s3/plugins/streaming_retry.rb +139 -0
  101. data/lib/aws-sdk-s3/plugins/url_encoded_keys.rb +2 -0
  102. data/lib/aws-sdk-s3/presigned_post.rb +160 -99
  103. data/lib/aws-sdk-s3/presigner.rb +138 -59
  104. data/lib/aws-sdk-s3/resource.rb +155 -17
  105. data/lib/aws-sdk-s3/types.rb +12229 -4377
  106. data/lib/aws-sdk-s3/waiters.rb +67 -1
  107. data/lib/aws-sdk-s3.rb +46 -32
  108. data/sig/bucket.rbs +216 -0
  109. data/sig/bucket_acl.rbs +78 -0
  110. data/sig/bucket_cors.rbs +69 -0
  111. data/sig/bucket_lifecycle.rbs +88 -0
  112. data/sig/bucket_lifecycle_configuration.rbs +115 -0
  113. data/sig/bucket_logging.rbs +76 -0
  114. data/sig/bucket_notification.rbs +114 -0
  115. data/sig/bucket_policy.rbs +59 -0
  116. data/sig/bucket_request_payment.rbs +54 -0
  117. data/sig/bucket_tagging.rbs +65 -0
  118. data/sig/bucket_versioning.rbs +77 -0
  119. data/sig/bucket_website.rbs +93 -0
  120. data/sig/client.rbs +2406 -0
  121. data/sig/customizations/bucket.rbs +19 -0
  122. data/sig/customizations/object.rbs +38 -0
  123. data/sig/customizations/object_summary.rbs +35 -0
  124. data/sig/errors.rbs +34 -0
  125. data/sig/multipart_upload.rbs +111 -0
  126. data/sig/multipart_upload_part.rbs +105 -0
  127. data/sig/object.rbs +443 -0
  128. data/sig/object_acl.rbs +86 -0
  129. data/sig/object_summary.rbs +335 -0
  130. data/sig/object_version.rbs +137 -0
  131. data/sig/resource.rbs +132 -0
  132. data/sig/types.rbs +2596 -0
  133. data/sig/waiters.rbs +95 -0
  134. metadata +74 -15
@@ -0,0 +1,335 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing guide for more information:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ module Aws
9
+ module S3
10
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html
11
+ class ObjectSummary
12
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#initialize-instance_method
13
+ def initialize: (String bucket_name, String key, Hash[Symbol, untyped] options) -> void
14
+ | (bucket_name: String, key: String, ?client: Client) -> void
15
+ | (Hash[Symbol, untyped] args) -> void
16
+
17
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#bucket_name-instance_method
18
+ def bucket_name: () -> String
19
+
20
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#key-instance_method
21
+ def key: () -> String
22
+
23
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#last_modified-instance_method
24
+ def last_modified: () -> ::Time
25
+
26
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#etag-instance_method
27
+ def etag: () -> ::String
28
+
29
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#checksum_algorithm-instance_method
30
+ def checksum_algorithm: () -> ::Array[("CRC32" | "CRC32C" | "SHA1" | "SHA256")]
31
+
32
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#size-instance_method
33
+ def size: () -> ::Integer
34
+
35
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#storage_class-instance_method
36
+ def storage_class: () -> ("STANDARD" | "REDUCED_REDUNDANCY" | "GLACIER" | "STANDARD_IA" | "ONEZONE_IA" | "INTELLIGENT_TIERING" | "DEEP_ARCHIVE" | "OUTPOSTS" | "GLACIER_IR" | "SNOW" | "EXPRESS_ONEZONE")
37
+
38
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#owner-instance_method
39
+ def owner: () -> Types::Owner
40
+
41
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#restore_status-instance_method
42
+ def restore_status: () -> Types::RestoreStatus
43
+
44
+ def client: () -> Client
45
+
46
+
47
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#data-instance_method
48
+ def data: () -> Types::Object
49
+
50
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#data_loaded?-instance_method
51
+ def data_loaded?: () -> bool
52
+
53
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#exists?-instance_method
54
+ def exists?: (?max_attempts: Integer, ?delay: Numeric, ?before_attempt: (^(Integer attempts) -> void), ?before_wait: (^(Integer attempts, untyped response) -> void)) -> bool
55
+ | (?Hash[Symbol, untyped]) -> bool
56
+
57
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#wait_until_exists-instance_method
58
+ def wait_until_exists: (?max_attempts: Integer, ?delay: Numeric, ?before_attempt: (^(Integer attempts) -> void), ?before_wait: (^(Integer attempts, untyped response) -> void)) ?{ (untyped waiter) -> void } -> ObjectSummary
59
+ | (?Hash[Symbol, untyped]) ?{ (untyped waiter) -> void } -> ObjectSummary
60
+
61
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#wait_until_not_exists-instance_method
62
+ def wait_until_not_exists: (?max_attempts: Integer, ?delay: Numeric, ?before_attempt: (^(Integer attempts) -> void), ?before_wait: (^(Integer attempts, untyped response) -> void)) ?{ (untyped waiter) -> void } -> ObjectSummary
63
+ | (?Hash[Symbol, untyped]) ?{ (untyped waiter) -> void } -> ObjectSummary
64
+
65
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#copy_from-instance_method
66
+ def copy_from: (
67
+ ?acl: ("private" | "public-read" | "public-read-write" | "authenticated-read" | "aws-exec-read" | "bucket-owner-read" | "bucket-owner-full-control"),
68
+ ?cache_control: ::String,
69
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256"),
70
+ ?content_disposition: ::String,
71
+ ?content_encoding: ::String,
72
+ ?content_language: ::String,
73
+ ?content_type: ::String,
74
+ copy_source: ::String,
75
+ ?copy_source_if_match: ::String,
76
+ ?copy_source_if_modified_since: ::Time,
77
+ ?copy_source_if_none_match: ::String,
78
+ ?copy_source_if_unmodified_since: ::Time,
79
+ ?expires: ::Time,
80
+ ?grant_full_control: ::String,
81
+ ?grant_read: ::String,
82
+ ?grant_read_acp: ::String,
83
+ ?grant_write_acp: ::String,
84
+ ?metadata: Hash[::String, ::String],
85
+ ?metadata_directive: ("COPY" | "REPLACE"),
86
+ ?tagging_directive: ("COPY" | "REPLACE"),
87
+ ?server_side_encryption: ("AES256" | "aws:kms" | "aws:kms:dsse"),
88
+ ?storage_class: ("STANDARD" | "REDUCED_REDUNDANCY" | "STANDARD_IA" | "ONEZONE_IA" | "INTELLIGENT_TIERING" | "GLACIER" | "DEEP_ARCHIVE" | "OUTPOSTS" | "GLACIER_IR" | "SNOW" | "EXPRESS_ONEZONE"),
89
+ ?website_redirect_location: ::String,
90
+ ?sse_customer_algorithm: ::String,
91
+ ?sse_customer_key: ::String,
92
+ ?sse_customer_key_md5: ::String,
93
+ ?ssekms_key_id: ::String,
94
+ ?ssekms_encryption_context: ::String,
95
+ ?bucket_key_enabled: bool,
96
+ ?copy_source_sse_customer_algorithm: ::String,
97
+ ?copy_source_sse_customer_key: ::String,
98
+ ?copy_source_sse_customer_key_md5: ::String,
99
+ ?request_payer: ("requester"),
100
+ ?tagging: ::String,
101
+ ?object_lock_mode: ("GOVERNANCE" | "COMPLIANCE"),
102
+ ?object_lock_retain_until_date: ::Time,
103
+ ?object_lock_legal_hold_status: ("ON" | "OFF"),
104
+ ?expected_bucket_owner: ::String,
105
+ ?expected_source_bucket_owner: ::String
106
+ ) -> Types::CopyObjectOutput
107
+ | (?Hash[Symbol, untyped]) -> Types::CopyObjectOutput
108
+
109
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#delete-instance_method
110
+ def delete: (
111
+ ?mfa: ::String,
112
+ ?version_id: ::String,
113
+ ?request_payer: ("requester"),
114
+ ?bypass_governance_retention: bool,
115
+ ?expected_bucket_owner: ::String
116
+ ) -> Types::DeleteObjectOutput
117
+ | (?Hash[Symbol, untyped]) -> Types::DeleteObjectOutput
118
+
119
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#get-instance_method
120
+ def get: (
121
+ ?if_match: ::String,
122
+ ?if_modified_since: ::Time,
123
+ ?if_none_match: ::String,
124
+ ?if_unmodified_since: ::Time,
125
+ ?range: ::String,
126
+ ?response_cache_control: ::String,
127
+ ?response_content_disposition: ::String,
128
+ ?response_content_encoding: ::String,
129
+ ?response_content_language: ::String,
130
+ ?response_content_type: ::String,
131
+ ?response_expires: ::Time,
132
+ ?version_id: ::String,
133
+ ?sse_customer_algorithm: ::String,
134
+ ?sse_customer_key: ::String,
135
+ ?sse_customer_key_md5: ::String,
136
+ ?request_payer: ("requester"),
137
+ ?part_number: ::Integer,
138
+ ?expected_bucket_owner: ::String,
139
+ ?checksum_mode: ("ENABLED")
140
+ ) -> Types::GetObjectOutput
141
+ | (?Hash[Symbol, untyped]) -> Types::GetObjectOutput
142
+
143
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#initiate_multipart_upload-instance_method
144
+ def initiate_multipart_upload: (
145
+ ?acl: ("private" | "public-read" | "public-read-write" | "authenticated-read" | "aws-exec-read" | "bucket-owner-read" | "bucket-owner-full-control"),
146
+ ?cache_control: ::String,
147
+ ?content_disposition: ::String,
148
+ ?content_encoding: ::String,
149
+ ?content_language: ::String,
150
+ ?content_type: ::String,
151
+ ?expires: ::Time,
152
+ ?grant_full_control: ::String,
153
+ ?grant_read: ::String,
154
+ ?grant_read_acp: ::String,
155
+ ?grant_write_acp: ::String,
156
+ ?metadata: Hash[::String, ::String],
157
+ ?server_side_encryption: ("AES256" | "aws:kms" | "aws:kms:dsse"),
158
+ ?storage_class: ("STANDARD" | "REDUCED_REDUNDANCY" | "STANDARD_IA" | "ONEZONE_IA" | "INTELLIGENT_TIERING" | "GLACIER" | "DEEP_ARCHIVE" | "OUTPOSTS" | "GLACIER_IR" | "SNOW" | "EXPRESS_ONEZONE"),
159
+ ?website_redirect_location: ::String,
160
+ ?sse_customer_algorithm: ::String,
161
+ ?sse_customer_key: ::String,
162
+ ?sse_customer_key_md5: ::String,
163
+ ?ssekms_key_id: ::String,
164
+ ?ssekms_encryption_context: ::String,
165
+ ?bucket_key_enabled: bool,
166
+ ?request_payer: ("requester"),
167
+ ?tagging: ::String,
168
+ ?object_lock_mode: ("GOVERNANCE" | "COMPLIANCE"),
169
+ ?object_lock_retain_until_date: ::Time,
170
+ ?object_lock_legal_hold_status: ("ON" | "OFF"),
171
+ ?expected_bucket_owner: ::String,
172
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256")
173
+ ) -> MultipartUpload
174
+ | (?Hash[Symbol, untyped]) -> MultipartUpload
175
+
176
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#put-instance_method
177
+ def put: (
178
+ ?acl: ("private" | "public-read" | "public-read-write" | "authenticated-read" | "aws-exec-read" | "bucket-owner-read" | "bucket-owner-full-control"),
179
+ ?body: ::String | ::StringIO | ::File,
180
+ ?cache_control: ::String,
181
+ ?content_disposition: ::String,
182
+ ?content_encoding: ::String,
183
+ ?content_language: ::String,
184
+ ?content_length: ::Integer,
185
+ ?content_md5: ::String,
186
+ ?content_type: ::String,
187
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256"),
188
+ ?checksum_crc32: ::String,
189
+ ?checksum_crc32c: ::String,
190
+ ?checksum_sha1: ::String,
191
+ ?checksum_sha256: ::String,
192
+ ?expires: ::Time,
193
+ ?if_none_match: ::String,
194
+ ?grant_full_control: ::String,
195
+ ?grant_read: ::String,
196
+ ?grant_read_acp: ::String,
197
+ ?grant_write_acp: ::String,
198
+ ?metadata: Hash[::String, ::String],
199
+ ?server_side_encryption: ("AES256" | "aws:kms" | "aws:kms:dsse"),
200
+ ?storage_class: ("STANDARD" | "REDUCED_REDUNDANCY" | "STANDARD_IA" | "ONEZONE_IA" | "INTELLIGENT_TIERING" | "GLACIER" | "DEEP_ARCHIVE" | "OUTPOSTS" | "GLACIER_IR" | "SNOW" | "EXPRESS_ONEZONE"),
201
+ ?website_redirect_location: ::String,
202
+ ?sse_customer_algorithm: ::String,
203
+ ?sse_customer_key: ::String,
204
+ ?sse_customer_key_md5: ::String,
205
+ ?ssekms_key_id: ::String,
206
+ ?ssekms_encryption_context: ::String,
207
+ ?bucket_key_enabled: bool,
208
+ ?request_payer: ("requester"),
209
+ ?tagging: ::String,
210
+ ?object_lock_mode: ("GOVERNANCE" | "COMPLIANCE"),
211
+ ?object_lock_retain_until_date: ::Time,
212
+ ?object_lock_legal_hold_status: ("ON" | "OFF"),
213
+ ?expected_bucket_owner: ::String
214
+ ) -> Types::PutObjectOutput
215
+ | (?Hash[Symbol, untyped]) -> Types::PutObjectOutput
216
+
217
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#restore_object-instance_method
218
+ def restore_object: (
219
+ ?version_id: ::String,
220
+ ?restore_request: {
221
+ days: ::Integer?,
222
+ glacier_job_parameters: {
223
+ tier: ("Standard" | "Bulk" | "Expedited")
224
+ }?,
225
+ type: ("SELECT")?,
226
+ tier: ("Standard" | "Bulk" | "Expedited")?,
227
+ description: ::String?,
228
+ select_parameters: {
229
+ input_serialization: {
230
+ csv: {
231
+ file_header_info: ("USE" | "IGNORE" | "NONE")?,
232
+ comments: ::String?,
233
+ quote_escape_character: ::String?,
234
+ record_delimiter: ::String?,
235
+ field_delimiter: ::String?,
236
+ quote_character: ::String?,
237
+ allow_quoted_record_delimiter: bool?
238
+ }?,
239
+ compression_type: ("NONE" | "GZIP" | "BZIP2")?,
240
+ json: {
241
+ type: ("DOCUMENT" | "LINES")?
242
+ }?,
243
+ parquet: {
244
+ }?
245
+ },
246
+ expression_type: ("SQL"),
247
+ expression: ::String,
248
+ output_serialization: {
249
+ csv: {
250
+ quote_fields: ("ALWAYS" | "ASNEEDED")?,
251
+ quote_escape_character: ::String?,
252
+ record_delimiter: ::String?,
253
+ field_delimiter: ::String?,
254
+ quote_character: ::String?
255
+ }?,
256
+ json: {
257
+ record_delimiter: ::String?
258
+ }?
259
+ }
260
+ }?,
261
+ output_location: {
262
+ s3: {
263
+ bucket_name: ::String,
264
+ prefix: ::String,
265
+ encryption: {
266
+ encryption_type: ("AES256" | "aws:kms" | "aws:kms:dsse"),
267
+ kms_key_id: ::String?,
268
+ kms_context: ::String?
269
+ }?,
270
+ canned_acl: ("private" | "public-read" | "public-read-write" | "authenticated-read" | "aws-exec-read" | "bucket-owner-read" | "bucket-owner-full-control")?,
271
+ access_control_list: Array[
272
+ {
273
+ grantee: {
274
+ display_name: ::String?,
275
+ email_address: ::String?,
276
+ id: ::String?,
277
+ type: ("CanonicalUser" | "AmazonCustomerByEmail" | "Group"),
278
+ uri: ::String?
279
+ }?,
280
+ permission: ("FULL_CONTROL" | "WRITE" | "WRITE_ACP" | "READ" | "READ_ACP")?
281
+ },
282
+ ]?,
283
+ tagging: {
284
+ tag_set: Array[
285
+ {
286
+ key: ::String,
287
+ value: ::String
288
+ },
289
+ ]
290
+ }?,
291
+ user_metadata: Array[
292
+ {
293
+ name: ::String?,
294
+ value: ::String?
295
+ },
296
+ ]?,
297
+ storage_class: ("STANDARD" | "REDUCED_REDUNDANCY" | "STANDARD_IA" | "ONEZONE_IA" | "INTELLIGENT_TIERING" | "GLACIER" | "DEEP_ARCHIVE" | "OUTPOSTS" | "GLACIER_IR" | "SNOW" | "EXPRESS_ONEZONE")?
298
+ }?
299
+ }?
300
+ },
301
+ ?request_payer: ("requester"),
302
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256"),
303
+ ?expected_bucket_owner: ::String
304
+ ) -> Types::RestoreObjectOutput
305
+ | (?Hash[Symbol, untyped]) -> Types::RestoreObjectOutput
306
+
307
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#acl-instance_method
308
+ def acl: () -> ObjectAcl
309
+
310
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#bucket-instance_method
311
+ def bucket: () -> Bucket
312
+
313
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#multipart_upload-instance_method
314
+ def multipart_upload: (String id) -> MultipartUpload
315
+
316
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#object-instance_method
317
+ def object: () -> Object
318
+
319
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectSummary.html#version-instance_method
320
+ def version: (String id) -> ObjectVersion
321
+
322
+ class Collection < ::Aws::Resources::Collection[ObjectSummary]
323
+
324
+ def batch_delete!: (
325
+ ?mfa: ::String,
326
+ ?request_payer: ("requester"),
327
+ ?bypass_governance_retention: bool,
328
+ ?expected_bucket_owner: ::String,
329
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256")
330
+ ) -> void
331
+ | (?Hash[Symbol, untyped]) -> void
332
+ end
333
+ end
334
+ end
335
+ end
@@ -0,0 +1,137 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing guide for more information:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ module Aws
9
+ module S3
10
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html
11
+ class ObjectVersion
12
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#initialize-instance_method
13
+ def initialize: (String bucket_name, String object_key, String id, Hash[Symbol, untyped] options) -> void
14
+ | (bucket_name: String, object_key: String, id: String, ?client: Client) -> void
15
+ | (Hash[Symbol, untyped] args) -> void
16
+
17
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#bucket_name-instance_method
18
+ def bucket_name: () -> String
19
+
20
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#object_key-instance_method
21
+ def object_key: () -> String
22
+
23
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#id-instance_method
24
+ def id: () -> String
25
+
26
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#etag-instance_method
27
+ def etag: () -> ::String
28
+
29
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#checksum_algorithm-instance_method
30
+ def checksum_algorithm: () -> ::Array[("CRC32" | "CRC32C" | "SHA1" | "SHA256")]
31
+
32
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#size-instance_method
33
+ def size: () -> ::Integer
34
+
35
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#storage_class-instance_method
36
+ def storage_class: () -> ("STANDARD")
37
+
38
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#key-instance_method
39
+ def key: () -> ::String
40
+
41
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#version_id-instance_method
42
+ def version_id: () -> ::String
43
+
44
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#is_latest-instance_method
45
+ def is_latest: () -> bool
46
+
47
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#last_modified-instance_method
48
+ def last_modified: () -> ::Time
49
+
50
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#owner-instance_method
51
+ def owner: () -> Types::Owner
52
+
53
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#restore_status-instance_method
54
+ def restore_status: () -> Types::RestoreStatus
55
+
56
+ def client: () -> Client
57
+
58
+
59
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#data-instance_method
60
+ def data: () -> Types::ObjectVersion
61
+
62
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#data_loaded?-instance_method
63
+ def data_loaded?: () -> bool
64
+
65
+
66
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#delete-instance_method
67
+ def delete: (
68
+ ?mfa: ::String,
69
+ ?request_payer: ("requester"),
70
+ ?bypass_governance_retention: bool,
71
+ ?expected_bucket_owner: ::String
72
+ ) -> Types::DeleteObjectOutput
73
+ | (?Hash[Symbol, untyped]) -> Types::DeleteObjectOutput
74
+
75
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#get-instance_method
76
+ def get: (
77
+ ?if_match: ::String,
78
+ ?if_modified_since: ::Time,
79
+ ?if_none_match: ::String,
80
+ ?if_unmodified_since: ::Time,
81
+ ?range: ::String,
82
+ ?response_cache_control: ::String,
83
+ ?response_content_disposition: ::String,
84
+ ?response_content_encoding: ::String,
85
+ ?response_content_language: ::String,
86
+ ?response_content_type: ::String,
87
+ ?response_expires: ::Time,
88
+ ?sse_customer_algorithm: ::String,
89
+ ?sse_customer_key: ::String,
90
+ ?sse_customer_key_md5: ::String,
91
+ ?request_payer: ("requester"),
92
+ ?part_number: ::Integer,
93
+ ?expected_bucket_owner: ::String,
94
+ ?checksum_mode: ("ENABLED")
95
+ ) -> Types::GetObjectOutput
96
+ | (?Hash[Symbol, untyped]) -> Types::GetObjectOutput
97
+
98
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#head-instance_method
99
+ def head: (
100
+ ?if_match: ::String,
101
+ ?if_modified_since: ::Time,
102
+ ?if_none_match: ::String,
103
+ ?if_unmodified_since: ::Time,
104
+ ?range: ::String,
105
+ ?response_cache_control: ::String,
106
+ ?response_content_disposition: ::String,
107
+ ?response_content_encoding: ::String,
108
+ ?response_content_language: ::String,
109
+ ?response_content_type: ::String,
110
+ ?response_expires: ::Time,
111
+ ?sse_customer_algorithm: ::String,
112
+ ?sse_customer_key: ::String,
113
+ ?sse_customer_key_md5: ::String,
114
+ ?request_payer: ("requester"),
115
+ ?part_number: ::Integer,
116
+ ?expected_bucket_owner: ::String,
117
+ ?checksum_mode: ("ENABLED")
118
+ ) -> Types::HeadObjectOutput
119
+ | (?Hash[Symbol, untyped]) -> Types::HeadObjectOutput
120
+
121
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/ObjectVersion.html#object-instance_method
122
+ def object: () -> Object
123
+
124
+ class Collection < ::Aws::Resources::Collection[ObjectVersion]
125
+
126
+ def batch_delete!: (
127
+ ?mfa: ::String,
128
+ ?request_payer: ("requester"),
129
+ ?bypass_governance_retention: bool,
130
+ ?expected_bucket_owner: ::String,
131
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256")
132
+ ) -> void
133
+ | (?Hash[Symbol, untyped]) -> void
134
+ end
135
+ end
136
+ end
137
+ end
data/sig/resource.rbs ADDED
@@ -0,0 +1,132 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing guide for more information:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ module Aws
9
+ module S3
10
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Resource.html
11
+ class Resource
12
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Resource.html#initialize-instance_method
13
+ def initialize: (
14
+ ?client: Client,
15
+ ?credentials: untyped,
16
+ ?region: String,
17
+ ?access_grants: bool,
18
+ ?access_grants_credentials_provider: untyped,
19
+ ?access_key_id: String,
20
+ ?account_id: String,
21
+ ?active_endpoint_cache: bool,
22
+ ?adaptive_retry_wait_to_fill: bool,
23
+ ?client_side_monitoring: bool,
24
+ ?client_side_monitoring_client_id: String,
25
+ ?client_side_monitoring_host: String,
26
+ ?client_side_monitoring_port: Integer,
27
+ ?client_side_monitoring_publisher: untyped,
28
+ ?compute_checksums: bool,
29
+ ?convert_params: bool,
30
+ ?correct_clock_skew: bool,
31
+ ?defaults_mode: String,
32
+ ?disable_host_prefix_injection: bool,
33
+ ?disable_request_compression: bool,
34
+ ?disable_s3_express_session_auth: bool,
35
+ ?endpoint: String,
36
+ ?endpoint_cache_max_entries: Integer,
37
+ ?endpoint_cache_max_threads: Integer,
38
+ ?endpoint_cache_poll_interval: Integer,
39
+ ?endpoint_discovery: bool,
40
+ ?event_stream_handler: Proc,
41
+ ?express_credentials_provider: untyped,
42
+ ?follow_redirects: bool,
43
+ ?force_path_style: bool,
44
+ ?ignore_configured_endpoint_urls: bool,
45
+ ?input_event_stream_handler: Proc,
46
+ ?log_formatter: untyped,
47
+ ?log_level: Symbol,
48
+ ?logger: untyped,
49
+ ?max_attempts: Integer,
50
+ ?output_event_stream_handler: Proc,
51
+ ?profile: String,
52
+ ?request_min_compression_size_bytes: Integer,
53
+ ?require_https_for_sse_cpk: bool,
54
+ ?retry_backoff: Proc,
55
+ ?retry_base_delay: Float,
56
+ ?retry_jitter: (:none | :equal | :full | ^(Integer) -> Integer),
57
+ ?retry_limit: Integer,
58
+ ?retry_max_delay: Integer,
59
+ ?retry_mode: ("legacy" | "standard" | "adaptive"),
60
+ ?s3_disable_multiregion_access_points: bool,
61
+ ?s3_us_east_1_regional_endpoint: String,
62
+ ?s3_use_arn_region: bool,
63
+ ?sdk_ua_app_id: String,
64
+ ?secret_access_key: String,
65
+ ?session_token: String,
66
+ ?sigv4a_signing_region_set: Array[String],
67
+ ?stub_responses: untyped,
68
+ ?telemetry_provider: Aws::Telemetry::TelemetryProviderBase,
69
+ ?token_provider: untyped,
70
+ ?use_accelerate_endpoint: bool,
71
+ ?use_dualstack_endpoint: bool,
72
+ ?use_fips_endpoint: bool,
73
+ ?validate_params: bool,
74
+ ?endpoint_provider: untyped,
75
+ ?http_proxy: String,
76
+ ?http_open_timeout: (Float | Integer),
77
+ ?http_read_timeout: (Float | Integer),
78
+ ?http_idle_timeout: (Float | Integer),
79
+ ?http_continue_timeout: (Float | Integer),
80
+ ?ssl_timeout: (Float | Integer | nil),
81
+ ?http_wire_trace: bool,
82
+ ?ssl_verify_peer: bool,
83
+ ?ssl_ca_bundle: String,
84
+ ?ssl_ca_directory: String,
85
+ ?ssl_ca_store: String,
86
+ ?on_chunk_received: Proc,
87
+ ?on_chunk_sent: Proc,
88
+ ?raise_response_errors: bool
89
+ ) -> void
90
+ | (?Hash[Symbol, untyped]) -> void
91
+
92
+ def client: () -> Client
93
+
94
+
95
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Resource.html#create_bucket-instance_method
96
+ def create_bucket: (
97
+ ?acl: ("private" | "public-read" | "public-read-write" | "authenticated-read"),
98
+ bucket: ::String,
99
+ ?create_bucket_configuration: {
100
+ location_constraint: ("af-south-1" | "ap-east-1" | "ap-northeast-1" | "ap-northeast-2" | "ap-northeast-3" | "ap-south-1" | "ap-south-2" | "ap-southeast-1" | "ap-southeast-2" | "ap-southeast-3" | "ca-central-1" | "cn-north-1" | "cn-northwest-1" | "EU" | "eu-central-1" | "eu-north-1" | "eu-south-1" | "eu-south-2" | "eu-west-1" | "eu-west-2" | "eu-west-3" | "me-south-1" | "sa-east-1" | "us-east-2" | "us-gov-east-1" | "us-gov-west-1" | "us-west-1" | "us-west-2")?,
101
+ location: {
102
+ type: ("AvailabilityZone")?,
103
+ name: ::String?
104
+ }?,
105
+ bucket: {
106
+ data_redundancy: ("SingleAvailabilityZone")?,
107
+ type: ("Directory")?
108
+ }?
109
+ },
110
+ ?grant_full_control: ::String,
111
+ ?grant_read: ::String,
112
+ ?grant_read_acp: ::String,
113
+ ?grant_write: ::String,
114
+ ?grant_write_acp: ::String,
115
+ ?object_lock_enabled_for_bucket: bool,
116
+ ?object_ownership: ("BucketOwnerPreferred" | "ObjectWriter" | "BucketOwnerEnforced")
117
+ ) -> Bucket
118
+ | (?Hash[Symbol, untyped]) -> Bucket
119
+
120
+
121
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Resource.html#bucket-instance_method
122
+ def bucket: (String name) -> Bucket
123
+
124
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Resource.html#buckets-instance_method
125
+ def buckets: (
126
+ ?prefix: ::String,
127
+ ?bucket_region: ::String
128
+ ) -> Bucket::Collection
129
+ | (?Hash[Symbol, untyped]) -> Bucket::Collection
130
+ end
131
+ end
132
+ end