Skip to main content
Glama
heroku

Heroku MCP server

Official
by heroku

pg_backups

Manage and monitor Heroku app database backups using this tool. View existing backups, track progress, verify availability, and ensure disaster recovery readiness.

Instructions

Manage database backup operations and schedules. Use this tool when you need to: 1) View existing database backups, 2) Monitor backup schedules and status, 3) Track backup operation progress, 4) Verify backup availability. The tool helps maintain database backup operations and disaster recovery readiness.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
appYesThe name of the Heroku app whose backups to manage.

Implementation Reference

  • The handler function for the 'pg_backups' tool. It constructs a CommandBuilder for 'pg:backups' with the app flag and executes it via herokuRepl, returning formatted output.
    async (options: PgBackupsOptions): Promise<McpToolResponse> => {
      const command = new CommandBuilder(TOOL_COMMAND_MAP.PG_BACKUPS)
        .addFlags({
          app: options.app
        })
        .build();
    
      const output = await herokuRepl.executeCommand(command);
      return handleCliOutput(output);
    }
  • Zod schema defining the input parameters for the pg_backups tool: requires 'app' string.
    export const pgBackupsOptionsSchema = z.object({
      app: z.string().describe('Target app name')
    });
    
    export type PgBackupsOptions = z.infer<typeof pgBackupsOptionsSchema>;
  • The registration function for the pg_backups tool, which calls server.tool with name, description, schema, and inline handler.
    export const registerPgBackupsTool = (server: McpServer, herokuRepl: HerokuREPL): void => {
      server.tool(
        'pg_backups',
        'Manage backups: schedules, status, verification, recovery',
        pgBackupsOptionsSchema.shape,
        async (options: PgBackupsOptions): Promise<McpToolResponse> => {
          const command = new CommandBuilder(TOOL_COMMAND_MAP.PG_BACKUPS)
            .addFlags({
              app: options.app
            })
            .build();
    
          const output = await herokuRepl.executeCommand(command);
          return handleCliOutput(output);
        }
      );
    };
  • src/index.ts:84-84 (registration)
    Invocation of the registerPgBackupsTool during server initialization.
    data.registerPgBackupsTool(server, herokuRepl);
  • Constant mapping the PG_BACKUPS key to the Heroku CLI command 'pg:backups' used in the handler.
    PG_BACKUPS: 'pg:backups',
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden but lacks critical behavioral details. It mentions what the tool helps with but doesn't disclose whether operations are read-only or mutating, what permissions are needed, rate limits, or error conditions. The description is insufficient for a tool with potential operational impact.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with a clear opening statement followed by bullet-like usage scenarios. It's appropriately sized at two sentences, though the second sentence could be slightly more concise by eliminating redundancy like 'helps maintain database backup operations'.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a backup management tool with no annotations and no output schema, the description provides reasonable context about what the tool does but lacks critical details about behavioral characteristics, return values, and error handling. It's minimally adequate but leaves significant gaps for operational understanding.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents the single 'app' parameter. The description doesn't add any parameter-specific information beyond what's in the schema, maintaining the baseline score of 3 for adequate but not enhanced parameter documentation.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose as managing database backup operations and schedules, with specific verbs like 'view', 'monitor', 'track', and 'verify'. It distinguishes from siblings like pg_info or pg_maintenance by focusing on backups, though it doesn't explicitly contrast with them.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides explicit usage scenarios (viewing backups, monitoring schedules, tracking progress, verifying availability) that clearly indicate when to use this tool. However, it doesn't specify when NOT to use it or name alternatives among sibling tools.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/heroku/heroku-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server