Data Connectors
Data Connectors allow you to link your existing database directly to Cobi, enabling the Data Assistant to query and analyze your data in real-time.All database connections are read-only. Cobi will never modify your data.
Supported Databases
Cobi currently supports the following database types:- PostgreSQL - Full support for PostgreSQL versions 12+
- MySQL - Full support for MySQL 8.0+
Connecting Your Database
Open Developer Settings
Navigate to the Developer section in the sidebar, then select Data Connectors.
Enter Connection Details
Fill in your database credentials:
| Field | Description |
|---|---|
| Connection Name | A friendly name to identify this data source (e.g., “Production DB”, “Analytics”) |
| Host | Your database server address (e.g., db.example.com or an IP address) |
| Port | The database port (default: 5432 for PostgreSQL) |
| Database Name | The name of the specific database to connect to |
| Username | Database user with read access |
| Password | Password for the database user |
Test Connection
Click Test Connection to verify your credentials. Cobi will attempt to connect and confirm access.
Network Configuration
IP Allowlisting
If your database is behind a firewall, you’ll need to allowlist Cobi’s IP addresses:Contact [email protected] to get the IP addresses for your region.
Using SSH Tunnels
For databases that aren’t publicly accessible, we recommend setting up an SSH tunnel or using a bastion host. Contact our support team for guidance on secure connection options.Best Practices
Create a Read-Only User
We strongly recommend creating a dedicated database user with read-only permissions:Limit Table Access
If you only want Cobi to access specific tables, grant permissions selectively:Managing Connections
Edit a Connection
To update connection details:- Go to Developer > Data Connectors
- Click on the connection you want to edit
- Update the fields as needed
- Click Test Connection to verify, then Save Changes
Delete a Connection
To remove a data source:- Go to Developer > Data Connectors
- Click on the connection
- Click Delete Connection
Troubleshooting
Connection Failed
If your connection test fails, check the following:- Firewall rules - Ensure Cobi’s IP addresses are allowlisted
- Credentials - Verify username and password are correct
- Host/Port - Confirm the host address and port are correct
- Database name - Check that the database exists and the user has access
- SSL requirements - Some databases require SSL connections
Slow Queries
If the Data Assistant is slow when querying your database:- Ensure your database has appropriate indexes
- Consider creating views for commonly queried data
- Add Custom Instructions to help Cobi write optimized queries
Next Steps
Once your database is connected:- Add Custom Instructions to help Cobi understand your data
- Start a conversation with the Data Assistant to explore your data