tcb storage buckets list
List every Storage bucket in the current PG environment.
v3.4.0+
PG mode storage commands have been available since @cloudbase/cli@3.4.0.
Usage
tcb storage buckets list [-e <envId>] [--json]
Parameters
| Parameter | Required | Description | Default |
|---|---|---|---|
-e, --env-id <envId> | No | Environment ID | — |
--json | No | Output the raw PGExecuteResult, including Columns / Rows | — |
The table output has the columns Id / Name / Public / Size Limit / MIME Types / Created / Updated.
Examples
tcb storage buckets list
tcb storage buckets list --json
Create and delete buckets
There is no dedicated command for creating or deleting a bucket; run SQL with tcb db execute:
# Create a bucket
tcb db execute -e <envId> --sql "INSERT INTO storage.buckets (id, name, public, created_at, updated_at) VALUES ('avatars', 'avatars', false, now(), now())"