Send an Email Verification Code for 2FA Setup
Send a verification code to the email address of the current user to enable 2FA. The code expires after 5 minutes.
Request URL
POST {base_url}/uc-auth/api/v1/mfa/email/send-code
Request parameters
- Headers
-
Parameter Required Type Description Authorization Yes String The access token used for authentication. Format: Bearer
{access_token}. - Body parameters
-
Parameter Required Type Description email No String The email address of the current user.
Response parameters
| Parameter | Type | Description |
|---|---|---|
| requestId | String | The unique ID of the request, which can be used to quickly locate the request. |
| code | String | The HTTP status code of the request.
|
| message | String | The status message of the request. |
| detailMessage | String | The detailed error information. When the request is successful, this parameter returns empty. |
Example
Request example
POST /uc-auth/api/v1/mfa/email/send-code HTTP/1.1
Host: api.cn.novoone.com
Authorization: Bearer eyJraWQiOiJjbi0wLWtleS0xIiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiIxMDAwQGNvbG9ydGVzdDIiLCJncmFudF90eXBlIjoicGFzc3dvcmQiLCJ1c2VyX25hbWUiOiIxMDAwQGNvbG9ydGVzdDIiLCJzY29wZSI6WyJyZWFkIiwid3JpdGUiXSwiY2xpZW50X2V4dCI6eyJkZXNjcmlwdGlvbiI6IueuoeeQhuWQjuWPsFdlYuW6lOeUqCIsInBsYXRmb3JtIjoid2ViIn0sImV4cCI6MTc5MTg4NDc1NSwiaWF0IjoxNzkxODYzMTU1LCJqdGkiOiJiZTI3MWJlMC05NzdhLTQxYmItOTM4My0zMTcwMDQxYmQyOGIiLCJjbGllbnRfaWQiOiJub3ZvLWFkbWluLXdlYiIsInNpZCI6IjM4N2MzMGFiLTMyZTQtNDA5OS1hYWQ2LTZhMTc0MDZjOWQ2NyIsInVzZXJfZXh0Ijp7InJvbGVJZHMiOlsxMDJdLCJwdWlkIjozMDc2OTEzNjQ0OTE1OTk4NzIwLCJ0ZW5hbnRJZCI6MjA3OTUwNDIwNTMwOTE5NDI0MSwicGFyZW50VWNJZCI6MzA3NjkxMzY0NDg5MDgzMjg5NiwidGVuYW50Q29kZSI6ImNvbG9ydGVzdDIiLCJ0eXBlIjoiVF9VU0VSIiwidXNlcklkIjoyMDc5NzQ2OTE1Mzg4MDc2MDMzLCJlbWFpbCI6Imxlb0BzYW1wbGUuY29tIiwidXNlcm5hbWUiOiIxMDAwQGNvbG9ydGVzdDIiLCJ1Y0lkIjozMDc2OTEzNjQ0ODkwODMyODk2fX0.OECMIAzAvXeOjt5hAQNJJqOvQMIAlISSYQI50oy-nsYMSz-gCcnIza1sfs6h84-SiGm84NSSbn5qWAfIsi-pATDstMsqsltgmqaxuwszc1hlBZqEVv1Wfoa11ez2TS_gjUFR7vpMv1qSbeBVoVSMqgF6D86jbLOBLrhvVOR-PvTp1QnPrj8l0f2jPFlOIr8ecaRazcDuODB6Hnf7QYSjMaKD60vIVuIEKCYnmpYeInMAroFETCDzS53IJu-FBQucETpb-4LLzzuSnx8Iw_3esDPLfCpqeJVpxst1cleijSIkksEILmSHNivnpHDmXI8vjEkHCqYBs0ie4XY7cHIAqw
Content-Type: application/json
{
"email":"demo@yeastar.com"
}
Response example
HTTP/1.1 200 OK { "requestId": "c81c84783a363b30f41e106f8ea7233a", "code": "200", "message": "SUCCESS" }