***

title: add_section
slug: /reference/python/agents/swml-service/add-section
description: Add a new empty section to the SWML document.
max-toc-depth: 3
---------------------

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

Add a new empty section to the SWML document. Sections are named containers for
ordered lists of verbs. Every document starts with a `main` section.

## **Parameters**

<ParamField path="section_name" type="str" required={true} toc={true}>
  Name of the section to create. Must be unique within the document.
</ParamField>

## **Returns**

`bool` — `True` if the section was created, `False` if a section with that name
already exists.

## **Example**

```python {4}
from signalwire import SWMLService

service = SWMLService(name="multi-section")
service.add_section("fallback")
service.add_verb_to_section("fallback", "play", {
    "url": "https://example.com/sorry.mp3"
})
service.add_verb_to_section("fallback", "hangup", {})

print(service.render_document())
```