forked from docs/doc-exports
Reviewed-by: Kabai, Zoltán Gábor <zoltan-gabor.kabai@t-systems.com> Co-authored-by: Wei, Hongmin <weihongmin1@huawei.com> Co-committed-by: Wei, Hongmin <weihongmin1@huawei.com>
13 KiB
13 KiB
Creating a Virtual MFA Device
Function
This API is provided for IAM users to create a virtual MFA device.
URI
POST /v3.0/OS-MFA/virtual-mfa-devices
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
Token (no special permission requirements) of the IAM user corresponding to the user_id specified in the request body. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
Yes |
object |
MFA device information. |
Response Parameters
Status code: 201
Parameter |
Type |
Description |
---|---|---|
object |
MFA device information. |
Example Request
POST https://sample.domain.com/v3.0/OS-MFA/virtual-mfa-devices { "virtual_mfa_device" : { "name" : "{device_name}", "user_id" : "09f99d8f6a001d4f1f01c00c31968..." } }
Example Response
Status code: 201
The request is successful.
{ "virtual_mfa_device": { "serial_number": "iam:09f6bd6a96801de40f01c00c85691...:mfa/{device_name}", "base32_string_seed": "{string}" } }
Status Codes
Status Code |
Description |
---|---|
201 |
The request is successful. |
400 |
The request is invalid. |
401 |
Authentication failed. |
403 |
You do not have permission to perform this action. |
409 |
A conflict occurs when the requested resource is saved. |
500 |
A system error occurred. |
Parent topic: Security Settings