Get a database
SDK platic.tools.databases.get()
Read the connection and its password authorization. nextStep tells you what to do next. To see every connection, use list databases.
Example
curl https://api.platic.ai/v1/tools/databases/$DB_ID \
-H "Authorization: Bearer $PLATIC_API_KEY" await platic.tools.databases.get("db_123"); Path parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
databaseId | string | The id of the connection | ✓ |
Response
200 OK. It never includes the password.
{
"status": "success",
"data": {
"id": "Xb2mQe7LtR9sKd4fHw1N",
"name": "store",
"description": "Orders, customers, and inventory of the online store.",
"engine": "postgres",
"host": "db.example.com",
"port": 5432,
"database": "store",
"user": "readonly",
"ssl": "require",
"status": "enabled",
"hiddenTables": ["payments"],
"hiddenColumns": ["customers.phone"],
"pageSize": 50,
"timeoutSeconds": 5,
"password": { "state": "authorized", "secretId": "7e4a1c9b3d5f7a0c2e4b6d8f0a1c3e5b7d9f1a3c5e7b9d0f2a4c6e8b0d2f4a6c", "secretName": "Password of the store database" },
"tools": [
{ "id": "Xb2mQe7LtR9sKd4fHw1N_list_tables", "name": "db_store_list_tables", "tool": "list_tables" },
{ "id": "Xb2mQe7LtR9sKd4fHw1N_describe_table", "name": "db_store_describe_table", "tool": "describe_table" },
{ "id": "Xb2mQe7LtR9sKd4fHw1N_query", "name": "db_store_query", "tool": "query" },
{ "id": "Xb2mQe7LtR9sKd4fHw1N_next_page", "name": "db_store_next_page", "tool": "next_page" }
],
"lastTest": { "ok": true, "at": "2026-11-14T16:01:12.000Z", "version": "PostgreSQL 16.4", "tableCount": 3 },
"createdAt": "2026-11-14T16:00:00.000Z",
"updatedAt": "2026-11-14T16:01:12.000Z",
"nextStep": "Ready. Give its tools to an agent with PUT /v1/agents/{agentId}/tools/{toolId} and a toolId from tools."
}
} Response fields
| Field | Type | Description |
|---|---|---|
id | string | The id of the connection |
name, description | string | As they were created. description is "" if it has none |
engine, host, port, database, user, ssl | various | The connection details |
status | string | enabled or paused |
hiddenTables, hiddenColumns | string[] | What the agent does not see |
pageSize, timeoutSeconds | number | Rows per page and time limit of each query |
password | object | state (authorized, needs_authorization, bound, or none), secretId, and, if the credential can read secrets, secretName. See the password |
tools | array | The four tools in the catalog: id (the toolId to connect it to an agent), name, and tool (list_tables, describe_table, query, or next_page) |
lastTest | object | null | The last test: ok, at, and, if it connected, version and tableCount; if it failed, code and message. null before the first test and after the connection details change |
createdAt, updatedAt | string | null | ISO 8601 |
nextStep | string | What is missing, in English |
Errors
| Status | details.code | When it happens |
|---|---|---|
403 | FORBIDDEN | The person behind the token does not have access to Integrations |
404 | NOT_FOUND | There is no connection with that id in the workspace |