Skip to main content
Glama
shukiv

blesta-mcp

by shukiv

Call any Blesta API method

blesta_call
Destructive

Invoke any Blesta API model method with named parameters, including nested arrays and plugin models. Automatically infers the HTTP verb when omitted.

Instructions

Escape hatch: call any public model method of the Blesta API as {model}/{method}. Parameters are passed BY NAME and must match the PHP method's argument names (see https://source-docs.blesta.com/classes/{Model}.html). Nested arrays/objects are supported (e.g. params: {"vars": {"client_id": 1, "lines": [{"description": "x", "amount": "5.00"}]}}). Plugin models use "plugin.model" (e.g. "support_manager.support_manager_tickets"). If http_method is omitted it is inferred from the method name (get*/search* -> GET, add* -> POST, edit*/set* -> PUT, delete* -> DELETE). Timestamps must include a timezone (e.g. 2026-01-31T12:00:00Z). If Blesta answers HTTP 500 'Failed to retrieve the default value', resend with every optional argument explicitly set. Any valid API key has full administrative power; prefer the purpose-built tools when one exists.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modelYesModel name in snake_case as used in the URL, e.g. clients, invoices, services, transactions, or plugin.model
methodYesPublic method name, e.g. get, getList, add, edit
paramsNoNamed arguments for the method; nested objects/arrays allowed
max_charsNoCap on returned JSON size (default 60000)
http_methodNoOverride the inferred HTTP verb

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A5/5.0
Behavior5/5

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

Annotations already signal destructive and non-idempotent behavior, but the description adds substantial behavioral context: arbitrary public methods, named-parameter binding to PHP arguments, HTTP method inference, plugin model naming, timezone requirements, a documented error-handling retry, and the warning that 'Any valid API key has full administrative power'. These traits are not visible in the annotations and materially affect invocation.

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 dense but every sentence earns its place: invocation pattern, parameter semantics, plugin naming, HTTP inference, timestamp rule, error retry, and security warning. It is front-loaded with the core usage and then layers necessary caveats, which is appropriate for an open-ended escape-hatch tool.

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?

Given the tool's deliberately open-ended nature and the absence of an output schema, the description is unusually complete: it covers how to construct model/method calls, pass parameters, handle nested data, choose HTTP verbs, format timestamps, recover from a specific server error, and understand privilege implications. An agent has enough to invoke it correctly across a wide range of Blesta methods.

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

Parameters5/5

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

Although schema coverage is 100%, the description meaningfully expands parameter semantics: it explains that parameters are passed BY NAME and must match PHP method argument names, gives a nested-array example, specifies plugin.model naming, and defines how http_method is inferred when omitted. This goes well beyond the schema's property descriptions.

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 'Escape hatch: call any public model method of the Blesta API as {model}/{method}', naming a specific verb, resource, and invocation pattern. It also explicitly distances itself from the purpose-built sibling tools by warning to 'prefer the purpose-built tools when one exists', so an agent can tell it apart.

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?

It states when to use the tool ('escape hatch'), when not to ('prefer the purpose-built tools when one exists'), and gives concrete operational guidance such as inferring HTTP method from method name, using plugin.model syntax, and resending with all optional arguments on a specific error. This is explicit selection and usage guidance beyond any schema.

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