DF0014: Invalid Agent Field

RPC function "{name}" has an invalid agent field: description must be a non-empty string.

Message

RPC function "{name}" has an invalid agent field: description must be a non-empty string.

Cause

An RPC function opts into agent exposure with an agent field, but its required description is missing or empty. Agents rely on the description to decide when to invoke a tool.

Example

defineRpcFunction({
  name: 'rolldown-get-session-summary',
  type: 'query',
  agent: {
    description: '', // ❌ empty
  },
  // ...
})

Fix

Provide a non-empty description (~1–3 sentences) explaining what the tool does and when agents should invoke it, or remove the agent field to keep it RPC-only.

defineRpcFunction({
  name: 'rolldown-get-session-summary',
  type: 'query',
  agent: {
    description: 'Summarize a Rolldown build session by its id. Safe to call freely.',
  },
  // ...
})

Source