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

# Get Recovery Action • AI Agent SDK

> get_recovery_action: Get recommended recovery action.

# get\_recovery\_action

<div className="flex items-center gap-2">
  <Badge color="purple">Method</Badge>
</div>

> This is a method of the [**DoomLoopDetector**](../classes/DoomLoopDetector) class in the [**doom\_loop**](../modules/doom_loop) module.

Get recommended recovery action.

## Signature

```python theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
def get_recovery_action() -> RecoveryAction
```

### Returns

<ResponseField name="Returns" type="RecoveryAction">
  Recommended recovery action
</ResponseField>

## Uses

* `get_loop_type`

## Used By

* [`EscalationPipeline.execute_at_stage`](../functions/EscalationPipeline-execute_at_stage)

## Source

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