Diagnosticar rejeição (cStat)
bpe_diagnosticar_rejeicaoDiagnose BP-e rejection codes by returning the official reason, violated MOC rules, and corrective action from a cStat, helping users resolve SEFAZ validation errors.
Instructions
Recebe um cStat (ex.: 215, 539, 678) e retorna mensagem oficial, causa, regras violadas (grupos A–J/CI do MOC) e ação corretiva.
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": {
"cStat": "<cStat>"
},
"name": "bpe_diagnosticar_rejeicao"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cStat | Yes | ||
| xMotivo | No | xMotivo retornado (extrai complementos como [chBPe], [nProt], [Motivo]) | |
| tpEvento | No | Filtra as regras do Grupo J pelo evento |