PgBeam Docs
Projects

listCacheRules

List cache rules

Returns the cache rules for a database, showing all observed query shapes with their stats and cache recommendations.

Usage

const result = await api.projects.listCacheRules();

Parameters

ParameterTypeRequiredDescription
queryParams.page_sizenumberNoMaximum number of items to return (1-100, default 20).
queryParams.page_tokenstringNoOpaque token for cursor-based pagination.

Response

Promise<ListCacheRulesResponse> — cache rule entries.

Example

import { PgBeamClient } from "pgbeam";

const client = new PgBeamClient({
  token: "pbk_...",
  baseUrl: "https://api.pgbeam.com",
});

const result = await client.api.projects.listCacheRules({
  queryParams: { page_size: 20, page_token: "..." },
});

Errors

StatusDescription
400Invalid request parameters.
401Missing or invalid authentication.
403Operation not allowed by current plan limits.
404Resource not found.
429Rate limited. Try again later.

On this page