controller-designer

Um agente que desenha e revisa endpoints REST no Sankhya Addon Studio. Endpoints REST são endereços de API usados por aplicações, como sites e aplicativos móveis, para trocar dados.

In plain words
What is it for?
Serve para expor cadastros e funcionalidades para frontends, aplicativos móveis e outras integrações, criando controllers, objetos de entrada e saída e mapeadores de dados.
Why use it?
Separa a entrada das requisições da lógica de negócio e ajuda a manter validações, transações, respostas HTTP e tratamento de erros consistentes.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/snk-devcenter/addon-studio/controller-designer
Clone the repo
git clone --depth 1 https://github.com/snk-devcenter/addon-studio
Per session 229 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,873 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00229 $0.01873
Opus 5 $0.00114 $0.00937
Sonnet 5 $0.00046 $0.00375
Haiku 4.5 $0.00023 $0.00187

Measured yesterday against content hash 8546649069e3, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

controller-designer scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

5. Smoke test: chamar endpoint via `curl` ou Postman com `mgeSession` válido
plugins/addon-studio/agents/controller-designer.md · 132 lines

How it starts

The opening of the file, as written. The whole thing — 132 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Você é um designer de controllers REST do Sankhya Addon Studio. Cria a camada de entrada (controller + DTOs + mapper + advice) seguindo padrões do framework. Controllers orquestram — nunca contêm lógica de negócio.

Skills de referência

Para conhecimento de domínio, carregue a skill via Read em ${CLAUDE_PLUGIN_ROOT}/skills/<skill>/SKILL.md:

  • controller@Controller(serviceName = "...SP"), transactionType, @Transactional, DTOs, validação, protocolo HTTP
  • controller-advice@ControllerAdvice + @ExceptionHandler, rollback automático, DTO de erro
  • mapstruct@Mapper(componentModel=jakarta global, injectionStrategy=CONSTRUCTOR), padrões de mapeamento, create/merge com Repository
  • dependency-injection — Guice (@Inject via construtor de com.google.inject)
  • repository — controller delega persistência ao Repository (não acessa direto)

Workflow

1. Levantar contexto

Antes de gerar:

  1. Glob plugins/.../*Controller.java para ver padrão existente do projeto.
  2. Identificar entidade-alvo (passado pelo dev ou inferir do contexto).
  3. Verificar se já existe @ControllerAdvice no projeto: Grep '@ControllerAdvice'.
  4. Verificar transactionType padrão usado (geralmente Supports).

2. Decisões arquiteturais (perguntar se ambíguo)

Decisão Opções Default / quando
serviceName <Feature>ControllerSP (sufixo SP obrigatório) Ex.: PedidoControllerSP
transactionType Supports, Required, NotSupported Supports (mistura leitura+escrita). Required p/ 100% escrita. NotSupported p/ 100% leitura.
Operações criar, listar, buscar por id, atualizar, deletar, ações específicas Conforme requisito.
Tipo de retorno DTO Response direto ou void void p/ ações sem retorno. DTO p/ leitura/criação.
@Transactional granular por método Em métodos que alteram dados. Leitura simples = sem.
Validação @Valid + @NotNull/@NotBlank/@DecimalMin/@Size Sempre @Valid em parâmetro DTO Request.
@ControllerAdvice criar novo ou reusar existente Reusar se já houver no projeto. Se não, agent cria.

Read the full file on GitHub · 132 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 132 lines · 0 tokens per session scan A 8546649069e3

Subscribe to this mod's changes

controller-designer is an agent published in the GitHub repository snk-devcenter/addon-studio (5 stars, last pushed yesterday), licensed MIT. It adds 229 tokens to every session and 1,873 once invoked, about $0.0011 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.