Overview
Connect a PostgreSQL database to Telemetron so the AI support agent can run read-only SQL queries against your data during customer conversations. This allows the agent to look up order history, account details, device records, or any other data stored in your database.Prerequisites
- A PostgreSQL database accessible from the internet (or via a static IP allowlist)
- A database user with read-only permissions (recommended)
- The database connection string
Setup
Enter Connection String
Provide your PostgreSQL connection string in the following format:SSL is enabled by default. To disable SSL, append
?sslmode=disable to the connection string:Configuration
Security Requirements
- Read-only user — Create a dedicated database user with only
SELECTprivileges. Telemetron will only executeSELECTqueries, but a restricted user provides defense in depth. - Network access — The database must be accessible from Telemetron’s servers. Ensure your firewall or security group allows inbound connections on the PostgreSQL port.
- SSL — SSL is enabled by default for encrypted connections. Only disable SSL if your database does not support it.
Schema Browser
After connecting, the schema browser displays all discovered tables with their columns, data types, and nullable status. Click Refresh Schema to update the schema if your database structure changes.How It Works
The AI support agent generates and executes read-only SQL queries against your connected database. During a conversation, when a customer question requires data lookup, the agent formulates aSELECT query, runs it against your database, and uses the results to provide an informed response. Only SELECT statements are executed — no data is modified.
Troubleshooting
| Issue | Resolution |
|---|---|
| Connection test fails | Verify the connection string format, credentials, host, and port. Ensure the database is accessible from external networks. |
| SSL connection errors | If your database does not support SSL, append ?sslmode=disable to the connection string. |
| Permission denied | Ensure the database user has SELECT privileges on the tables you want the agent to access. |
| Schema not showing all tables | The user may not have USAGE permission on all schemas. Grant access to additional schemas as needed. |
| Slow query responses | Consider adding indexes to commonly queried columns. The AI agent’s queries are read-only but may scan large tables. |