Skip to main content

Factory reset workflow

This guide explains the factory reset flow for third-party API users.

Overview

Factory reset is triggered by a single mutation:

  1. Call requestFactoryReset from your API client.

The workflow state is tracked with Device.shouldBeReset (FactoryResetRequestState) in the returned Device.

Step 1: Request reset

mutation REQUEST_FACTORY_RESET($deviceId: ID!, $mode: FactoryResetRequestState!) {
requestFactoryReset(deviceId: $deviceId, mode: $mode) {
id
uniqueIdNumber
shouldBeReset
isConfigured
hasBeenAppliedByDeviceAt
lastDeviceConfig {
id
version
createdAt
}
}
}

Mode choice

  • PARTIAL: keeps current SIM management and Wi-Fi sections.
  • TOTAL: restores complete template values.

Immediate API effects

  • A new device config version is created from the software template.
  • Device config apply status is reset (hasBeenAppliedByDeviceAt = null).
  • Device reset flag becomes PARTIAL or TOTAL.

What to do after calling the mutation

No additional mutation is required from a third-party API user.

Permission model

  • requestFactoryReset: FACTORY_RESET_REQUEST

Common failure cases

  • Request called while shouldBeReset != IDLE.
  • Unknown deviceId.