import { ApiProperty } from '@nestjs/swagger';
import { IsNotEmpty, IsNumber, IsString } from 'class-validator';

export class VerifyOtpDto {
  @IsString()
  @IsNotEmpty()
  @ApiProperty({
    required: true,
    type: String,
    description: 'Action',
  })
  action: string;

  @IsNumber()
  @IsNotEmpty({ message: `Otp is required.` })
  @ApiProperty({
    required: true,
    type: String,
    description: 'Otp',
  })
  otp: number;

  @IsString()
  @IsNotEmpty({ message: `Mobile number can't be empty` })
  @ApiProperty({
    required: true,
    type: String,
    description: 'Phone Number',
  })
  phone_number: string;

  @IsString()
  @IsNotEmpty()
  @ApiProperty({
    required: true,
    type: String,
    description: 'Country Code',
  })
  country_phone_code: string;
}
