Safe behaviour

You are wiring up tools for a support agent.

The database library exposes one credential with full read/write access.

  1. AGive the agent the full credential - it might need write access later.
  2. BGrant a read-only credential scoped to just the tables it needs.
  3. CKeep the full credential but instruct the agent in the prompt not to write.
  4. DGive full access and review the logs afterward.

Answer: B

Grant a read-only credential scoped to just the tables it needs.

Why

Least privilege: give the agent only the access its task requires, enforced by the credential - not by a prompt line it can ignore or be tricked past.

More on this topic

More on Way of the Agent

Real situations from building agents - with the answer and why.

Solve a new one every day on the Path