route.output_mismatch
Route output is not exactly what it runs returns.
Area 7, HTTP; not declinable; the next step is usually the agent's.
output: is exactly what the route runs returns:
type Memo = Text { max_length: 200}type MemoId = Uuid {}type AddMemo = Input { text: Memo}type MemoView = Output { text: Memo}action add_memo(input: AddMemo) -> MemoView { return MemoView { text: input.text }}type MemoSummary = Output { text: Memo}routes Memos { prefix: /memos POST / { input: AddMemo output: MemoSummary run: add_memo(input) }}
error POST /memos sends MemoSummary, but add_memo returns MemoView
--> main.jadpo:30:17
|30 | output: MemoSummary | ^^^^^^^^^^^ not `MemoView`
- reason
- A route's
output:is exactly what it runs returns, so the route shows its contract and never sends a field its type doesn't declare. - next
- Write
output: MemoView(agent) - rule
- route.
output_ mismatch - help
- https://jadpo.
dev/docs/errors/route. output_ mismatch
Markdown for agents: /docs/errors/route.output_mismatch.md.Built from Jadpo main at aee2e8f.