projectscache-rules
cache-rules list
List cache rules for a database
List all tracked query shapes and their caching status for a database. Shows the
query hash, a truncated SQL pattern, query type, whether caching is enabled,
call count, average latency, and PgBeam's caching recommendation. Results are
paginated — use --page-size and --page-token to navigate pages.
Usage
pgbeam cache-rules list [flags]Options
| Option | Description | Required | Default |
|---|---|---|---|
--database-id <value> | ID of the database whose cache rules to list | Yes | - |
--page-size <value> | Number of entries per page (1-100). Defaults to the API default. | No | - |
--page-token <value> | Pagination token returned from a previous list call to fetch the next page | No | - |
Global options
All global options (--token, --profile,
--project, --org, --json, --no-color, --debug) are also available on
this command.
Examples
# List cache rules for a database
pgbeam cache-rules list --database-id db_xxx
# Get the first 20 rules
pgbeam cache-rules list --database-id db_xxx --page-size 20
# Get the next page using a pagination token
pgbeam cache-rules list --database-id db_xxx --page-token <token>
# List as JSON
pgbeam cache-rules list --database-id db_xxx --jsonOutput
Displays a table with columns: Hash, Query, Type, Cached, Calls, Avg (ms), and
Recommendation. If more pages are available, prints the --page-token value for
the next page. With --json, returns the full paginated response.