对接阿里云短信OK

This commit is contained in:
yml2213
2026-05-29 12:11:13 +08:00
parent a334f1837d
commit eb80a3ba84
14 changed files with 495 additions and 29 deletions
+2
View File
@@ -84,6 +84,8 @@ func writeAuthError(c *gin.Context, err error) {
response.BadRequest(c, "手机号格式不正确")
case errors.Is(err, ErrCodeRateLimited):
response.Error(c, http.StatusTooManyRequests, "rate_limited", "验证码发送过于频繁")
case errors.Is(err, ErrSMSSendFailed):
response.Error(c, http.StatusBadGateway, "sms_send_failed", "验证码发送失败,请稍后重试")
case errors.Is(err, ErrCodeInvalid):
response.BadRequest(c, "验证码错误或已过期")
case errors.Is(err, ErrUserDisabled):