@periskope/types 0.6.96 → 0.6.98

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/supabase.types.ts CHANGED
@@ -1,2551 +1,2405 @@
1
- export type Json = { [key: string]: any } | any
1
+ export type Json = { [key: string]: any } | any;
2
2
 
3
3
  export type Database = {
4
4
  graphql_public: {
5
5
  Tables: {
6
- [_ in never]: never
7
- }
6
+ [_ in never]: never;
7
+ };
8
8
  Views: {
9
- [_ in never]: never
10
- }
9
+ [_ in never]: never;
10
+ };
11
11
  Functions: {
12
12
  graphql: {
13
13
  Args: {
14
- operationName?: string
15
- query?: string
16
- variables?: Json
17
- extensions?: Json
18
- }
19
- Returns: Json
20
- }
21
- }
14
+ operationName?: string;
15
+ query?: string;
16
+ variables?: Json;
17
+ extensions?: Json;
18
+ };
19
+ Returns: Json;
20
+ };
21
+ };
22
22
  Enums: {
23
- [_ in never]: never
24
- }
23
+ [_ in never]: never;
24
+ };
25
25
  CompositeTypes: {
26
- [_ in never]: never
27
- }
28
- }
26
+ [_ in never]: never;
27
+ };
28
+ };
29
29
  public: {
30
30
  Tables: {
31
31
  tbl_api_logs: {
32
32
  Row: {
33
- org_id: string
34
- path: string
35
- req: Json
36
- request_id: string
37
- res: Json
38
- status: number
39
- timestamp: string
40
- token_id: string
41
- }
33
+ org_id: string;
34
+ path: string;
35
+ req: Json;
36
+ request_id: string;
37
+ res: Json;
38
+ status: number;
39
+ timestamp: string;
40
+ token_id: string;
41
+ };
42
42
  Insert: {
43
- org_id: string
44
- path: string
45
- req: Json
46
- request_id: string
47
- res: Json
48
- status: number
49
- timestamp: string
50
- token_id: string
51
- }
43
+ org_id: string;
44
+ path: string;
45
+ req: Json;
46
+ request_id: string;
47
+ res: Json;
48
+ status: number;
49
+ timestamp: string;
50
+ token_id: string;
51
+ };
52
52
  Update: {
53
- org_id?: string
54
- path?: string
55
- req?: Json
56
- request_id?: string
57
- res?: Json
58
- status?: number
59
- timestamp?: string
60
- token_id?: string
61
- }
62
- Relationships: []
63
- }
53
+ org_id?: string;
54
+ path?: string;
55
+ req?: Json;
56
+ request_id?: string;
57
+ res?: Json;
58
+ status?: number;
59
+ timestamp?: string;
60
+ token_id?: string;
61
+ };
62
+ Relationships: [];
63
+ };
64
64
  tbl_broadcast_logs: {
65
65
  Row: {
66
- broadcast_id: string
67
- chat_id: string
68
- completed_at: string | null
69
- created_at: string
70
- delivered_count: number | null
71
- delivery_info: Json | null
72
- is_success: boolean | null
73
- member_count: number | null
74
- message_id: string | null
75
- org_id: string
76
- org_phone: string | null
77
- read_count: number | null
78
- }
66
+ broadcast_id: string;
67
+ chat_id: string;
68
+ completed_at: string | null;
69
+ created_at: string;
70
+ delivered_count: number | null;
71
+ delivery_info: Json | null;
72
+ is_success: boolean | null;
73
+ member_count: number | null;
74
+ message_id: string | null;
75
+ org_id: string;
76
+ org_phone: string | null;
77
+ read_count: number | null;
78
+ };
79
79
  Insert: {
80
- broadcast_id: string
81
- chat_id: string
82
- completed_at?: string | null
83
- created_at?: string
84
- delivered_count?: number | null
85
- delivery_info?: Json | null
86
- is_success?: boolean | null
87
- member_count?: number | null
88
- message_id?: string | null
89
- org_id: string
90
- org_phone?: string | null
91
- read_count?: number | null
92
- }
80
+ broadcast_id: string;
81
+ chat_id: string;
82
+ completed_at?: string | null;
83
+ created_at?: string;
84
+ delivered_count?: number | null;
85
+ delivery_info?: Json | null;
86
+ is_success?: boolean | null;
87
+ member_count?: number | null;
88
+ message_id?: string | null;
89
+ org_id: string;
90
+ org_phone?: string | null;
91
+ read_count?: number | null;
92
+ };
93
93
  Update: {
94
- broadcast_id?: string
95
- chat_id?: string
96
- completed_at?: string | null
97
- created_at?: string
98
- delivered_count?: number | null
99
- delivery_info?: Json | null
100
- is_success?: boolean | null
101
- member_count?: number | null
102
- message_id?: string | null
103
- org_id?: string
104
- org_phone?: string | null
105
- read_count?: number | null
106
- }
94
+ broadcast_id?: string;
95
+ chat_id?: string;
96
+ completed_at?: string | null;
97
+ created_at?: string;
98
+ delivered_count?: number | null;
99
+ delivery_info?: Json | null;
100
+ is_success?: boolean | null;
101
+ member_count?: number | null;
102
+ message_id?: string | null;
103
+ org_id?: string;
104
+ org_phone?: string | null;
105
+ read_count?: number | null;
106
+ };
107
107
  Relationships: [
108
108
  {
109
- foreignKeyName: "tbl_broadcast_logs_broadcast_id_fkey"
110
- columns: ["broadcast_id"]
111
- isOneToOne: false
112
- referencedRelation: "tbl_broadcast_messages"
113
- referencedColumns: ["broadcast_id"]
109
+ foreignKeyName: 'tbl_broadcast_logs_broadcast_id_fkey';
110
+ columns: ['broadcast_id'];
111
+ isOneToOne: false;
112
+ referencedRelation: 'tbl_broadcast_messages';
113
+ referencedColumns: ['broadcast_id'];
114
114
  },
115
115
  {
116
- foreignKeyName: "tbl_broadcast_logs_broadcast_id_fkey"
117
- columns: ["broadcast_id"]
118
- isOneToOne: false
119
- referencedRelation: "view_broadcast_logs"
120
- referencedColumns: ["broadcast_id"]
116
+ foreignKeyName: 'tbl_broadcast_logs_broadcast_id_fkey';
117
+ columns: ['broadcast_id'];
118
+ isOneToOne: false;
119
+ referencedRelation: 'view_broadcast_logs';
120
+ referencedColumns: ['broadcast_id'];
121
121
  },
122
122
  {
123
- foreignKeyName: "tbl_broadcast_logs_org_id_fkey"
124
- columns: ["org_id"]
125
- isOneToOne: false
126
- referencedRelation: "tbl_org"
127
- referencedColumns: ["org_id"]
123
+ foreignKeyName: 'tbl_broadcast_logs_org_id_fkey';
124
+ columns: ['org_id'];
125
+ isOneToOne: false;
126
+ referencedRelation: 'tbl_org';
127
+ referencedColumns: ['org_id'];
128
128
  },
129
129
  {
130
- foreignKeyName: "tbl_broadcast_logs_org_id_fkey"
131
- columns: ["org_id"]
132
- isOneToOne: false
133
- referencedRelation: "view_org"
134
- referencedColumns: ["org_id"]
130
+ foreignKeyName: 'tbl_broadcast_logs_org_id_fkey';
131
+ columns: ['org_id'];
132
+ isOneToOne: false;
133
+ referencedRelation: 'view_org';
134
+ referencedColumns: ['org_id'];
135
135
  },
136
- ]
137
- }
136
+ ];
137
+ };
138
138
  tbl_broadcast_messages: {
139
139
  Row: {
140
- broadcast_id: string
140
+ broadcast_id: string;
141
141
  broadcast_status:
142
- | Database["public"]["Enums"]["enum_broadcast_status"]
143
- | null
144
- chat_ids: string[] | null
145
- created_at: string
146
- message_payload: Json | null
147
- org_id: string
148
- org_phone: string | null
149
- performed_at: string | null
150
- performed_by: string | null
151
- scheduled_at: string | null
152
- variables: Json | null
153
- }
142
+ | Database['public']['Enums']['enum_broadcast_status']
143
+ | null;
144
+ chat_ids: string[] | null;
145
+ created_at: string;
146
+ message_payload: Json | null;
147
+ org_id: string;
148
+ org_phone: string | null;
149
+ performed_at: string | null;
150
+ performed_by: string | null;
151
+ scheduled_at: string | null;
152
+ variables: Json | null;
153
+ };
154
154
  Insert: {
155
- broadcast_id?: string
155
+ broadcast_id?: string;
156
156
  broadcast_status?:
157
- | Database["public"]["Enums"]["enum_broadcast_status"]
158
- | null
159
- chat_ids?: string[] | null
160
- created_at?: string
161
- message_payload?: Json | null
162
- org_id: string
163
- org_phone?: string | null
164
- performed_at?: string | null
165
- performed_by?: string | null
166
- scheduled_at?: string | null
167
- variables?: Json | null
168
- }
157
+ | Database['public']['Enums']['enum_broadcast_status']
158
+ | null;
159
+ chat_ids?: string[] | null;
160
+ created_at?: string;
161
+ message_payload?: Json | null;
162
+ org_id: string;
163
+ org_phone?: string | null;
164
+ performed_at?: string | null;
165
+ performed_by?: string | null;
166
+ scheduled_at?: string | null;
167
+ variables?: Json | null;
168
+ };
169
169
  Update: {
170
- broadcast_id?: string
170
+ broadcast_id?: string;
171
171
  broadcast_status?:
172
- | Database["public"]["Enums"]["enum_broadcast_status"]
173
- | null
174
- chat_ids?: string[] | null
175
- created_at?: string
176
- message_payload?: Json | null
177
- org_id?: string
178
- org_phone?: string | null
179
- performed_at?: string | null
180
- performed_by?: string | null
181
- scheduled_at?: string | null
182
- variables?: Json | null
183
- }
172
+ | Database['public']['Enums']['enum_broadcast_status']
173
+ | null;
174
+ chat_ids?: string[] | null;
175
+ created_at?: string;
176
+ message_payload?: Json | null;
177
+ org_id?: string;
178
+ org_phone?: string | null;
179
+ performed_at?: string | null;
180
+ performed_by?: string | null;
181
+ scheduled_at?: string | null;
182
+ variables?: Json | null;
183
+ };
184
184
  Relationships: [
185
185
  {
186
- foreignKeyName: "tbl_broadcast_messages_org_id_fkey"
187
- columns: ["org_id"]
188
- isOneToOne: false
189
- referencedRelation: "tbl_org"
190
- referencedColumns: ["org_id"]
186
+ foreignKeyName: 'tbl_broadcast_messages_org_id_fkey';
187
+ columns: ['org_id'];
188
+ isOneToOne: false;
189
+ referencedRelation: 'tbl_org';
190
+ referencedColumns: ['org_id'];
191
191
  },
192
192
  {
193
- foreignKeyName: "tbl_broadcast_messages_org_id_fkey"
194
- columns: ["org_id"]
195
- isOneToOne: false
196
- referencedRelation: "view_org"
197
- referencedColumns: ["org_id"]
193
+ foreignKeyName: 'tbl_broadcast_messages_org_id_fkey';
194
+ columns: ['org_id'];
195
+ isOneToOne: false;
196
+ referencedRelation: 'view_org';
197
+ referencedColumns: ['org_id'];
198
198
  },
199
- ]
200
- }
199
+ ];
200
+ };
201
201
  tbl_broadcast_templates: {
202
202
  Row: {
203
- created_at: string
204
- message_payload: Json | null
205
- org_id: string
206
- template_id: string
207
- template_name: string | null
208
- updated_at: string | null
209
- variable_names: Json | null
210
- }
203
+ created_at: string;
204
+ message_payload: Json | null;
205
+ org_id: string;
206
+ template_id: string;
207
+ template_name: string | null;
208
+ updated_at: string | null;
209
+ variable_names: Json | null;
210
+ };
211
211
  Insert: {
212
- created_at?: string
213
- message_payload?: Json | null
214
- org_id: string
215
- template_id?: string
216
- template_name?: string | null
217
- updated_at?: string | null
218
- variable_names?: Json | null
219
- }
212
+ created_at?: string;
213
+ message_payload?: Json | null;
214
+ org_id: string;
215
+ template_id?: string;
216
+ template_name?: string | null;
217
+ updated_at?: string | null;
218
+ variable_names?: Json | null;
219
+ };
220
220
  Update: {
221
- created_at?: string
222
- message_payload?: Json | null
223
- org_id?: string
224
- template_id?: string
225
- template_name?: string | null
226
- updated_at?: string | null
227
- variable_names?: Json | null
228
- }
221
+ created_at?: string;
222
+ message_payload?: Json | null;
223
+ org_id?: string;
224
+ template_id?: string;
225
+ template_name?: string | null;
226
+ updated_at?: string | null;
227
+ variable_names?: Json | null;
228
+ };
229
229
  Relationships: [
230
230
  {
231
- foreignKeyName: "tbl_broadcast_templates_org_id_fkey"
232
- columns: ["org_id"]
233
- isOneToOne: false
234
- referencedRelation: "tbl_org"
235
- referencedColumns: ["org_id"]
231
+ foreignKeyName: 'tbl_broadcast_templates_org_id_fkey';
232
+ columns: ['org_id'];
233
+ isOneToOne: false;
234
+ referencedRelation: 'tbl_org';
235
+ referencedColumns: ['org_id'];
236
236
  },
237
237
  {
238
- foreignKeyName: "tbl_broadcast_templates_org_id_fkey"
239
- columns: ["org_id"]
240
- isOneToOne: false
241
- referencedRelation: "view_org"
242
- referencedColumns: ["org_id"]
238
+ foreignKeyName: 'tbl_broadcast_templates_org_id_fkey';
239
+ columns: ['org_id'];
240
+ isOneToOne: false;
241
+ referencedRelation: 'view_org';
242
+ referencedColumns: ['org_id'];
243
243
  },
244
- ]
245
- }
244
+ ];
245
+ };
246
246
  tbl_chat_access: {
247
247
  Row: {
248
- active_phone: string | null
249
- chat_id: string
250
- email: string
251
- has_access: boolean | null
252
- last_read_timestamp: string | null
253
- message_unread_count: number | null
254
- org_id: string
255
- }
248
+ active_phone: string | null;
249
+ chat_id: string;
250
+ email: string;
251
+ has_access: boolean | null;
252
+ last_read_timestamp: string | null;
253
+ message_unread_count: number | null;
254
+ org_id: string;
255
+ };
256
256
  Insert: {
257
- active_phone?: string | null
258
- chat_id: string
259
- email: string
260
- has_access?: boolean | null
261
- last_read_timestamp?: string | null
262
- message_unread_count?: number | null
263
- org_id: string
264
- }
257
+ active_phone?: string | null;
258
+ chat_id: string;
259
+ email: string;
260
+ has_access?: boolean | null;
261
+ last_read_timestamp?: string | null;
262
+ message_unread_count?: number | null;
263
+ org_id: string;
264
+ };
265
265
  Update: {
266
- active_phone?: string | null
267
- chat_id?: string
268
- email?: string
269
- has_access?: boolean | null
270
- last_read_timestamp?: string | null
271
- message_unread_count?: number | null
272
- org_id?: string
273
- }
266
+ active_phone?: string | null;
267
+ chat_id?: string;
268
+ email?: string;
269
+ has_access?: boolean | null;
270
+ last_read_timestamp?: string | null;
271
+ message_unread_count?: number | null;
272
+ org_id?: string;
273
+ };
274
274
  Relationships: [
275
275
  {
276
- foreignKeyName: "tbl_chat_access_org_id_email_fkey"
277
- columns: ["org_id", "email"]
278
- isOneToOne: false
279
- referencedRelation: "tbl_org_members"
280
- referencedColumns: ["org_id", "email"]
276
+ foreignKeyName: 'tbl_chat_access_org_id_email_fkey';
277
+ columns: ['org_id', 'email'];
278
+ isOneToOne: false;
279
+ referencedRelation: 'tbl_org_members';
280
+ referencedColumns: ['org_id', 'email'];
281
281
  },
282
- ]
283
- }
282
+ ];
283
+ };
284
284
  tbl_chat_logs: {
285
285
  Row: {
286
- action: string | null
287
- chat_id: string | null
288
- is_success: boolean | null
289
- log_id: string
290
- metadata: Json | null
291
- operation_id: string
292
- org_id: string
293
- org_phone: string
294
- participant_id: string | null
295
- performed_by: string | null
296
- timestamp: string | null
297
- }
286
+ action: string | null;
287
+ chat_id: string | null;
288
+ is_success: boolean | null;
289
+ log_id: string;
290
+ metadata: Json | null;
291
+ operation_id: string;
292
+ org_id: string;
293
+ org_phone: string;
294
+ participant_id: string | null;
295
+ performed_by: string | null;
296
+ timestamp: string | null;
297
+ };
298
298
  Insert: {
299
- action?: string | null
300
- chat_id?: string | null
301
- is_success?: boolean | null
302
- log_id?: string
303
- metadata?: Json | null
304
- operation_id: string
305
- org_id: string
306
- org_phone: string
307
- participant_id?: string | null
308
- performed_by?: string | null
309
- timestamp?: string | null
310
- }
299
+ action?: string | null;
300
+ chat_id?: string | null;
301
+ is_success?: boolean | null;
302
+ log_id?: string;
303
+ metadata?: Json | null;
304
+ operation_id: string;
305
+ org_id: string;
306
+ org_phone: string;
307
+ participant_id?: string | null;
308
+ performed_by?: string | null;
309
+ timestamp?: string | null;
310
+ };
311
311
  Update: {
312
- action?: string | null
313
- chat_id?: string | null
314
- is_success?: boolean | null
315
- log_id?: string
316
- metadata?: Json | null
317
- operation_id?: string
318
- org_id?: string
319
- org_phone?: string
320
- participant_id?: string | null
321
- performed_by?: string | null
322
- timestamp?: string | null
323
- }
312
+ action?: string | null;
313
+ chat_id?: string | null;
314
+ is_success?: boolean | null;
315
+ log_id?: string;
316
+ metadata?: Json | null;
317
+ operation_id?: string;
318
+ org_id?: string;
319
+ org_phone?: string;
320
+ participant_id?: string | null;
321
+ performed_by?: string | null;
322
+ timestamp?: string | null;
323
+ };
324
324
  Relationships: [
325
325
  {
326
- foreignKeyName: "tbl_chat_logs_org_id_fkey"
327
- columns: ["org_id"]
328
- isOneToOne: false
329
- referencedRelation: "tbl_org"
330
- referencedColumns: ["org_id"]
326
+ foreignKeyName: 'tbl_chat_logs_org_id_fkey';
327
+ columns: ['org_id'];
328
+ isOneToOne: false;
329
+ referencedRelation: 'tbl_org';
330
+ referencedColumns: ['org_id'];
331
331
  },
332
332
  {
333
- foreignKeyName: "tbl_chat_logs_org_id_fkey"
334
- columns: ["org_id"]
335
- isOneToOne: false
336
- referencedRelation: "view_org"
337
- referencedColumns: ["org_id"]
333
+ foreignKeyName: 'tbl_chat_logs_org_id_fkey';
334
+ columns: ['org_id'];
335
+ isOneToOne: false;
336
+ referencedRelation: 'view_org';
337
+ referencedColumns: ['org_id'];
338
338
  },
339
- ]
340
- }
339
+ ];
340
+ };
341
341
  tbl_chat_messages: {
342
342
  Row: {
343
- ack: string | null
344
- author: string | null
345
- body: string | null
346
- broadcast: boolean | null
347
- broadcast_id: string | null
348
- chat_id: string | null
349
- delivery_info: Json | null
350
- device_type: string | null
351
- duration: string | null
352
- flag_metadata: Json | null
353
- flag_response_time: number | null
354
- forwarding_score: number | null
355
- from: string | null
356
- from_me: boolean | null
357
- has_media: boolean | null
358
- has_quoted_msg: boolean | null
359
- has_reaction: boolean | null
360
- id: Json | null
361
- invite_v4: Json | null
362
- is_deleted: boolean | null
363
- is_ephemeral: boolean | null
364
- is_forwarded: boolean | null
365
- is_gif: boolean | null
366
- is_starred: boolean | null
367
- is_status: boolean | null
368
- links: Json | null
369
- location: Json | null
370
- media: Json | null
371
- media_key: string | null
372
- mentioned_ids: string[] | null
373
- message_id: string
374
- message_ticket_id: string | null
375
- message_type: string | null
376
- order_id: string | null
377
- org_id: string
378
- org_phone: string
379
- performed_by: string | null
380
- prev_body: string | null
381
- quoted_message_id: string | null
382
- raw_data: Json | null
383
- sender_phone: string | null
384
- sent_message_id: string | null
385
- timestamp: string | null
386
- to: string | null
387
- token: string | null
388
- unique_id: string | null
389
- updated_at: string | null
390
- vcards: string[] | null
391
- }
343
+ ack: string | null;
344
+ author: string | null;
345
+ body: string | null;
346
+ broadcast: boolean | null;
347
+ broadcast_id: string | null;
348
+ chat_id: string | null;
349
+ delivery_info: Json | null;
350
+ device_type: string | null;
351
+ duration: string | null;
352
+ flag_metadata: Json | null;
353
+ flag_response_time: number | null;
354
+ forwarding_score: number | null;
355
+ from: string | null;
356
+ from_me: boolean | null;
357
+ has_media: boolean | null;
358
+ has_quoted_msg: boolean | null;
359
+ has_reaction: boolean | null;
360
+ id: Json | null;
361
+ invite_v4: Json | null;
362
+ is_deleted: boolean | null;
363
+ is_ephemeral: boolean | null;
364
+ is_forwarded: boolean | null;
365
+ is_gif: boolean | null;
366
+ is_starred: boolean | null;
367
+ is_status: boolean | null;
368
+ links: Json | null;
369
+ location: Json | null;
370
+ media: Json | null;
371
+ media_key: string | null;
372
+ mentioned_ids: string[] | null;
373
+ message_id: string;
374
+ message_ticket_id: string | null;
375
+ message_type: string | null;
376
+ order_id: string | null;
377
+ org_id: string;
378
+ org_phone: string;
379
+ performed_by: string | null;
380
+ prev_body: string | null;
381
+ quoted_message_id: string | null;
382
+ raw_data: Json | null;
383
+ sender_phone: string | null;
384
+ sent_message_id: string | null;
385
+ timestamp: string | null;
386
+ to: string | null;
387
+ token: string | null;
388
+ unique_id: string | null;
389
+ updated_at: string | null;
390
+ vcards: string[] | null;
391
+ };
392
392
  Insert: {
393
- ack?: string | null
394
- author?: string | null
395
- body?: string | null
396
- broadcast?: boolean | null
397
- broadcast_id?: string | null
398
- chat_id?: string | null
399
- delivery_info?: Json | null
400
- device_type?: string | null
401
- duration?: string | null
402
- flag_metadata?: Json | null
403
- flag_response_time?: number | null
404
- forwarding_score?: number | null
405
- from?: string | null
406
- from_me?: boolean | null
407
- has_media?: boolean | null
408
- has_quoted_msg?: boolean | null
409
- has_reaction?: boolean | null
410
- id?: Json | null
411
- invite_v4?: Json | null
412
- is_deleted?: boolean | null
413
- is_ephemeral?: boolean | null
414
- is_forwarded?: boolean | null
415
- is_gif?: boolean | null
416
- is_starred?: boolean | null
417
- is_status?: boolean | null
418
- links?: Json | null
419
- location?: Json | null
420
- media?: Json | null
421
- media_key?: string | null
422
- mentioned_ids?: string[] | null
423
- message_id: string
424
- message_ticket_id?: string | null
425
- message_type?: string | null
426
- order_id?: string | null
427
- org_id: string
428
- org_phone: string
429
- performed_by?: string | null
430
- prev_body?: string | null
431
- quoted_message_id?: string | null
432
- raw_data?: Json | null
433
- sender_phone?: string | null
434
- sent_message_id?: string | null
435
- timestamp?: string | null
436
- to?: string | null
437
- token?: string | null
438
- unique_id?: string | null
439
- updated_at?: string | null
440
- vcards?: string[] | null
441
- }
393
+ ack?: string | null;
394
+ author?: string | null;
395
+ body?: string | null;
396
+ broadcast?: boolean | null;
397
+ broadcast_id?: string | null;
398
+ chat_id?: string | null;
399
+ delivery_info?: Json | null;
400
+ device_type?: string | null;
401
+ duration?: string | null;
402
+ flag_metadata?: Json | null;
403
+ flag_response_time?: number | null;
404
+ forwarding_score?: number | null;
405
+ from?: string | null;
406
+ from_me?: boolean | null;
407
+ has_media?: boolean | null;
408
+ has_quoted_msg?: boolean | null;
409
+ has_reaction?: boolean | null;
410
+ id?: Json | null;
411
+ invite_v4?: Json | null;
412
+ is_deleted?: boolean | null;
413
+ is_ephemeral?: boolean | null;
414
+ is_forwarded?: boolean | null;
415
+ is_gif?: boolean | null;
416
+ is_starred?: boolean | null;
417
+ is_status?: boolean | null;
418
+ links?: Json | null;
419
+ location?: Json | null;
420
+ media?: Json | null;
421
+ media_key?: string | null;
422
+ mentioned_ids?: string[] | null;
423
+ message_id: string;
424
+ message_ticket_id?: string | null;
425
+ message_type?: string | null;
426
+ order_id?: string | null;
427
+ org_id: string;
428
+ org_phone: string;
429
+ performed_by?: string | null;
430
+ prev_body?: string | null;
431
+ quoted_message_id?: string | null;
432
+ raw_data?: Json | null;
433
+ sender_phone?: string | null;
434
+ sent_message_id?: string | null;
435
+ timestamp?: string | null;
436
+ to?: string | null;
437
+ token?: string | null;
438
+ unique_id?: string | null;
439
+ updated_at?: string | null;
440
+ vcards?: string[] | null;
441
+ };
442
442
  Update: {
443
- ack?: string | null
444
- author?: string | null
445
- body?: string | null
446
- broadcast?: boolean | null
447
- broadcast_id?: string | null
448
- chat_id?: string | null
449
- delivery_info?: Json | null
450
- device_type?: string | null
451
- duration?: string | null
452
- flag_metadata?: Json | null
453
- flag_response_time?: number | null
454
- forwarding_score?: number | null
455
- from?: string | null
456
- from_me?: boolean | null
457
- has_media?: boolean | null
458
- has_quoted_msg?: boolean | null
459
- has_reaction?: boolean | null
460
- id?: Json | null
461
- invite_v4?: Json | null
462
- is_deleted?: boolean | null
463
- is_ephemeral?: boolean | null
464
- is_forwarded?: boolean | null
465
- is_gif?: boolean | null
466
- is_starred?: boolean | null
467
- is_status?: boolean | null
468
- links?: Json | null
469
- location?: Json | null
470
- media?: Json | null
471
- media_key?: string | null
472
- mentioned_ids?: string[] | null
473
- message_id?: string
474
- message_ticket_id?: string | null
475
- message_type?: string | null
476
- order_id?: string | null
477
- org_id?: string
478
- org_phone?: string
479
- performed_by?: string | null
480
- prev_body?: string | null
481
- quoted_message_id?: string | null
482
- raw_data?: Json | null
483
- sender_phone?: string | null
484
- sent_message_id?: string | null
485
- timestamp?: string | null
486
- to?: string | null
487
- token?: string | null
488
- unique_id?: string | null
489
- updated_at?: string | null
490
- vcards?: string[] | null
491
- }
443
+ ack?: string | null;
444
+ author?: string | null;
445
+ body?: string | null;
446
+ broadcast?: boolean | null;
447
+ broadcast_id?: string | null;
448
+ chat_id?: string | null;
449
+ delivery_info?: Json | null;
450
+ device_type?: string | null;
451
+ duration?: string | null;
452
+ flag_metadata?: Json | null;
453
+ flag_response_time?: number | null;
454
+ forwarding_score?: number | null;
455
+ from?: string | null;
456
+ from_me?: boolean | null;
457
+ has_media?: boolean | null;
458
+ has_quoted_msg?: boolean | null;
459
+ has_reaction?: boolean | null;
460
+ id?: Json | null;
461
+ invite_v4?: Json | null;
462
+ is_deleted?: boolean | null;
463
+ is_ephemeral?: boolean | null;
464
+ is_forwarded?: boolean | null;
465
+ is_gif?: boolean | null;
466
+ is_starred?: boolean | null;
467
+ is_status?: boolean | null;
468
+ links?: Json | null;
469
+ location?: Json | null;
470
+ media?: Json | null;
471
+ media_key?: string | null;
472
+ mentioned_ids?: string[] | null;
473
+ message_id?: string;
474
+ message_ticket_id?: string | null;
475
+ message_type?: string | null;
476
+ order_id?: string | null;
477
+ org_id?: string;
478
+ org_phone?: string;
479
+ performed_by?: string | null;
480
+ prev_body?: string | null;
481
+ quoted_message_id?: string | null;
482
+ raw_data?: Json | null;
483
+ sender_phone?: string | null;
484
+ sent_message_id?: string | null;
485
+ timestamp?: string | null;
486
+ to?: string | null;
487
+ token?: string | null;
488
+ unique_id?: string | null;
489
+ updated_at?: string | null;
490
+ vcards?: string[] | null;
491
+ };
492
492
  Relationships: [
493
493
  {
494
- foreignKeyName: "tbl_chat_messages_parent_fkey_tbl_org_phones"
495
- columns: ["org_phone", "org_id"]
496
- isOneToOne: false
497
- referencedRelation: "tbl_org_phones"
498
- referencedColumns: ["org_phone", "org_id"]
494
+ foreignKeyName: 'tbl_chat_messages_parent_fkey_tbl_org_phones';
495
+ columns: ['org_phone', 'org_id'];
496
+ isOneToOne: false;
497
+ referencedRelation: 'tbl_org_phones';
498
+ referencedColumns: ['org_phone', 'org_id'];
499
499
  },
500
- ]
501
- }
502
- tbl_chat_messages_2997dd64_89bf_48d3_9a22_b314fca017e5: {
503
- Row: {
504
- ack: string | null
505
- author: string | null
506
- body: string | null
507
- broadcast: boolean | null
508
- broadcast_id: string | null
509
- chat_id: string | null
510
- delivery_info: Json | null
511
- device_type: string | null
512
- duration: string | null
513
- flag_metadata: Json | null
514
- flag_response_time: number | null
515
- forwarding_score: number | null
516
- from: string | null
517
- from_me: boolean | null
518
- has_media: boolean | null
519
- has_quoted_msg: boolean | null
520
- has_reaction: boolean | null
521
- id: Json | null
522
- invite_v4: Json | null
523
- is_deleted: boolean | null
524
- is_ephemeral: boolean | null
525
- is_forwarded: boolean | null
526
- is_gif: boolean | null
527
- is_starred: boolean | null
528
- is_status: boolean | null
529
- links: Json | null
530
- location: Json | null
531
- media: Json | null
532
- media_key: string | null
533
- mentioned_ids: string[] | null
534
- message_id: string
535
- message_ticket_id: string | null
536
- message_type: string | null
537
- order_id: string | null
538
- org_id: string
539
- org_phone: string
540
- performed_by: string | null
541
- prev_body: string | null
542
- quoted_message_id: string | null
543
- raw_data: Json | null
544
- sender_phone: string | null
545
- sent_message_id: string | null
546
- timestamp: string | null
547
- to: string | null
548
- token: string | null
549
- unique_id: string | null
550
- updated_at: string | null
551
- vcards: string[] | null
552
- }
553
- Insert: {
554
- ack?: string | null
555
- author?: string | null
556
- body?: string | null
557
- broadcast?: boolean | null
558
- broadcast_id?: string | null
559
- chat_id?: string | null
560
- delivery_info?: Json | null
561
- device_type?: string | null
562
- duration?: string | null
563
- flag_metadata?: Json | null
564
- flag_response_time?: number | null
565
- forwarding_score?: number | null
566
- from?: string | null
567
- from_me?: boolean | null
568
- has_media?: boolean | null
569
- has_quoted_msg?: boolean | null
570
- has_reaction?: boolean | null
571
- id?: Json | null
572
- invite_v4?: Json | null
573
- is_deleted?: boolean | null
574
- is_ephemeral?: boolean | null
575
- is_forwarded?: boolean | null
576
- is_gif?: boolean | null
577
- is_starred?: boolean | null
578
- is_status?: boolean | null
579
- links?: Json | null
580
- location?: Json | null
581
- media?: Json | null
582
- media_key?: string | null
583
- mentioned_ids?: string[] | null
584
- message_id: string
585
- message_ticket_id?: string | null
586
- message_type?: string | null
587
- order_id?: string | null
588
- org_id: string
589
- org_phone: string
590
- performed_by?: string | null
591
- prev_body?: string | null
592
- quoted_message_id?: string | null
593
- raw_data?: Json | null
594
- sender_phone?: string | null
595
- sent_message_id?: string | null
596
- timestamp?: string | null
597
- to?: string | null
598
- token?: string | null
599
- unique_id?: string | null
600
- updated_at?: string | null
601
- vcards?: string[] | null
602
- }
603
- Update: {
604
- ack?: string | null
605
- author?: string | null
606
- body?: string | null
607
- broadcast?: boolean | null
608
- broadcast_id?: string | null
609
- chat_id?: string | null
610
- delivery_info?: Json | null
611
- device_type?: string | null
612
- duration?: string | null
613
- flag_metadata?: Json | null
614
- flag_response_time?: number | null
615
- forwarding_score?: number | null
616
- from?: string | null
617
- from_me?: boolean | null
618
- has_media?: boolean | null
619
- has_quoted_msg?: boolean | null
620
- has_reaction?: boolean | null
621
- id?: Json | null
622
- invite_v4?: Json | null
623
- is_deleted?: boolean | null
624
- is_ephemeral?: boolean | null
625
- is_forwarded?: boolean | null
626
- is_gif?: boolean | null
627
- is_starred?: boolean | null
628
- is_status?: boolean | null
629
- links?: Json | null
630
- location?: Json | null
631
- media?: Json | null
632
- media_key?: string | null
633
- mentioned_ids?: string[] | null
634
- message_id?: string
635
- message_ticket_id?: string | null
636
- message_type?: string | null
637
- order_id?: string | null
638
- org_id?: string
639
- org_phone?: string
640
- performed_by?: string | null
641
- prev_body?: string | null
642
- quoted_message_id?: string | null
643
- raw_data?: Json | null
644
- sender_phone?: string | null
645
- sent_message_id?: string | null
646
- timestamp?: string | null
647
- to?: string | null
648
- token?: string | null
649
- unique_id?: string | null
650
- updated_at?: string | null
651
- vcards?: string[] | null
652
- }
653
- Relationships: []
654
- }
500
+ ];
501
+ };
655
502
  tbl_chat_messages_default: {
656
503
  Row: {
657
- ack: string | null
658
- author: string | null
659
- body: string | null
660
- broadcast: boolean | null
661
- broadcast_id: string | null
662
- chat_id: string | null
663
- delivery_info: Json | null
664
- device_type: string | null
665
- duration: string | null
666
- flag_metadata: Json | null
667
- flag_response_time: number | null
668
- forwarding_score: number | null
669
- from: string | null
670
- from_me: boolean | null
671
- has_media: boolean | null
672
- has_quoted_msg: boolean | null
673
- has_reaction: boolean | null
674
- id: Json | null
675
- invite_v4: Json | null
676
- is_deleted: boolean | null
677
- is_ephemeral: boolean | null
678
- is_forwarded: boolean | null
679
- is_gif: boolean | null
680
- is_starred: boolean | null
681
- is_status: boolean | null
682
- links: Json | null
683
- location: Json | null
684
- media: Json | null
685
- media_key: string | null
686
- mentioned_ids: string[] | null
687
- message_id: string
688
- message_ticket_id: string | null
689
- message_type: string | null
690
- order_id: string | null
691
- org_id: string
692
- org_phone: string
693
- performed_by: string | null
694
- prev_body: string | null
695
- quoted_message_id: string | null
696
- raw_data: Json | null
697
- sender_phone: string | null
698
- sent_message_id: string | null
699
- timestamp: string | null
700
- to: string | null
701
- token: string | null
702
- unique_id: string | null
703
- updated_at: string | null
704
- vcards: string[] | null
705
- }
504
+ ack: string | null;
505
+ author: string | null;
506
+ body: string | null;
507
+ broadcast: boolean | null;
508
+ broadcast_id: string | null;
509
+ chat_id: string | null;
510
+ delivery_info: Json | null;
511
+ device_type: string | null;
512
+ duration: string | null;
513
+ flag_metadata: Json | null;
514
+ flag_response_time: number | null;
515
+ forwarding_score: number | null;
516
+ from: string | null;
517
+ from_me: boolean | null;
518
+ has_media: boolean | null;
519
+ has_quoted_msg: boolean | null;
520
+ has_reaction: boolean | null;
521
+ id: Json | null;
522
+ invite_v4: Json | null;
523
+ is_deleted: boolean | null;
524
+ is_ephemeral: boolean | null;
525
+ is_forwarded: boolean | null;
526
+ is_gif: boolean | null;
527
+ is_starred: boolean | null;
528
+ is_status: boolean | null;
529
+ links: Json | null;
530
+ location: Json | null;
531
+ media: Json | null;
532
+ media_key: string | null;
533
+ mentioned_ids: string[] | null;
534
+ message_id: string;
535
+ message_ticket_id: string | null;
536
+ message_type: string | null;
537
+ order_id: string | null;
538
+ org_id: string;
539
+ org_phone: string;
540
+ performed_by: string | null;
541
+ prev_body: string | null;
542
+ quoted_message_id: string | null;
543
+ raw_data: Json | null;
544
+ sender_phone: string | null;
545
+ sent_message_id: string | null;
546
+ timestamp: string | null;
547
+ to: string | null;
548
+ token: string | null;
549
+ unique_id: string | null;
550
+ updated_at: string | null;
551
+ vcards: string[] | null;
552
+ };
706
553
  Insert: {
707
- ack?: string | null
708
- author?: string | null
709
- body?: string | null
710
- broadcast?: boolean | null
711
- broadcast_id?: string | null
712
- chat_id?: string | null
713
- delivery_info?: Json | null
714
- device_type?: string | null
715
- duration?: string | null
716
- flag_metadata?: Json | null
717
- flag_response_time?: number | null
718
- forwarding_score?: number | null
719
- from?: string | null
720
- from_me?: boolean | null
721
- has_media?: boolean | null
722
- has_quoted_msg?: boolean | null
723
- has_reaction?: boolean | null
724
- id?: Json | null
725
- invite_v4?: Json | null
726
- is_deleted?: boolean | null
727
- is_ephemeral?: boolean | null
728
- is_forwarded?: boolean | null
729
- is_gif?: boolean | null
730
- is_starred?: boolean | null
731
- is_status?: boolean | null
732
- links?: Json | null
733
- location?: Json | null
734
- media?: Json | null
735
- media_key?: string | null
736
- mentioned_ids?: string[] | null
737
- message_id: string
738
- message_ticket_id?: string | null
739
- message_type?: string | null
740
- order_id?: string | null
741
- org_id: string
742
- org_phone: string
743
- performed_by?: string | null
744
- prev_body?: string | null
745
- quoted_message_id?: string | null
746
- raw_data?: Json | null
747
- sender_phone?: string | null
748
- sent_message_id?: string | null
749
- timestamp?: string | null
750
- to?: string | null
751
- token?: string | null
752
- unique_id?: string | null
753
- updated_at?: string | null
754
- vcards?: string[] | null
755
- }
554
+ ack?: string | null;
555
+ author?: string | null;
556
+ body?: string | null;
557
+ broadcast?: boolean | null;
558
+ broadcast_id?: string | null;
559
+ chat_id?: string | null;
560
+ delivery_info?: Json | null;
561
+ device_type?: string | null;
562
+ duration?: string | null;
563
+ flag_metadata?: Json | null;
564
+ flag_response_time?: number | null;
565
+ forwarding_score?: number | null;
566
+ from?: string | null;
567
+ from_me?: boolean | null;
568
+ has_media?: boolean | null;
569
+ has_quoted_msg?: boolean | null;
570
+ has_reaction?: boolean | null;
571
+ id?: Json | null;
572
+ invite_v4?: Json | null;
573
+ is_deleted?: boolean | null;
574
+ is_ephemeral?: boolean | null;
575
+ is_forwarded?: boolean | null;
576
+ is_gif?: boolean | null;
577
+ is_starred?: boolean | null;
578
+ is_status?: boolean | null;
579
+ links?: Json | null;
580
+ location?: Json | null;
581
+ media?: Json | null;
582
+ media_key?: string | null;
583
+ mentioned_ids?: string[] | null;
584
+ message_id: string;
585
+ message_ticket_id?: string | null;
586
+ message_type?: string | null;
587
+ order_id?: string | null;
588
+ org_id: string;
589
+ org_phone: string;
590
+ performed_by?: string | null;
591
+ prev_body?: string | null;
592
+ quoted_message_id?: string | null;
593
+ raw_data?: Json | null;
594
+ sender_phone?: string | null;
595
+ sent_message_id?: string | null;
596
+ timestamp?: string | null;
597
+ to?: string | null;
598
+ token?: string | null;
599
+ unique_id?: string | null;
600
+ updated_at?: string | null;
601
+ vcards?: string[] | null;
602
+ };
756
603
  Update: {
757
- ack?: string | null
758
- author?: string | null
759
- body?: string | null
760
- broadcast?: boolean | null
761
- broadcast_id?: string | null
762
- chat_id?: string | null
763
- delivery_info?: Json | null
764
- device_type?: string | null
765
- duration?: string | null
766
- flag_metadata?: Json | null
767
- flag_response_time?: number | null
768
- forwarding_score?: number | null
769
- from?: string | null
770
- from_me?: boolean | null
771
- has_media?: boolean | null
772
- has_quoted_msg?: boolean | null
773
- has_reaction?: boolean | null
774
- id?: Json | null
775
- invite_v4?: Json | null
776
- is_deleted?: boolean | null
777
- is_ephemeral?: boolean | null
778
- is_forwarded?: boolean | null
779
- is_gif?: boolean | null
780
- is_starred?: boolean | null
781
- is_status?: boolean | null
782
- links?: Json | null
783
- location?: Json | null
784
- media?: Json | null
785
- media_key?: string | null
786
- mentioned_ids?: string[] | null
787
- message_id?: string
788
- message_ticket_id?: string | null
789
- message_type?: string | null
790
- order_id?: string | null
791
- org_id?: string
792
- org_phone?: string
793
- performed_by?: string | null
794
- prev_body?: string | null
795
- quoted_message_id?: string | null
796
- raw_data?: Json | null
797
- sender_phone?: string | null
798
- sent_message_id?: string | null
799
- timestamp?: string | null
800
- to?: string | null
801
- token?: string | null
802
- unique_id?: string | null
803
- updated_at?: string | null
804
- vcards?: string[] | null
805
- }
806
- Relationships: []
807
- }
604
+ ack?: string | null;
605
+ author?: string | null;
606
+ body?: string | null;
607
+ broadcast?: boolean | null;
608
+ broadcast_id?: string | null;
609
+ chat_id?: string | null;
610
+ delivery_info?: Json | null;
611
+ device_type?: string | null;
612
+ duration?: string | null;
613
+ flag_metadata?: Json | null;
614
+ flag_response_time?: number | null;
615
+ forwarding_score?: number | null;
616
+ from?: string | null;
617
+ from_me?: boolean | null;
618
+ has_media?: boolean | null;
619
+ has_quoted_msg?: boolean | null;
620
+ has_reaction?: boolean | null;
621
+ id?: Json | null;
622
+ invite_v4?: Json | null;
623
+ is_deleted?: boolean | null;
624
+ is_ephemeral?: boolean | null;
625
+ is_forwarded?: boolean | null;
626
+ is_gif?: boolean | null;
627
+ is_starred?: boolean | null;
628
+ is_status?: boolean | null;
629
+ links?: Json | null;
630
+ location?: Json | null;
631
+ media?: Json | null;
632
+ media_key?: string | null;
633
+ mentioned_ids?: string[] | null;
634
+ message_id?: string;
635
+ message_ticket_id?: string | null;
636
+ message_type?: string | null;
637
+ order_id?: string | null;
638
+ org_id?: string;
639
+ org_phone?: string;
640
+ performed_by?: string | null;
641
+ prev_body?: string | null;
642
+ quoted_message_id?: string | null;
643
+ raw_data?: Json | null;
644
+ sender_phone?: string | null;
645
+ sent_message_id?: string | null;
646
+ timestamp?: string | null;
647
+ to?: string | null;
648
+ token?: string | null;
649
+ unique_id?: string | null;
650
+ updated_at?: string | null;
651
+ vcards?: string[] | null;
652
+ };
653
+ Relationships: [];
654
+ };
808
655
  tbl_chat_notifications: {
809
656
  Row: {
810
- author: string | null
811
- body: string | null
812
- chat_id: string | null
813
- id: Json | null
814
- notification_id: string
815
- org_id: string
816
- org_phone: string
817
- recipientids: string[] | null
818
- timestamp: string | null
819
- type: string | null
820
- unique_id: string | null
821
- }
657
+ author: string | null;
658
+ body: string | null;
659
+ chat_id: string | null;
660
+ id: Json | null;
661
+ notification_id: string;
662
+ org_id: string;
663
+ org_phone: string;
664
+ recipientids: string[] | null;
665
+ timestamp: string | null;
666
+ type: string | null;
667
+ unique_id: string | null;
668
+ };
822
669
  Insert: {
823
- author?: string | null
824
- body?: string | null
825
- chat_id?: string | null
826
- id?: Json | null
827
- notification_id: string
828
- org_id: string
829
- org_phone: string
830
- recipientids?: string[] | null
831
- timestamp?: string | null
832
- type?: string | null
833
- unique_id?: string | null
834
- }
670
+ author?: string | null;
671
+ body?: string | null;
672
+ chat_id?: string | null;
673
+ id?: Json | null;
674
+ notification_id: string;
675
+ org_id: string;
676
+ org_phone: string;
677
+ recipientids?: string[] | null;
678
+ timestamp?: string | null;
679
+ type?: string | null;
680
+ unique_id?: string | null;
681
+ };
835
682
  Update: {
836
- author?: string | null
837
- body?: string | null
838
- chat_id?: string | null
839
- id?: Json | null
840
- notification_id?: string
841
- org_id?: string
842
- org_phone?: string
843
- recipientids?: string[] | null
844
- timestamp?: string | null
845
- type?: string | null
846
- unique_id?: string | null
847
- }
683
+ author?: string | null;
684
+ body?: string | null;
685
+ chat_id?: string | null;
686
+ id?: Json | null;
687
+ notification_id?: string;
688
+ org_id?: string;
689
+ org_phone?: string;
690
+ recipientids?: string[] | null;
691
+ timestamp?: string | null;
692
+ type?: string | null;
693
+ unique_id?: string | null;
694
+ };
848
695
  Relationships: [
849
696
  {
850
- foreignKeyName: "tbl_chat_notifications_fkey_tbl_org_phones"
851
- columns: ["org_id", "org_phone"]
852
- isOneToOne: false
853
- referencedRelation: "tbl_org_phones"
854
- referencedColumns: ["org_id", "org_phone"]
697
+ foreignKeyName: 'tbl_chat_notifications_fkey_tbl_org_phones';
698
+ columns: ['org_id', 'org_phone'];
699
+ isOneToOne: false;
700
+ referencedRelation: 'tbl_org_phones';
701
+ referencedColumns: ['org_id', 'org_phone'];
855
702
  },
856
- ]
857
- }
703
+ ];
704
+ };
858
705
  tbl_chat_participants: {
859
706
  Row: {
860
- chat_id: string
861
- contact_id: string
862
- id: Json | null
863
- is_admin: boolean | null
864
- is_super_admin: boolean | null
865
- org_id: string
866
- org_phone: string
867
- }
707
+ chat_id: string;
708
+ contact_id: string;
709
+ id: Json | null;
710
+ is_admin: boolean | null;
711
+ is_super_admin: boolean | null;
712
+ org_id: string;
713
+ org_phone: string;
714
+ };
868
715
  Insert: {
869
- chat_id: string
870
- contact_id: string
871
- id?: Json | null
872
- is_admin?: boolean | null
873
- is_super_admin?: boolean | null
874
- org_id: string
875
- org_phone: string
876
- }
716
+ chat_id: string;
717
+ contact_id: string;
718
+ id?: Json | null;
719
+ is_admin?: boolean | null;
720
+ is_super_admin?: boolean | null;
721
+ org_id: string;
722
+ org_phone: string;
723
+ };
877
724
  Update: {
878
- chat_id?: string
879
- contact_id?: string
880
- id?: Json | null
881
- is_admin?: boolean | null
882
- is_super_admin?: boolean | null
883
- org_id?: string
884
- org_phone?: string
885
- }
725
+ chat_id?: string;
726
+ contact_id?: string;
727
+ id?: Json | null;
728
+ is_admin?: boolean | null;
729
+ is_super_admin?: boolean | null;
730
+ org_id?: string;
731
+ org_phone?: string;
732
+ };
886
733
  Relationships: [
887
734
  {
888
- foreignKeyName: "tbl_chat_participants_fkey_tbl_chats"
889
- columns: ["org_id", "org_phone", "chat_id"]
890
- isOneToOne: false
891
- referencedRelation: "tbl_chats"
892
- referencedColumns: ["org_id", "org_phone", "chat_id"]
735
+ foreignKeyName: 'tbl_chat_participants_fkey_tbl_chats';
736
+ columns: ['org_id', 'org_phone', 'chat_id'];
737
+ isOneToOne: false;
738
+ referencedRelation: 'tbl_chats';
739
+ referencedColumns: ['org_id', 'org_phone', 'chat_id'];
893
740
  },
894
- ]
895
- }
741
+ ];
742
+ };
896
743
  tbl_chat_properties: {
897
744
  Row: {
898
- chat_id: string
899
- custom_properties: Json | null
900
- flag_count: number
901
- hubspot_metadata: Json | null
902
- label_ids: Json | null
903
- org_id: string
904
- }
745
+ chat_id: string;
746
+ custom_properties: Json | null;
747
+ flag_count: number;
748
+ hubspot_metadata: Json | null;
749
+ label_ids: Json | null;
750
+ org_id: string;
751
+ };
905
752
  Insert: {
906
- chat_id: string
907
- custom_properties?: Json | null
908
- flag_count?: number
909
- hubspot_metadata?: Json | null
910
- label_ids?: Json | null
911
- org_id: string
912
- }
753
+ chat_id: string;
754
+ custom_properties?: Json | null;
755
+ flag_count?: number;
756
+ hubspot_metadata?: Json | null;
757
+ label_ids?: Json | null;
758
+ org_id: string;
759
+ };
913
760
  Update: {
914
- chat_id?: string
915
- custom_properties?: Json | null
916
- flag_count?: number
917
- hubspot_metadata?: Json | null
918
- label_ids?: Json | null
919
- org_id?: string
920
- }
921
- Relationships: []
922
- }
761
+ chat_id?: string;
762
+ custom_properties?: Json | null;
763
+ flag_count?: number;
764
+ hubspot_metadata?: Json | null;
765
+ label_ids?: Json | null;
766
+ org_id?: string;
767
+ };
768
+ Relationships: [];
769
+ };
923
770
  tbl_chat_reactions: {
924
771
  Row: {
925
- ack: number | null
926
- chat_id: string | null
927
- id: Json | null
928
- message_id: string
929
- msg_id: Json | null
930
- org_id: string
931
- org_phone: string
932
- orphan: number | null
933
- orphan_reason: string | null
934
- reaction: string | null
935
- reaction_id: string
936
- read: boolean | null
937
- sender_id: string
938
- timestamp: string | null
939
- unique_id: string | null
940
- }
772
+ ack: number | null;
773
+ chat_id: string | null;
774
+ id: Json | null;
775
+ message_id: string;
776
+ msg_id: Json | null;
777
+ org_id: string;
778
+ org_phone: string;
779
+ orphan: number | null;
780
+ orphan_reason: string | null;
781
+ reaction: string | null;
782
+ reaction_id: string;
783
+ read: boolean | null;
784
+ sender_id: string;
785
+ timestamp: string | null;
786
+ unique_id: string | null;
787
+ };
941
788
  Insert: {
942
- ack?: number | null
943
- chat_id?: string | null
944
- id?: Json | null
945
- message_id: string
946
- msg_id?: Json | null
947
- org_id: string
948
- org_phone: string
949
- orphan?: number | null
950
- orphan_reason?: string | null
951
- reaction?: string | null
952
- reaction_id: string
953
- read?: boolean | null
954
- sender_id: string
955
- timestamp?: string | null
956
- unique_id?: string | null
957
- }
789
+ ack?: number | null;
790
+ chat_id?: string | null;
791
+ id?: Json | null;
792
+ message_id: string;
793
+ msg_id?: Json | null;
794
+ org_id: string;
795
+ org_phone: string;
796
+ orphan?: number | null;
797
+ orphan_reason?: string | null;
798
+ reaction?: string | null;
799
+ reaction_id: string;
800
+ read?: boolean | null;
801
+ sender_id: string;
802
+ timestamp?: string | null;
803
+ unique_id?: string | null;
804
+ };
958
805
  Update: {
959
- ack?: number | null
960
- chat_id?: string | null
961
- id?: Json | null
962
- message_id?: string
963
- msg_id?: Json | null
964
- org_id?: string
965
- org_phone?: string
966
- orphan?: number | null
967
- orphan_reason?: string | null
968
- reaction?: string | null
969
- reaction_id?: string
970
- read?: boolean | null
971
- sender_id?: string
972
- timestamp?: string | null
973
- unique_id?: string | null
974
- }
806
+ ack?: number | null;
807
+ chat_id?: string | null;
808
+ id?: Json | null;
809
+ message_id?: string;
810
+ msg_id?: Json | null;
811
+ org_id?: string;
812
+ org_phone?: string;
813
+ orphan?: number | null;
814
+ orphan_reason?: string | null;
815
+ reaction?: string | null;
816
+ reaction_id?: string;
817
+ read?: boolean | null;
818
+ sender_id?: string;
819
+ timestamp?: string | null;
820
+ unique_id?: string | null;
821
+ };
975
822
  Relationships: [
976
823
  {
977
- foreignKeyName: "tbl_chat_reactions_fkey_tbl_org_phones"
978
- columns: ["org_id", "org_phone"]
979
- isOneToOne: false
980
- referencedRelation: "tbl_org_phones"
981
- referencedColumns: ["org_id", "org_phone"]
824
+ foreignKeyName: 'tbl_chat_reactions_fkey_tbl_org_phones';
825
+ columns: ['org_id', 'org_phone'];
826
+ isOneToOne: false;
827
+ referencedRelation: 'tbl_org_phones';
828
+ referencedColumns: ['org_id', 'org_phone'];
982
829
  },
983
- ]
984
- }
830
+ ];
831
+ };
985
832
  tbl_chat_tickets: {
986
833
  Row: {
987
- assigned_by: string | null
988
- assignee: string | null
989
- chat_id: string
990
- close_ticket_metadata: Json | null
991
- closed_at: string | null
992
- created_at: string
993
- due_date: string | null
994
- hubspot_metadata: Json | null
995
- is_deleted: boolean
996
- label_ids: Json | null
997
- last_updated_at: string
998
- org_id: string
999
- priority: number | null
1000
- quoted_message_id: string | null
1001
- raised_by: string | null
1002
- response_time: number | null
1003
- status: Database["public"]["Enums"]["enum_chat_tickets_status"] | null
1004
- subject: string
1005
- ticket_id: string
1006
- ticket_metadata: Json | null
1007
- }
834
+ assigned_by: string | null;
835
+ assignee: string | null;
836
+ chat_id: string;
837
+ close_ticket_metadata: Json | null;
838
+ closed_at: string | null;
839
+ created_at: string;
840
+ due_date: string | null;
841
+ hubspot_metadata: Json | null;
842
+ is_deleted: boolean;
843
+ label_ids: Json | null;
844
+ last_updated_at: string;
845
+ org_id: string;
846
+ priority: number | null;
847
+ quoted_message_id: string | null;
848
+ raised_by: string | null;
849
+ response_time: number | null;
850
+ status:
851
+ | Database['public']['Enums']['enum_chat_tickets_status']
852
+ | null;
853
+ subject: string;
854
+ ticket_id: string;
855
+ ticket_metadata: Json | null;
856
+ };
1008
857
  Insert: {
1009
- assigned_by?: string | null
1010
- assignee?: string | null
1011
- chat_id: string
1012
- close_ticket_metadata?: Json | null
1013
- closed_at?: string | null
1014
- created_at?: string
1015
- due_date?: string | null
1016
- hubspot_metadata?: Json | null
1017
- is_deleted?: boolean
1018
- label_ids?: Json | null
1019
- last_updated_at?: string
1020
- org_id: string
1021
- priority?: number | null
1022
- quoted_message_id?: string | null
1023
- raised_by?: string | null
1024
- response_time?: number | null
858
+ assigned_by?: string | null;
859
+ assignee?: string | null;
860
+ chat_id: string;
861
+ close_ticket_metadata?: Json | null;
862
+ closed_at?: string | null;
863
+ created_at?: string;
864
+ due_date?: string | null;
865
+ hubspot_metadata?: Json | null;
866
+ is_deleted?: boolean;
867
+ label_ids?: Json | null;
868
+ last_updated_at?: string;
869
+ org_id: string;
870
+ priority?: number | null;
871
+ quoted_message_id?: string | null;
872
+ raised_by?: string | null;
873
+ response_time?: number | null;
1025
874
  status?:
1026
- | Database["public"]["Enums"]["enum_chat_tickets_status"]
1027
- | null
1028
- subject: string
1029
- ticket_id?: string
1030
- ticket_metadata?: Json | null
1031
- }
875
+ | Database['public']['Enums']['enum_chat_tickets_status']
876
+ | null;
877
+ subject: string;
878
+ ticket_id?: string;
879
+ ticket_metadata?: Json | null;
880
+ };
1032
881
  Update: {
1033
- assigned_by?: string | null
1034
- assignee?: string | null
1035
- chat_id?: string
1036
- close_ticket_metadata?: Json | null
1037
- closed_at?: string | null
1038
- created_at?: string
1039
- due_date?: string | null
1040
- hubspot_metadata?: Json | null
1041
- is_deleted?: boolean
1042
- label_ids?: Json | null
1043
- last_updated_at?: string
1044
- org_id?: string
1045
- priority?: number | null
1046
- quoted_message_id?: string | null
1047
- raised_by?: string | null
1048
- response_time?: number | null
882
+ assigned_by?: string | null;
883
+ assignee?: string | null;
884
+ chat_id?: string;
885
+ close_ticket_metadata?: Json | null;
886
+ closed_at?: string | null;
887
+ created_at?: string;
888
+ due_date?: string | null;
889
+ hubspot_metadata?: Json | null;
890
+ is_deleted?: boolean;
891
+ label_ids?: Json | null;
892
+ last_updated_at?: string;
893
+ org_id?: string;
894
+ priority?: number | null;
895
+ quoted_message_id?: string | null;
896
+ raised_by?: string | null;
897
+ response_time?: number | null;
1049
898
  status?:
1050
- | Database["public"]["Enums"]["enum_chat_tickets_status"]
1051
- | null
1052
- subject?: string
1053
- ticket_id?: string
1054
- ticket_metadata?: Json | null
1055
- }
899
+ | Database['public']['Enums']['enum_chat_tickets_status']
900
+ | null;
901
+ subject?: string;
902
+ ticket_id?: string;
903
+ ticket_metadata?: Json | null;
904
+ };
1056
905
  Relationships: [
1057
906
  {
1058
- foreignKeyName: "tbl_chat_tickets_org_id_fkey"
1059
- columns: ["org_id"]
1060
- isOneToOne: false
1061
- referencedRelation: "tbl_org"
1062
- referencedColumns: ["org_id"]
907
+ foreignKeyName: 'tbl_chat_tickets_org_id_fkey';
908
+ columns: ['org_id'];
909
+ isOneToOne: false;
910
+ referencedRelation: 'tbl_org';
911
+ referencedColumns: ['org_id'];
1063
912
  },
1064
913
  {
1065
- foreignKeyName: "tbl_chat_tickets_org_id_fkey"
1066
- columns: ["org_id"]
1067
- isOneToOne: false
1068
- referencedRelation: "view_org"
1069
- referencedColumns: ["org_id"]
914
+ foreignKeyName: 'tbl_chat_tickets_org_id_fkey';
915
+ columns: ['org_id'];
916
+ isOneToOne: false;
917
+ referencedRelation: 'view_org';
918
+ referencedColumns: ['org_id'];
1070
919
  },
1071
- ]
1072
- }
920
+ ];
921
+ };
1073
922
  tbl_chats: {
1074
923
  Row: {
1075
- archived: boolean | null
1076
- chat_id: string
1077
- chat_image: string | null
1078
- chat_name: string | null
1079
- chat_type: string | null
1080
- created_at: string
1081
- group_metadata: Json | null
1082
- id: Json | null
1083
- invite_link: string | null
1084
- is_group: boolean | null
1085
- is_muted: boolean | null
1086
- is_read_only: boolean | null
1087
- latest_message: Json | null
1088
- member_count: number | null
1089
- mute_expiration: number | null
1090
- name: string | null
1091
- org_id: string
1092
- org_phone: string
1093
- pinned: boolean | null
1094
- timestamp: string | null
1095
- unread_count: number | null
1096
- updated_at: string
1097
- }
924
+ archived: boolean | null;
925
+ chat_id: string;
926
+ chat_image: string | null;
927
+ chat_name: string | null;
928
+ chat_type: string | null;
929
+ created_at: string;
930
+ group_metadata: Json | null;
931
+ id: Json | null;
932
+ invite_link: string | null;
933
+ is_group: boolean | null;
934
+ is_muted: boolean | null;
935
+ is_read_only: boolean | null;
936
+ latest_message: Json | null;
937
+ member_count: number | null;
938
+ mute_expiration: number | null;
939
+ name: string | null;
940
+ org_id: string;
941
+ org_phone: string;
942
+ pinned: boolean | null;
943
+ timestamp: string | null;
944
+ unread_count: number | null;
945
+ updated_at: string;
946
+ };
1098
947
  Insert: {
1099
- archived?: boolean | null
1100
- chat_id: string
1101
- chat_image?: string | null
1102
- chat_name?: string | null
1103
- chat_type?: string | null
1104
- created_at?: string
1105
- group_metadata?: Json | null
1106
- id?: Json | null
1107
- invite_link?: string | null
1108
- is_group?: boolean | null
1109
- is_muted?: boolean | null
1110
- is_read_only?: boolean | null
1111
- latest_message?: Json | null
1112
- member_count?: number | null
1113
- mute_expiration?: number | null
1114
- name?: string | null
1115
- org_id: string
1116
- org_phone: string
1117
- pinned?: boolean | null
1118
- timestamp?: string | null
1119
- unread_count?: number | null
1120
- updated_at?: string
1121
- }
948
+ archived?: boolean | null;
949
+ chat_id: string;
950
+ chat_image?: string | null;
951
+ chat_name?: string | null;
952
+ chat_type?: string | null;
953
+ created_at?: string;
954
+ group_metadata?: Json | null;
955
+ id?: Json | null;
956
+ invite_link?: string | null;
957
+ is_group?: boolean | null;
958
+ is_muted?: boolean | null;
959
+ is_read_only?: boolean | null;
960
+ latest_message?: Json | null;
961
+ member_count?: number | null;
962
+ mute_expiration?: number | null;
963
+ name?: string | null;
964
+ org_id: string;
965
+ org_phone: string;
966
+ pinned?: boolean | null;
967
+ timestamp?: string | null;
968
+ unread_count?: number | null;
969
+ updated_at?: string;
970
+ };
1122
971
  Update: {
1123
- archived?: boolean | null
1124
- chat_id?: string
1125
- chat_image?: string | null
1126
- chat_name?: string | null
1127
- chat_type?: string | null
1128
- created_at?: string
1129
- group_metadata?: Json | null
1130
- id?: Json | null
1131
- invite_link?: string | null
1132
- is_group?: boolean | null
1133
- is_muted?: boolean | null
1134
- is_read_only?: boolean | null
1135
- latest_message?: Json | null
1136
- member_count?: number | null
1137
- mute_expiration?: number | null
1138
- name?: string | null
1139
- org_id?: string
1140
- org_phone?: string
1141
- pinned?: boolean | null
1142
- timestamp?: string | null
1143
- unread_count?: number | null
1144
- updated_at?: string
1145
- }
972
+ archived?: boolean | null;
973
+ chat_id?: string;
974
+ chat_image?: string | null;
975
+ chat_name?: string | null;
976
+ chat_type?: string | null;
977
+ created_at?: string;
978
+ group_metadata?: Json | null;
979
+ id?: Json | null;
980
+ invite_link?: string | null;
981
+ is_group?: boolean | null;
982
+ is_muted?: boolean | null;
983
+ is_read_only?: boolean | null;
984
+ latest_message?: Json | null;
985
+ member_count?: number | null;
986
+ mute_expiration?: number | null;
987
+ name?: string | null;
988
+ org_id?: string;
989
+ org_phone?: string;
990
+ pinned?: boolean | null;
991
+ timestamp?: string | null;
992
+ unread_count?: number | null;
993
+ updated_at?: string;
994
+ };
1146
995
  Relationships: [
1147
996
  {
1148
- foreignKeyName: "tbl_chats_fkey_tbl_org_phones"
1149
- columns: ["org_phone", "org_id"]
1150
- isOneToOne: false
1151
- referencedRelation: "tbl_org_phones"
1152
- referencedColumns: ["org_phone", "org_id"]
997
+ foreignKeyName: 'tbl_chats_fkey_tbl_org_phones';
998
+ columns: ['org_phone', 'org_id'];
999
+ isOneToOne: false;
1000
+ referencedRelation: 'tbl_org_phones';
1001
+ referencedColumns: ['org_phone', 'org_id'];
1153
1002
  },
1154
- ]
1155
- }
1003
+ ];
1004
+ };
1156
1005
  tbl_contacts: {
1157
1006
  Row: {
1158
- business_profile: Json | null
1159
- contact_color: Database["public"]["Enums"]["enum_chat_colors"] | null
1160
- contact_id: string
1161
- contact_image: string | null
1162
- contact_name: string | null
1163
- contact_type: string | null
1164
- id: Json | null
1165
- is_blocked: boolean | null
1166
- is_business: boolean | null
1167
- is_enterprise: boolean | null
1168
- is_group: boolean | null
1169
- is_internal: boolean | null
1170
- is_me: boolean | null
1171
- is_my_contact: boolean | null
1172
- is_user: boolean | null
1173
- is_wa_contact: boolean | null
1174
- label_ids: Json
1175
- name: string | null
1176
- number: string | null
1177
- org_id: string
1178
- pushname: string | null
1179
- short_name: string | null
1180
- updated_at: string | null
1181
- verified_level: number | null
1182
- verified_name: string | null
1183
- }
1007
+ business_profile: Json | null;
1008
+ contact_color: Database['public']['Enums']['enum_chat_colors'] | null;
1009
+ contact_id: string;
1010
+ contact_image: string | null;
1011
+ contact_name: string | null;
1012
+ contact_type: string | null;
1013
+ id: Json | null;
1014
+ is_blocked: boolean | null;
1015
+ is_business: boolean | null;
1016
+ is_enterprise: boolean | null;
1017
+ is_group: boolean | null;
1018
+ is_internal: boolean | null;
1019
+ is_me: boolean | null;
1020
+ is_my_contact: boolean | null;
1021
+ is_user: boolean | null;
1022
+ is_wa_contact: boolean | null;
1023
+ label_ids: Json;
1024
+ name: string | null;
1025
+ number: string | null;
1026
+ org_id: string;
1027
+ pushname: string | null;
1028
+ short_name: string | null;
1029
+ updated_at: string | null;
1030
+ verified_level: number | null;
1031
+ verified_name: string | null;
1032
+ };
1184
1033
  Insert: {
1185
- business_profile?: Json | null
1186
- contact_color?: Database["public"]["Enums"]["enum_chat_colors"] | null
1187
- contact_id: string
1188
- contact_image?: string | null
1189
- contact_name?: string | null
1190
- contact_type?: string | null
1191
- id?: Json | null
1192
- is_blocked?: boolean | null
1193
- is_business?: boolean | null
1194
- is_enterprise?: boolean | null
1195
- is_group?: boolean | null
1196
- is_internal?: boolean | null
1197
- is_me?: boolean | null
1198
- is_my_contact?: boolean | null
1199
- is_user?: boolean | null
1200
- is_wa_contact?: boolean | null
1201
- label_ids?: Json
1202
- name?: string | null
1203
- number?: string | null
1204
- org_id: string
1205
- pushname?: string | null
1206
- short_name?: string | null
1207
- updated_at?: string | null
1208
- verified_level?: number | null
1209
- verified_name?: string | null
1210
- }
1034
+ business_profile?: Json | null;
1035
+ contact_color?:
1036
+ | Database['public']['Enums']['enum_chat_colors']
1037
+ | null;
1038
+ contact_id: string;
1039
+ contact_image?: string | null;
1040
+ contact_name?: string | null;
1041
+ contact_type?: string | null;
1042
+ id?: Json | null;
1043
+ is_blocked?: boolean | null;
1044
+ is_business?: boolean | null;
1045
+ is_enterprise?: boolean | null;
1046
+ is_group?: boolean | null;
1047
+ is_internal?: boolean | null;
1048
+ is_me?: boolean | null;
1049
+ is_my_contact?: boolean | null;
1050
+ is_user?: boolean | null;
1051
+ is_wa_contact?: boolean | null;
1052
+ label_ids?: Json;
1053
+ name?: string | null;
1054
+ number?: string | null;
1055
+ org_id: string;
1056
+ pushname?: string | null;
1057
+ short_name?: string | null;
1058
+ updated_at?: string | null;
1059
+ verified_level?: number | null;
1060
+ verified_name?: string | null;
1061
+ };
1211
1062
  Update: {
1212
- business_profile?: Json | null
1213
- contact_color?: Database["public"]["Enums"]["enum_chat_colors"] | null
1214
- contact_id?: string
1215
- contact_image?: string | null
1216
- contact_name?: string | null
1217
- contact_type?: string | null
1218
- id?: Json | null
1219
- is_blocked?: boolean | null
1220
- is_business?: boolean | null
1221
- is_enterprise?: boolean | null
1222
- is_group?: boolean | null
1223
- is_internal?: boolean | null
1224
- is_me?: boolean | null
1225
- is_my_contact?: boolean | null
1226
- is_user?: boolean | null
1227
- is_wa_contact?: boolean | null
1228
- label_ids?: Json
1229
- name?: string | null
1230
- number?: string | null
1231
- org_id?: string
1232
- pushname?: string | null
1233
- short_name?: string | null
1234
- updated_at?: string | null
1235
- verified_level?: number | null
1236
- verified_name?: string | null
1237
- }
1063
+ business_profile?: Json | null;
1064
+ contact_color?:
1065
+ | Database['public']['Enums']['enum_chat_colors']
1066
+ | null;
1067
+ contact_id?: string;
1068
+ contact_image?: string | null;
1069
+ contact_name?: string | null;
1070
+ contact_type?: string | null;
1071
+ id?: Json | null;
1072
+ is_blocked?: boolean | null;
1073
+ is_business?: boolean | null;
1074
+ is_enterprise?: boolean | null;
1075
+ is_group?: boolean | null;
1076
+ is_internal?: boolean | null;
1077
+ is_me?: boolean | null;
1078
+ is_my_contact?: boolean | null;
1079
+ is_user?: boolean | null;
1080
+ is_wa_contact?: boolean | null;
1081
+ label_ids?: Json;
1082
+ name?: string | null;
1083
+ number?: string | null;
1084
+ org_id?: string;
1085
+ pushname?: string | null;
1086
+ short_name?: string | null;
1087
+ updated_at?: string | null;
1088
+ verified_level?: number | null;
1089
+ verified_name?: string | null;
1090
+ };
1238
1091
  Relationships: [
1239
1092
  {
1240
- foreignKeyName: "tbl_contacts_org_id_fkey"
1241
- columns: ["org_id"]
1242
- isOneToOne: false
1243
- referencedRelation: "tbl_org"
1244
- referencedColumns: ["org_id"]
1093
+ foreignKeyName: 'tbl_contacts_org_id_fkey';
1094
+ columns: ['org_id'];
1095
+ isOneToOne: false;
1096
+ referencedRelation: 'tbl_org';
1097
+ referencedColumns: ['org_id'];
1245
1098
  },
1246
1099
  {
1247
- foreignKeyName: "tbl_contacts_org_id_fkey"
1248
- columns: ["org_id"]
1249
- isOneToOne: false
1250
- referencedRelation: "view_org"
1251
- referencedColumns: ["org_id"]
1100
+ foreignKeyName: 'tbl_contacts_org_id_fkey';
1101
+ columns: ['org_id'];
1102
+ isOneToOne: false;
1103
+ referencedRelation: 'view_org';
1104
+ referencedColumns: ['org_id'];
1252
1105
  },
1253
- ]
1254
- }
1106
+ ];
1107
+ };
1255
1108
  tbl_custom_properties: {
1256
1109
  Row: {
1257
- created_at: string
1258
- created_by: string | null
1259
- org_id: string | null
1260
- property_id: string
1261
- property_name: string
1262
- property_value: string | null
1263
- property_value_type: string | null
1264
- type: string | null
1265
- }
1110
+ created_at: string;
1111
+ created_by: string | null;
1112
+ org_id: string | null;
1113
+ property_id: string;
1114
+ property_name: string;
1115
+ property_value: string | null;
1116
+ property_value_type: string | null;
1117
+ type: string | null;
1118
+ };
1266
1119
  Insert: {
1267
- created_at?: string
1268
- created_by?: string | null
1269
- org_id?: string | null
1270
- property_id?: string
1271
- property_name: string
1272
- property_value?: string | null
1273
- property_value_type?: string | null
1274
- type?: string | null
1275
- }
1120
+ created_at?: string;
1121
+ created_by?: string | null;
1122
+ org_id?: string | null;
1123
+ property_id?: string;
1124
+ property_name: string;
1125
+ property_value?: string | null;
1126
+ property_value_type?: string | null;
1127
+ type?: string | null;
1128
+ };
1276
1129
  Update: {
1277
- created_at?: string
1278
- created_by?: string | null
1279
- org_id?: string | null
1280
- property_id?: string
1281
- property_name?: string
1282
- property_value?: string | null
1283
- property_value_type?: string | null
1284
- type?: string | null
1285
- }
1130
+ created_at?: string;
1131
+ created_by?: string | null;
1132
+ org_id?: string | null;
1133
+ property_id?: string;
1134
+ property_name?: string;
1135
+ property_value?: string | null;
1136
+ property_value_type?: string | null;
1137
+ type?: string | null;
1138
+ };
1286
1139
  Relationships: [
1287
1140
  {
1288
- foreignKeyName: "tbl_custom_properties_org_id_fkey"
1289
- columns: ["org_id"]
1290
- isOneToOne: false
1291
- referencedRelation: "tbl_org"
1292
- referencedColumns: ["org_id"]
1141
+ foreignKeyName: 'tbl_custom_properties_org_id_fkey';
1142
+ columns: ['org_id'];
1143
+ isOneToOne: false;
1144
+ referencedRelation: 'tbl_org';
1145
+ referencedColumns: ['org_id'];
1293
1146
  },
1294
1147
  {
1295
- foreignKeyName: "tbl_custom_properties_org_id_fkey"
1296
- columns: ["org_id"]
1297
- isOneToOne: false
1298
- referencedRelation: "view_org"
1299
- referencedColumns: ["org_id"]
1148
+ foreignKeyName: 'tbl_custom_properties_org_id_fkey';
1149
+ columns: ['org_id'];
1150
+ isOneToOne: false;
1151
+ referencedRelation: 'view_org';
1152
+ referencedColumns: ['org_id'];
1300
1153
  },
1301
- ]
1302
- }
1154
+ ];
1155
+ };
1303
1156
  tbl_integration_hooks: {
1304
1157
  Row: {
1305
- hook_url: string
1306
- id: string
1307
- integration_id: string | null
1308
- integration_metadata: Json
1309
- integration_name: Database["public"]["Enums"]["enum_integration_name"]
1310
- integration_type: string
1311
- is_subscribed: boolean
1312
- org_id: string
1313
- subscribed_at: string
1314
- type: Database["public"]["Enums"]["enum_integration_type"]
1315
- }
1158
+ hook_url: string;
1159
+ id: string;
1160
+ integration_id: string | null;
1161
+ integration_metadata: Json;
1162
+ integration_name: Database['public']['Enums']['enum_integration_name'];
1163
+ integration_type: string;
1164
+ is_subscribed: boolean;
1165
+ org_id: string;
1166
+ subscribed_at: string;
1167
+ type: Database['public']['Enums']['enum_integration_type'];
1168
+ };
1316
1169
  Insert: {
1317
- hook_url: string
1318
- id?: string
1319
- integration_id?: string | null
1320
- integration_metadata: Json
1321
- integration_name: Database["public"]["Enums"]["enum_integration_name"]
1322
- integration_type: string
1323
- is_subscribed: boolean
1324
- org_id: string
1325
- subscribed_at?: string
1326
- type: Database["public"]["Enums"]["enum_integration_type"]
1327
- }
1170
+ hook_url: string;
1171
+ id?: string;
1172
+ integration_id?: string | null;
1173
+ integration_metadata: Json;
1174
+ integration_name: Database['public']['Enums']['enum_integration_name'];
1175
+ integration_type: string;
1176
+ is_subscribed: boolean;
1177
+ org_id: string;
1178
+ subscribed_at?: string;
1179
+ type: Database['public']['Enums']['enum_integration_type'];
1180
+ };
1328
1181
  Update: {
1329
- hook_url?: string
1330
- id?: string
1331
- integration_id?: string | null
1332
- integration_metadata?: Json
1333
- integration_name?: Database["public"]["Enums"]["enum_integration_name"]
1334
- integration_type?: string
1335
- is_subscribed?: boolean
1336
- org_id?: string
1337
- subscribed_at?: string
1338
- type?: Database["public"]["Enums"]["enum_integration_type"]
1339
- }
1182
+ hook_url?: string;
1183
+ id?: string;
1184
+ integration_id?: string | null;
1185
+ integration_metadata?: Json;
1186
+ integration_name?: Database['public']['Enums']['enum_integration_name'];
1187
+ integration_type?: string;
1188
+ is_subscribed?: boolean;
1189
+ org_id?: string;
1190
+ subscribed_at?: string;
1191
+ type?: Database['public']['Enums']['enum_integration_type'];
1192
+ };
1340
1193
  Relationships: [
1341
1194
  {
1342
- foreignKeyName: "tbl_integration_hooks_org_id_fkey"
1343
- columns: ["org_id"]
1344
- isOneToOne: false
1345
- referencedRelation: "tbl_org"
1346
- referencedColumns: ["org_id"]
1195
+ foreignKeyName: 'tbl_integration_hooks_org_id_fkey';
1196
+ columns: ['org_id'];
1197
+ isOneToOne: false;
1198
+ referencedRelation: 'tbl_org';
1199
+ referencedColumns: ['org_id'];
1347
1200
  },
1348
1201
  {
1349
- foreignKeyName: "tbl_integration_hooks_org_id_fkey"
1350
- columns: ["org_id"]
1351
- isOneToOne: false
1352
- referencedRelation: "view_org"
1353
- referencedColumns: ["org_id"]
1202
+ foreignKeyName: 'tbl_integration_hooks_org_id_fkey';
1203
+ columns: ['org_id'];
1204
+ isOneToOne: false;
1205
+ referencedRelation: 'view_org';
1206
+ referencedColumns: ['org_id'];
1354
1207
  },
1355
- ]
1356
- }
1208
+ ];
1209
+ };
1357
1210
  tbl_integration_logs: {
1358
1211
  Row: {
1359
- created_at: string
1360
- id: string
1361
- integration_name: Database["public"]["Enums"]["enum_integration_name"]
1362
- integration_type: string
1363
- metadata: Json
1364
- org_id: string
1365
- response: Json | null
1366
- success: boolean
1367
- type: Database["public"]["Enums"]["enum_integration_type"]
1368
- }
1212
+ created_at: string;
1213
+ id: string;
1214
+ integration_name: Database['public']['Enums']['enum_integration_name'];
1215
+ integration_type: string;
1216
+ metadata: Json;
1217
+ org_id: string;
1218
+ response: Json | null;
1219
+ success: boolean;
1220
+ type: Database['public']['Enums']['enum_integration_type'];
1221
+ };
1369
1222
  Insert: {
1370
- created_at?: string
1371
- id?: string
1372
- integration_name: Database["public"]["Enums"]["enum_integration_name"]
1373
- integration_type: string
1374
- metadata?: Json
1375
- org_id: string
1376
- response?: Json | null
1377
- success?: boolean
1378
- type: Database["public"]["Enums"]["enum_integration_type"]
1379
- }
1223
+ created_at?: string;
1224
+ id?: string;
1225
+ integration_name: Database['public']['Enums']['enum_integration_name'];
1226
+ integration_type: string;
1227
+ metadata?: Json;
1228
+ org_id: string;
1229
+ response?: Json | null;
1230
+ success?: boolean;
1231
+ type: Database['public']['Enums']['enum_integration_type'];
1232
+ };
1380
1233
  Update: {
1381
- created_at?: string
1382
- id?: string
1383
- integration_name?: Database["public"]["Enums"]["enum_integration_name"]
1384
- integration_type?: string
1385
- metadata?: Json
1386
- org_id?: string
1387
- response?: Json | null
1388
- success?: boolean
1389
- type?: Database["public"]["Enums"]["enum_integration_type"]
1390
- }
1234
+ created_at?: string;
1235
+ id?: string;
1236
+ integration_name?: Database['public']['Enums']['enum_integration_name'];
1237
+ integration_type?: string;
1238
+ metadata?: Json;
1239
+ org_id?: string;
1240
+ response?: Json | null;
1241
+ success?: boolean;
1242
+ type?: Database['public']['Enums']['enum_integration_type'];
1243
+ };
1391
1244
  Relationships: [
1392
1245
  {
1393
- foreignKeyName: "tbl_integration_logs_org_id_fkey"
1394
- columns: ["org_id"]
1395
- isOneToOne: false
1396
- referencedRelation: "tbl_org"
1397
- referencedColumns: ["org_id"]
1246
+ foreignKeyName: 'tbl_integration_logs_org_id_fkey';
1247
+ columns: ['org_id'];
1248
+ isOneToOne: false;
1249
+ referencedRelation: 'tbl_org';
1250
+ referencedColumns: ['org_id'];
1398
1251
  },
1399
1252
  {
1400
- foreignKeyName: "tbl_integration_logs_org_id_fkey"
1401
- columns: ["org_id"]
1402
- isOneToOne: false
1403
- referencedRelation: "view_org"
1404
- referencedColumns: ["org_id"]
1253
+ foreignKeyName: 'tbl_integration_logs_org_id_fkey';
1254
+ columns: ['org_id'];
1255
+ isOneToOne: false;
1256
+ referencedRelation: 'view_org';
1257
+ referencedColumns: ['org_id'];
1405
1258
  },
1406
- ]
1407
- }
1259
+ ];
1260
+ };
1408
1261
  tbl_integration_tokens: {
1409
1262
  Row: {
1410
- exp: string
1411
- iat: string
1412
- id: string
1413
- is_revealed: boolean
1414
- name: string
1415
- org_id: string
1416
- role: string
1417
- token: string
1418
- token_metadata: Json | null
1419
- type: Database["public"]["Enums"]["enum_integration_type"]
1420
- }
1263
+ exp: string;
1264
+ iat: string;
1265
+ id: string;
1266
+ is_revealed: boolean;
1267
+ name: string;
1268
+ org_id: string;
1269
+ role: string;
1270
+ token: string;
1271
+ token_metadata: Json | null;
1272
+ type: Database['public']['Enums']['enum_integration_type'];
1273
+ };
1421
1274
  Insert: {
1422
- exp: string
1423
- iat: string
1424
- id?: string
1425
- is_revealed?: boolean
1426
- name: string
1427
- org_id: string
1428
- role: string
1429
- token: string
1430
- token_metadata?: Json | null
1431
- type: Database["public"]["Enums"]["enum_integration_type"]
1432
- }
1275
+ exp: string;
1276
+ iat: string;
1277
+ id?: string;
1278
+ is_revealed?: boolean;
1279
+ name: string;
1280
+ org_id: string;
1281
+ role: string;
1282
+ token: string;
1283
+ token_metadata?: Json | null;
1284
+ type: Database['public']['Enums']['enum_integration_type'];
1285
+ };
1433
1286
  Update: {
1434
- exp?: string
1435
- iat?: string
1436
- id?: string
1437
- is_revealed?: boolean
1438
- name?: string
1439
- org_id?: string
1440
- role?: string
1441
- token?: string
1442
- token_metadata?: Json | null
1443
- type?: Database["public"]["Enums"]["enum_integration_type"]
1444
- }
1287
+ exp?: string;
1288
+ iat?: string;
1289
+ id?: string;
1290
+ is_revealed?: boolean;
1291
+ name?: string;
1292
+ org_id?: string;
1293
+ role?: string;
1294
+ token?: string;
1295
+ token_metadata?: Json | null;
1296
+ type?: Database['public']['Enums']['enum_integration_type'];
1297
+ };
1445
1298
  Relationships: [
1446
1299
  {
1447
- foreignKeyName: "public_tbl_integration_tokens_org_id_fkey"
1448
- columns: ["org_id"]
1449
- isOneToOne: false
1450
- referencedRelation: "tbl_org"
1451
- referencedColumns: ["org_id"]
1300
+ foreignKeyName: 'public_tbl_integration_tokens_org_id_fkey';
1301
+ columns: ['org_id'];
1302
+ isOneToOne: false;
1303
+ referencedRelation: 'tbl_org';
1304
+ referencedColumns: ['org_id'];
1452
1305
  },
1453
1306
  {
1454
- foreignKeyName: "public_tbl_integration_tokens_org_id_fkey"
1455
- columns: ["org_id"]
1456
- isOneToOne: false
1457
- referencedRelation: "view_org"
1458
- referencedColumns: ["org_id"]
1307
+ foreignKeyName: 'public_tbl_integration_tokens_org_id_fkey';
1308
+ columns: ['org_id'];
1309
+ isOneToOne: false;
1310
+ referencedRelation: 'view_org';
1311
+ referencedColumns: ['org_id'];
1459
1312
  },
1460
- ]
1461
- }
1313
+ ];
1314
+ };
1462
1315
  tbl_org: {
1463
1316
  Row: {
1464
- created_at: string
1465
- org_id: string
1466
- org_image: string | null
1467
- org_metadata: Json | null
1468
- org_name: string | null
1469
- org_plan: Json | null
1470
- stripe_customer_details: Json | null
1471
- stripe_customer_id: string | null
1472
- stripe_subscription_details: Json | null
1473
- support_link: string | null
1474
- }
1317
+ created_at: string;
1318
+ org_id: string;
1319
+ org_image: string | null;
1320
+ org_metadata: Json | null;
1321
+ org_name: string | null;
1322
+ org_plan: Json | null;
1323
+ stripe_customer_details: Json | null;
1324
+ stripe_customer_id: string | null;
1325
+ stripe_subscription_details: Json | null;
1326
+ support_link: string | null;
1327
+ };
1475
1328
  Insert: {
1476
- created_at?: string
1477
- org_id?: string
1478
- org_image?: string | null
1479
- org_metadata?: Json | null
1480
- org_name?: string | null
1481
- org_plan?: Json | null
1482
- stripe_customer_details?: Json | null
1483
- stripe_customer_id?: string | null
1484
- stripe_subscription_details?: Json | null
1485
- support_link?: string | null
1486
- }
1329
+ created_at?: string;
1330
+ org_id?: string;
1331
+ org_image?: string | null;
1332
+ org_metadata?: Json | null;
1333
+ org_name?: string | null;
1334
+ org_plan?: Json | null;
1335
+ stripe_customer_details?: Json | null;
1336
+ stripe_customer_id?: string | null;
1337
+ stripe_subscription_details?: Json | null;
1338
+ support_link?: string | null;
1339
+ };
1487
1340
  Update: {
1488
- created_at?: string
1489
- org_id?: string
1490
- org_image?: string | null
1491
- org_metadata?: Json | null
1492
- org_name?: string | null
1493
- org_plan?: Json | null
1494
- stripe_customer_details?: Json | null
1495
- stripe_customer_id?: string | null
1496
- stripe_subscription_details?: Json | null
1497
- support_link?: string | null
1498
- }
1499
- Relationships: []
1500
- }
1341
+ created_at?: string;
1342
+ org_id?: string;
1343
+ org_image?: string | null;
1344
+ org_metadata?: Json | null;
1345
+ org_name?: string | null;
1346
+ org_plan?: Json | null;
1347
+ stripe_customer_details?: Json | null;
1348
+ stripe_customer_id?: string | null;
1349
+ stripe_subscription_details?: Json | null;
1350
+ support_link?: string | null;
1351
+ };
1352
+ Relationships: [];
1353
+ };
1501
1354
  tbl_org_labels: {
1502
1355
  Row: {
1503
- color: string
1504
- created_at: string
1505
- label_id: string
1506
- name: string
1507
- org_id: string
1508
- type: string
1509
- }
1356
+ color: string;
1357
+ created_at: string;
1358
+ label_id: string;
1359
+ name: string;
1360
+ org_id: string;
1361
+ type: string;
1362
+ };
1510
1363
  Insert: {
1511
- color?: string
1512
- created_at?: string
1513
- label_id?: string
1514
- name: string
1515
- org_id: string
1516
- type?: string
1517
- }
1364
+ color?: string;
1365
+ created_at?: string;
1366
+ label_id?: string;
1367
+ name: string;
1368
+ org_id: string;
1369
+ type?: string;
1370
+ };
1518
1371
  Update: {
1519
- color?: string
1520
- created_at?: string
1521
- label_id?: string
1522
- name?: string
1523
- org_id?: string
1524
- type?: string
1525
- }
1372
+ color?: string;
1373
+ created_at?: string;
1374
+ label_id?: string;
1375
+ name?: string;
1376
+ org_id?: string;
1377
+ type?: string;
1378
+ };
1526
1379
  Relationships: [
1527
1380
  {
1528
- foreignKeyName: "tbl_org_labels_org_id_fkey"
1529
- columns: ["org_id"]
1530
- isOneToOne: false
1531
- referencedRelation: "tbl_org"
1532
- referencedColumns: ["org_id"]
1381
+ foreignKeyName: 'tbl_org_labels_org_id_fkey';
1382
+ columns: ['org_id'];
1383
+ isOneToOne: false;
1384
+ referencedRelation: 'tbl_org';
1385
+ referencedColumns: ['org_id'];
1533
1386
  },
1534
1387
  {
1535
- foreignKeyName: "tbl_org_labels_org_id_fkey"
1536
- columns: ["org_id"]
1537
- isOneToOne: false
1538
- referencedRelation: "view_org"
1539
- referencedColumns: ["org_id"]
1388
+ foreignKeyName: 'tbl_org_labels_org_id_fkey';
1389
+ columns: ['org_id'];
1390
+ isOneToOne: false;
1391
+ referencedRelation: 'view_org';
1392
+ referencedColumns: ['org_id'];
1540
1393
  },
1541
- ]
1542
- }
1394
+ ];
1395
+ };
1543
1396
  tbl_org_members: {
1544
1397
  Row: {
1545
- created_at: string | null
1546
- email: string
1547
- invited_at: string | null
1548
- invited_by: string | null
1549
- is_active: boolean
1550
- is_owner: boolean | null
1551
- label_ids: string[] | null
1552
- member_color: Database["public"]["Enums"]["enum_chat_colors"]
1553
- member_image: string | null
1554
- member_name: string | null
1555
- org_id: string
1556
- org_phones: string[] | null
1557
- preferences: Json
1558
- role: Database["public"]["Enums"]["enum_member_role"]
1559
- user_id: string | null
1560
- }
1398
+ created_at: string | null;
1399
+ email: string;
1400
+ invited_at: string | null;
1401
+ invited_by: string | null;
1402
+ is_active: boolean;
1403
+ is_owner: boolean | null;
1404
+ label_ids: string[] | null;
1405
+ member_color: Database['public']['Enums']['enum_chat_colors'];
1406
+ member_image: string | null;
1407
+ member_name: string | null;
1408
+ org_id: string;
1409
+ org_phones: string[] | null;
1410
+ preferences: Json;
1411
+ role: Database['public']['Enums']['enum_member_role'];
1412
+ user_id: string | null;
1413
+ };
1561
1414
  Insert: {
1562
- created_at?: string | null
1563
- email: string
1564
- invited_at?: string | null
1565
- invited_by?: string | null
1566
- is_active?: boolean
1567
- is_owner?: boolean | null
1568
- label_ids?: string[] | null
1569
- member_color?: Database["public"]["Enums"]["enum_chat_colors"]
1570
- member_image?: string | null
1571
- member_name?: string | null
1572
- org_id: string
1573
- org_phones?: string[] | null
1574
- preferences?: Json
1575
- role?: Database["public"]["Enums"]["enum_member_role"]
1576
- user_id?: string | null
1577
- }
1415
+ created_at?: string | null;
1416
+ email: string;
1417
+ invited_at?: string | null;
1418
+ invited_by?: string | null;
1419
+ is_active?: boolean;
1420
+ is_owner?: boolean | null;
1421
+ label_ids?: string[] | null;
1422
+ member_color?: Database['public']['Enums']['enum_chat_colors'];
1423
+ member_image?: string | null;
1424
+ member_name?: string | null;
1425
+ org_id: string;
1426
+ org_phones?: string[] | null;
1427
+ preferences?: Json;
1428
+ role?: Database['public']['Enums']['enum_member_role'];
1429
+ user_id?: string | null;
1430
+ };
1578
1431
  Update: {
1579
- created_at?: string | null
1580
- email?: string
1581
- invited_at?: string | null
1582
- invited_by?: string | null
1583
- is_active?: boolean
1584
- is_owner?: boolean | null
1585
- label_ids?: string[] | null
1586
- member_color?: Database["public"]["Enums"]["enum_chat_colors"]
1587
- member_image?: string | null
1588
- member_name?: string | null
1589
- org_id?: string
1590
- org_phones?: string[] | null
1591
- preferences?: Json
1592
- role?: Database["public"]["Enums"]["enum_member_role"]
1593
- user_id?: string | null
1594
- }
1432
+ created_at?: string | null;
1433
+ email?: string;
1434
+ invited_at?: string | null;
1435
+ invited_by?: string | null;
1436
+ is_active?: boolean;
1437
+ is_owner?: boolean | null;
1438
+ label_ids?: string[] | null;
1439
+ member_color?: Database['public']['Enums']['enum_chat_colors'];
1440
+ member_image?: string | null;
1441
+ member_name?: string | null;
1442
+ org_id?: string;
1443
+ org_phones?: string[] | null;
1444
+ preferences?: Json;
1445
+ role?: Database['public']['Enums']['enum_member_role'];
1446
+ user_id?: string | null;
1447
+ };
1595
1448
  Relationships: [
1596
1449
  {
1597
- foreignKeyName: "tbl_org_members_fkey_auth_users"
1598
- columns: ["user_id"]
1599
- isOneToOne: false
1600
- referencedRelation: "users"
1601
- referencedColumns: ["id"]
1450
+ foreignKeyName: 'tbl_org_members_fkey_auth_users';
1451
+ columns: ['user_id'];
1452
+ isOneToOne: false;
1453
+ referencedRelation: 'users';
1454
+ referencedColumns: ['id'];
1602
1455
  },
1603
1456
  {
1604
- foreignKeyName: "tbl_org_members_fkey_tbl_org"
1605
- columns: ["org_id"]
1606
- isOneToOne: false
1607
- referencedRelation: "tbl_org"
1608
- referencedColumns: ["org_id"]
1457
+ foreignKeyName: 'tbl_org_members_fkey_tbl_org';
1458
+ columns: ['org_id'];
1459
+ isOneToOne: false;
1460
+ referencedRelation: 'tbl_org';
1461
+ referencedColumns: ['org_id'];
1609
1462
  },
1610
1463
  {
1611
- foreignKeyName: "tbl_org_members_fkey_tbl_org"
1612
- columns: ["org_id"]
1613
- isOneToOne: false
1614
- referencedRelation: "view_org"
1615
- referencedColumns: ["org_id"]
1464
+ foreignKeyName: 'tbl_org_members_fkey_tbl_org';
1465
+ columns: ['org_id'];
1466
+ isOneToOne: false;
1467
+ referencedRelation: 'view_org';
1468
+ referencedColumns: ['org_id'];
1616
1469
  },
1617
- ]
1618
- }
1470
+ ];
1471
+ };
1619
1472
  tbl_org_phones: {
1620
1473
  Row: {
1621
- created_at: string
1622
- first_connected_at: string | null
1623
- is_browser_open: boolean
1624
- is_ready: boolean | null
1625
- legacy_version: boolean | null
1626
- org_id: string
1627
- org_phone: string | null
1628
- phone_id: string
1629
- phone_image: string | null
1630
- phone_name: string | null
1631
- phone_state: Json | null
1632
- qr_code: string | null
1633
- server_image: string | null
1634
- server_ip: string | null
1635
- updated_at: string | null
1636
- wa_state: string | null
1637
- wa_version: string | null
1638
- }
1474
+ created_at: string;
1475
+ first_connected_at: string | null;
1476
+ is_browser_open: boolean;
1477
+ is_ready: boolean | null;
1478
+ legacy_version: boolean | null;
1479
+ org_id: string;
1480
+ org_phone: string | null;
1481
+ phone_id: string;
1482
+ phone_image: string | null;
1483
+ phone_name: string | null;
1484
+ phone_state: Json | null;
1485
+ qr_code: string | null;
1486
+ server_image: string | null;
1487
+ server_ip: string | null;
1488
+ updated_at: string | null;
1489
+ wa_state: string | null;
1490
+ wa_version: string | null;
1491
+ };
1639
1492
  Insert: {
1640
- created_at?: string
1641
- first_connected_at?: string | null
1642
- is_browser_open?: boolean
1643
- is_ready?: boolean | null
1644
- legacy_version?: boolean | null
1645
- org_id: string
1646
- org_phone?: string | null
1647
- phone_id?: string
1648
- phone_image?: string | null
1649
- phone_name?: string | null
1650
- phone_state?: Json | null
1651
- qr_code?: string | null
1652
- server_image?: string | null
1653
- server_ip?: string | null
1654
- updated_at?: string | null
1655
- wa_state?: string | null
1656
- wa_version?: string | null
1657
- }
1493
+ created_at?: string;
1494
+ first_connected_at?: string | null;
1495
+ is_browser_open?: boolean;
1496
+ is_ready?: boolean | null;
1497
+ legacy_version?: boolean | null;
1498
+ org_id: string;
1499
+ org_phone?: string | null;
1500
+ phone_id?: string;
1501
+ phone_image?: string | null;
1502
+ phone_name?: string | null;
1503
+ phone_state?: Json | null;
1504
+ qr_code?: string | null;
1505
+ server_image?: string | null;
1506
+ server_ip?: string | null;
1507
+ updated_at?: string | null;
1508
+ wa_state?: string | null;
1509
+ wa_version?: string | null;
1510
+ };
1658
1511
  Update: {
1659
- created_at?: string
1660
- first_connected_at?: string | null
1661
- is_browser_open?: boolean
1662
- is_ready?: boolean | null
1663
- legacy_version?: boolean | null
1664
- org_id?: string
1665
- org_phone?: string | null
1666
- phone_id?: string
1667
- phone_image?: string | null
1668
- phone_name?: string | null
1669
- phone_state?: Json | null
1670
- qr_code?: string | null
1671
- server_image?: string | null
1672
- server_ip?: string | null
1673
- updated_at?: string | null
1674
- wa_state?: string | null
1675
- wa_version?: string | null
1676
- }
1512
+ created_at?: string;
1513
+ first_connected_at?: string | null;
1514
+ is_browser_open?: boolean;
1515
+ is_ready?: boolean | null;
1516
+ legacy_version?: boolean | null;
1517
+ org_id?: string;
1518
+ org_phone?: string | null;
1519
+ phone_id?: string;
1520
+ phone_image?: string | null;
1521
+ phone_name?: string | null;
1522
+ phone_state?: Json | null;
1523
+ qr_code?: string | null;
1524
+ server_image?: string | null;
1525
+ server_ip?: string | null;
1526
+ updated_at?: string | null;
1527
+ wa_state?: string | null;
1528
+ wa_version?: string | null;
1529
+ };
1677
1530
  Relationships: [
1678
1531
  {
1679
- foreignKeyName: "tbl_org_phones_fkey_tbl_org"
1680
- columns: ["org_id"]
1681
- isOneToOne: false
1682
- referencedRelation: "tbl_org"
1683
- referencedColumns: ["org_id"]
1532
+ foreignKeyName: 'tbl_org_phones_fkey_tbl_org';
1533
+ columns: ['org_id'];
1534
+ isOneToOne: false;
1535
+ referencedRelation: 'tbl_org';
1536
+ referencedColumns: ['org_id'];
1684
1537
  },
1685
1538
  {
1686
- foreignKeyName: "tbl_org_phones_fkey_tbl_org"
1687
- columns: ["org_id"]
1688
- isOneToOne: false
1689
- referencedRelation: "view_org"
1690
- referencedColumns: ["org_id"]
1539
+ foreignKeyName: 'tbl_org_phones_fkey_tbl_org';
1540
+ columns: ['org_id'];
1541
+ isOneToOne: false;
1542
+ referencedRelation: 'view_org';
1543
+ referencedColumns: ['org_id'];
1691
1544
  },
1692
1545
  {
1693
- foreignKeyName: "tbl_org_phones_org_id_fkey"
1694
- columns: ["org_id"]
1695
- isOneToOne: false
1696
- referencedRelation: "tbl_org"
1697
- referencedColumns: ["org_id"]
1546
+ foreignKeyName: 'tbl_org_phones_org_id_fkey';
1547
+ columns: ['org_id'];
1548
+ isOneToOne: false;
1549
+ referencedRelation: 'tbl_org';
1550
+ referencedColumns: ['org_id'];
1698
1551
  },
1699
1552
  {
1700
- foreignKeyName: "tbl_org_phones_org_id_fkey"
1701
- columns: ["org_id"]
1702
- isOneToOne: false
1703
- referencedRelation: "view_org"
1704
- referencedColumns: ["org_id"]
1553
+ foreignKeyName: 'tbl_org_phones_org_id_fkey';
1554
+ columns: ['org_id'];
1555
+ isOneToOne: false;
1556
+ referencedRelation: 'view_org';
1557
+ referencedColumns: ['org_id'];
1705
1558
  },
1706
- ]
1707
- }
1559
+ ];
1560
+ };
1708
1561
  tbl_quick_replies: {
1709
1562
  Row: {
1710
- command: string | null
1711
- created_at: string
1712
- message_payload: Json | null
1713
- org_id: string | null
1714
- reply_id: string
1715
- }
1563
+ command: string | null;
1564
+ created_at: string;
1565
+ message_payload: Json | null;
1566
+ org_id: string | null;
1567
+ reply_id: string;
1568
+ };
1716
1569
  Insert: {
1717
- command?: string | null
1718
- created_at?: string
1719
- message_payload?: Json | null
1720
- org_id?: string | null
1721
- reply_id?: string
1722
- }
1570
+ command?: string | null;
1571
+ created_at?: string;
1572
+ message_payload?: Json | null;
1573
+ org_id?: string | null;
1574
+ reply_id?: string;
1575
+ };
1723
1576
  Update: {
1724
- command?: string | null
1725
- created_at?: string
1726
- message_payload?: Json | null
1727
- org_id?: string | null
1728
- reply_id?: string
1729
- }
1577
+ command?: string | null;
1578
+ created_at?: string;
1579
+ message_payload?: Json | null;
1580
+ org_id?: string | null;
1581
+ reply_id?: string;
1582
+ };
1730
1583
  Relationships: [
1731
1584
  {
1732
- foreignKeyName: "tbl_quick_replies_org_id_fkey"
1733
- columns: ["org_id"]
1734
- isOneToOne: false
1735
- referencedRelation: "tbl_org"
1736
- referencedColumns: ["org_id"]
1585
+ foreignKeyName: 'tbl_quick_replies_org_id_fkey';
1586
+ columns: ['org_id'];
1587
+ isOneToOne: false;
1588
+ referencedRelation: 'tbl_org';
1589
+ referencedColumns: ['org_id'];
1737
1590
  },
1738
1591
  {
1739
- foreignKeyName: "tbl_quick_replies_org_id_fkey"
1740
- columns: ["org_id"]
1741
- isOneToOne: false
1742
- referencedRelation: "view_org"
1743
- referencedColumns: ["org_id"]
1592
+ foreignKeyName: 'tbl_quick_replies_org_id_fkey';
1593
+ columns: ['org_id'];
1594
+ isOneToOne: false;
1595
+ referencedRelation: 'view_org';
1596
+ referencedColumns: ['org_id'];
1744
1597
  },
1745
- ]
1746
- }
1598
+ ];
1599
+ };
1747
1600
  tbl_tools_whatsapp_links: {
1748
1601
  Row: {
1749
- created_at: string
1750
- link_id: string
1751
- link_name: string
1752
- message: string | null
1753
- phone: string
1754
- }
1602
+ created_at: string;
1603
+ link_id: string;
1604
+ link_name: string;
1605
+ message: string | null;
1606
+ phone: string;
1607
+ };
1755
1608
  Insert: {
1756
- created_at?: string
1757
- link_id?: string
1758
- link_name: string
1759
- message?: string | null
1760
- phone: string
1761
- }
1609
+ created_at?: string;
1610
+ link_id?: string;
1611
+ link_name: string;
1612
+ message?: string | null;
1613
+ phone: string;
1614
+ };
1762
1615
  Update: {
1763
- created_at?: string
1764
- link_id?: string
1765
- link_name?: string
1766
- message?: string | null
1767
- phone?: string
1768
- }
1769
- Relationships: []
1770
- }
1771
- }
1616
+ created_at?: string;
1617
+ link_id?: string;
1618
+ link_name?: string;
1619
+ message?: string | null;
1620
+ phone?: string;
1621
+ };
1622
+ Relationships: [];
1623
+ };
1624
+ };
1772
1625
  Views: {
1773
1626
  view_broadcast_logs: {
1774
1627
  Row: {
1775
- broadcast_id: string | null
1628
+ broadcast_id: string | null;
1776
1629
  broadcast_status:
1777
- | Database["public"]["Enums"]["enum_broadcast_status"]
1778
- | null
1779
- created_at: string | null
1780
- delivery_percentage: number | null
1781
- failed_chats: number | null
1782
- message_payload: Json | null
1783
- org_id: string | null
1784
- pending_chats: number | null
1785
- performed_at: string | null
1786
- performed_by: string | null
1787
- read_percentage: number | null
1788
- scheduled_at: string | null
1789
- sent_chats: number | null
1790
- total_chats: number | null
1791
- total_delivered_count: number | null
1792
- total_member_count: number | null
1793
- total_read_count: number | null
1794
- }
1630
+ | Database['public']['Enums']['enum_broadcast_status']
1631
+ | null;
1632
+ created_at: string | null;
1633
+ delivery_percentage: number | null;
1634
+ failed_chats: number | null;
1635
+ message_payload: Json | null;
1636
+ org_id: string | null;
1637
+ pending_chats: number | null;
1638
+ performed_at: string | null;
1639
+ performed_by: string | null;
1640
+ read_percentage: number | null;
1641
+ scheduled_at: string | null;
1642
+ sent_chats: number | null;
1643
+ total_chats: number | null;
1644
+ total_delivered_count: number | null;
1645
+ total_member_count: number | null;
1646
+ total_read_count: number | null;
1647
+ };
1795
1648
  Relationships: [
1796
1649
  {
1797
- foreignKeyName: "tbl_broadcast_messages_org_id_fkey"
1798
- columns: ["org_id"]
1799
- isOneToOne: false
1800
- referencedRelation: "tbl_org"
1801
- referencedColumns: ["org_id"]
1650
+ foreignKeyName: 'tbl_broadcast_messages_org_id_fkey';
1651
+ columns: ['org_id'];
1652
+ isOneToOne: false;
1653
+ referencedRelation: 'tbl_org';
1654
+ referencedColumns: ['org_id'];
1802
1655
  },
1803
1656
  {
1804
- foreignKeyName: "tbl_broadcast_messages_org_id_fkey"
1805
- columns: ["org_id"]
1806
- isOneToOne: false
1807
- referencedRelation: "view_org"
1808
- referencedColumns: ["org_id"]
1657
+ foreignKeyName: 'tbl_broadcast_messages_org_id_fkey';
1658
+ columns: ['org_id'];
1659
+ isOneToOne: false;
1660
+ referencedRelation: 'view_org';
1661
+ referencedColumns: ['org_id'];
1809
1662
  },
1810
- ]
1811
- }
1663
+ ];
1664
+ };
1812
1665
  view_chat_logs: {
1813
1666
  Row: {
1814
- action: string | null
1815
- failed: number | null
1816
- operation_id: string | null
1817
- org_id: string | null
1818
- pending: number | null
1819
- performed_at: string | null
1820
- performed_by: string | null
1821
- success: number | null
1822
- total_chats: number | null
1823
- total_logs: number | null
1824
- total_participants: number | null
1825
- }
1667
+ action: string | null;
1668
+ failed: number | null;
1669
+ operation_id: string | null;
1670
+ org_id: string | null;
1671
+ pending: number | null;
1672
+ performed_at: string | null;
1673
+ performed_by: string | null;
1674
+ success: number | null;
1675
+ total_chats: number | null;
1676
+ total_logs: number | null;
1677
+ total_participants: number | null;
1678
+ };
1826
1679
  Relationships: [
1827
1680
  {
1828
- foreignKeyName: "tbl_chat_logs_org_id_fkey"
1829
- columns: ["org_id"]
1830
- isOneToOne: false
1831
- referencedRelation: "tbl_org"
1832
- referencedColumns: ["org_id"]
1681
+ foreignKeyName: 'tbl_chat_logs_org_id_fkey';
1682
+ columns: ['org_id'];
1683
+ isOneToOne: false;
1684
+ referencedRelation: 'tbl_org';
1685
+ referencedColumns: ['org_id'];
1833
1686
  },
1834
1687
  {
1835
- foreignKeyName: "tbl_chat_logs_org_id_fkey"
1836
- columns: ["org_id"]
1837
- isOneToOne: false
1838
- referencedRelation: "view_org"
1839
- referencedColumns: ["org_id"]
1688
+ foreignKeyName: 'tbl_chat_logs_org_id_fkey';
1689
+ columns: ['org_id'];
1690
+ isOneToOne: false;
1691
+ referencedRelation: 'view_org';
1692
+ referencedColumns: ['org_id'];
1840
1693
  },
1841
- ]
1842
- }
1694
+ ];
1695
+ };
1843
1696
  view_chats: {
1844
1697
  Row: {
1845
- active_phone: string | null
1846
- chat_access: Json | null
1847
- chat_id: string | null
1848
- chat_image: string | null
1849
- chat_name: string | null
1850
- chat_type: string | null
1851
- created_at: string | null
1852
- custom_properties: Json | null
1853
- flag_count: number | null
1854
- group_description: string | null
1855
- hubspot_metadata: Json | null
1856
- info_admins_only: boolean | null
1857
- invite_link: string | null
1858
- is_archived: boolean | null
1859
- is_muted: boolean | null
1860
- label_ids: Json | null
1861
- last_read_timestamp: string | null
1862
- latest_message: Json | null
1863
- member_count: number | null
1864
- message_unread_count: number | null
1865
- messages_admins_only: boolean | null
1866
- org_id: string | null
1867
- org_phone: string | null
1868
- updated_at: string | null
1869
- }
1870
- Relationships: []
1871
- }
1698
+ active_phone: string | null;
1699
+ chat_access: Json | null;
1700
+ chat_id: string | null;
1701
+ chat_image: string | null;
1702
+ chat_name: string | null;
1703
+ chat_type: string | null;
1704
+ created_at: string | null;
1705
+ custom_properties: Json | null;
1706
+ flag_count: number | null;
1707
+ group_description: string | null;
1708
+ hubspot_metadata: Json | null;
1709
+ info_admins_only: boolean | null;
1710
+ invite_link: string | null;
1711
+ is_archived: boolean | null;
1712
+ is_muted: boolean | null;
1713
+ label_ids: Json | null;
1714
+ last_read_timestamp: string | null;
1715
+ latest_message: Json | null;
1716
+ member_count: number | null;
1717
+ message_unread_count: number | null;
1718
+ messages_admins_only: boolean | null;
1719
+ org_id: string | null;
1720
+ org_phone: string | null;
1721
+ updated_at: string | null;
1722
+ };
1723
+ Relationships: [];
1724
+ };
1872
1725
  view_org: {
1873
1726
  Row: {
1874
- created_at: string | null
1875
- is_enterprise: boolean | null
1876
- is_free_trial: boolean | null
1877
- is_hubspot_connected: boolean | null
1878
- org_id: string | null
1879
- org_image: string | null
1880
- org_metadata: Json | null
1881
- org_name: string | null
1882
- org_plan: Json | null
1883
- pending_days: number | null
1884
- phone_limit: string | null
1885
- plan_id: string | null
1886
- stripe_customer_details: Json | null
1887
- stripe_customer_id: string | null
1888
- stripe_subscription_details: Json | null
1889
- subscription_status: string | null
1890
- support_link: string | null
1891
- user_limit: string | null
1892
- }
1727
+ access_scopes: Json | null;
1728
+ created_at: string | null;
1729
+ is_enterprise: boolean | null;
1730
+ is_free_trial: boolean | null;
1731
+ is_hubspot_connected: boolean | null;
1732
+ org_id: string | null;
1733
+ org_image: string | null;
1734
+ org_metadata: Json | null;
1735
+ org_name: string | null;
1736
+ org_plan: Json | null;
1737
+ pending_days: number | null;
1738
+ phone_limit: string | null;
1739
+ plan_id: string | null;
1740
+ stripe_customer_details: Json | null;
1741
+ stripe_customer_id: string | null;
1742
+ stripe_subscription_details: Json | null;
1743
+ subscription_status: string | null;
1744
+ support_link: string | null;
1745
+ user_limit: string | null;
1746
+ };
1893
1747
  Insert: {
1894
- created_at?: string | null
1895
- is_enterprise?: never
1896
- is_free_trial?: never
1897
- is_hubspot_connected?: never
1898
- org_id?: string | null
1899
- org_image?: string | null
1900
- org_metadata?: Json | null
1901
- org_name?: string | null
1902
- org_plan?: Json | null
1903
- pending_days?: never
1904
- phone_limit?: never
1905
- plan_id?: never
1906
- stripe_customer_details?: Json | null
1907
- stripe_customer_id?: string | null
1908
- stripe_subscription_details?: Json | null
1909
- subscription_status?: never
1910
- support_link?: string | null
1911
- user_limit?: never
1912
- }
1748
+ access_scopes?: never;
1749
+ created_at?: string | null;
1750
+ is_enterprise?: never;
1751
+ is_free_trial?: never;
1752
+ is_hubspot_connected?: never;
1753
+ org_id?: string | null;
1754
+ org_image?: string | null;
1755
+ org_metadata?: Json | null;
1756
+ org_name?: string | null;
1757
+ org_plan?: Json | null;
1758
+ pending_days?: never;
1759
+ phone_limit?: never;
1760
+ plan_id?: never;
1761
+ stripe_customer_details?: Json | null;
1762
+ stripe_customer_id?: string | null;
1763
+ stripe_subscription_details?: Json | null;
1764
+ subscription_status?: never;
1765
+ support_link?: string | null;
1766
+ user_limit?: never;
1767
+ };
1913
1768
  Update: {
1914
- created_at?: string | null
1915
- is_enterprise?: never
1916
- is_free_trial?: never
1917
- is_hubspot_connected?: never
1918
- org_id?: string | null
1919
- org_image?: string | null
1920
- org_metadata?: Json | null
1921
- org_name?: string | null
1922
- org_plan?: Json | null
1923
- pending_days?: never
1924
- phone_limit?: never
1925
- plan_id?: never
1926
- stripe_customer_details?: Json | null
1927
- stripe_customer_id?: string | null
1928
- stripe_subscription_details?: Json | null
1929
- subscription_status?: never
1930
- support_link?: string | null
1931
- user_limit?: never
1932
- }
1933
- Relationships: []
1934
- }
1935
- }
1769
+ access_scopes?: never;
1770
+ created_at?: string | null;
1771
+ is_enterprise?: never;
1772
+ is_free_trial?: never;
1773
+ is_hubspot_connected?: never;
1774
+ org_id?: string | null;
1775
+ org_image?: string | null;
1776
+ org_metadata?: Json | null;
1777
+ org_name?: string | null;
1778
+ org_plan?: Json | null;
1779
+ pending_days?: never;
1780
+ phone_limit?: never;
1781
+ plan_id?: never;
1782
+ stripe_customer_details?: Json | null;
1783
+ stripe_customer_id?: string | null;
1784
+ stripe_subscription_details?: Json | null;
1785
+ subscription_status?: never;
1786
+ support_link?: string | null;
1787
+ user_limit?: never;
1788
+ };
1789
+ Relationships: [];
1790
+ };
1791
+ };
1936
1792
  Functions: {
1937
1793
  create_partition: {
1938
1794
  Args: {
1939
- org_id_input: string
1940
- }
1941
- Returns: boolean
1942
- }
1795
+ org_id_input: string;
1796
+ };
1797
+ Returns: boolean;
1798
+ };
1943
1799
  drop_partition: {
1944
1800
  Args: {
1945
- org_id_input: string
1946
- }
1947
- Returns: boolean
1948
- }
1801
+ org_id_input: string;
1802
+ };
1803
+ Returns: boolean;
1804
+ };
1949
1805
  gen_id: {
1950
1806
  Args: {
1951
- prefix: string
1952
- size?: number
1953
- alphabet?: string
1954
- }
1955
- Returns: string
1956
- }
1807
+ prefix: string;
1808
+ size?: number;
1809
+ alphabet?: string;
1810
+ };
1811
+ Returns: string;
1812
+ };
1957
1813
  gen_ticket_id: {
1958
1814
  Args: {
1959
- org_id_input: string
1960
- }
1961
- Returns: string
1962
- }
1815
+ org_id_input: string;
1816
+ };
1817
+ Returns: string;
1818
+ };
1963
1819
  generate_access_token: {
1964
1820
  Args: {
1965
- name_input?: string
1966
- type_input?: Database["public"]["Enums"]["enum_integration_type"]
1967
- org_id_input?: string
1968
- }
1969
- Returns: Json
1970
- }
1821
+ name_input?: string;
1822
+ type_input?: Database['public']['Enums']['enum_integration_type'];
1823
+ org_id_input?: string;
1824
+ };
1825
+ Returns: Json;
1826
+ };
1971
1827
  get_api_auth_details: {
1972
1828
  Args: {
1973
- org_id_input?: string
1974
- org_phone_input?: string
1975
- token_id_input?: string
1976
- token_type_input?: Database["public"]["Enums"]["enum_integration_type"]
1977
- }
1978
- Returns: Json
1979
- }
1829
+ org_id_input?: string;
1830
+ org_phone_input?: string;
1831
+ token_id_input?: string;
1832
+ token_type_input?: Database['public']['Enums']['enum_integration_type'];
1833
+ };
1834
+ Returns: Json;
1835
+ };
1980
1836
  get_chat_labels_data: {
1981
1837
  Args: {
1982
- org_id_input: string
1983
- chat_ids_input?: string[]
1984
- }
1985
- Returns: Json[]
1986
- }
1838
+ org_id_input: string;
1839
+ chat_ids_input?: string[];
1840
+ };
1841
+ Returns: Json[];
1842
+ };
1987
1843
  get_chat_members: {
1988
1844
  Args: {
1989
- org_id_input?: string
1990
- chat_id_input?: string[]
1991
- }
1992
- Returns: Json
1993
- }
1845
+ org_id_input?: string;
1846
+ chat_id_input?: string[];
1847
+ };
1848
+ Returns: Json;
1849
+ };
1994
1850
  get_chats: {
1995
1851
  Args: {
1996
- org_id_input?: string
1997
- chat_id_input?: string[]
1998
- }
1999
- Returns: Json
2000
- }
1852
+ org_id_input?: string;
1853
+ chat_id_input?: string[];
1854
+ };
1855
+ Returns: Json;
1856
+ };
2001
1857
  get_chats_info: {
2002
1858
  Args: {
2003
- chat_id_input: string
2004
- org_id_input: string
2005
- org_phone_input?: string
2006
- }
2007
- Returns: Json
2008
- }
1859
+ chat_id_input: string;
1860
+ org_id_input: string;
1861
+ org_phone_input?: string;
1862
+ };
1863
+ Returns: Json;
1864
+ };
2009
1865
  get_contacts: {
2010
1866
  Args: {
2011
- org_id_input: string
2012
- contact_ids_input?: string[]
2013
- with_name?: boolean
2014
- sync_phone_contacts?: boolean
2015
- }
2016
- Returns: Json
2017
- }
1867
+ org_id_input: string;
1868
+ contact_ids_input?: string[];
1869
+ with_name?: boolean;
1870
+ sync_phone_contacts?: boolean;
1871
+ };
1872
+ Returns: Json;
1873
+ };
2018
1874
  get_dashboard_statistics_between_dates: {
2019
1875
  Args: {
2020
- org_id_input: string
2021
- start_date: string
2022
- end_date: string
2023
- chat_id_input?: string[]
2024
- }
2025
- Returns: Json
2026
- }
1876
+ org_id_input: string;
1877
+ start_date: string;
1878
+ end_date: string;
1879
+ chat_id_input?: string[];
1880
+ };
1881
+ Returns: Json;
1882
+ };
2027
1883
  get_export_chats_data: {
2028
1884
  Args: {
2029
- org_id_input: string
2030
- chat_ids?: string[]
2031
- }
2032
- Returns: Json
2033
- }
1885
+ org_id_input: string;
1886
+ chat_ids?: string[];
1887
+ };
1888
+ Returns: Json;
1889
+ };
2034
1890
  get_integration_data: {
2035
1891
  Args: {
2036
- org_id_input?: string
2037
- }
2038
- Returns: Json
2039
- }
1892
+ org_id_input?: string;
1893
+ };
1894
+ Returns: Json;
1895
+ };
2040
1896
  get_messages_notifications_reactions: {
2041
1897
  Args: {
2042
- org_id_input: string
2043
- chat_id_input?: string[]
2044
- message_limit_input?: number
2045
- reaction_notification_limit_input?: number
2046
- last_updated_at_input?: string
2047
- }
2048
- Returns: Json
2049
- }
1898
+ org_id_input: string;
1899
+ chat_id_input?: string[];
1900
+ message_limit_input?: number;
1901
+ reaction_notification_limit_input?: number;
1902
+ last_updated_at_input?: string;
1903
+ };
1904
+ Returns: Json;
1905
+ };
2050
1906
  get_org: {
2051
1907
  Args: {
2052
- org_id_input?: string
2053
- }
2054
- Returns: Json
2055
- }
1908
+ org_id_input?: string;
1909
+ };
1910
+ Returns: Json;
1911
+ };
2056
1912
  get_org_phones: {
2057
1913
  Args: {
2058
- org_id_input?: string
2059
- phone_id_input?: string
2060
- }
2061
- Returns: Json
2062
- }
1914
+ org_id_input?: string;
1915
+ phone_id_input?: string;
1916
+ };
1917
+ Returns: Json;
1918
+ };
2063
1919
  get_team_metrics_between_dates: {
2064
1920
  Args: {
2065
- org_id_input: string
2066
- start_date: string
2067
- end_date: string
2068
- chat_id_input?: string[]
2069
- }
2070
- Returns: Json
2071
- }
1921
+ org_id_input: string;
1922
+ start_date: string;
1923
+ end_date: string;
1924
+ chat_id_input?: string[];
1925
+ };
1926
+ Returns: Json;
1927
+ };
2072
1928
  get_ticket_info: {
2073
1929
  Args: {
2074
- ticket_id_input?: string
2075
- org_id_input?: string
2076
- chat_id_input?: string
2077
- unique_message_id_input?: string
2078
- }
2079
- Returns: Json
2080
- }
1930
+ ticket_id_input?: string;
1931
+ org_id_input?: string;
1932
+ chat_id_input?: string;
1933
+ unique_message_id_input?: string;
1934
+ };
1935
+ Returns: Json;
1936
+ };
2081
1937
  image_path: {
2082
1938
  Args: {
2083
- path_input?: string
2084
- bucket_name?: string
2085
- req_base?: boolean
2086
- }
2087
- Returns: string
2088
- }
1939
+ path_input?: string;
1940
+ bucket_name?: string;
1941
+ req_base?: boolean;
1942
+ };
1943
+ Returns: string;
1944
+ };
2089
1945
  list_org_from_user: {
2090
- Args: Record<PropertyKey, never>
2091
- Returns: string[]
2092
- }
1946
+ Args: Record<PropertyKey, never>;
1947
+ Returns: string[];
1948
+ };
2093
1949
  list_role_from_user: {
2094
- Args: Record<PropertyKey, never>
2095
- Returns: Database["public"]["Enums"]["enum_member_role"]
2096
- }
1950
+ Args: Record<PropertyKey, never>;
1951
+ Returns: Database['public']['Enums']['enum_member_role'];
1952
+ };
2097
1953
  update_labels: {
2098
1954
  Args: {
2099
- org_id_input: string
2100
- tbl_type: string
2101
- row_label_map: Json
2102
- replace_labels?: boolean
2103
- }
2104
- Returns: undefined
2105
- }
2106
- }
1955
+ org_id_input: string;
1956
+ tbl_type: string;
1957
+ row_label_map: Json;
1958
+ replace_labels?: boolean;
1959
+ };
1960
+ Returns: undefined;
1961
+ };
1962
+ };
2107
1963
  Enums: {
2108
- enum_broadcast_status: "inprogress" | "completed" | "stopped"
1964
+ enum_broadcast_status: 'inprogress' | 'completed' | 'stopped';
2109
1965
  enum_chat_colors:
2110
- | "#B4876E"
2111
- | "#A5B337"
2112
- | "#06CF9C"
2113
- | "#25D366"
2114
- | "#02A698"
2115
- | "#7D9EF1"
2116
- | "#007BFC"
2117
- | "#5E47DE"
2118
- | "#7F66FF"
2119
- | "#9333EA"
2120
- | "#FA6533"
2121
- | "#C4532D"
2122
- | "#DC2626"
2123
- | "#FF2E74"
2124
- | "#DB2777"
2125
- enum_chat_tickets_status: "open" | "inprogress" | "closed" | "archived"
1966
+ | '#B4876E'
1967
+ | '#A5B337'
1968
+ | '#06CF9C'
1969
+ | '#25D366'
1970
+ | '#02A698'
1971
+ | '#7D9EF1'
1972
+ | '#007BFC'
1973
+ | '#5E47DE'
1974
+ | '#7F66FF'
1975
+ | '#9333EA'
1976
+ | '#FA6533'
1977
+ | '#C4532D'
1978
+ | '#DC2626'
1979
+ | '#FF2E74'
1980
+ | '#DB2777';
1981
+ enum_chat_tickets_status: 'open' | 'inprogress' | 'closed' | 'archived';
2126
1982
  enum_integration_name:
2127
- | "org.created"
2128
- | "org.updated"
2129
- | "org.member.created"
2130
- | "org.member.updated"
2131
- | "org.phone.created"
2132
- | "org.phone.connected"
2133
- | "org.phone.disconnected"
2134
- | "org.subscription.trial_will_end"
2135
- | "chat.created"
2136
- | "chat.updated"
2137
- | "message.created"
2138
- | "message.updated"
2139
- | "message.deleted"
2140
- | "message.ack.updated"
2141
- | "reaction.created"
2142
- | "reaction.updated"
2143
- | "ticket.created"
2144
- | "ticket.updated"
2145
- | "ticket.deleted"
1983
+ | 'org.created'
1984
+ | 'org.updated'
1985
+ | 'org.member.created'
1986
+ | 'org.member.updated'
1987
+ | 'org.phone.created'
1988
+ | 'org.phone.connected'
1989
+ | 'org.phone.disconnected'
1990
+ | 'org.subscription.trial_will_end'
1991
+ | 'chat.created'
1992
+ | 'chat.updated'
1993
+ | 'message.created'
1994
+ | 'message.updated'
1995
+ | 'message.deleted'
1996
+ | 'message.ack.updated'
1997
+ | 'reaction.created'
1998
+ | 'reaction.updated'
1999
+ | 'ticket.created'
2000
+ | 'ticket.updated'
2001
+ | 'ticket.deleted';
2146
2002
  enum_integration_type:
2147
- | "zapier"
2148
- | "pabbly"
2149
- | "api"
2150
- | "webhook"
2151
- | "hubspot"
2152
- | "freshdesk"
2153
- | "slack"
2154
- | "jira"
2155
- | "salesforce"
2156
- enum_member_role: "admin" | "member"
2157
- }
2003
+ | 'zapier'
2004
+ | 'pabbly'
2005
+ | 'api'
2006
+ | 'webhook'
2007
+ | 'hubspot'
2008
+ | 'freshdesk'
2009
+ | 'slack'
2010
+ | 'jira'
2011
+ | 'salesforce';
2012
+ enum_member_role: 'admin' | 'member';
2013
+ };
2158
2014
  CompositeTypes: {
2159
- [_ in never]: never
2160
- }
2161
- }
2015
+ [_ in never]: never;
2016
+ };
2017
+ };
2162
2018
  storage: {
2163
2019
  Tables: {
2164
2020
  buckets: {
2165
2021
  Row: {
2166
- allowed_mime_types: string[] | null
2167
- avif_autodetection: boolean | null
2168
- created_at: string | null
2169
- file_size_limit: number | null
2170
- id: string
2171
- name: string
2172
- owner: string | null
2173
- owner_id: string | null
2174
- public: boolean | null
2175
- updated_at: string | null
2176
- }
2022
+ allowed_mime_types: string[] | null;
2023
+ avif_autodetection: boolean | null;
2024
+ created_at: string | null;
2025
+ file_size_limit: number | null;
2026
+ id: string;
2027
+ name: string;
2028
+ owner: string | null;
2029
+ owner_id: string | null;
2030
+ public: boolean | null;
2031
+ updated_at: string | null;
2032
+ };
2177
2033
  Insert: {
2178
- allowed_mime_types?: string[] | null
2179
- avif_autodetection?: boolean | null
2180
- created_at?: string | null
2181
- file_size_limit?: number | null
2182
- id: string
2183
- name: string
2184
- owner?: string | null
2185
- owner_id?: string | null
2186
- public?: boolean | null
2187
- updated_at?: string | null
2188
- }
2034
+ allowed_mime_types?: string[] | null;
2035
+ avif_autodetection?: boolean | null;
2036
+ created_at?: string | null;
2037
+ file_size_limit?: number | null;
2038
+ id: string;
2039
+ name: string;
2040
+ owner?: string | null;
2041
+ owner_id?: string | null;
2042
+ public?: boolean | null;
2043
+ updated_at?: string | null;
2044
+ };
2189
2045
  Update: {
2190
- allowed_mime_types?: string[] | null
2191
- avif_autodetection?: boolean | null
2192
- created_at?: string | null
2193
- file_size_limit?: number | null
2194
- id?: string
2195
- name?: string
2196
- owner?: string | null
2197
- owner_id?: string | null
2198
- public?: boolean | null
2199
- updated_at?: string | null
2200
- }
2201
- Relationships: []
2202
- }
2046
+ allowed_mime_types?: string[] | null;
2047
+ avif_autodetection?: boolean | null;
2048
+ created_at?: string | null;
2049
+ file_size_limit?: number | null;
2050
+ id?: string;
2051
+ name?: string;
2052
+ owner?: string | null;
2053
+ owner_id?: string | null;
2054
+ public?: boolean | null;
2055
+ updated_at?: string | null;
2056
+ };
2057
+ Relationships: [];
2058
+ };
2203
2059
  migrations: {
2204
2060
  Row: {
2205
- executed_at: string | null
2206
- hash: string
2207
- id: number
2208
- name: string
2209
- }
2061
+ executed_at: string | null;
2062
+ hash: string;
2063
+ id: number;
2064
+ name: string;
2065
+ };
2210
2066
  Insert: {
2211
- executed_at?: string | null
2212
- hash: string
2213
- id: number
2214
- name: string
2215
- }
2067
+ executed_at?: string | null;
2068
+ hash: string;
2069
+ id: number;
2070
+ name: string;
2071
+ };
2216
2072
  Update: {
2217
- executed_at?: string | null
2218
- hash?: string
2219
- id?: number
2220
- name?: string
2221
- }
2222
- Relationships: []
2223
- }
2073
+ executed_at?: string | null;
2074
+ hash?: string;
2075
+ id?: number;
2076
+ name?: string;
2077
+ };
2078
+ Relationships: [];
2079
+ };
2224
2080
  objects: {
2225
2081
  Row: {
2226
- bucket_id: string | null
2227
- created_at: string | null
2228
- id: string
2229
- last_accessed_at: string | null
2230
- metadata: Json | null
2231
- name: string | null
2232
- owner: string | null
2233
- owner_id: string | null
2234
- path_tokens: string[] | null
2235
- updated_at: string | null
2236
- version: string | null
2237
- }
2082
+ bucket_id: string | null;
2083
+ created_at: string | null;
2084
+ id: string;
2085
+ last_accessed_at: string | null;
2086
+ metadata: Json | null;
2087
+ name: string | null;
2088
+ owner: string | null;
2089
+ owner_id: string | null;
2090
+ path_tokens: string[] | null;
2091
+ updated_at: string | null;
2092
+ version: string | null;
2093
+ };
2238
2094
  Insert: {
2239
- bucket_id?: string | null
2240
- created_at?: string | null
2241
- id?: string
2242
- last_accessed_at?: string | null
2243
- metadata?: Json | null
2244
- name?: string | null
2245
- owner?: string | null
2246
- owner_id?: string | null
2247
- path_tokens?: string[] | null
2248
- updated_at?: string | null
2249
- version?: string | null
2250
- }
2095
+ bucket_id?: string | null;
2096
+ created_at?: string | null;
2097
+ id?: string;
2098
+ last_accessed_at?: string | null;
2099
+ metadata?: Json | null;
2100
+ name?: string | null;
2101
+ owner?: string | null;
2102
+ owner_id?: string | null;
2103
+ path_tokens?: string[] | null;
2104
+ updated_at?: string | null;
2105
+ version?: string | null;
2106
+ };
2251
2107
  Update: {
2252
- bucket_id?: string | null
2253
- created_at?: string | null
2254
- id?: string
2255
- last_accessed_at?: string | null
2256
- metadata?: Json | null
2257
- name?: string | null
2258
- owner?: string | null
2259
- owner_id?: string | null
2260
- path_tokens?: string[] | null
2261
- updated_at?: string | null
2262
- version?: string | null
2263
- }
2108
+ bucket_id?: string | null;
2109
+ created_at?: string | null;
2110
+ id?: string;
2111
+ last_accessed_at?: string | null;
2112
+ metadata?: Json | null;
2113
+ name?: string | null;
2114
+ owner?: string | null;
2115
+ owner_id?: string | null;
2116
+ path_tokens?: string[] | null;
2117
+ updated_at?: string | null;
2118
+ version?: string | null;
2119
+ };
2264
2120
  Relationships: [
2265
2121
  {
2266
- foreignKeyName: "objects_bucketId_fkey"
2267
- columns: ["bucket_id"]
2268
- isOneToOne: false
2269
- referencedRelation: "buckets"
2270
- referencedColumns: ["id"]
2122
+ foreignKeyName: 'objects_bucketId_fkey';
2123
+ columns: ['bucket_id'];
2124
+ isOneToOne: false;
2125
+ referencedRelation: 'buckets';
2126
+ referencedColumns: ['id'];
2271
2127
  },
2272
- ]
2273
- }
2128
+ ];
2129
+ };
2274
2130
  s3_multipart_uploads: {
2275
2131
  Row: {
2276
- bucket_id: string
2277
- created_at: string
2278
- id: string
2279
- in_progress_size: number
2280
- key: string
2281
- owner_id: string | null
2282
- upload_signature: string
2283
- version: string
2284
- }
2132
+ bucket_id: string;
2133
+ created_at: string;
2134
+ id: string;
2135
+ in_progress_size: number;
2136
+ key: string;
2137
+ owner_id: string | null;
2138
+ upload_signature: string;
2139
+ version: string;
2140
+ };
2285
2141
  Insert: {
2286
- bucket_id: string
2287
- created_at?: string
2288
- id: string
2289
- in_progress_size?: number
2290
- key: string
2291
- owner_id?: string | null
2292
- upload_signature: string
2293
- version: string
2294
- }
2142
+ bucket_id: string;
2143
+ created_at?: string;
2144
+ id: string;
2145
+ in_progress_size?: number;
2146
+ key: string;
2147
+ owner_id?: string | null;
2148
+ upload_signature: string;
2149
+ version: string;
2150
+ };
2295
2151
  Update: {
2296
- bucket_id?: string
2297
- created_at?: string
2298
- id?: string
2299
- in_progress_size?: number
2300
- key?: string
2301
- owner_id?: string | null
2302
- upload_signature?: string
2303
- version?: string
2304
- }
2152
+ bucket_id?: string;
2153
+ created_at?: string;
2154
+ id?: string;
2155
+ in_progress_size?: number;
2156
+ key?: string;
2157
+ owner_id?: string | null;
2158
+ upload_signature?: string;
2159
+ version?: string;
2160
+ };
2305
2161
  Relationships: [
2306
2162
  {
2307
- foreignKeyName: "s3_multipart_uploads_bucket_id_fkey"
2308
- columns: ["bucket_id"]
2309
- isOneToOne: false
2310
- referencedRelation: "buckets"
2311
- referencedColumns: ["id"]
2163
+ foreignKeyName: 's3_multipart_uploads_bucket_id_fkey';
2164
+ columns: ['bucket_id'];
2165
+ isOneToOne: false;
2166
+ referencedRelation: 'buckets';
2167
+ referencedColumns: ['id'];
2312
2168
  },
2313
- ]
2314
- }
2169
+ ];
2170
+ };
2315
2171
  s3_multipart_uploads_parts: {
2316
2172
  Row: {
2317
- bucket_id: string
2318
- created_at: string
2319
- etag: string
2320
- id: string
2321
- key: string
2322
- owner_id: string | null
2323
- part_number: number
2324
- size: number
2325
- upload_id: string
2326
- version: string
2327
- }
2173
+ bucket_id: string;
2174
+ created_at: string;
2175
+ etag: string;
2176
+ id: string;
2177
+ key: string;
2178
+ owner_id: string | null;
2179
+ part_number: number;
2180
+ size: number;
2181
+ upload_id: string;
2182
+ version: string;
2183
+ };
2328
2184
  Insert: {
2329
- bucket_id: string
2330
- created_at?: string
2331
- etag: string
2332
- id?: string
2333
- key: string
2334
- owner_id?: string | null
2335
- part_number: number
2336
- size?: number
2337
- upload_id: string
2338
- version: string
2339
- }
2185
+ bucket_id: string;
2186
+ created_at?: string;
2187
+ etag: string;
2188
+ id?: string;
2189
+ key: string;
2190
+ owner_id?: string | null;
2191
+ part_number: number;
2192
+ size?: number;
2193
+ upload_id: string;
2194
+ version: string;
2195
+ };
2340
2196
  Update: {
2341
- bucket_id?: string
2342
- created_at?: string
2343
- etag?: string
2344
- id?: string
2345
- key?: string
2346
- owner_id?: string | null
2347
- part_number?: number
2348
- size?: number
2349
- upload_id?: string
2350
- version?: string
2351
- }
2197
+ bucket_id?: string;
2198
+ created_at?: string;
2199
+ etag?: string;
2200
+ id?: string;
2201
+ key?: string;
2202
+ owner_id?: string | null;
2203
+ part_number?: number;
2204
+ size?: number;
2205
+ upload_id?: string;
2206
+ version?: string;
2207
+ };
2352
2208
  Relationships: [
2353
2209
  {
2354
- foreignKeyName: "s3_multipart_uploads_parts_bucket_id_fkey"
2355
- columns: ["bucket_id"]
2356
- isOneToOne: false
2357
- referencedRelation: "buckets"
2358
- referencedColumns: ["id"]
2210
+ foreignKeyName: 's3_multipart_uploads_parts_bucket_id_fkey';
2211
+ columns: ['bucket_id'];
2212
+ isOneToOne: false;
2213
+ referencedRelation: 'buckets';
2214
+ referencedColumns: ['id'];
2359
2215
  },
2360
2216
  {
2361
- foreignKeyName: "s3_multipart_uploads_parts_upload_id_fkey"
2362
- columns: ["upload_id"]
2363
- isOneToOne: false
2364
- referencedRelation: "s3_multipart_uploads"
2365
- referencedColumns: ["id"]
2217
+ foreignKeyName: 's3_multipart_uploads_parts_upload_id_fkey';
2218
+ columns: ['upload_id'];
2219
+ isOneToOne: false;
2220
+ referencedRelation: 's3_multipart_uploads';
2221
+ referencedColumns: ['id'];
2366
2222
  },
2367
- ]
2368
- }
2369
- }
2223
+ ];
2224
+ };
2225
+ };
2370
2226
  Views: {
2371
- [_ in never]: never
2372
- }
2227
+ [_ in never]: never;
2228
+ };
2373
2229
  Functions: {
2374
2230
  can_insert_object: {
2375
2231
  Args: {
2376
- bucketid: string
2377
- name: string
2378
- owner: string
2379
- metadata: Json
2380
- }
2381
- Returns: undefined
2382
- }
2232
+ bucketid: string;
2233
+ name: string;
2234
+ owner: string;
2235
+ metadata: Json;
2236
+ };
2237
+ Returns: undefined;
2238
+ };
2383
2239
  extension: {
2384
2240
  Args: {
2385
- name: string
2386
- }
2387
- Returns: string
2388
- }
2241
+ name: string;
2242
+ };
2243
+ Returns: string;
2244
+ };
2389
2245
  filename: {
2390
2246
  Args: {
2391
- name: string
2392
- }
2393
- Returns: string
2394
- }
2247
+ name: string;
2248
+ };
2249
+ Returns: string;
2250
+ };
2395
2251
  foldername: {
2396
2252
  Args: {
2397
- name: string
2398
- }
2399
- Returns: string[]
2400
- }
2253
+ name: string;
2254
+ };
2255
+ Returns: string[];
2256
+ };
2401
2257
  get_size_by_bucket: {
2402
- Args: Record<PropertyKey, never>
2258
+ Args: Record<PropertyKey, never>;
2403
2259
  Returns: {
2404
- size: number
2405
- bucket_id: string
2406
- }[]
2407
- }
2260
+ size: number;
2261
+ bucket_id: string;
2262
+ }[];
2263
+ };
2408
2264
  list_multipart_uploads_with_delimiter: {
2409
2265
  Args: {
2410
- bucket_id: string
2411
- prefix_param: string
2412
- delimiter_param: string
2413
- max_keys?: number
2414
- next_key_token?: string
2415
- next_upload_token?: string
2416
- }
2266
+ bucket_id: string;
2267
+ prefix_param: string;
2268
+ delimiter_param: string;
2269
+ max_keys?: number;
2270
+ next_key_token?: string;
2271
+ next_upload_token?: string;
2272
+ };
2417
2273
  Returns: {
2418
- key: string
2419
- id: string
2420
- created_at: string
2421
- }[]
2422
- }
2274
+ key: string;
2275
+ id: string;
2276
+ created_at: string;
2277
+ }[];
2278
+ };
2423
2279
  list_objects_with_delimiter: {
2424
2280
  Args: {
2425
- bucket_id: string
2426
- prefix_param: string
2427
- delimiter_param: string
2428
- max_keys?: number
2429
- start_after?: string
2430
- next_token?: string
2431
- }
2281
+ bucket_id: string;
2282
+ prefix_param: string;
2283
+ delimiter_param: string;
2284
+ max_keys?: number;
2285
+ start_after?: string;
2286
+ next_token?: string;
2287
+ };
2432
2288
  Returns: {
2433
- name: string
2434
- id: string
2435
- metadata: Json
2436
- updated_at: string
2437
- }[]
2438
- }
2289
+ name: string;
2290
+ id: string;
2291
+ metadata: Json;
2292
+ updated_at: string;
2293
+ }[];
2294
+ };
2439
2295
  search: {
2440
2296
  Args: {
2441
- prefix: string
2442
- bucketname: string
2443
- limits?: number
2444
- levels?: number
2445
- offsets?: number
2446
- search?: string
2447
- sortcolumn?: string
2448
- sortorder?: string
2449
- }
2297
+ prefix: string;
2298
+ bucketname: string;
2299
+ limits?: number;
2300
+ levels?: number;
2301
+ offsets?: number;
2302
+ search?: string;
2303
+ sortcolumn?: string;
2304
+ sortorder?: string;
2305
+ };
2450
2306
  Returns: {
2451
- name: string
2452
- id: string
2453
- updated_at: string
2454
- created_at: string
2455
- last_accessed_at: string
2456
- metadata: Json
2457
- }[]
2458
- }
2459
- }
2307
+ name: string;
2308
+ id: string;
2309
+ updated_at: string;
2310
+ created_at: string;
2311
+ last_accessed_at: string;
2312
+ metadata: Json;
2313
+ }[];
2314
+ };
2315
+ };
2460
2316
  Enums: {
2461
- [_ in never]: never
2462
- }
2317
+ [_ in never]: never;
2318
+ };
2463
2319
  CompositeTypes: {
2464
- [_ in never]: never
2465
- }
2466
- }
2467
- }
2320
+ [_ in never]: never;
2321
+ };
2322
+ };
2323
+ };
2468
2324
 
