s3_get_object
Retrieve an object from B2: read small files inline as base64 or stream any size to a local path using saveToPath.
Instructions
Read a SMALL object inline (≤1 MiB, returned base64) — for manifests, sidecars, and configs the agent must inspect — or stream any size to a local path with saveToPath. saveToPath writes the fetched bytes to the local filesystem (creating parent directories), removes the partial file if the stream fails (cleanup of its own output only), and performs no mutation of B2 or any remote data. For real object data, generate a GetObject URL with s3_get_presigned_url and download directly from B2 (bytes never pass through the server or the model context).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | The object key. | |
| range | No | Byte range, e.g. 'bytes=0-1048575'. | |
| bucket | Yes | The bucket name. | |
| versionId | No | Specific version of the object to retrieve. | |
| saveToPath | No | If provided, save the file to this local path. |