***

title: remove_directory
slug: /reference/python/agents/web-service/remove-directory
description: Remove a directory from being served.
max-toc-depth: 3
---------------------

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

Remove a directory from being served. A leading `/` is added to the route
automatically if missing. If the route is not currently mounted, this method
does nothing.

## **Parameters**

<ParamField path="route" type="str" required={true} toc={true}>
  URL path to remove (e.g., `"/audio"`).
</ParamField>

## **Returns**

`None`

## **Example**

```python {7}
from signalwire import WebService

web = WebService(
    port=8002,
    directories={"/audio": "./audio_files", "/images": "./public/images"}
)
web.remove_directory("/images")
web.start()  # Only /audio is served
```