mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-26 18:42:49 +00:00
31 lines
627 B
TypeScript
31 lines
627 B
TypeScript
import { ApiProperty, ApiPropertyOptional } from "@nestjs/swagger";
|
|
import { IsEmail, IsNotEmpty, IsOptional, IsString } from "class-validator";
|
|
|
|
export class SendEmailDto {
|
|
@ApiProperty({
|
|
description: "Recipient email address",
|
|
example: "customer@example.com",
|
|
})
|
|
@IsEmail()
|
|
@IsNotEmpty()
|
|
to!: string;
|
|
|
|
@ApiProperty({
|
|
description: "Email subject",
|
|
example: "Your EDR Freight verification code",
|
|
})
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
subject!: string;
|
|
|
|
@ApiPropertyOptional()
|
|
@IsOptional()
|
|
@IsString()
|
|
text?: string;
|
|
|
|
@ApiPropertyOptional()
|
|
@IsOptional()
|
|
@IsString()
|
|
html?: string;
|
|
}
|