oshaani MCP Marketplace
Sign in

← Documentation

MySQL MCP Database

Explore databases and tables and run read-only SQL queries on MySQL or MariaDB.

1 credits / tool call

Quick start

  1. Add a MySQL connection with the settings below, then click Test configuration.
  2. Create an API key for your agent.
  3. Paste the key below, click Test endpoint, and copy the configuration for your platform.
Endpointhttps://market.oshaani.com/mysql (your default connection) or https://market.oshaani.com/mysql/<connection-id>
TransportStreamable HTTP (stateless, JSON responses). MCP protocol versions 2024-11-05 to 2025-11-25 and 2026-07-28.
AuthenticationAuthorization: Bearer <API key>, using a key from the API keys page.

Agent configuration

The default URL uses your organisation's default MySQL connection; a URL with an ID pins one connection.
Get a key
The key is filled into the snippets below. It stays in this page and is only sent with the test request.
Runs initialize and tools/list against the endpoint, exactly like an agent. No credits are charged.

Any MCP client that supports remote (Streamable HTTP) servers with custom headers.

{
  "name": "mysql",
  "transport": "streamable-http",
  "url": "https://market.oshaani.com/mysql",
  "headers": {
    "Authorization": "Bearer YOUR_API_KEY"
  }
}

Connection settings

Entered once per connection on market.oshaani.com. Secrets are encrypted and never shown again or sent to agents.

SettingTypeDescription
Host
host required
string Public hostname or IP address of the server
pattern ^[A-Za-z0-9.:-]+$
Port
port
integer
default 3306

min 1, max 65535
Default database
database
string
max length 64
Username
username required
string Use an account that only has SELECT privileges
min length 1
Password
password required secret
string
TLS mode
tls
"preferred" | "verify_identity" | "disabled"
default "preferred"
preferred encrypts when the server supports it; verify_identity also checks the certificate against public CAs
Maximum rows per query
max_rows
integer
default 500

min 1, max 10000
Query timeout (seconds)
statement_timeout_seconds
integer
default 15

min 1, max 25

Tools (5)

list_databases read-only

List databases (schemas) the account can see

No arguments.

list_tables read-only

List tables and views with estimated row counts and sizes

ArgumentTypeDescription
database string Defaults to the connection's database
min length 1, max length 64

describe_table read-only

Describe a table: columns, types, keys, indexes and foreign keys

ArgumentTypeDescription
table required string
min length 1, max length 64
database string Defaults to the connection's database
min length 1, max length 64

run_read_query read-only

Run a read-only SQL query and return the columns and rows

ArgumentTypeDescription
sql required string A single SELECT, SHOW or DESCRIBE statement
min length 1, max length 50000
database string Database to run in; defaults to the connection's database
min length 1, max length 64
max_rows integer Defaults to the connection's limit
min 1, max 10000

explain_query read-only

Show the query plan MySQL would use, without running the query

ArgumentTypeDescription
sql required string A single SELECT, SHOW or DESCRIBE statement
min length 1, max length 50000
database string Defaults to the connection's database
min length 1, max length 64

Billing & errors

Each successful tool call costs 1 oshaani.com credit. initialize, tools/list, failed calls and timeouts are free.

JSON-RPC codeMeaning
-32054 (HTTP 401)Missing, unknown or revoked API key
-32053 (HTTP 404)No MySQL connection configured for your organisation, or the connection ID is wrong
-32055 (HTTP 403)Connection disabled or origin not allowed
-32052 (HTTP 429)Rate limit reached; retry after a minute
-32050Not enough oshaani.com credits for the call
-32051Billing temporarily unavailable; the call was not run

Errors from MySQL itself (bad IDs, permissions) come back as tool results with isError: true so the agent can read and correct them. See the MySQL API documentation.