Skip to main content
Glama

Get schema

well_get_schema
Read-only

Discover available data types and fields.

USAGE:

  • well_get_schema() → List ALL available roots, including the accounting graph (ledger_accounts, journals, journal_entries) plus account_balances, tax_rates, exchange_rates — query these for real financial statements (compte de résultat / balance sheet) instead of reconstructing them from raw invoices

  • well_get_schema({ root: "invoices" }) → List all available fields for invoices

WORKFLOW:

  1. Call well_get_schema(root) to see available fields

  2. Pick the fields you need for your task (typically 5-15)

  3. Call well_query_records with those specific fields

Returns fields with path, type, and (when documented) semantic context:

  • { path: "invoices.grand_total", type: "numeric", context: "Total invoice amount incl. tax in the document currency...", enrichment: "AI extraction" } → use _eq, _gt, _lt, etc.

  • { path: "invoices.local_currency", type: "enum" } → use ONLY _eq, _neq, _in, _nin, _is_null

  • { path: "invoices.issuer.name", type: "text" } → use _eq, _like, _ilike, etc.

  • "context" (when present) explains what the field MEANS in the domain and how it's used — read it to pick the right field and write correct filters.

  • "enrichment" (when present) is the value's provenance (e.g. "Bank sync", "AI extraction", "System generated", "Derived", "Manual"). Use the type to choose the right whereClause operators in well_query_records. To use in well_query_records, convert path to array: "invoices.issuer.name" → ["invoices", "issuer", "name"]

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
rootNoEntity root to inspect. Omit to list every available root (call well_get_schema() with no argument first). Includes the accounting graph (ledger_accounts, journals, journal_entries) alongside companies, invoices, transactions, accounts, and more.
depthNoRelationship depth: 0=scalars only, 1=direct relations (default), 2=nested, 3=level-3 graph
workspace_idNoTarget workspace. Optional: this tool describes the token itself rather than one workspace's data, so omitting it returns the same answer.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
rootNo
errorNo
rootsNo
totalNo
fieldsNo
successYes

TDQS

A4.9/5.0
Behavior5/5

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

Annotations already mark this as read-only and non-destructive, and the description adds meaningful behavioral detail: it returns fields with path, type, context, and enrichment provenance; explains that context helps pick the correct field and filters; and notes that workspace_id is irrelevant because the tool describes the token itself rather than workspace data. This goes well beyond the structured 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 well structured with USAGE, WORKFLOW, and return-format sections, and it front-loads the core purpose first. Every section earns its place, including the practical examples and the note about converting paths for well_query_records. It is dense but not padded.

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

Completeness5/5

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

For a schema-discovery tool with zero required parameters and an output schema, the description covers everything an agent needs: what roots to expect, how to invoke with or without a root, how to use the returned field metadata, how to map types to query operators, and how to translate paths for well_query_records. No critical guidance is missing.

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?

The input schema already provides 100% coverage for all three parameters, including root, depth, and workspace_id semantics. The description adds extra value with concrete root examples, the accounting-graph hint, operator selection by type, and path-to-array conversion. It does not add much beyond the schema for depth, but the schema already documents that sufficiently.

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 opens with a clear verb+resource statement: 'Discover available data types and fields,' then concretely demonstrates both invocation forms—no argument for all roots and with a root for field lists. It clearly distinguishes this tool from well_query_records by positioning it as the discovery step that feeds query construction.

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

Usage Guidelines5/5

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

The description provides an explicit WORKFLOW: call well_get_schema(root) first, select 5-15 fields, then call well_query_records. It also gives domain guidance, such as using the accounting graph for real financial statements instead of reconstructing them from raw invoices. This is specific, actionable, and tells the agent exactly when and how to use the tool.

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.

TDQS

A4.5/5.0
Disambiguation5/5

Each tool has a clearly distinct purpose: CRUD for companies, people, and invoices; financial analytics (cash, cost, runway, holdings); connector management and invocation; schema discovery; querying; reconciliation; and contact channel management. No two tools could be confused for the same action.

Naming Consistency5/5

All tools follow the `well_verb_noun` pattern with consistent verb choices (create, get, list, update, delete, add, remove, run, resolve, query, invoke). The naming is predictable and makes the tool's purpose immediately clear.

Tool Count4/5

With 26 tools, the set is slightly above the ideal 3-15 range, but every tool earns its place given the breadth of the domain (CRM, invoicing, financial analytics, reconciliation, connector management). The count is well-scoped and not excessive.

Completeness4/5

The tool surface covers core CRUD, financial KPIs, reconciliation, and connector management. Minor gaps exist (e.g., no direct tool to update contact channels or manage accounts), but the query and schema tools allow agents to work around them, and the primary workflows are fully supported.

Resources