fix(auth-service): add 'auth/' prefix to controller routes for Kong compatibility

Kong routes /api/v2/auth/* to auth-service without stripping the path,
so controllers need 'auth/' prefix to match frontend requests:
- SmsController: 'sms' -> 'auth/sms'
- PasswordController: 'password' -> 'auth/password'
- UserController: 'user' -> 'auth/user'

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
hailin 2026-01-14 08:53:48 -08:00
parent cb3c7623dc
commit c852f24a72
3 changed files with 3 additions and 3 deletions

View File

@ -22,7 +22,7 @@ class ChangePasswordDto {
newPassword: string;
}
@Controller('password')
@Controller('auth/password')
@UseGuards(ThrottlerGuard)
export class PasswordController {
constructor(private readonly passwordService: PasswordService) {}

View File

@ -21,7 +21,7 @@ class VerifySmsDto {
type: 'REGISTER' | 'LOGIN' | 'RESET_PASSWORD' | 'CHANGE_PHONE';
}
@Controller('sms')
@Controller('auth/sms')
@UseGuards(ThrottlerGuard)
export class SmsController {
constructor(private readonly smsService: SmsService) {}

View File

@ -7,7 +7,7 @@ import { UserService, UserProfileResult } from '@/application/services';
import { JwtAuthGuard } from '@/shared/guards/jwt-auth.guard';
import { CurrentUser } from '@/shared/decorators/current-user.decorator';
@Controller('user')
@Controller('auth/user')
@UseGuards(JwtAuthGuard)
export class UserController {
constructor(private readonly userService: UserService) {}