마이크 목록 조회
등록된 마이크 장치 목록을 조회합니다.
마지막 업데이트: 1980년 1월 1일
GET
/api/v1/mics설명
등록된 마이크 장치 목록을 조회하는 API입니다. 결과는 전달한 쿼리 파라미터를 기준으로 페이지네이션됩니다. 마이크 장치 객체를 참고하면 관련 구조를 자세히 확인할 수 있습니다.
각 마이크는 자체 임계값 설정을 가집니다. 자세한 내용은 이벤트 카테고리를 참고해 주세요.
인증
Access Token은 Bearer 토큰 인증 방식으로 전달해야 합니다.
자세한 내용은 인증 문서를 참고해 주세요.
쿼리 파라미터
page
Optional
integer ||
1페이지네이션을 위한 페이지 번호
(0보다 커야 함)size
Optional
integer ||
10페이지당 항목 수
(0보다 크고 101보다 작아야 함)name
Optional
string ||
null장치 이름으로 필터링
edge_id
Optional
string ||
null엣지 서버 ID로 필터링
응답
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
{
"page": 1,
"size": 10,
"total_cnt": 100,
"max_page": 10,
"results": [
{
"id": "string",
"name": "string",
"host": "string",
"edge_id": "string",
"status": "enum(active | inactive)",
"thresholds": {
"breathing_heavily": {
"sound_level_ge": 65,
"confidence": 0.8
},
"[event_category]": {
"sound_level_ge": 65,
"confidence": 0.8
}
},
"location": {
"latitude": -90,
"longitude": -180
},
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}
]
}요청 예제
기본 요청
1
2
3
4
5
6
7
8
const response = await fetch('http://{{EDGE_IP}}:8100/api/v1/mics?page=1&size=10', {
method: 'GET',
headers: {
"Authorization": "Bearer YOUR_ACCESS_TOKEN"
}
});
const data = await response.json();필터 요청
1
2
3
4
5
6
7
8
const response = await fetch('http://{{EDGE_IP}}:8100/api/v1/mics?name=mic1&edge_id=edge123&page=1&size=10', {
method: 'GET',
headers: {
"Authorization": "Bearer YOUR_ACCESS_TOKEN"
}
});
const data = await response.json();