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

# record • AI Agent SDK

> record: Record a restart at ``now`` and return whether the breaker tripped.

# record

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

> This is a method of the [**RestartLoopGuard**](../classes/RestartLoopGuard) class in the [**protocols**](../modules/protocols) module.

Record a restart at `now` and return whether the breaker tripped.

## Signature

```python theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
def record(now: float) -> bool
```

## Parameters

<ParamField query="now" type="float" required={true}>
  A monotonic timestamp for this restart event.
</ParamField>

### Returns

<ResponseField name="Returns" type="bool">
  `True` when at least `max_restarts` restarts have occurred
  within the trailing `window_seconds` (breaker tripped);
  `False` otherwise.
</ResponseField>

## Source

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