> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hymalaia.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Postgres Connector

> Index PostgreSQL table metadata (schemas and DDL) in Hymalaia

## How it works

The Postgres connector indexes **table metadata** for a given database and schema: it lists tables from `information_schema` and stores each table’s structure as a simplified **CREATE TABLE** DDL (column names and types). It does **not** index row-level table data.

Indexed content is refreshed on the connector’s normal schedule (typically **daily**, like other connectors).

## Setting up

### Authorization

Postgres uses a standard **TCP connection** with database credentials. Create a credential with:

* **Host** — hostname or IP of your Postgres server (e.g. `db.example.com`)
* **Port** — Postgres port (default is usually `5432`)
* **User** — role that can connect and read catalog metadata for the target schema
* **Password** — password for that role

The role must be able to read `information_schema.tables` and `information_schema.columns` for the schema you configure. Prefer a dedicated user with minimal rights when possible.

Ensure the Hymalaia deployment can reach the host (firewall, VPN, security groups, etc.).

### Indexing

<Steps>
  <Step title="Open Postgres connector">
    In the Hymalaia Admin Panel, open the **Postgres** connector.
  </Step>

  <Step title="Configure authorization">
    In **Step 1**, set up credentials:

    * Select an existing Postgres credential, or click **Create New**
    * Enter **Host**, **Port**, **User**, and **Password**
  </Step>

  <Step title="Save configuration">
    Click **Create** (or equivalent) to save the credential configuration.
  </Step>

  <Step title="Continue with selected credential">
    Ensure the correct credential is selected, then click **Continue**.
  </Step>

  <Step title="Specify database and schema">
    In **Step 2**, specify:

    * **Database** — the database name to connect to (e.g. `analytics`)
    * **Schema** — the schema whose tables you want indexed (e.g. `public`)

    Only metadata for tables in that schema is indexed.
  </Step>

  <Step title="Finish connector setup">
    Choose a connector name, set **document access**, assign **groups** if needed, then create the connector. Indexing will run on the connector schedule (typically daily).
  </Step>
</Steps>
