S3Client.list_parts
rboto-s3==0.4.0 · Service index · Types
Model summary (excerpt): Lists the parts that have been uploaded for a specific multipart upload. To use this operation, you must provide the upload ID in the request. You obtain this uploadID by sending the initiate multipart upload request through CreateMultipartUpload . The ListParts request returns a maximum of 1,000 uploaded parts. The limit of 1,000 parts is also the default value. You can restrict the number of...
Install and imports
Signature
async def list_parts(
*,
bucket: str,
key: str,
upload_id: str,
max_parts: int | None = None,
part_number_marker: str | None = None,
request_payer: RequestPayer | None = None,
expected_bucket_owner: str | None = None,
sse_customer_algorithm: str | None = None,
sse_customer_key: str | None = None,
sse_customer_key_md5: str | None = None,
) -> ListPartsOutput: ...
Arguments without defaults are required. None omits an optional request argument. Static types do not validate resource existence, permissions, lengths, ranges, or conditional service requirements.
Arguments
| Argument | Required | Model notes (excerpt) |
|---|---|---|
bucket |
Yes | The name of the bucket to which the parts are being uploaded. Directory buckets - When you use this operation with a directory bucket, you must use virtual-hosted-style requests in the format Bucket-name .s3express- zone-id . region-code .amazonaws.com . Path-style requests are not supported. Directory bucket names must be unique in the chosen Zone (Availability Zone or Local Zone). Bucket... |
key |
Yes | Object key for which the multipart upload was initiated. |
upload_id |
Yes | Upload ID identifying the multipart upload whose parts are being listed. |
max_parts |
No | Sets the maximum number of parts to return. |
part_number_marker |
No | Specifies the part after which listing should begin. Only parts with higher part numbers will be listed. |
request_payer |
No | |
expected_bucket_owner |
No | The account ID of the expected bucket owner. If the account ID that you provide does not match the actual owner of the bucket, the request fails with the HTTP status code 403 Forbidden (access denied). |
sse_customer_algorithm |
No | The server-side encryption (SSE) algorithm used to encrypt the object. This parameter is needed only when the object was created using a checksum algorithm. For more information, see Protecting data using SSE-C keys in the Amazon S3 User Guide . This functionality is not supported for directory buckets. |
sse_customer_key |
No | The server-side encryption (SSE) customer managed key. This parameter is needed only when the object was created using a checksum algorithm. For more information, see Protecting data using SSE-C keys in the Amazon S3 User Guide . This functionality is not supported for directory buckets. |
sse_customer_key_md5 |
No | The MD5 server-side encryption (SSE) customer managed key. This parameter is needed only when the object was created using a checksum algorithm. For more information, see Protecting data using SSE-C keys in the Amazon S3 User Guide . This functionality is not supported for directory buckets. |
Output
ListPartsOutput.
Read-only native attributes, accessed as response.field. Collection getters materialize Python values; to_dict() recursively materializes a mapping. Streams are consumed once.
| Field | Type | Presence | References |
|---|---|---|---|
abort_date |
str | None |
Always present | — |
abort_rule_id |
str | None |
Always present | — |
bucket |
str | None |
Always present | — |
key |
str | None |
Always present | — |
upload_id |
str | None |
Always present | — |
part_number_marker |
str | None |
Always present | — |
next_part_number_marker |
str | None |
Always present | — |
max_parts |
int | None |
Always present | — |
is_truncated |
bool | None |
Always present | — |
parts |
list[PartOutput] | None |
Always present | PartOutput |
initiator |
InitiatorOutput | None |
Always present | InitiatorOutput |
owner |
OwnerOutput | None |
Always present | OwnerOutput |
storage_class |
StorageClassOutput | None |
Always present | StorageClassOutput |
request_charged |
RequestChargedOutput | None |
Always present | RequestChargedOutput |
checksum_algorithm |
ChecksumAlgorithmOutput | None |
Always present | ChecksumAlgorithmOutput |
checksum_type |
ChecksumTypeOutput | None |
Always present | ChecksumTypeOutput |
version_id |
str | None |
Always present | — |
| None means a value can be absent. Output mappings include every declared key; optional input keys may be omitted. Unknown output enum/union variants are not automatically valid inputs.
Related types
Follow these links for nested inputs and outputs; recursive types link back to the same type page.
Pagination and streaming
client.paginators.list_parts(...) accepts the same arguments and returns AsyncIterator[ListPartsOutput]. Direct calls return one page. Pages preserve the Output representation above.
Input cursors: part_number_marker. Page-size argument: max_parts.
No output stream.
Errors
No modeled service errors for this operation.
Other service failures use the service base error; credential, transport and timeout failures use shared errors.