Skip to content

Client.read_bytes

python
async def Client.read_bytes(
    asset: Asset,
    *,
    max_bytes: int | None = None,
) -> bytes

Read an entire asset into memory.

Parameters

asset Asset

The asset to resolve and read.

max_bytes int | None

An optional maximum accepted object size in bytes.

Returns

The complete object contents as bytes.

Type to search…