> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getprimo.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update a device

> Update the device for the given device ID. Currently supports updating the device assignee (ownerId).

<span className="badge-write">Key: Write</span><span className="badge-company">Scope: Company</span>


## OpenAPI

````yaml https://api.getprimo.com/openapi.json patch /devices/{deviceId}
openapi: 3.1.1
info:
  title: Public API - BETA
  description: Read docs on https://docs.getprimo.com/
  version: '1.0'
  contact: {}
servers:
  - url: https://api.getprimo.com
security:
  - apikey: []
tags: []
paths:
  /devices/{deviceId}:
    patch:
      tags:
        - Devices
      summary: Update a device
      description: >-
        Update the device for the given device ID. Currently supports updating
        the device assignee (ownerId).
      operationId: updateDevice
      parameters:
        - name: deviceId
          required: true
          in: path
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateDeviceBody'
      responses:
        default:
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetDevice_Output'
components:
  schemas:
    UpdateDeviceBody:
      type: object
      properties:
        ownerId:
          description: ID of the employee to assign this device to, or null to unassign
          anyOf:
            - type: string
              pattern: ^[a-f\d]{24}$
            - type: 'null'
      required:
        - ownerId
    GetDevice_Output:
      type: object
      properties:
        id:
          type: string
        ownerId:
          description: The ID of the employee assigned to this device
          anyOf:
            - type: string
            - type: 'null'
        name:
          anyOf:
            - type: string
            - type: 'null'
        serialNumber:
          anyOf:
            - type: string
            - type: 'null'
        computerName:
          description: >-
            **Deprecated** — use `name` instead. This field will be removed on
            2026-04-13.
          deprecated: true
          anyOf:
            - type: string
            - type: 'null'
        tags:
          type: array
          items:
            type: string
        type:
          anyOf:
            - type: string
              enum:
                - LAPTOP
                - TABLET
                - SMARTPHONE
            - type: 'null'
        platform:
          anyOf:
            - type: string
              enum:
                - ANDROID
                - IOS
                - MACOS
                - WINDOWS
                - LINUX
                - CHROME_OS
                - IPADOS
                - UNKNOWN
            - type: 'null'
        brand:
          anyOf:
            - type: string
            - type: 'null'
        manufacturer:
          anyOf:
            - type: string
            - type: 'null'
        modelName:
          anyOf:
            - type: string
            - type: 'null'
        modelIdentifier:
          anyOf:
            - type: string
            - type: 'null'
        year:
          anyOf:
            - type: number
            - type: 'null'
        osVersion:
          anyOf:
            - type: string
            - type: 'null'
        osName:
          anyOf:
            - type: string
            - type: 'null'
        buildVersion:
          anyOf:
            - type: string
            - type: 'null'
        osUpdateStatus:
          description: >-
            OS update status of the device against the company's OS update
            policies: UP_TO_DATE, NOT_UP_TO_DATE, or NOT_SETUP when no OS update
            policy targets the device. Null when unknown.
          anyOf:
            - type: string
              enum:
                - UP_TO_DATE
                - NOT_UP_TO_DATE
                - NOT_SETUP
            - type: 'null'
        isEnrolled:
          type: boolean
        enrolledAt:
          anyOf:
            - type: string
              format: date-time
              pattern: >-
                ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
            - type: 'null'
        disenrolledAt:
          anyOf:
            - type: string
              format: date-time
              pattern: >-
                ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
            - type: 'null'
        lockWipeStatus:
          description: >-
            Current lock/wipe status of the device. LOCKING/LOCKED for lock
            operations, UNLOCKING for unlock in progress, WIPING/WIPED for wipe
            operations. Null when device is in normal state.
          anyOf:
            - type: string
              enum:
                - LOCKED
                - LOCKING
                - UNLOCKING
                - WIPED
                - WIPING
            - type: 'null'
        edrProvider:
          description: >-
            EDR provider protecting the device: SENTINELONE, THREATDOWN, or null
            when no EDR (e.g. no EDR configured, or device not yet protected).
          anyOf:
            - type: string
              enum:
                - SENTINELONE
                - THREATDOWN
            - type: 'null'
        createdAt:
          type: string
          format: date-time
          pattern: >-
            ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
        updatedAt:
          type: string
          format: date-time
          pattern: >-
            ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
      required:
        - id
        - tags
        - isEnrolled
        - createdAt
        - updatedAt
      additionalProperties: false
  securitySchemes:
    apikey:
      scheme: bearer
      bearerFormat: API key
      type: http
      description: >-
        Use your Primo API key in the Authorization header as `Bearer
        <API_KEY>`.

````