Chatzuri
Pricing
Guides
Guides
Introduction
  1. 1Getting Started
  2. 2Your Agent
  3. 3Knowledge & Sources
  4. 4Agent actions & Tools
    • Tools & actions overview
    • Credentials & safety
    • Built-in tools
    • Messaging tools
    • E-commerce tools
    • Payments tools
    • Scheduling tools
    • Database tools
    • Cloud storage tools
    • Business & productivity tools
    • Developer tools
    • Build a custom action
    • Trigger webhooks
  5. 5Agent Tasks
  6. 6WorkflowsBeta
  7. 7Channels
  8. 8Customers & Conversations
  9. 9Run Your Team
  10. 10Developer Tools
Developer reference →Showcase →
Guides4. Agent actions & ToolsDatabase tools
Chapter 4 · Agent actions & Tools

Database tools

Connect to PostgreSQL, MySQL/MariaDB, MongoDB, Redis, Supabase, and Airtable with read-only defaults and hard safety caps.

9 min read

Database tools let the agent run real queries against your data — not a copy, not a snapshot — so it can answer questions about today's orders, this week's signups, or the customer's current balance.

Shared safety model

Every database tool ships with three layers of protection:

  1. Your DB role — the database user the connection string points to. Provision it with least privilege (a read-only replica, a role with SELECT only).
  2. Capability profile — read-only by default on every new credential. Read+write enables INSERT / UPDATE; full access enables DELETE. Enforced before the query reaches the DB.
  3. Hard caps — 500 rows per response, 256 KB serialized, 30 s timeout, DDL (DROP/CREATE/ALTER) rejected unconditionally, multi-statement SQL rejected.
Heads up
Always pair the capability profile with a least-privilege DB role. Two locks must fail before anything bad happens. Don't use your production admin connection string.

PostgreSQL

Tool id: postgres_query. Credential type: postgres.

Use list_schemas, list_tables, or describe_table as discovery shortcuts, then run parameterised SQL with $1, $2 placeholders.

Setup

  1. Create a least-privilege role in Postgres: CREATE ROLE chatzuri_agent LOGIN PASSWORD '…'; GRANT CONNECT ON DATABASE app TO chatzuri_agent; GRANT USAGE ON SCHEMA public TO chatzuri_agent; GRANT SELECT ON ALL TABLES IN SCHEMA public TO chatzuri_agent;
  2. Save the connection details — either a full URI (postgresql://user:pass@host:5432/db?sslmode=require) or the discrete host / port / database / username / password / sslMode fields.
  3. Pick the SSL mode — use require for cloud-hosted Postgres (Supabase, Neon, RDS).

MySQL / MariaDB

Tool id: mysql_query. Credential type: mysql.

Same shape as Postgres but with ? placeholders. Works for self-hosted MySQL, MariaDB, PlanetScale, and AWS RDS.

Setup

  1. Create a least-privilege user: CREATE USER 'chatzuri'@'%' IDENTIFIED BY '…'; GRANT SELECT ON app.* TO 'chatzuri'@'%'; FLUSH PRIVILEGES;
  2. Save connection details on a MySQL credential. Set SSL mode to require on managed providers (PlanetScale, RDS).

MongoDB

Tool id: mongodb_query. Credential type: mongodb.

Actions: find, findOne, aggregate, countDocuments, distinct, list_collections, describe_collection, plus inserts / updates / deletes gated by the profile.

Setup

  1. Get the connection string from MongoDB Atlas (Database → Connect → Drivers) or your self-hosted cluster.
  2. Make sure the user in the URI has only the roles you want — e.g. read on a specific database for a read-only agent.
  3. Save the URI + optional defaultDatabase on a MongoDB credential.
  4. On Atlas, allow chatzuri's outbound IPs (or use 0.0.0.0/0 for a public test cluster). Production: lock to your VPC peer.
Note
Aggregation pipelines with $out or $merge stages are treated as writes — they're rejected on a read-only credential even though the named action is aggregate.

Redis

Tool id: redis_query. Credential type: redis.

24 commands across read (GET, MGET, EXISTS, TYPE, TTL, HGET, HGETALL, LRANGE, SCAN, …), write (SET, HSET, LPUSH, ZADD, EXPIRE, INCR, …), and delete (DEL, HDEL, SREM). FLUSHDB / FLUSHALL / KEYS * are never reachable regardless of profile.

Setup

  1. Get connection details from your provider (Upstash, AWS ElastiCache, self-hosted). Use a rediss:// URI for TLS, or set the TLS field on discrete-field credentials.
  2. Set a namespacePrefix (e.g. chatzuri:agent:abc:) — the tool prefixes every key the LLM supplies and limits SCAN to {prefix}*. Strong multi-tenant isolation; recommended for shared Redis.

Supabase

Tool id: supabase_query. Credential type: supabase.

Talks to your Supabase project's PostgREST endpoint — select, insert, update, upsert, delete, rpc, list_tables, describe_table.

Setup

  1. Open your project in app.supabase.com → Project Settings → API.
  2. Copy the Project URL.
  3. Pick a key: anon key (subject to Row-Level Security — recommended) or service_role key (bypasses RLS — full access).
  4. Save URL + key + optional defaultSchema (defaults to public) as a Supabase credential. Set the capability profile.
Tip
If you need raw SQL against your Supabase database (not PostgREST verbs), use the Postgres tool instead with the connection string from Project Settings → Database → Connection string.

Airtable

Tool id: airtable. Credential type: airtable.

Actions: list_tables, list_records, get_record, create_record, update_record, delete_record.

Setup

  1. Open airtable.com/create/tokens.
  2. Click Create new token. Add scopes: data.records:read at minimum, plus data.records:write and schema.bases:read if you want writes and list_tables.
  3. Add access to the specific base(s) you want the agent to touch.
  4. Click Create token and copy the personal access token (starts with pat…).
  5. Save the token + base id (visible in the base URL, https://airtable.com/{base_id}/…) as an Airtable credential.
Previous · Agent actions & ToolsScheduling toolsNext · Agent actions & ToolsCloud storage tools
Chatzuri

AI-powered agents are transforming customer interactions by providing instant, intelligent responses around the clock. They help businesses reduce operational costs, improve response times, and scale support without compromising quality. These agents understand natural language, learn from conversations, and integrate with existing systems to offer personalized experiences that enhance customer satisfaction and loyalty.

Chatzuri

AI-powered agents are transforming customer interactions by providing instant, intelligent responses around the clock. They help businesses reduce operational costs, improve response times, and scale support without compromising quality. These agents understand natural language, learn from conversations, and integrate with existing systems to offer personalized experiences that enhance customer satisfaction and loyalty.

Product

  • Pricing
  • Security
  • Affiliates

Resources

  • API
  • Guides
  • Blog
  • Help

Company

  • About us
  • Privacy Policy
  • Terms of Service
  • Cookie Policy
  • DPA

About

  • Teams
  • Singapore, Nairobi

© 2026 Chatzuri. All rights reserved.

Chatzuri uses AI and can make mistakes.

Terms of ServicePrivacy PolicyCookie PolicyChatzuri