ReferenceHTTP API
audioMetrics
The audioMetrics router: 2 methods of the audio-metrics capability, with tier, scope, input and output.
Capability audio-metrics · scope device · mode singleton · source packages/types/src/capabilities/audio-metrics.cap.ts:110.
Every method is called at /trpc/audioMetrics.<method> — queries with GET, mutations with POST. See How to call and Authorization. Device methods take deviceId in their input.
| Method | Kind | Tier | Token scope | Viewer |
|---|---|---|---|---|
getCurrentSnapshot | query | protected | view | yes |
getHistory | query | protected | view | yes |
audioMetrics.getCurrentSnapshot
- Kind: query —
GET /trpc/audioMetrics.getCurrentSnapshot - Tier: protected — any signed-in principal whose scopes cover the method
- Token scope:
viewon capabilityaudio-metrics, or categorydevice, or a device grant coveringdeviceId - Viewer: yes
- Try it: open
/system/api-explorer?method=audioMetrics.getCurrentSnapshoton your hub
Input
{ deviceId: number }Output
AudioMetricsSnapshotSchema | nullShapes: AudioMetricsSnapshotSchema
audioMetrics.getHistory
- Kind: query —
GET /trpc/audioMetrics.getHistory - Tier: protected — any signed-in principal whose scopes cover the method
- Token scope:
viewon capabilityaudio-metrics, or categorydevice, or a device grant coveringdeviceId - Viewer: yes
- Try it: open
/system/api-explorer?method=audioMetrics.getHistoryon your hub
Input
{ deviceId: number; windowSec?: number; sampleEveryMs?: number }Output
AudioMetricsHistorySchemaShapes: AudioMetricsHistorySchema