...
Список доступных метрик может быть получен при помощи запроса /api/metric/list:
API | Request | Response | Response status |
---|
WS API | Code Block |
---|
| SEND
destination:/app/api/metric/list
content-length:100
{"requestId":"eb2c2807-8c2f-4418-aebe-03622404e4bb","realm":"/api/metric/list","payload":{"id":"3"}} |
| Code Block |
---|
| MESSAGE
destination:/user/service
content-type:application/json;charset=UTF-8
subscription:sub-1
message-id:3-8
content-length:159
{"requestId":"eb2c2807-8c2f-4418-aebe-03622404e4bb","status":200,"reason":"SUCCESS","payload":[{"id":3,"name":"Video rate","note":"","enumName":"VIDEO_RATE"}]} |
| 200 OK 400 Obkect not found 500 Persist exception |
REST API | Code Block |
---|
| POST: /api/metric/list "application/json; charset=utf-8"
{"id":"3"} |
| Code Block |
---|
| {
"status": 200,
"reason": "SUCCESS",
"payload": [
{
"id": 3,
"name": "Video rate",
"note": "",
"enumName": "VIDEO_RATE"
}
]
} |
| 200 OK 400 Obkect not found 500 Persist exception |
Здесь:
- id – идентификатор метрики.
...