Skip to main content
Glama
JoseAlmeida-Ploomes

Ploomes MCP Server

salvar_modelo_proposta

Create or update a proposal, sale, or document template in Ploomes CRM. Manages HTML content, margins, and page setup for automated PDF generation.

Instructions

    Criar ou atualizar um modelo de Proposta/Venda/Documento (PVD) no Ploomes CRM.

    Passe o ID (DocumentTemplateId) para atualizar um modelo existente.

    Observações (revisadas a partir de captura real de rede do app Ploomes
    ao criar um modelo em Configurações > Modelos de proposta):
        1. entidade_id (EntityId): obrigatório ao criar um modelo novo. Use
           buscar_campos_entidades ou buscar_schema para descobrir o EntityId
           de Proposta (Quotes), Venda (Orders), Documento do Negócio ou
           Documento do Cliente.
        2. O Formulário (Form) do modelo é criado automaticamente pelo
           Ploomes ao criar o DocumentTemplate (o próprio app não cria um
           Form à parte antes). Não crie um Form manualmente — informe
           form_id apenas se quiser reaproveitar um formulário já existente.
        3. O conteúdo do PDF (cabeçalho/rodapé/corpo HTML e margens) vive
           dentro de "páginas" do modelo (Pages), não em campos soltos do
           DocumentTemplate. Ao criar um modelo sem pagina_id, este tool
           cria a primeira página automaticamente ("Seção 1", margens de
           20mm) com o HTML informado. Para editar uma página existente,
           informe pagina_id (Id dentro de Pages — consulte
           buscar_templates_documentos com $expand=Pages).
        4. Ao atualizar (id informado) sem pagina_id, cabecalho_html/
           rodape_html/corpo_html/margens são ignorados (não há como saber
           qual página alterar) e o tool retorna erro pedindo pagina_id.
        5. Depois de criado, use salvar_secao_formulario_proposta e
           salvar_campo_formulario_proposta para montar os campos do
           formulário do modelo (o que o usuário preenche ao gerar a PVD).
        6. Blocos de produto (grupo repetível de itens da proposta): o
           formulário do modelo é DERIVADO pelo Ploomes a partir do parsing
           do HTML salvo em corpo_html (Pages[].BodySourceCode) — não existe
           endpoint de "criar campo de bloco" isolado. Depois de criar o
           modelo aqui, use montar_bloco_produtos_proposta para inserir o
           bloco de Produtos no HTML da página automaticamente. Bloco de
           parcelas ainda não tem ferramenta equivalente.
        7. margem_topo/margem_rodape/margem_lateral são em mm e afetam o PDF,
           não o HTML.
        8. cabecalho_html/rodape_html/corpo_html aceitam código HTML com
           referências a campos (ex.: [Negócio.Título]) — veja um modelo
           existente com buscar_formulario_proposta como referência.
        9. Confirme o resultado com buscar_templates_documentos e
           buscar_formulario_proposta após salvar, e valide numa conta de
           sandbox antes de usar em produção — parte dos campos desta
           entidade têm documentação de API incompleta.
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNo
nomeYes
padraoNo
form_idNo
pagina_idNo
corpo_htmlNo
entidade_idNo
margem_topoNo
nome_paginaNo
rodape_htmlNo
altura_rodapeNo
margem_rodapeNo
tem_paginacaoNo
cabecalho_htmlNo
margem_lateralNo
altura_cabecalhoNo
ordenacao_paginaNo
equipes_permitidasNo
usuarios_permitidosNo
campo_valor_parcelasNo
formula_nome_arquivoNo
parcelas_obrigatoriasNo
variaveis_nome_arquivoNo
Behavior5/5

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

With no annotations provided, the description carries full transparency burden. It discloses that the tool automatically creates a first page if pagina_id is not provided, that updating without pagina_id returns an error, that margins are in mm, and that HTML can contain field references. It also notes API documentation incompleteness and recommends sandbox testing. No contradictions with annotations exist.

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 (9 bullet points) but each point contributes value, explaining complex behaviors and prerequisites. It is front-loaded with the main purpose and then structured as numbered observations. While effective, it could be slightly more concise without losing clarity. A 4 reflects good structure with minor redundancy.

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

Completeness4/5

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

Given 23 parameters, no output schema, and no annotations, the description covers the essential complexity: creating/updating templates, automatic page creation, form building workflow, and references to sibling tools. It warns about incomplete documentation and suggests verification steps. However, not every parameter is explained, and return values are not described (though no output schema exists). This is comprehensive but not exhaustive, earning a 4.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate. The observations explain key parameters like entidade_id, form_id, pagina_id, corpo_html, and margin settings, adding meaning beyond the raw schema. However, not all 23 parameters are individually described (e.g., variaveis_nome_arquivo, parcelas_obrigatorias are not explained). The coverage is high but not exhaustive, justifying a score of 4.

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 the tool creates or updates a 'modelo de Proposta/Venda/Documento (PVD)' in Ploomes CRM. It specifies that passing an ID updates an existing model, which distinguishes it from sibling tools like 'excluir_modelo_proposta'. The verb 'Criar ou atualizar' and resource 'modelo de Proposta/Venda/Documento' are specific and unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides extensive usage guidance, including when to use each parameter (e.g., entidade_id required for new models, form_id only for reusing existing forms). It references sibling tools (buscar_campos_entidades, salvar_secao_formulario_proposta, montar_bloco_produtos_proposta) for follow-up actions. It also warns against manually creating a Form and advises checking results with buscar_templates_documentos. This covers when-to-use, when-not-to-use, and alternatives, meeting the highest standard.

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/JoseAlmeida-Ploomes/ploomes-mcp'

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