2469
- type PublicSchema = Database[Extract<keyof Database, "public">]
2325
+ type PublicSchema = Database[Extract<keyof Database, 'public'>];
2470
2326
 
2471
2327
  export type Tables<
2472
2328
  PublicTableNameOrOptions extends
2473
- | keyof (PublicSchema["Tables"] & PublicSchema["Views"])
2329
+ | keyof (PublicSchema['Tables'] & PublicSchema['Views'])
2474
2330
  | { schema: keyof Database },
2475
2331
  TableName extends PublicTableNameOrOptions extends { schema: keyof Database }
2476
- ? keyof (Database[PublicTableNameOrOptions["schema"]]["Tables"] &
2477
- Database[PublicTableNameOrOptions["schema"]]["Views"])
2332
+ ? keyof (Database[PublicTableNameOrOptions['schema']]['Tables'] &
2333
+ Database[PublicTableNameOrOptions['schema']]['Views'])
2478
2334
  : never = never,
2479
2335
  > = PublicTableNameOrOptions extends { schema: keyof Database }
2480
- ? (Database[PublicTableNameOrOptions["schema"]]["Tables"] &
2481
- Database[PublicTableNameOrOptions["schema"]]["Views"])[TableName] extends {
2482
- Row: infer R
2336
+ ? (Database[PublicTableNameOrOptions['schema']]['Tables'] &
2337
+ Database[PublicTableNameOrOptions['schema']]['Views'])[TableName] extends {
2338
+ Row: infer R;
2483
2339
  }
2484
2340
  ? R
2485
2341
  : never
2486
- : PublicTableNameOrOptions extends keyof (PublicSchema["Tables"] &
2487
- PublicSchema["Views"])
2488
- ? (PublicSchema["Tables"] &
2489
- PublicSchema["Views"])[PublicTableNameOrOptions] extends {
2490
- Row: infer R
2342
+ : PublicTableNameOrOptions extends keyof (PublicSchema['Tables'] &
2343
+ PublicSchema['Views'])
2344
+ ? (PublicSchema['Tables'] &
2345
+ PublicSchema['Views'])[PublicTableNameOrOptions] extends {
2346
+ Row: infer R;
2491
2347
  }
2492
2348
  ? R
2493
2349
  : never
2494
- : never
2350
+ : never;
2495
2351
 
2496
2352
  export type TablesInsert<
2497
2353
  PublicTableNameOrOptions extends
2498
- | keyof PublicSchema["Tables"]
2354
+ | keyof PublicSchema['Tables']
2499
2355
  | { schema: keyof Database },
2500
2356
  TableName extends PublicTableNameOrOptions extends { schema: keyof Database }
2501
- ? keyof Database[PublicTableNameOrOptions["schema"]]["Tables"]
2357
+ ? keyof Database[PublicTableNameOrOptions['schema']]['Tables']
2502
2358
  : never = never,
2503
2359
  > = PublicTableNameOrOptions extends { schema: keyof Database }
2504
- ? Database[PublicTableNameOrOptions["schema"]]["Tables"][TableName] extends {
2505
- Insert: infer I
2360
+ ? Database[PublicTableNameOrOptions['schema']]['Tables'][TableName] extends {
2361
+ Insert: infer I;
2506
2362
  }
2507
2363
  ? I
2508
2364
  : never
2509
- : PublicTableNameOrOptions extends keyof PublicSchema["Tables"]
2510
- ? PublicSchema["Tables"][PublicTableNameOrOptions] extends {
2511
- Insert: infer I
2365
+ : PublicTableNameOrOptions extends keyof PublicSchema['Tables']
2366
+ ? PublicSchema['Tables'][PublicTableNameOrOptions] extends {
2367
+ Insert: infer I;
2512
2368
  }
2513
2369
  ? I
2514
2370
  : never
2515
- : never
2371
+ : never;
2516
2372
 
2517
2373
  export type TablesUpdate<
2518
2374
  PublicTableNameOrOptions extends
2519
- | keyof PublicSchema["Tables"]
2375
+ | keyof PublicSchema['Tables']
2520
2376
  | { schema: keyof Database },
2521
2377
  TableName extends PublicTableNameOrOptions extends { schema: keyof Database }
2522
- ? keyof Database[PublicTableNameOrOptions["schema"]]["Tables"]
2378
+ ? keyof Database[PublicTableNameOrOptions['schema']]['Tables']
2523
2379
  : never = never,
2524
2380
  > = PublicTableNameOrOptions extends { schema: keyof Database }
2525
- ? Database[PublicTableNameOrOptions["schema"]]["Tables"][TableName] extends {
2526
- Update: infer U
2381
+ ? Database[PublicTableNameOrOptions['schema']]['Tables'][TableName] extends {
2382
+ Update: infer U;
2527
2383
  }
2528
2384
  ? U
2529
2385
  : never
2530
- : PublicTableNameOrOptions extends keyof PublicSchema["Tables"]
2531
- ? PublicSchema["Tables"][PublicTableNameOrOptions] extends {
2532
- Update: infer U
2386
+ : PublicTableNameOrOptions extends keyof PublicSchema['Tables']
2387
+ ? PublicSchema['Tables'][PublicTableNameOrOptions] extends {
2388
+ Update: infer U;
2533
2389
  }
2534
2390
  ? U
2535
2391
  : never
2536
- : never
2392
+ : never;
2537
2393
 
2538
2394
  export type Enums<
2539
2395
  PublicEnumNameOrOptions extends
2540
- | keyof PublicSchema["Enums"]
2396
+ | keyof PublicSchema['Enums']
2541
2397
  | { schema: keyof Database },
2542
2398
  EnumName extends PublicEnumNameOrOptions extends { schema: keyof Database }
2543
- ? keyof Database[PublicEnumNameOrOptions["schema"]]["Enums"]
2399
+ ? keyof Database[PublicEnumNameOrOptions['schema']]['Enums']
2544
2400
  : never = never,
2545
2401
  > = PublicEnumNameOrOptions extends { schema: keyof Database }
2546
- ? Database[PublicEnumNameOrOptions["schema"]]["Enums"][EnumName]
2547
- : PublicEnumNameOrOptions extends keyof PublicSchema["Enums"]
2548
- ? PublicSchema["Enums"][PublicEnumNameOrOptions]
2549
- : never
2550
-
2551
-
2402
+ ? Database[PublicEnumNameOrOptions['schema']]['Enums'][EnumName]
2403
+ : PublicEnumNameOrOptions extends keyof PublicSchema['Enums']
2404
+ ? PublicSchema['Enums'][PublicEnumNameOrOptions]
2405
+ : never;