openclaw_device_repair
Repair the empty private key failure mode by backing up config, wiping the broken device and tokens, and triggering fresh keypair generation with a new pairing request.
Instructions
Recover from the expected Uint8Array of length 32, got length=0 failure mode (empty device.privateKey). Backs up store.json to store.json.bak.<ts>, wipes the broken device + cached tokens (keeps gateway URL + token configs), and drops the matching keychain entries. The next call to any scoped tool regenerates a fresh Ed25519 keypair and surfaces a new pendingPairing.requestId to approve in the Control panel. The instance arg is accepted but currently no-op — the local Store is shared across all instances. Destructive — run only when openclaw_device_status reports the empty-private-key failure mode.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| instance | No | Optional OpenClaw instance to route this call to (e.g. 'default', 'work'). Falls back to the active default instance, or the OPENCLAW_GATEWAY_URL/TOKEN env vars when set. List configured instances with openclaw_setup_list. |