133 lines
2.7 KiB
HTTP
133 lines
2.7 KiB
HTTP
### mqtt endpoints
|
|
GET http://{{host}}/api/v1/endpoints
|
|
Content-Type: application/json
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
### mqtt clients
|
|
GET http://{{host}}/api/v1/clients
|
|
Content-Type: application/json
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
### mqtt client info
|
|
GET http://{{host}}/api/v1/clients/info?clientId=123
|
|
Content-Type: application/json
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
### mqtt stats
|
|
GET http://{{host}}/api/v1/stats
|
|
Content-Type: application/json
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
### mqtt stats sse
|
|
GET http://{{host}}/api/v1/stats/sse
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
### mqtt publish
|
|
POST http://{{host}}/api/v1/mqtt/publish
|
|
Content-Type: application/json
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
{
|
|
"topic":"a/b/c",
|
|
"payload":"Hello World",
|
|
"qos":1,
|
|
"retain":false,
|
|
"clientId":"example"
|
|
}
|
|
|
|
### mqtt subscribe
|
|
POST http://{{host}}/api/v1/mqtt/subscribe
|
|
Content-Type: application/json
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
{
|
|
"topic":"a/b/c",
|
|
"qos":1,
|
|
"clientId":"example"
|
|
}
|
|
|
|
### mqtt unsubscribe
|
|
POST http://{{host}}/api/v1/mqtt/unsubscribe
|
|
Content-Type: application/json
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
{
|
|
"topic":"a/b/c",
|
|
"clientId":"example"
|
|
}
|
|
|
|
### mqtt publish batch
|
|
POST http://{{host}}/api/v1/mqtt/publish/batch
|
|
Content-Type: application/json
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
[
|
|
{
|
|
"topic":"a/b/c",
|
|
"payload":"Hello World",
|
|
"qos":1,
|
|
"retain":false,
|
|
"clientId":"example"
|
|
},
|
|
{
|
|
"topic":"a/b/c",
|
|
"payload":"Hello World Again",
|
|
"qos":0,
|
|
"retain":false,
|
|
"clientId":"example"
|
|
}
|
|
]
|
|
|
|
### mqtt subscribe batch
|
|
POST http://{{host}}/api/v1/mqtt/subscribe/batch
|
|
Content-Type: application/json
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
[
|
|
{
|
|
"topic":"a",
|
|
"qos":1,
|
|
"clientId":"example"
|
|
},
|
|
{
|
|
"topic":"b",
|
|
"qos":1,
|
|
"clientId":"example"
|
|
},
|
|
{
|
|
"topic":"c",
|
|
"qos":1,
|
|
"clientId":"example"
|
|
}
|
|
]
|
|
|
|
### mqtt unsubscribe batch
|
|
POST http://{{host}}/api/v1/mqtt/unsubscribe/batch
|
|
Content-Type: application/json
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
[
|
|
{
|
|
"topic":"a",
|
|
"clientId":"example"
|
|
},
|
|
{
|
|
"topic":"b",
|
|
"clientId":"example"
|
|
}
|
|
]
|
|
|
|
### mqtt delete clients
|
|
POST http://{{host}}/api/v1/clients/delete
|
|
Content-Type: application/x-www-form-urlencoded
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
clientId=123
|
|
|
|
### mqtt client subscriptions
|
|
GET http://{{host}}/api/v1/client/subscriptions
|
|
Content-Type: application/x-www-form-urlencoded
|
|
Authorization: Basic {{username}} {{password}}
|
|
|
|
clientId=123
|