Skip to main content
Glama

Create a database

create_database
Idempotent

Provision a SQL database — D1 (default, free) or Neon Postgres (--postgres, developer plan). Optionally attach it to an owned site's Worker env in the same call (siteSlug); otherwise attach it later with attach_database.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesdatabase name, a-z 0-9 -, 2-63 chars
bindingNoWorker binding name, UPPER_SNAKE (defaults to a name derived from `name`)
providerNodefaults to d1
siteSlugNoowned site slug to attach immediately

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already provide idempotentHint=true. The description adds value by disclosing provider plans (free D1, developer Neon), default behavior, and the attachment integration. No contradictions with annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences, front-loading the main action and provider options, then adding the optional attachment detail. Every word is necessary and well-structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the 4 parameters, 1 required, and an output schema, the description covers the core workflow. It could mention the binding parameter's role more explicitly, but overall it is sufficient for an agent to select and use the tool correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so each parameter is documented. The description adds integration context (siteSlug for immediate attachment, provider selection via --postgres) beyond the schema. This enriches understanding without repeating schema details.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool provisions a SQL database with specific providers (D1 or Neon) and optionally attaches it to a Worker environment. It differentiates from sibling tools like attach_database by indicating that attachment can be done in the same call or later.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear when-to-use guidance: it shows the default provider (D1) and alternative (Neon with --postgres), and explains how to attach immediately via siteSlug or later via attach_database. It does not explicitly state when not to use it, but the optionality is clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources