REST API
ThingsBoard Edge runs the same REST API server as ThingsBoard CE.
Most endpoints are identical — Edge adds two controllers specific to edge instance management: edge-controller and edge-event-controller.
Swagger UI
Section titled “Swagger UI”Access the interactive API reference on your Edge instance at:
http://localhost:8080/swagger-ui.htmlIf you are already logged into the ThingsBoard Edge UI, Swagger UI authenticates automatically using your session.
Authentication
Section titled “Authentication”API key (recommended)
Section titled “API key (recommended)”Pass the API key in the X-Authorization header:
X-Authorization: ApiKey YOUR_API_KEY_VALUEAPI keys are long-lived, require no login, and can be revoked through the ThingsBoard Edge UI.
JWT token (deprecated)
Section titled “JWT token (deprecated)”Obtain an access token by sending credentials to the login endpoint:
curl -X POST -H 'Content-Type: application/json' \ -d '{"username":"[email protected]", "password":"tenant"}' \ 'http://localhost:8080/api/auth/login'Response:
{"token":"YOUR_JWT_TOKEN", "refreshToken":"YOUR_JWT_REFRESH_TOKEN"}Use the token in subsequent requests:
X-Authorization: Bearer YOUR_JWT_TOKENAccess tokens are valid for 2.5 hours; refresh tokens for one week.
API capabilities
Section titled “API capabilities”The Attributes API, Time Series API, and RPC API work identically to CE — the same request paths, parameters, and response formats. For full examples and parameter references, see the CE REST API reference.
For the full list of available controllers grouped by category, see the Controller Reference.