Require Approval • AI Agent SDK
require_approval: Decorator to mark a tool as requiring human approval.
require_approval
Function
</div>
This function is defined in the approval module.
Decorator to mark a tool as requiring human approval.
Signature
def require_approval(risk_level: RiskLevel) -> AnyParameters
ParamField
RiskLevelNo description available.
Returns
ResponseField
AnyThe result of the operation.
Uses
get_approval_registryreg.add_requirementaddis_already_approvedfuncis_yaml_approvedmark_approvedis_env_auto_approveis_async_contextRuntimeError
Source
View on GitHubpraisonaiagents/approval/__init__.py at line 203