// server/src/model-config/dto/model-config-response.dto.ts
import { Exclude } from 'class-transformer';
import { ModelConfig } from '../model-config.entity';

export class ModelConfigResponseDto {
  id: string;
  name: string;
  provider: string;
  modelId: string;
  baseUrl?: string;

  @Exclude() // Exclude API key from being returned to the client
  apiKey?: string;

  type: string;
  isEnabled?: boolean;
  isDefault?: boolean;
  createdAt: Date;
  updatedAt: Date;

  constructor(partial: Partial<ModelConfig>) {
    Object.assign(this, partial);
  }
}
