Skip to main content
Glama

Cadastro de funcionário

cadastrar_funcionario

Funcionários da fazenda — operadores, tratoristas, aplicadores —, que depois entram na execução de OS e no abastecimento. Nome repetido na fazenda é recusado: é pelo nome que a UPí acha o funcionário. Equipes são montadas pelo portal.

Recebe uma LISTA (até 50 por chamada): mande tudo o que o usuário ditou de uma vez. Sem id inclui; com id altera só os campos informados; com id e desativar desativa. É tudo ou nada: se um item for recusado, NENHUM é gravado, e a resposta diz qual item e por quê. Nome repetido é recusado com o id do que já existe — pergunte se é para alterar.

GRAVA no upCampo. Mostre ao usuário a lista do que será gravado e confirme antes de chamar.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
itensYesOs itens a gravar.
fazendaNoNome da fazenda. Omita para usar a fazenda corrente do usuário — é o padrão, e é o que o usuário espera quando não cita nenhuma. Informe apenas quando ele nomear outra fazenda. Cada consulta trata de uma fazenda por vez.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
avisosNo
fazendaYes
gravadoYes
retornoYes
mensagemYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.4/5.0
Behavior5/5

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

Annotations only flag it as a non-read-only, non-destructive, non-idempotent write. The description goes well beyond that: all-or-nothing transaction semantics with per-item rejection reporting, duplicate-name rejection returning the existing id, name as the identity key used by UPí, team assembly happening elsewhere, and an explicit confirmation workflow. This is rich behavioral context the annotations cannot convey.

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?

Well front-loaded: purpose first, then batch/transaction rules, then persistence target and confirmation. The double emphasis on 'nome repetido' (once in the intro, once in the batch paragraph) is slightly redundant, but overall it is tight and every paragraph earns its place.

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?

Covers purpose, batching limit, transaction semantics, error reporting, duplicate handling, persistence target (upCampo), and the required user confirmation. With an output schema present, return values need not be explained. Nothing an agent needs to invoke this correctly is missing.

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 description coverage is 100%, so the schema already documents each field (id, nome, codigo, desativar, valor_hora, fazenda). The description reinforces the 'id excludes/includes/alters/desactivates' semantics and the fazenda default, adding moderate value but largely mirroring the schema. Baseline 3 is appropriate.

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?

Names the specific resource (funcionários da fazenda) and the concrete roles it covers, plus the downstream flows it feeds (execução de OS, abastecimento). Clearly distinguished from the many cadastrar_* siblings by being the only one dealing with people.

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?

Gives strong operational guidance: batch up to 50, send everything the user dictated at once, show the list and confirm before calling. Implies when to use 'id' vs no 'id'. However it does not explicitly name the sibling to use for lookup (consultar_cadastros is referenced only inside the schema description of 'id', not in the tool description).

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.

Resources