> 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/license.md).

# License

Upload and download DroneBridge license files

## Download the currently loaded license file

> Returns the raw binary license file as an octet stream. The \`Content-Disposition\` header will contain a filename derived from the activation key encoded in Base64, e.g. \`attachment; filename="ABCD1234.dlselic"\`.<br>

```json
{"openapi":"3.0.3","info":{"title":"DroneBridge ESP32 REST API","version":"1.0.0"},"tags":[{"name":"License","description":"Upload and download DroneBridge license files"}],"servers":[{"url":"http://192.168.2.1","description":"Default ESP32 AP address"}],"paths":{"/api/license":{"get":{"tags":["License"],"summary":"Download the currently loaded license file","description":"Returns the raw binary license file as an octet stream. The `Content-Disposition` header will contain a filename derived from the activation key encoded in Base64, e.g. `attachment; filename=\"ABCD1234.dlselic\"`.\n","operationId":"downloadLicense","responses":{"200":{"description":"Binary license file","headers":{"Content-Disposition":{"description":"Suggested filename for the downloaded file","schema":{"type":"string"}}},"content":{"application/octet-stream":{"schema":{"type":"string","format":"binary"}}}},"500":{"description":"Failed to encode activation key to Base64"}}}}}}
```

## Upload and activate a license file

> Accepts a raw binary license file. Example cURL invocation: \`curl -X POST -H "Content-Type: application/octet-stream" --data-binary @license.dlselic <http://192.168.2.1/api/license\\`><br>

```json
{"openapi":"3.0.3","info":{"title":"DroneBridge ESP32 REST API","version":"1.0.0"},"tags":[{"name":"License","description":"Upload and download DroneBridge license files"}],"servers":[{"url":"http://192.168.2.1","description":"Default ESP32 AP address"}],"paths":{"/api/license":{"post":{"tags":["License"],"summary":"Upload and activate a license file","description":"Accepts a raw binary license file. Example cURL invocation: `curl -X POST -H \"Content-Type: application/octet-stream\" --data-binary @license.dlselic http://192.168.2.1/api/license`\n","operationId":"uploadLicense","requestBody":{"required":true,"content":{"application/octet-stream":{"schema":{"type":"string","format":"binary","description":"Raw binary license key file (.dlselic)"}}}},"responses":{"200":{"description":"Activation attempted; check `success` field for result","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LicenseUploadResponse"}}}},"400":{"description":"Content-Length is 0 or exceeds the size of the license key","content":{"text/plain":{"schema":{"type":"string"}}}},"408":{"description":"Receive timeout while uploading the file"},"500":{"description":"Server-side memory allocation failure","content":{"text/plain":{"schema":{"type":"string"}}}}}}}},"components":{"schemas":{"LicenseUploadResponse":{"type":"object","properties":{"success":{"type":"boolean","description":"Whether the license was activated successfully"},"message":{"type":"string","description":"Human-readable success message (only present on success)"},"type":{"type":"string","description":"License type string (only present on success)"},"expiration":{"type":"string","description":"Expiration date string (only present on success)"},"error":{"type":"string","description":"Error message (only present on failure)"}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://dronebridge.gitbook.io/docs/dronebridge-for-esp32-drone-light-show-edition/developers-dlse-api-definition/license.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
