Build your own seekdb MCP server with Google GenAI Toolbox
MCP (Model Context Protocol) is an open-source protocol introduced by Anthropic in November 2024. It enables large language models (LLMs) to interact with external tools or data sources without manual intervention. With MCP, an LLM can directly instruct a tool to perform specific actions (Actions) based on its output.
Google GenAI Toolbox for Databases is an open-source toolkit that simplifies the development of tools by handling complex tasks such as connection pooling and authentication. This allows developers to build tools more easily, quickly, and securely.
This article demonstrates how to build a seekdb MCP server using Google GenAI Toolbox without writing any code.
Prerequisites
-
You have deployed seekdb.
-
Your system supports running binary files (Linux, macOS, or Windows).
Step 1: Obtain database connection information
Contact your seekdb deployment team or administrator to obtain the database connection string, for example:
mysql -h$host -P$port -u$user_name -p$password -D$database_name
Parameter description:
-
$host: the IP address for connecting to seekdb. -
$port: the port for connecting to seekdb, defaulting to2881. -
$database_name: the name of the database to access.tipThe user must have the
CREATE,INSERT,DROP, andSELECTprivileges on the database. -
$user_name: the username for the database connection. -
$password: the password for the account.
Step 2: Download and start using Google GenAI Toolbox
Download the Toolbox binary file
Download the latest version of the Toolbox binary file:
export OS="linux/amd64" # Choose one of linux/amd64, darwin/arm64, darwin/amd64, or windows/amd64
export VERSION="0.24.0"
curl -O https://storage.googleapis.com/genai-toolbox/v$VERSION/$OS/toolbox
chmod +x toolbox
Create a configuration file
Create a tools.yaml file and write the following content. Replace the connection information with your seekdb address. This example configuration shows how to use the Toolbox to retrieve an ASH report and cluster information through an MCP tool. You can customize your own tools.
sources:
seekdb:
kind: oceanbase
host: *.*.*.*
port: 2881
database: oceanbase
user: root
password: "****"
queryTimeout: 60s
tools:
get-ash-report:
kind: oceanbase-sql
source: seekdb
description: get ASH report
parameters:
- name: start_time
type: string
description: The start time of the ASH report
- name: end_time
type: string
description: The end time of the ASH report
statement: CALL DBMS_WORKLOAD_REPOSITORY.ASH_REPORT(?,?, NULL, NULL, NULL, 'TEXT', NULL, NULL, NULL);
get-all-server-nodes:
kind: oceanbase-sql
source: seekdb
description: get all server nodes
statement: select * from DBA_OB_SERVERS;
toolsets:
my_first_toolset:
- get-ash-report
Start the Toolbox
Start the Toolbox. You should see the following output:
./toolbox --tools-file tools.yaml
2025-08-28T10:37:49.776637+08:00 INFO "Initialized 1 sources."
2025-08-28T10:37:49.777513+08:00 INFO "Initialized 0 authServices."
2025-08-28T10:37:49.777586+08:00 INFO "Initialized 1 tools."
2025-08-28T10:37:49.777627+08:00 INFO "Initialized 2 toolsets."
2025-08-28T10:37:49.778334+08:00 INFO "Server ready to serve!"
Step 3: (Optional) Test with MCP Inspector
Inspector is an interactive development tool for testing and debugging MCP servers.
You can run Inspector directly using npx without installation:
npx @modelcontextprotocol/inspector node build/index.js
Configure the connection
-
Access http://ip:6274.
-
Transport Type select SSE.

-
Enter the URL:
http://ip:5000/mcp/sseand click the Connect button.
-
In the Tools tab, click List Tools and try the
get-all-server-nodestool. You should see the following output:
{
"BLOCK_MIGRATE_IN_TIME": null,
"BUILD_VERSION": "1.0.0.0_100000262025111218-5343637512e28c346f938516af53b7879d4d5974(Nov 12 2025 19:03:56)",
"CREATE_TIME": "2025-12-03T11:00:21.864447Z",
"ID": 1,
"LAST_OFFLINE_TIME": null,
"MODIFY_TIME": "2025-12-23T10:01:00.154657Z",
"SQL_PORT": 2881,
"START_SERVICE_TIME": "2025-12-23T10:01:00.15322Z",
"STATUS": "ACTIVE",
"STOP_TIME": null,
"SVR_IP": "127.0.0.1",
"SVR_PORT": 2882,
"WITH_ROOTSERVER": "YES",
"ZONE": "z1"
}
Step 4: Integrate with your MCP client
After successful testing, you now have your own MCP server without writing any code. You can integrate any MCP client with large language models to enhance your workflow efficiency.
Supported MCP Clients
- Continue - IDE plugin supporting Visual Studio Code and IntelliJ IDEA
- Claude Desktop - Anthropic's desktop application
- Cline - Command-line AI assistant
- Other clients supporting the MCP protocol
Next Steps
- Customize tool configurations and add more SQL queries related to seekdb.
- Integrate into your workflow to improve database management and analysis efficiency.
- Explore more MCP tools and features.