feat: 实现短信模块

This commit is contained in:
2025-12-17 23:01:13 +08:00
parent 54acad1671
commit 2ef3507cea
10 changed files with 286 additions and 13 deletions

View File

@@ -0,0 +1,15 @@
import { Body, Controller, Post } from '@nestjs/common';
import { SendLoginSmsDto } from './dto/send-login-sms.dto';
import { SmsService } from './sms.service';
@Controller('sms')
export class SmsController {
constructor(private readonly smsService: SmsService) { }
@Post('send/login')
async sendLoginSms(@Body() dto: SendLoginSmsDto) {
await this.smsService.sendSms(dto.phone, 'login');
return null;
}
}