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

# remove_global_data

> Remove one or more keys from the global session data.

[functionresult]: /docs/server-sdks/reference/python/agents/function-result

Remove one or more keys from the global session data.

## **Parameters**

**`keys`** `str | list[str]` — required

A single key string or a list of key strings to remove from global data.

---

## **Returns**

[`FunctionResult`][functionresult] — self, for chaining.

## **Example**

```python {11}
from signalwire import AgentBase
from signalwire import FunctionResult

agent = AgentBase(name="my-agent", route="/agent")
agent.set_prompt_text("You are a helpful assistant.")

@agent.tool(name="clear_session_data", description="Clear session data")
def clear_session_data(args, raw_data):
    return (
        FunctionResult("Session data cleared.")
        .remove_global_data(["customer_id", "verified"])
    )

agent.serve()
```