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

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

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

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

Šī metode ļauj atiestatīt lietotāja TOTP noslēpumus.

::: noteclassic
Šī metode ir pieejama tikai *Super admin* lietotāja tipam.
Atļaujas izsaukt šo metodi var tikt atsauktas lietotāja lomas iestatījumos.
Plašāku informāciju skatiet [Lietotāju lomas](/manual/web_interface/frontend_sections/users/user_roles).
:::

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

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

`(array)` Lietotāju ID, kuriem atiestatīt TOTP noslēpumus.

::: noteclassic
Norādīto lietotāju sesijas arī tiks dzēstas (izņemot lietotāju, kurš nosūta pieprasījumu).
:::

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

[comment]: # ({261f8ac9-664dd395})
### Atgrieztās vērtības

`(object)` Atgriež objektu, kas satur to lietotāju ID, kuriem ir atiestatīti TOTP noslēpumi, īpašībā `userids`.

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

[comment]: # ({b41637d2-40f7edfd})
### Piemēri

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

[comment]: # ({f5ef228d-9fb090fd})
#### TOTP noslēpumu atiestatīšana vairākiem lietotājiem

Atiestatiet TOTP noslēpumus diviem lietotājiem.

[Pieprasījums](/manual/api#performing-requests):

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

Atbilde:

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

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

[comment]: # ({5bd16955-0c80b38e})
### Skatiet arī

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

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

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

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

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