> ## 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.

# Wipe a device

> Wipe the device for the given device ID.

**Supported platforms:** macOS, iOS, Windows, Linux

**Platform-specific behavior:**
- **Windows**: Accepts optional `wipeType` parameter:
  - `SOFT` (default): Attempts to wipe the device once. If it fails, the device reboots to its initial state.
  - `HARD`: Attempts to wipe the device repeatedly until successful.
    - ⚠️ **Warning:** If the wipe keeps failing, this can leave the device in an unusable state, requiring a reinstallation via USB key.
- **macOS/iOS/Linux**: Performs a full device erase. The `wipeType` parameter is ignored.

**Not supported:** Android, Chrome OS

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


## OpenAPI

````yaml https://api.getprimo.com/openapi.json post /devices/{deviceId}/wipe
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}/wipe:
    post:
      tags:
        - Devices
      summary: Wipe a device
      description: >-
        Wipe the device for the given device ID.


        **Supported platforms:** macOS, iOS, Windows, Linux


        **Platform-specific behavior:**

        - **Windows**: Accepts optional `wipeType` parameter:
          - `SOFT` (default): Attempts to wipe the device once. If it fails, the device reboots to its initial state.
          - `HARD`: Attempts to wipe the device repeatedly until successful.
            - ⚠️ **Warning:** If the wipe keeps failing, this can leave the device in an unusable state, requiring a reinstallation via USB key.
        - **macOS/iOS/Linux**: Performs a full device erase. The `wipeType`
        parameter is ignored.


        **Not supported:** Android, Chrome OS
      operationId: wipeDevice
      parameters:
        - name: deviceId
          required: true
          in: path
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WipeDeviceBody'
      responses:
        default:
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WipeDevice_Output'
components:
  schemas:
    WipeDeviceBody:
      type: object
      properties:
        wipeType:
          description: >-
            Type of wipe to perform. Only applicable for Windows devices. SOFT
            resets the device but preserves user data, HARD performs a complete
            factory reset. Ignored for other platforms.
          type: string
          enum:
            - SOFT
            - HARD
    WipeDevice_Output:
      type: object
      properties:
        success:
          type: boolean
          const: true
        platform:
          type: string
          description: The platform of the wiped device
          enum:
            - ANDROID
            - IOS
            - MACOS
            - WINDOWS
            - LINUX
            - CHROME_OS
            - IPADOS
            - UNKNOWN
        wipeType:
          description: >-
            The type of wipe that was performed. Only present for Windows
            devices (SOFT or HARD). Null for other platforms.
          anyOf:
            - type: string
              enum:
                - SOFT
                - HARD
            - type: 'null'
        message:
          type: string
          description: A human-readable description of the wipe operation
      required:
        - success
        - platform
        - message
      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>`.

````