Files
genai-toolbox/docs/en/resources/tools/postgres/postgres-database-overview.md
Yuan Teoh 735cb760ea docs: update long lines and tables (#1952)
Update long lines and tables formatting in markdown doc files.
2025-11-14 20:25:49 +00:00

2.0 KiB

title, type, weight, description, aliases
title type weight description aliases
postgres-database-overview docs 1 The "postgres-database-overview" fetches the current state of the PostgreSQL server.
/resources/tools/postgres-database-overview

About

The postgres-database-overview fetches the current state of the PostgreSQL server. It's compatible with any of the following sources:

postgres-database-overview fetches the current state of the PostgreSQL server This tool does not take any input parameters.

Example

tools:
  database_overview:
    kind: postgres-database-overview
    source: cloudsql-pg-source
    description: |
    fetches the current state of the PostgreSQL server. It returns the postgres version, whether it's a replica, uptime duration, maximum connection limit, number of current connections, number of active connections and the percentage of connections in use.

The response is a JSON object with the following elements:

{
 "pg_version": "PostgreSQL server version string",
 "is_replica": "boolean indicating if the instance is in recovery mode",
 "uptime": "interval string representing the total server uptime",
 "max_connections": "integer maximum number of allowed connections",
 "current_connections": "integer number of current connections",
 "active_connections": "integer number of currently active connections",
 "pct_connections_used": "float percentage of max_connections currently in use"
}

Reference

field type required description
kind string true Must be "postgres-database-overview".
source string true Name of the source the SQL should execute on.
description string false Description of the tool that is passed to the agent.