ReferenceHTTP API
deviceRuns
The deviceRuns router: 3 methods of the device-runs capability, with tier, scope, input and output.
Capability device-runs · scope device · mode singleton · source packages/types/src/capabilities/device-runs.cap.ts:105.
Every method is called at /trpc/deviceRuns.<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 |
|---|---|---|---|---|
listRuns | query | protected | view | yes |
getRun | query | protected | view | yes |
getCurrentRun | query | protected | view | yes |
deviceRuns.listRuns
- Kind: query —
GET /trpc/deviceRuns.listRuns - Tier: protected — any signed-in principal whose scopes cover the method
- Token scope:
viewon capabilitydevice-runs, or categorydevice, or a device grant coveringdeviceId - Viewer: yes
- Try it: open
/system/api-explorer?method=deviceRuns.listRunson your hub
Input
{ deviceId: number; outcome?: DeviceRunOutcomeSchema; atFrom?: number; atTo?: number; limit?: number = 50; cursor?: string }Output
{ runs: DeviceRunSchema[]; nextCursor: string | null }Shapes: DeviceRunOutcomeSchema · DeviceRunSchema
deviceRuns.getRun
- Kind: query —
GET /trpc/deviceRuns.getRun - Tier: protected — any signed-in principal whose scopes cover the method
- Token scope:
viewon capabilitydevice-runs, or categorydevice, or a device grant coveringdeviceId - Viewer: yes
- Try it: open
/system/api-explorer?method=deviceRuns.getRunon your hub
Input
{ deviceId: number; runId: string }Output
DeviceRunSchema | nullShapes: DeviceRunSchema
deviceRuns.getCurrentRun
- Kind: query —
GET /trpc/deviceRuns.getCurrentRun - Tier: protected — any signed-in principal whose scopes cover the method
- Token scope:
viewon capabilitydevice-runs, or categorydevice, or a device grant coveringdeviceId - Viewer: yes
- Try it: open
/system/api-explorer?method=deviceRuns.getCurrentRunon your hub
Input
{ deviceId: number }Output
DeviceRunSchema | nullShapes: DeviceRunSchema