import { Entity, PrimaryGeneratedColumn, Column, UpdateDateColumn } from 'typeorm';

@Entity('external_services_credentials')
export class ExternalServicesCredentials {
    @PrimaryGeneratedColumn('uuid')
    id: string;

    @Column({ name: 'service_name', unique: true })
    serviceName: string;

    @Column({ name: 'encrypted_payload', type: 'text' })
    encryptedPayload: string;

    @Column({ name: 'updated_by', nullable: true })
    updatedBy: string;

    @UpdateDateColumn({ name: 'updated_at' })
    updatedAt: Date;
}
