Skip to main content
Glama

create_collection

Create a new PocketBase collection with defined fields, indexes, and API rules to structure data and control record access.

Instructions

Create a new collection with fields and API rules.

Input Schema

NameRequiredDescriptionDefault
nameYesThe collection name (must be unique, alphanumeric with underscores).
typeNoThe collection type — 'base', 'auth', or 'view'. Defaults to 'base'.base
fieldsNoList of field definitions. Each field is a dict with at least 'name' and 'type' keys (e.g. {"name": "title", "type": "text"}).
indexesNoList of index expressions.
list_ruleNoAPI rule for listing records (empty string = public, None = superusers only).
view_ruleNoAPI rule for viewing a single record.
create_ruleNoAPI rule for creating records.
delete_ruleNoAPI rule for deleting records.
update_ruleNoAPI rule for updating records.

Output Schema

NameRequiredDescriptionDefault
idYes
nameYes
typeYesCollection type: 'base', 'auth', or 'view'.
fieldsYes
systemYes
indexesYes
listRuleNo
viewRuleNo
createRuleNo
deleteRuleNo
updateRuleNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden and falls well short. It does not say that creation is a persistent, schema-altering mutation, what permissions are needed, whether it fails on duplicate names, or what errors surface for invalid rule expressions. Only the schema's 'must be unique' note partially covers failure behavior.

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

Conciseness4/5

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

A single short, front-loaded sentence with no filler or redundancy. It could carry more substance without bloat, but nothing in it is wasted.

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

Completeness2/5

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

An output schema exists, so return values need not be explained, but this is a nine-parameter schema-mutating operation with zero annotations and the description gives no permission, failure, or side-effect context. An agent would need to infer too much before calling it safely.

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

Parameters3/5

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

Schema description coverage is 100%, so all nine parameters, including the None-vs-empty-string rule semantics, are already documented in the schema. The description only echoes 'fields and API rules', adding no meaning beyond that, so the baseline 3 applies.

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

Purpose4/5

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

States a specific verb and resource (create a new collection) plus the two main content areas (fields and API rules), so an agent knows exactly what operation this performs. It does not differentiate from sibling update_collection or delete_collection beyond the implicit 'new', but the verb is unambiguous.

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

Usage Guidelines2/5

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

No explicit guidance about when to use this versus update_collection, no prerequisites (e.g. auth level required to define API rules), and no note about what to do if the collection already exists. Only the word 'new' hints at the create-vs-update distinction.

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