aboutsummaryrefslogtreecommitdiff
path: root/src/types.ts
blob: e41223c0e8d6300a507ac379328208f627f319fb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
interface Base {
  _id: string;
  createdAt: string;
  updatedAt: string;
}

export interface User extends Base {
  username: string;
}

export interface EventContext {
  name: string;
  participants: string[];
  conferenceId: string;
  attendanceId: string;
}

export interface Event extends Base {
  type: string;
  schedule: string;
  status?: 'running' | 'complete' | 'failed' | 'notStarted';
  failReason?: string;
  context: EventContext;
  nextRunAt: string;
  lastRunAt: string;
}

export interface Log extends Base {
  message: string;
  eventId: string;
}