> For a complete index of all SignalWire documentation pages, fetch https://signalwire.com/docs/llms.txt

# get_skill_data

> Read this skill instance's namespaced state from raw_data.

[ref-skillbase]: /docs/server-sdks/reference/python/agents/skill-base

Read this skill instance's namespaced state from `raw_data["global_data"]`.
Each skill instance gets an isolated namespace to prevent collisions between
multiple skills.

## **Parameters**

**`raw_data`** `dict[str, Any]` — required

The raw\_data dict passed to SWAIG function handlers.

---

## **Returns**

`dict[str, Any]` -- The skill's state, or empty dict if not found.

## **Example**

```python {3}
def _handle_query(self, args, raw_data):
    state = self.get_skill_data(raw_data)
    last_query = state.get("last_query", "none")
    return FunctionResult(f"Previous query was: {last_query}")
```