List S3 objects
Lists one bounded page of objects from an S3-compatible connection.
@lainstack/s3/list-objects · Object storage
How to use it
Section titled “How to use it”List S3 objects returns one page of object keys and sizes from an S3-compatible connection. Use it to find keys, then pass a key to @lainstack/s3/read-object, @lainstack/s3/write-object or @lainstack/s3/delete-object. It does not return file contents.
Traps:
- There is no cursor and no way to ask for the next page. A page holds at most 100 objects (
limit, default 50). Whentruncatedis true, more objects exist that you cannot reach. Narrow theprefixto see them. objectsis an inline list ofkeyandsizeonly. There is no modified date and no content type.- The
prefixis relative to the connection’s configured prefix. A prefix cannot start withhttp://,https://,s3://orarn:. bucketis optional. Set it only when the connection does not already select one.- An empty
objectslist is a normal result, not an error.
Settings
Section titled “Settings”| Setting | Key | Type | Details |
|---|---|---|---|
| S3-compatible connection (required) | credentialId |
Connection | Uses the selected S3-compatible object-storage connection. At most 255 characters. |
| Bucket | bucket |
Text | Optional exact bucket when the connection does not already select one. Keys are relative to the configured connection prefix. |
| Prefix | prefix |
Text | Optional relative object-key prefix. |
| Maximum objects (required) | limit |
Number | Returns one bounded page of up to 100 objects. |
Outputs
Section titled “Outputs”| Output | Path | Type |
|---|---|---|
| Objects | objects |
List |
| Truncated | truncated |
Yes or no |