[comment]: # translation:outdated

[comment]: # ({9773f653-4af7a213})
# user.resettotp

[comment]: # ({/9773f653-4af7a213})

[comment]: # ({2f760ecf-1d5cf984})
### Descrizione

`object user.resettotp(object/array users)`

Questo metodo consente di reimpostare i segreti TOTP degli utenti.

::: noteclassic
Questo metodo è disponibile solo per il tipo di utente *Super admin*.
Le autorizzazioni per chiamare il metodo possono essere revocate nelle impostazioni del ruolo utente.
Per ulteriori informazioni, vedere [User roles](/manual/web_interface/frontend_sections/users/user_roles).
:::

[comment]: # ({/2f760ecf-1d5cf984})

[comment]: # ({c8b7ac78-eed4792f})
### Parametri

`(array)` ID degli utenti per i quali reimpostare i segreti TOTP.

::: noteclassic
Anche le sessioni utente degli utenti specificati verranno eliminate (tranne quella dell'utente che invia la richiesta).
:::

[comment]: # ({/c8b7ac78-eed4792f})

[comment]: # ({261f8ac9-664dd395})
### Valori restituiti

`(object)` Restituisce un oggetto contenente gli ID degli utenti per i quali i segreti TOTP sono stati reimpostati, nella proprietà `userids`.

[comment]: # ({/261f8ac9-664dd395})

[comment]: # ({b41637d2-40f7edfd})
### Esempi

[comment]: # ({/b41637d2-40f7edfd})

[comment]: # ({f5ef228d-9fb090fd})
#### Reimpostazione dei segreti TOTP per più utenti

Reimpostare i segreti TOTP per due utenti.

[Richiesta](/manual/api#performing-requests):

```json
{
    "jsonrpc": "2.0",
    "method": "user.resettotp",
    "params": [
        "1",
        "5"
    ],
    "id": 1
}
```

Risposta:

```json
{
    "jsonrpc": "2.0",
    "result": {
        "userids": [
            "1",
            "5"
        ]
    },
    "id": 1
}
```

[comment]: # ({/f5ef228d-9fb090fd})

[comment]: # ({5bd16955-0c80b38e})
### Vedi anche

-   [Oggetto MFA](/manual/api/reference/mfa/object)

[comment]: # ({/5bd16955-0c80b38e})

[comment]: # ({646dbdd5-5ddc468d})
### Sorgente

CUser::resettotp() in *ui/include/classes/api/services/CUser.php*.

[comment]: # ({/646dbdd5-5ddc468d})
