> For the complete documentation index, see [llms.txt](https://dronebridge.gitbook.io/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dronebridge.gitbook.io/docs/dronebridge-for-esp32-drone-light-show-edition/developers-dlse-api-definition/clients.md).

# Clients

Manage active UDP client connections

## Add a UDP client connection

> Registers a new UDP destination (IPv4 address + port). The ESP32 will start forwarding serial data to this endpoint immediately. Optionally persists the entry to NVM so it survives reboots.<br>

```json
{"openapi":"3.0.3","info":{"title":"DroneBridge ESP32 REST API","version":"1.0.0"},"tags":[{"name":"Clients","description":"Manage active UDP client connections"}],"servers":[{"url":"http://192.168.2.1","description":"Default ESP32 AP address"}],"paths":{"/api/settings/clients/udp":{"post":{"tags":["Clients"],"summary":"Add a UDP client connection","description":"Registers a new UDP destination (IPv4 address + port). The ESP32 will start forwarding serial data to this endpoint immediately. Optionally persists the entry to NVM so it survives reboots.\n","operationId":"addUdpClient","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UdpClientRequest"}}}},"responses":{"200":{"description":"Result of the add operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusResponse"}}}},"400":{"description":"Request body too large","content":{"text/plain":{"schema":{"type":"string"}}}},"500":{"description":"Internal server error while receiving data","content":{"text/plain":{"schema":{"type":"string"}}}}}}}},"components":{"schemas":{"UdpClientRequest":{"type":"object","required":["ip","port"],"properties":{"ip":{"type":"string","format":"ipv4","description":"IPv4 address of the UDP destination"},"port":{"type":"integer","minimum":1,"maximum":65535,"description":"UDP destination port"},"save":{"type":"boolean","description":"If `true`, persist this client to NVM so it is restored after a reboot. Only one entry can be persisted at a time.\n","default":false}}},"StatusResponse":{"type":"object","description":"Generic status/message response used by several endpoints","properties":{"status":{"type":"string","enum":["success","failed"]},"msg":{"type":"string"}}}}}}
```

## Remove all UDP client connections

> Clears the entire in-memory UDP client list and erases the single persisted UDP client from NVM. Ground-control software will need to re-register after this call.<br>

```json
{"openapi":"3.0.3","info":{"title":"DroneBridge ESP32 REST API","version":"1.0.0"},"tags":[{"name":"Clients","description":"Manage active UDP client connections"}],"servers":[{"url":"http://192.168.2.1","description":"Default ESP32 AP address"}],"paths":{"/api/settings/clients/clear_udp":{"delete":{"tags":["Clients"],"summary":"Remove all UDP client connections","description":"Clears the entire in-memory UDP client list and erases the single persisted UDP client from NVM. Ground-control software will need to re-register after this call.\n","operationId":"clearUdpClients","responses":{"200":{"description":"All UDP clients removed successfully","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusResponse"}}}}}}}},"components":{"schemas":{"StatusResponse":{"type":"object","description":"Generic status/message response used by several endpoints","properties":{"status":{"type":"string","enum":["success","failed"]},"msg":{"type":"string"}}}}}}
```
