- Nouveaux champs : functionalDoc, technicalDoc, externalDocUrl, contactFunctional, contactTechnical, accessRights - Entity, DTOs, service et seeder mis à jour côté backend - Page upload et api-detail mis à jour côté frontend Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
52 lines
822 B
TypeScript
52 lines
822 B
TypeScript
import { IsString, IsNotEmpty, IsIn, IsOptional, IsUUID } from 'class-validator';
|
|
import { ApiType } from '@datacat/shared';
|
|
|
|
export class CreateApiEntryDto {
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
title!: string;
|
|
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
version!: string;
|
|
|
|
@IsString()
|
|
@IsOptional()
|
|
description?: string;
|
|
|
|
@IsIn(['ASYNCAPI', 'OPENAPI'])
|
|
type!: ApiType;
|
|
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
yamlContent!: string;
|
|
|
|
@IsUUID()
|
|
@IsOptional()
|
|
categoryId?: string;
|
|
|
|
@IsString()
|
|
@IsOptional()
|
|
functionalDoc?: string;
|
|
|
|
@IsString()
|
|
@IsOptional()
|
|
technicalDoc?: string;
|
|
|
|
@IsString()
|
|
@IsOptional()
|
|
externalDocUrl?: string;
|
|
|
|
@IsString()
|
|
@IsOptional()
|
|
contactFunctional?: string;
|
|
|
|
@IsString()
|
|
@IsOptional()
|
|
contactTechnical?: string;
|
|
|
|
@IsString()
|
|
@IsOptional()
|
|
accessRights?: string;
|
|
}
|