Files
datacat/back/src/modules/apis/dto/create-api-entry.dto.ts
z3n 1bbb0c1125 feat(apis): ajout champs de documentation enrichie sur les API entries
- 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>
2026-05-22 14:13:56 +00:00

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;
}