Skip to main content
Glama
beel-es

BeeL MCP server

Official
by beel-es

beel_activate_by_id

Activates an existing company (NIF) in Test or Live mode to start issuing Spanish electronic invoices, handling idempotent retries and Stripe checkout when no card is on file.

Instructions

Switches an existing company (NIF) on in the mode carried in the body. The mode is always explicit and never taken from the credential's environment, so a Test key can switch a NIF on in Live. TEST is immediate and free. PROD is immediate when the account already has a card on file or an enterprise contract, and the NIF is added to the existing subscription. With no card on file it answers 402 CHECKOUT_REQUIRED, returning a checkout_url when success_url and cancel_url are supplied. Switching on in Live also requires being the billing subject of the account (403 NOT_BILLING_OWNER otherwise). Repeating the call opens no second checkout and adds no second subscription item: it returns the existing activation with already_active: true. The same Idempotency-Key sent to this route and to the nested one it replaces is the same operation, so it is replayed and never charged twice. It also cancels a pending switch-off. While that switch-off is pending the NIF is still on — it just carries an effective date — so switching it on again only removes that date, answers scheduled_deactivation_cancelled: true, and charges or credits nothing.

Endpoint: POST /v1/companies/{company_id}/activations

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bodyYes
company_idYesNIF (company) being switched on. 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 NIF you do not reach answers `403`, and so does a NIF that does not exist, so the existence of a NIF in another account is never disclosed.
idempotency_keyNoOptional idempotency key for this operation. Omit it and one is derived from the request itself, which makes a blind retry safe but also collapses a SECOND, deliberately identical operation into the first for 24 hours. Set it — to an order id, or anything unique per intended operation — whenever you mean to create something that may look identical to what you just created.
Behavior5/5

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

The description elaborates on numerous operational nuances beyond the annotations: the mode is never inferred from the environment, PROD behavior depends on card-on-file, errors like 402 and 403, idempotency (no second checkout/charge, already_active flag), and the ability to cancel a pending switch-off. This is far more than the simple flags (readOnlyHint=false, destructiveHint=false) provide. The only discrepancy is with idempotentHint=false, but the description accurately explains the actual idempotent-like 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?

The description is lengthy but each paragraph covers a distinct aspect: core operation, mode behavior, idempotency, and switch-off cancellation. The first sentence front-loads the main purpose. While it is thorough, it could be condensed without losing essential detail; it is not overly verbose but is on the edge of being long. Therefore, a 4 is appropriate.

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?

The tool has no output schema, so the description takes full responsibility for conveying expected outcomes. It covers success indicators (already_active, scheduled_deactivation_cancelled), error conditions (402, 403), and payment/checkout flow. It also explains the interplay with the nested route and idempotency. No critical behavioral aspect seems missing for an agent to call it correctly.

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 the schema already includes detailed descriptions (coverage 67%), the description adds substantial meaning: it explains why 'environment' must be explicit and its impact on AEAT registration, the derivation and behavior of 'idempotency_key' (auto-generated vs. explicit, 24-hour collapse), and the purpose of 'success_url'/'cancel_url' including why plain string format is necessary. These insights go well beyond the schema definitions.

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 specific verb and resource: 'Switches an existing company (NIF) on'. It clearly states the action and distinguishes it from the opposite operation (deactivation, evidenced by the sibling 'beel_deactivate_by_id'). The mode is explicitly clarified as being carried in the body, adding precision. This leaves no ambiguity about what the tool does.

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 contextual guidance: it explains the immediate vs. checkout-required behavior for TEST vs. PROD, the billing-subject requirement, and the cancellation of pending switch-offs. These conditions imply when the tool is appropriate. It does not explicitly name alternatives to avoid using, but the tool's role is clear given the sibling list. The guidance is sufficient but not as explicit as a 'use this when...' directive.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/beel-es/beel-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server