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

export class CompleteUploadDto {
  @ApiProperty({ description: '上传会话 ID（upload-url 响应中返回）' })
  @IsString()
  uploadId: string;

  @ApiPropertyOptional({ description: 'COS 对象键（用于客户端幂等校验）' })
  @IsOptional()
  @IsString()
  objectKey?: string;

  @ApiPropertyOptional({ description: '文件 SHA256 校验和' })
  @IsOptional()
  @IsString()
  checksum?: string;
}
