Rename an authenticator
As authenticator names can be rather non-descriptive, users may want to change the name to something they recognize. When a user renames an authenticator, the authenticators
API endpoint is invoked with a PATCH
request.
The name is freely definable, so it can contain PII data.
Send an HTTP request to the authenticators endpoint
For detailed information on the HTTP request parameters and response fields, see the Authenticators endpoint page of the API reference documentation.
Send the PATCH https://{instance}.mauth.nevis.cloud/api/v1/authenticators/{authenticatorId}
call with your instance ID and the authenticatorId
of the given authenticator. Configure the call as follows:
- Send your access key in the Authorization Bearer token header.
- Add a new name as the value of the
name
request parameter.
HTTP request examples
- cURL
- Python 3
# Set $authenticator_id
curl "https://$instance.mauth.nevis.cloud/api/v1/authenticators/$authenticator_id" \
-X PATCH \
-H "Authorization: Bearer $access_key" \
-H 'Content-Type: application/json' \
-d "{ \"name\":\"$name\" }"
authenticator_id = 'f3ef70fc-9231-48f8-8e81-8eef7826d594'
data = {'name':name}
resp = requests.patch(f'https://{instance}.mauth.nevis.cloud/api/v1/authenticators/{authenticator_id}',
headers = {'authorization': f'Bearer {access_key}'},
json = data)
print(resp.json())
HTTP response examples
- Authenticator updated
- Authenticator not found
200 OK
: Authenticator is updated.
{
"authenticatorId": "f3ef70fc-9231-48f8-8e81-8eef7826d594",
"name": "Personal Phone",
"type": "ios",
"enrolledAt": "2020-10-09T08:44:36Z",
"updatedAt": "2020-10-09T08:44:36Z",
"authenticatorType": "app",
"state": "active",
"uaf": {
"userAgent": "NMASDK/3.3.2.447 (iPhone13,2; iPhoneOS 16.6) ch.nevis.accessapp.muvonda/2.7.20812.812",
"deviceRef": "be4b7fe8-1785-4818-9550-bb8cd7153fff"
}
}
404 Not found
: No authenticator with provided authenticatorId
exists.
In setups where multiple application backends are used with a single app, authenticators should only be renamed through the app, not the API. This is to avoid a mismatch between the name of the same authenticator on the different backends.