Update Device – Fleets API – MediaKind
Update Device
PATCH Request
https://app.mk.io/api/v1/projects/:project_name/fleet/devices/:name
Update a device. To learn more about devices, read Device Concept.
RBAC Capability Required
fleet.device.update
Authentication
Authorization
Bearer authentication of the form Bearer <token>, where token is your auth token.
Path parameters
project_name: string Requiredname: string Required
Request
This endpoint expects an object.
metadata
- Optional
metadata: object DefaultPatchMetadata- displayName: string Optional 1-255 characters
- labels: map from strings to string Optional
Maximum number of labels: 32.
Maximum length of a label or value: 256 characters.
spec
- Optional
spec: object DevicePatchBodySpec- autoPreloadLatestSoftware: boolean Optional Defaults to false
- availableNetworks: list of objects AvailableNetworkFragment Optional
- interfaceName: string Required pattern:
[^\s\/]{1,16} - networkName: string Required pattern:
^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$
- interfaceName: string Required pattern:
- desiredSoftwareVersion: string Optional <=255 characters
- geolocation: object GeolocationFragment Optional
- coordinates: list of doubles Required 0-2 items
- locationId: string Optional pattern:
^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$ - preloadSoftwareVersion: string Optional <=255 characters
- shortCode: string Optional 8-8 characters
- siteName: string Optional pattern:
^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$
Response
200 - The updated device
- kind: string Required
- metadata: object MetadataSchema Required
- created: string Optional format: date-time
- createdBy: string Optional format: uuid
- createdByEmail: string Optional
- displayName: string Optional
- id: string Required format: uuid
- labels: map from strings to string Optional
- name: string Optional
- updated: string Optional format: date-time
- updatedBy: string Optional format: uuid
- updatedByEmail: string Optional
- spec: object DeviceBodySpec Required
Errors
- 400 Bad Request:
- error: object ErrorDetail Required
- code: string Required
- detail: string Required
- ref: string Required
- status: integer Required
- error: object ErrorDetail Required
- 401 Unauthorized:
- error: object ErrorDetail Required
- 403 Forbidden:
- error: object ErrorDetail Required
- 404 Not Found:
- error: object ErrorDetail Required
- 429 Too Many Requests:
- error: object ErrorDetail Required
- 500 Internal Server Error:
- error: object ErrorDetail Required