Disable password login¶
Disable password authentication for an account. The account must have at least two passwordless authentication credentials to be able to disable normal password login.
MailUsers who disable password login must use device passwords to login to SMTP/IMAP/POP enabled email clients.
- HTTP Method:
POST
- URL:
https://example.domain.tld/api/v1/auth/password/disable/<username>/
- Require authentication:
Yes
- Permission level required:
MasterAdmin
/DomainAdmin
/MailUser
Path parameters¶
Parameter | Type | Description | Required |
---|---|---|---|
username | str | Account username | Required |
Response parameters¶
Parameter | Type | Description |
---|---|---|
password_login | str | disabled |
Example request (Python)¶
import requests
import json
from pprint import pprint
url = "https://example.domain.tld/api/v1/auth/password/disable/admin/"
r = requests.post(url, auth=("admin","long-auth_token-here"))
try:
pprint(r.json())
except:
print(r.text)
Example response (JSON)¶
{"password_login" : "disabled"}