25 lines
563 B
TypeScript
25 lines
563 B
TypeScript
|
import { ApiProperty } from '@nestjs/swagger';
|
||
|
import { DNSRecordType } from '../dns.enum';
|
||
|
|
||
|
export class CreateRecordDataDto {
|
||
|
@ApiProperty({
|
||
|
required: false,
|
||
|
description: 'When specified, will be inserted at this index.',
|
||
|
})
|
||
|
index?: number;
|
||
|
|
||
|
@ApiProperty({ required: true })
|
||
|
name: string;
|
||
|
|
||
|
@ApiProperty({ required: true, type: 'string' })
|
||
|
type: DNSRecordType;
|
||
|
|
||
|
@ApiProperty({ required: true })
|
||
|
value: string;
|
||
|
}
|
||
|
|
||
|
export class CreateRecordDto {
|
||
|
@ApiProperty({ required: true })
|
||
|
record: CreateRecordDataDto | CreateRecordDataDto[];
|
||
|
}
|