Skip to main content
Glama
BeeL MCP server

BeeL MCP server

Official
by beel-es

beel_update_email_configuration

DestructiveIdempotent

Updates the sender and optional defaults for a company's invoice emails, replacing omitted values with defaults and returning the resulting configuration.

Instructions

Replaces the sender chosen for the invoice emails of the company, and optionally their defaults. It does not affect other emails. The sender is a replacement, not a merge: a property that is omitted or null goes back to its default, which is to inherit the default email domain of the account and to use facturas as the local_part. The response is the configuration as it is after the change, including the address in effect.

  • sender.source: when omitted it is EMAIL_DOMAIN if email_domain_id is sent and ACCOUNT_DEFAULT otherwise. email_domain_id is accepted only with EMAIL_DOMAIN, and local_part is not accepted with BEEL: any other combination answers 422 VALIDATION_ERROR.

  • defaults: omitted, the stored defaults stay as they are. null removes them. An object replaces all of them, so a property left out of it is removed. Sending an object requires the email customization plan: without it the call answers 403 FEATURE_NOT_AVAILABLE, and the sender is not changed. The templates accept the variables listed by GET /v1/email-template-variables.

  • email_domain_id: an email domain of the account that has already been registered. A domain that does not exist, belongs to another account or was removed answers 404 EMAIL_DOMAIN_NOT_FOUND; one that is still being registered answers 409 EMAIL_DOMAIN_NOT_READY. Choosing a domain that is not verified is allowed: until it is verified, invoice emails go out from the default email domain of the account if that one is verified, and from BeeL. otherwise.

  • local_part: up to 64 characters: lowercase letters, digits and the symbols !#$%&'*+/=?^_\{|}~-, with single dots between groups. Any other value answers 422 VALIDATION_ERROR`.

  • Removed email domains: when the email domain a company chose is removed, the company goes back to ACCOUNT_DEFAULT and keeps its local_part.

  • Credentials: it changes the address real invoices are sent from, so it requires a live API key and the companies:write scope. A test API key answers 403 LIVE_CREDENTIAL_REQUIRED. Send an Idempotency-Key so a retry does not repeat the operation.

  • Environment: the configuration belongs to the company and is the same in test and live.

BeeL API endpoint: PUT /v1/companies/{company_id}/email-configuration (reference: https://docs.beel.es)

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "company_id": "<company_id>",
      "body": "<body>"
    },
    "name": "beel_update_email_configuration"
  }
}

Input Schema

NameRequiredDescriptionDefault
bodyYes
company_idYesUnique identifier (UUID) of the company the operation acts on: its identifier, not its NIF. It is the only source of context: the account that owns it is derived from it, and the `BeeL-Active-Company` header plays no part. A company you do not reach answers `403`, and so does a company that does not exist, so the existence of a company in another account is never disclosed.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.12.0

TDQS

A4.7/5.0
Behavior5/5

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

Well beyond the annotations, the description spells out replacement (not merge) semantics, that omitted or null properties revert to defaults, that an object replaces all stored defaults, that a missing plan yields 403 FEATURE_NOT_AVAILABLE without changing the sender, and the exact 404/409/422 failure modes for domains and local_part. It also discloses credential requirements, idempotency guidance, and that the configuration is identical in test and live, which is exactly the operational context an agent needs before a destructive write.

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?

The critical replacement semantics and scope limit are front-loaded in the first two sentences, then organized into labelled bullets that keep a dense description navigable. It is long, and the 'Removed email domains' bullet describes an event outside this call rather than behavior of the call itself, but overall the material earns its space.

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 destructive, nested-object mutation with no output schema, the description covers the return value ('the configuration as it is after the change, including the address in effect'), auth requirements, idempotency, error codes, and environment scoping. An agent has everything needed to call it correctly without opening the schema.

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?

With only 50% schema coverage, the description carries the load and does so: it documents source defaulting (EMAIL_DOMAIN when email_domain_id is sent, ACCOUNT_DEFAULT otherwise), the illegal combinations that trigger 422, the local_part character and length rules, and the all-or-nothing behavior of the defaults object. These are cross-field rules the schema cannot express on its own.

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 opening sentence gives a specific verb and resource ('Replaces the sender chosen for the invoice emails of the company, and optionally their defaults') and immediately bounds the scope with 'It does not affect other emails', which separates it from the tax, verifactu and invoice-customization siblings. The endpoint line (PUT /v1/companies/{company_id}/email-configuration) removes any remaining ambiguity about what is being written.

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?

Usage context is clear: it is the write counterpart that changes the live invoice sender, requires a live API key plus the companies:write scope, and should carry an Idempotency-Key. It never explicitly names a read alternative such as beel_get_email_configuration or states when to prefer it, and there is no explicit when-not-to-use clause beyond the plan/credential restrictions, so it stops short of full routing guidance.

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

Deploy Server

Other Tools