Skip to main content
Glama

Notsy Facturación

emitir_cfdi

Emite y timbra un CFDI 4.0 OFICIAL ante el SAT (acción real, con costo y difícil de revertir). Llama primero a preview_factura. El motor aplica los límites de la API key (puede requerir aprobación humana) y registra la acción en la bitácora.

Args: iguales a preview_factura, más:
    observaciones: texto libre opcional en el CFDI.
    anticipo_id: opcional, id de un anticipo previo a aplicar (relación 07 + nota de crédito).
    idempotency_key: OBLIGATORIA en producción (genera un UUID por operación y reúsalo en
        los reintentos). Si reintentas con la misma clave, NO se timbra de nuevo: se
        devuelve el resultado original (evita CFDIs duplicados ante el SAT).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
clienteNo
conceptosYes
emisor_idNo
cliente_idNo
forma_pagoNo03
anticipo_idNo
metodo_pagoNoPUE
observacionesNo
idempotency_keyNo

TDQS

A4.2/5.0
Behavior5/5

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

No annotations provided, so description carries full burden. It discloses real action with cost, difficulty to revert, logging, human approval possibility, and idempotency behavior (no duplicate stamping). This is comprehensive and exceeds minimum.

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?

Description is well-structured with a purpose paragraph followed by parameter list. Front-loaded with important caveats. Slightly long but every sentence serves a purpose.

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

Completeness3/5

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

Given complexity (9 params, no output schema), description covers key behavioral traits but lacks full parameter detail and return value explanation. Relies on sibling tool for base args, which may not be self-contained.

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 coverage is 0%, so description must compensate. It explains three new parameters (observaciones, anticipo_id, idempotency_key) but relies on referencing 'preview_factura' for the rest. This adds value but leaves some parameters unexplained in isolation.

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 clearly states it 'Emite y timbra un CFDI 4.0 OFICIAL ante el SAT' with explicit mention of cost and difficulty to revert. It distinguishes itself from sibling 'preview_factura' by noting it's the actual action, not a preview.

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?

It explicitly instructs users to call 'preview_factura' first, and mentions API key limits, human approval, and idempotency key for retries. This provides clear usage context, though it does not explicitly list when to avoid using this 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.4/5.0
Disambiguation5/5

Each tool has a clearly distinct purpose: preview_factura is a dry-run, emitir_cfdi actually timbres, resolver_claves_sat finds SAT keys, and whoami checks identity. No overlap in functionality.

Naming Consistency4/5

Most tools follow a Spanish verb_noun pattern (emitir_cfdi, resolver_claves_sat), but preview_factura uses an English verb and whoami is a Unix command, introducing minor inconsistency.

Tool Count5/5

With only 4 tools, the set is well-scoped for a focused invoicing server: preview, emit, key resolution, and authentication. Each tool earns its place without bloat.

Completeness3/5

The core workflow (preview and emit CFDI) is covered, but the server lacks operations for canceling CFDIs, listing past emissions, or managing clients/anticipos, which are part of a full invoicing lifecycle.

Resources