Skip to main content

The database agents love is here: CloudBase now supports PostgreSQL

CloudBase TeamCloudBase Team
4 min read
The database agents love is here: CloudBase now supports PostgreSQL

Every mature AI application needs a solid database behind it.

Today, Tencent Cloud CloudBase officially supports PostgreSQL (commonly shortened to PG). As one of the most widely used open-source databases, PG is mature, standard in its usage, and a natural fit for agent operations. Once integrated with CloudBase, everything an AI needs when generating an app — creating tables, configuring permissions, generating APIs — can be done in one place.

CloudBase PG has been specially adapted on top of Tencent Cloud's database capabilities to match the new demands of agent-driven development, so the database can keep pace with the rapid, iterative rhythm of agent development. At the same time, CloudBase PG is highly compatible with Supabase, so developers already on Supabase can migrate at low cost.

Agents can read it: tables, permissions and APIs in one step

PostgreSQL has a quality that suits agents perfectly: standard enough, and explicit enough.

Table structure, field constraints, database functions and permission policies can all be defined in standard SQL. An agent reads the schema and understands how data is stored, who can access it, and what it can do.

Take a collaborative document app as an example — with a few lines of SQL you complete data modeling, identity binding and permission control all at once.

In CloudBase, creating a table also lets you define the data structure, user identity and access permissions at the same time. Once the table is created, a RESTful API is generated automatically — CRUD works immediately, no separate server-side endpoints to develop.

More complex needs like full-text search, scheduled jobs and RAG semantic search can be done through database functions, transactions and capabilities like pgvector. The MCP Server, Agent Skills and plugin system CloudBase released earlier are also adapted for PG mode — from creating tables and configuring permissions to calling APIs, agents can not only read it, but do it themselves.

Agents can experiment freely: second-level cloning of TB-scale databases

While developing an app, agents frequently need to modify table structure, adjust permission policies and try different query logic. Code can be changed freely — now the database can be "branched" freely too.

CloudBase PostgreSQL supports Database Branch. When an agent needs to try a new approach, it can clone an independent database environment, modify schema, functions and permission policies inside it, publish after validation succeeds, and drop the branch on failure without affecting production data.

Backing this is Tencent Cloud Database. On Tencent Cloud's self-developed underlying architecture, cloning a 1TB database shrinks from hours to seconds, so every agent experiment can quickly get a database environment with the same structure as production, yet isolated.

Agents on demand: second-level creation, no idle resource waste

The number of apps an agent generates and the frequency of calls aren't fixed, so the database also needs to start, stop and scale flexibly with the app.

CloudBase PostgreSQL cuts database environment creation from minutes to seconds. When an agent generates a new app, the database keeps up, with no need to wait for a traditional database instance to finish creation and initialization.

When the app goes idle, the system automatically suspends compute resources while keeping data, permission policies and APIs intact, and recovers quickly when requests return. When load surges, compute resources scale up quickly — available the moment you need them, not occupying resources when you don't.

This capability is already running stably on Tencent's own agents:

  • CloudBase connects to the WorkBuddy connector — once connected, users can use CloudBase directly as their app's database and backend.

  • Tusi, built on CloudBase, lets users complete app development and deployment from a prompt, with generated apps automatically getting an independent database, data isolation and an account system.

Already on Supabase? Migration is almost code-free

CloudBase PG is highly compatible with Supabase. The two are largely aligned in database, user authentication, permissions and interfaces, so most projects can migrate with only minor changes — a seamless move.

Your AI app's front end is already polished. Come pair it with a solid backend on Tencent Cloud CloudBase.

Build your next app on CloudBase

An all-in-one backend covering database, cloud functions, static hosting, and AI capabilities.