Files
Automata/packages/cli/src/databases/entities/WebhookEntity.ts
2023-01-02 17:42:32 +01:00

26 lines
477 B
TypeScript

import { Column, Entity, Index, PrimaryColumn } from 'typeorm';
import { idStringifier } from '../utils/transformers';
@Entity()
@Index(['webhookId', 'method', 'pathLength'])
export class WebhookEntity {
@Column({ transformer: idStringifier })
workflowId: string;
@PrimaryColumn()
webhookPath: string;
@PrimaryColumn()
method: string;
@Column()
node: string;
@Column({ nullable: true })
webhookId?: string;
@Column({ nullable: true })
pathLength?: number;
}