> ## Documentation Index
> Fetch the complete documentation index at: https://praison.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Model Request Blocked • AI Agent SDK

> ModelRequestBlocked: Raised when a real model request is attempted while requests are blocked.

# ModelRequestBlocked

> Defined in the [**guard**](../modules/guard) module.

<Badge color="blue">AI Agent</Badge>

Raised when a real model request is attempted while requests are blocked.

Derives from `BaseException` on purpose: the agent's tool loop catches
`Exception` broadly and turns failures into a `None` answer, which would
hide exactly the leak this guard exists to expose.

Attributes:
model: The model id the blocked request named, if known.
provider: The request path that was blocked (e.g. `"litellm.completion"`).
call\_site: `"&lt;file&gt;:&lt;line&gt; in &lt;function&gt;"` for the outermost caller
outside praisonaiagents, i.e. the line in your code to fix.

## Constructor

<ParamField query="message" type="str" required={true}>
  No description available.
</ParamField>

## Source

<Card title="View on GitHub" icon="github" href="https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai-agents/praisonaiagents/model_harness/guard.py#L93">
  `praisonaiagents/model_harness/guard.py` at line 93
</Card>
