跳转到内容
开发者文档 / 认证接口

发送重置密码邮件

向指定邮箱发送重置密码验证码。

POST/api/auth/forget/email

鉴权方式 请求头 Api-Key、Api-Secret

Content-Type application/json

请求体

参数类型必填说明
emailstring是已注册的合法邮箱,服务端按小写处理
bash
curl -X POST 'https://resource-api.xyeidc.com/api/auth/forget/email' \
  -H 'Api-Key: YOUR_API_KEY' \
  -H 'Api-Secret: YOUR_API_SECRET' \
  -H 'Content-Type: application/json' \
  -d '{"email":"developer@example.com"}'

响应示例

json
{
  "code": 200,
  "msg": "Success!",
  "data": "deve******"
}

data 返回目标邮箱前 4 个字符加掩码,用于确认发送对象;真正的 6 位验证码只会发送到目标邮箱,有效期为 5 分钟。邮件服务有 1 分钟冷却时间,请避免高频重复发送。