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

# attempt_store

```python theme={null}
from intuned_runtime import attempt_store

attempt_store: Store
```

A key-value store scoped to the current attempt. Use it to pass initialized dependencies from hooks to your automation code, or to share data between different parts of your automation. The store is cleared when the attempt ends.

Unlike `persistent_store`, which persists across runs, `attempt_store` is temporary and only available during the current execution. It can store any Python object, not just JSON-serializable data—making it ideal for sharing initialized objects, clients, or context across your automation.

## Common use cases

**Sharing context** — Store initialized dependencies, loggers, API clients, or configuration objects that you want to access from multiple functions without passing them as arguments. Set them up in a [hook](/main/01-learn/recipes/setup-hooks) and retrieve them in your automation—useful for libraries like [Stagehand](/main/04-integrations/stagehand) or [Browser Use](/main/04-integrations/browser-use).

**Sharing data within an automation** — Store intermediate results that you need to access later in the same execution.

## `Store`

```python theme={null}
class Store:
    def get(self, key: str, default: Any = None) -> Any: ...
    def set(self, key: str, value: Any) -> None: ...
```

## Method reference

### get

```python theme={null}
def get(self, key: str, default: Any = None) -> Any: ...
```

Retrieve a value from the attempt store.

**Parameters**

<ParamField body="key" type="str" required>
  The key to retrieve the value for.
</ParamField>

<ParamField body="default" type="Any" default="None" optional>
  The default value to return if the key is not found.
</ParamField>

**Returns**

Returns the value associated with the key, or `default` if not found.

### set

```python theme={null}
def set(self, key: str, value: Any) -> None: ...
```

Store a value in the attempt store.

**Parameters**

<ParamField body="key" type="str" required>
  The key to set the value for.
</ParamField>

<ParamField body="value" type="Any" required>
  The value to store.
</ParamField>

**Returns**

Returns `None`.

## Related

* [Setup hooks recipe](/main/01-learn/recipes/setup-hooks) — Learn how to initialize dependencies in hooks.
* [Stagehand integration](/main/04-integrations/stagehand) — Using Stagehand with attempt\_store.
* [Browser Use integration](/main/04-integrations/browser-use) — Using Browser Use with attempt\_store.
