***

title: set_function_includes
slug: /reference/python/agents/agent-base/set-function-includes
description: Set the complete list of remote function includes.
max-toc-depth: 3
---------------------

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

[ai-swaig-includes]: /docs/swml/reference/ai/swaig/includes

[swml-swaig-includes-reference]: /docs/swml/reference/ai/swaig/includes

[add-function-include]: /docs/server-sdks/reference/python/agents/agent-base/add-function-include

[ref-agentbase]: /docs/server-sdks/reference/python/agents/agent-base

Replace the entire list of remote SWAIG function includes at once. Each entry must
contain a `url` and a `functions` list. Invalid entries (missing required keys or
non-list `functions`) are silently dropped.

<Info>
  This maps to the SWML [`ai.swaig.includes`][ai-swaig-includes] array.
  See the [SWML SWAIG includes reference][swml-swaig-includes-reference] for details.
</Info>

<Tip>
  Use [`add_function_include()`][add-function-include]
  to append a single include without replacing existing ones.
</Tip>

## **Parameters**

<ParamField path="includes" type="list[dict[str, Any]]" required={true} toc={true}>
  List of include objects. Each object must have:

  * `url` (`str`) -- Remote SWAIG server URL
  * `functions` (`list[str]`) -- Function names to include

  Optional keys like `meta_data` are passed through unchanged.
</ParamField>

## **Returns**

[`AgentBase`][ref-agentbase] -- Returns self for method chaining.

## **Example**

```python {5}
from signalwire import AgentBase

agent = AgentBase(name="assistant", route="/assistant")
agent.set_prompt_text("You are a helpful assistant.")
agent.set_function_includes([
    {"url": "https://tools.example.com/swaig", "functions": ["lookup_order"]},
    {"url": "https://billing.example.com/swaig", "functions": ["get_invoice", "process_refund"]},
])
agent.serve()
```