> ## 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.

# Require Approval • AI Agent SDK

> require_approval: Decorator to mark a tool as requiring human approval.

# require\_approval

<div className="flex items-center gap-2">
  <Badge color="teal">Function</Badge>
</div>

> This function is defined in the [**approval**](../modules/approval) module.

Decorator to mark a tool as requiring human approval.

## Signature

```python theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
def require_approval(risk_level: RiskLevel) -> Any
```

## Parameters

<ParamField query="risk_level" type="RiskLevel" required={false} default="'high'">
  The risk level of the tool ("critical", "high", "medium", "low")
</ParamField>

### Returns

<ResponseField name="Returns" type="Any">
  The result of the operation.
</ResponseField>

## Uses

* `APPROVAL_REQUIRED_TOOLS.add`
* `is_already_approved`
* `func`
* `is_yaml_approved`
* `mark_approved`
* `is_env_auto_approve`
* `asyncio.get_running_loop`
* `RuntimeError`
* `asyncio.run`
* `request_approval`

## Source

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