@notionhq/client 5.13.0 → 5.15.0

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.
Files changed (70) hide show
  1. package/build/package.json +1 -1
  2. package/build/src/Client.d.ts +43 -1
  3. package/build/src/Client.d.ts.map +1 -1
  4. package/build/src/Client.js +139 -0
  5. package/build/src/Client.js.map +1 -1
  6. package/build/src/api-endpoints/blocks.d.ts +984 -0
  7. package/build/src/api-endpoints/blocks.d.ts.map +1 -0
  8. package/build/src/api-endpoints/blocks.js +89 -0
  9. package/build/src/api-endpoints/blocks.js.map +1 -0
  10. package/build/src/api-endpoints/comments.d.ts +112 -0
  11. package/build/src/api-endpoints/comments.d.ts.map +1 -0
  12. package/build/src/api-endpoints/comments.js +42 -0
  13. package/build/src/api-endpoints/comments.js.map +1 -0
  14. package/build/src/api-endpoints/common.d.ts +1939 -0
  15. package/build/src/api-endpoints/common.d.ts.map +1 -0
  16. package/build/src/api-endpoints/common.js +5 -0
  17. package/build/src/api-endpoints/common.js.map +1 -0
  18. package/build/src/api-endpoints/custom-emojis.d.ts +26 -0
  19. package/build/src/api-endpoints/custom-emojis.d.ts.map +1 -0
  20. package/build/src/api-endpoints/custom-emojis.js +16 -0
  21. package/build/src/api-endpoints/custom-emojis.js.map +1 -0
  22. package/build/src/api-endpoints/data-sources.d.ts +430 -0
  23. package/build/src/api-endpoints/data-sources.d.ts.map +1 -0
  24. package/build/src/api-endpoints/data-sources.js +64 -0
  25. package/build/src/api-endpoints/data-sources.js.map +1 -0
  26. package/build/src/api-endpoints/databases.d.ts +109 -0
  27. package/build/src/api-endpoints/databases.d.ts.map +1 -0
  28. package/build/src/api-endpoints/databases.js +53 -0
  29. package/build/src/api-endpoints/databases.js.map +1 -0
  30. package/build/src/api-endpoints/file-uploads.d.ts +138 -0
  31. package/build/src/api-endpoints/file-uploads.d.ts.map +1 -0
  32. package/build/src/api-endpoints/file-uploads.js +63 -0
  33. package/build/src/api-endpoints/file-uploads.js.map +1 -0
  34. package/build/src/api-endpoints/oauth.d.ts +90 -0
  35. package/build/src/api-endpoints/oauth.d.ts.map +1 -0
  36. package/build/src/api-endpoints/oauth.js +42 -0
  37. package/build/src/api-endpoints/oauth.js.map +1 -0
  38. package/build/src/api-endpoints/pages.d.ts +639 -0
  39. package/build/src/api-endpoints/pages.d.ts.map +1 -0
  40. package/build/src/api-endpoints/pages.js +102 -0
  41. package/build/src/api-endpoints/pages.js.map +1 -0
  42. package/build/src/api-endpoints/search.d.ts +36 -0
  43. package/build/src/api-endpoints/search.d.ts.map +1 -0
  44. package/build/src/api-endpoints/search.js +16 -0
  45. package/build/src/api-endpoints/search.js.map +1 -0
  46. package/build/src/api-endpoints/users.d.ts +53 -0
  47. package/build/src/api-endpoints/users.d.ts.map +1 -0
  48. package/build/src/api-endpoints/users.js +36 -0
  49. package/build/src/api-endpoints/users.js.map +1 -0
  50. package/build/src/api-endpoints/views.d.ts +504 -0
  51. package/build/src/api-endpoints/views.d.ts.map +1 -0
  52. package/build/src/api-endpoints/views.js +86 -0
  53. package/build/src/api-endpoints/views.js.map +1 -0
  54. package/build/src/api-endpoints/webhooks.d.ts +302 -0
  55. package/build/src/api-endpoints/webhooks.d.ts.map +1 -0
  56. package/build/src/api-endpoints/webhooks.js +5 -0
  57. package/build/src/api-endpoints/webhooks.js.map +1 -0
  58. package/build/src/api-endpoints.d.ts +13 -4078
  59. package/build/src/api-endpoints.d.ts.map +1 -1
  60. package/build/src/api-endpoints.js +31 -452
  61. package/build/src/api-endpoints.js.map +1 -1
  62. package/build/src/helpers.d.ts +5 -1
  63. package/build/src/helpers.d.ts.map +1 -1
  64. package/build/src/helpers.js +7 -0
  65. package/build/src/helpers.js.map +1 -1
  66. package/build/src/index.d.ts +2 -2
  67. package/build/src/index.d.ts.map +1 -1
  68. package/build/src/index.js +2 -1
  69. package/build/src/index.js.map +1 -1
  70. package/package.json +1 -1
@@ -0,0 +1,1939 @@
1
+ type AnnotationResponse = {
2
+ bold: boolean;
3
+ italic: boolean;
4
+ strikethrough: boolean;
5
+ underline: boolean;
6
+ code: boolean;
7
+ color: ApiColor;
8
+ };
9
+ /**
10
+ * One of: `default`, `gray`, `brown`, `orange`, `yellow`, `green`, `blue`, `purple`,
11
+ * `pink`, `red`, `default_background`, `gray_background`, `brown_background`,
12
+ * `orange_background`, `yellow_background`, `green_background`, `blue_background`,
13
+ * `purple_background`, `pink_background`, `red_background`
14
+ */
15
+ export type ApiColor = "default" | "gray" | "brown" | "orange" | "yellow" | "green" | "blue" | "purple" | "pink" | "red" | "default_background" | "gray_background" | "brown_background" | "orange_background" | "yellow_background" | "green_background" | "blue_background" | "purple_background" | "pink_background" | "red_background";
16
+ type BlockIdParentForBlockBasedObjectResponse = {
17
+ type: "block_id";
18
+ block_id: IdResponse;
19
+ };
20
+ type BoardViewConfigRequest = {
21
+ type: "board";
22
+ group_by: GroupByConfigRequest;
23
+ sub_group_by?: GroupByConfigRequest | null;
24
+ properties?: Array<ViewPropertyConfigRequest> | null;
25
+ cover?: CoverConfigRequest | null;
26
+ cover_size?: "small" | "medium" | "large" | null;
27
+ cover_aspect?: "contain" | "cover" | null;
28
+ card_layout?: "list" | "compact" | null;
29
+ };
30
+ type BotInfoResponse = {
31
+ owner: {
32
+ type: "user";
33
+ user: {
34
+ id: IdResponse;
35
+ object: "user";
36
+ name: string | null;
37
+ avatar_url: string | null;
38
+ type: "person";
39
+ person: {
40
+ email?: string;
41
+ };
42
+ } | PartialUserObjectResponse;
43
+ } | {
44
+ type: "workspace";
45
+ workspace: true;
46
+ };
47
+ workspace_id: string;
48
+ workspace_limits: {
49
+ max_file_upload_size_in_bytes: number;
50
+ };
51
+ workspace_name: string | null;
52
+ };
53
+ export type BotUserObjectResponse = {
54
+ type: "bot";
55
+ bot: EmptyObject | BotInfoResponse;
56
+ };
57
+ type ButtonPropertyConfigurationRequest = {
58
+ type?: "button";
59
+ button: EmptyObject;
60
+ };
61
+ type CalendarViewConfigRequest = {
62
+ type: "calendar";
63
+ date_property_id: string;
64
+ properties?: Array<ViewPropertyConfigRequest> | null;
65
+ view_range?: "week" | "month" | null;
66
+ show_weekends?: boolean | null;
67
+ };
68
+ type ChartAggregationRequest = {
69
+ aggregator: "count" | "count_values" | "sum" | "average" | "median" | "min" | "max" | "range" | "unique" | "empty" | "not_empty" | "percent_empty" | "percent_not_empty" | "checked" | "unchecked" | "percent_checked" | "percent_unchecked" | "earliest_date" | "latest_date" | "date_range";
70
+ property_id?: string;
71
+ };
72
+ type ChartReferenceLineRequest = {
73
+ value: number;
74
+ label: string;
75
+ color: "gray" | "lightgray" | "brown" | "yellow" | "orange" | "green" | "blue" | "purple" | "pink" | "red";
76
+ dash_style: "solid" | "dash";
77
+ id?: string;
78
+ };
79
+ type ChartViewConfigRequest = {
80
+ type: "chart";
81
+ chart_type: "column" | "bar" | "line" | "donut" | "number";
82
+ x_axis?: GroupByConfigRequest | null;
83
+ y_axis?: ChartAggregationRequest | null;
84
+ x_axis_property_id?: string | null;
85
+ y_axis_property_id?: string | null;
86
+ value?: ChartAggregationRequest | null;
87
+ sort?: "manual" | "x_ascending" | "x_descending" | "y_ascending" | "y_descending" | null;
88
+ color_theme?: "gray" | "blue" | "yellow" | "green" | "purple" | "teal" | "orange" | "pink" | "red" | "auto" | "colorful" | null;
89
+ height?: "small" | "medium" | "large" | "extra_large" | null;
90
+ hide_empty_groups?: boolean | null;
91
+ legend_position?: "off" | "bottom" | "side" | null;
92
+ show_data_labels?: boolean | null;
93
+ axis_labels?: "none" | "x_axis" | "y_axis" | "both" | null;
94
+ grid_lines?: "none" | "horizontal" | "vertical" | "both" | null;
95
+ cumulative?: boolean | null;
96
+ smooth_line?: boolean | null;
97
+ hide_line_fill_area?: boolean | null;
98
+ group_style?: "normal" | "percent" | "side_by_side" | null;
99
+ y_axis_min?: number | null;
100
+ y_axis_max?: number | null;
101
+ donut_labels?: "none" | "value" | "name" | "name_and_value" | null;
102
+ hide_title?: boolean | null;
103
+ stack_by?: GroupByConfigRequest | null;
104
+ reference_lines?: Array<ChartReferenceLineRequest> | null;
105
+ caption?: string | null;
106
+ color_by_value?: boolean | null;
107
+ };
108
+ type CheckboxGroupByConfigRequest = {
109
+ type: "checkbox";
110
+ property_id: string;
111
+ sort: GroupSortRequest;
112
+ hide_empty_groups?: boolean;
113
+ };
114
+ type CheckboxPropertyConfigurationRequest = {
115
+ type?: "checkbox";
116
+ checkbox: EmptyObject;
117
+ };
118
+ type CheckboxPropertyFilter = {
119
+ equals: boolean;
120
+ } | {
121
+ does_not_equal: boolean;
122
+ };
123
+ export type ContentPositionSchema = {
124
+ type: "after_block";
125
+ after_block: {
126
+ id: IdRequest;
127
+ };
128
+ } | {
129
+ type: "start";
130
+ } | {
131
+ type: "end";
132
+ };
133
+ type CoverConfigRequest = {
134
+ type: "page_cover" | "page_content" | "property";
135
+ property_id?: string;
136
+ };
137
+ type CreateDatabaseForViewRequest = {
138
+ parent: {
139
+ type: "page_id";
140
+ page_id: IdRequest;
141
+ };
142
+ position?: {
143
+ type: "after_block";
144
+ block_id: IdRequest;
145
+ };
146
+ };
147
+ export type CreateViewQueryRequest = {
148
+ page_size?: number;
149
+ };
150
+ export type CreateViewRequest = {
151
+ data_source_id: IdRequest;
152
+ name: string;
153
+ type: ViewTypeRequest;
154
+ database_id?: IdRequest;
155
+ view_id?: IdRequest;
156
+ filter?: ViewFilterRequest;
157
+ sorts?: ViewSortsRequest;
158
+ quick_filters?: Record<string, QuickFilterConditionRequest>;
159
+ create_database?: CreateDatabaseForViewRequest;
160
+ configuration?: ViewConfigRequest;
161
+ position?: ViewPositionRequest;
162
+ placement?: WidgetPlacementRequest;
163
+ };
164
+ type CreatedByPropertyConfigurationRequest = {
165
+ type?: "created_by";
166
+ created_by: EmptyObject;
167
+ };
168
+ type CreatedTimePropertyConfigurationRequest = {
169
+ type?: "created_time";
170
+ created_time: EmptyObject;
171
+ };
172
+ type CustomEmojiPageIconResponse = {
173
+ type: "custom_emoji";
174
+ custom_emoji: CustomEmojiResponse;
175
+ };
176
+ export type CustomEmojiResponse = {
177
+ id: IdResponse;
178
+ name: string;
179
+ url: string;
180
+ };
181
+ export type DataSourceParentResponse = {
182
+ type: "data_source_id";
183
+ data_source_id: IdResponse;
184
+ database_id: IdResponse;
185
+ };
186
+ export type DataSourceViewReferenceResponse = {
187
+ object: "view";
188
+ id: IdResponse;
189
+ };
190
+ export type DatabaseParentResponse = {
191
+ type: "database_id";
192
+ database_id: IdResponse;
193
+ };
194
+ type DateGroupByConfigRequest = {
195
+ type: "date" | "created_time" | "last_edited_time";
196
+ property_id: string;
197
+ group_by: "relative" | "day" | "week" | "month" | "year";
198
+ sort: GroupSortRequest;
199
+ hide_empty_groups?: boolean;
200
+ start_day_of_week?: 0 | 1;
201
+ };
202
+ type DatePropertyConfigurationRequest = {
203
+ type?: "date";
204
+ date: EmptyObject;
205
+ };
206
+ type DatePropertyFilter = {
207
+ equals: string;
208
+ } | {
209
+ before: string;
210
+ } | {
211
+ after: string;
212
+ } | {
213
+ on_or_before: string;
214
+ } | {
215
+ on_or_after: string;
216
+ } | {
217
+ this_week: EmptyObject;
218
+ } | {
219
+ past_week: EmptyObject;
220
+ } | {
221
+ past_month: EmptyObject;
222
+ } | {
223
+ past_year: EmptyObject;
224
+ } | {
225
+ next_week: EmptyObject;
226
+ } | {
227
+ next_month: EmptyObject;
228
+ } | {
229
+ next_year: EmptyObject;
230
+ } | ExistencePropertyFilter;
231
+ export type DateResponse = {
232
+ start: string;
233
+ end: string | null;
234
+ time_zone: TimeZoneRequest | null;
235
+ };
236
+ type EmailPropertyConfigurationRequest = {
237
+ type?: "email";
238
+ email: EmptyObject;
239
+ };
240
+ type EmojiPageIconResponse = {
241
+ type: "emoji";
242
+ emoji: EmojiRequest;
243
+ };
244
+ type EmojiRequest = string;
245
+ export type EmptyObject = Record<string, never>;
246
+ export type EquationRichTextItemResponse = {
247
+ type: "equation";
248
+ equation: {
249
+ expression: string;
250
+ };
251
+ };
252
+ type ExistencePropertyFilter = {
253
+ is_empty: true;
254
+ } | {
255
+ is_not_empty: true;
256
+ };
257
+ type ExternalPageCoverRequest = {
258
+ type?: "external";
259
+ external: {
260
+ url: string;
261
+ };
262
+ };
263
+ type ExternalPageCoverResponse = {
264
+ type: "external";
265
+ external: {
266
+ url: string;
267
+ };
268
+ };
269
+ type ExternalPageIconResponse = {
270
+ type: "external";
271
+ external: {
272
+ url: string;
273
+ };
274
+ };
275
+ type FilePageCoverResponse = {
276
+ type: "file";
277
+ file: InternalFileResponse;
278
+ };
279
+ type FilePageIconResponse = {
280
+ type: "file";
281
+ file: InternalFileResponse;
282
+ };
283
+ type FileUploadPageCoverRequest = {
284
+ type?: "file_upload";
285
+ file_upload: {
286
+ id: string;
287
+ };
288
+ };
289
+ export type FileUploadWithOptionalNameRequest = {
290
+ file_upload: FileUploadIdRequest;
291
+ type?: "file_upload";
292
+ name?: StringRequest;
293
+ };
294
+ type FilesPropertyConfigurationRequest = {
295
+ type?: "files";
296
+ files: EmptyObject;
297
+ };
298
+ type FormViewConfigRequest = {
299
+ type: "form";
300
+ is_form_closed?: boolean | null;
301
+ anonymous_submissions?: boolean | null;
302
+ submission_permissions?: "none" | "comment_only" | "reader" | "read_and_write" | "editor" | null;
303
+ };
304
+ type FormulaCheckboxSubGroupByRequest = {
305
+ type: "checkbox";
306
+ sort: GroupSortRequest;
307
+ };
308
+ type FormulaDateSubGroupByRequest = {
309
+ type: "date";
310
+ group_by: "relative" | "day" | "week" | "month" | "year";
311
+ sort: GroupSortRequest;
312
+ start_day_of_week?: 0 | 1;
313
+ };
314
+ type FormulaGroupByConfigRequest = {
315
+ type: "formula";
316
+ property_id: string;
317
+ group_by: FormulaDateSubGroupByRequest | FormulaTextSubGroupByRequest | FormulaNumberSubGroupByRequest | FormulaCheckboxSubGroupByRequest;
318
+ hide_empty_groups?: boolean;
319
+ };
320
+ type FormulaNumberSubGroupByRequest = {
321
+ type: "number";
322
+ sort: GroupSortRequest;
323
+ range_start?: number;
324
+ range_end?: number;
325
+ range_size?: number;
326
+ };
327
+ type FormulaPropertyConfigurationRequest = {
328
+ type?: "formula";
329
+ formula: {
330
+ expression?: string;
331
+ };
332
+ };
333
+ type FormulaPropertyFilter = {
334
+ string: TextPropertyFilter;
335
+ } | {
336
+ checkbox: CheckboxPropertyFilter;
337
+ } | {
338
+ number: NumberPropertyFilter;
339
+ } | {
340
+ date: DatePropertyFilter;
341
+ };
342
+ type FormulaTextSubGroupByRequest = {
343
+ type: "text";
344
+ group_by: "exact" | "alphabet_prefix";
345
+ sort: GroupSortRequest;
346
+ };
347
+ type GalleryViewConfigRequest = {
348
+ type: "gallery";
349
+ properties?: Array<ViewPropertyConfigRequest> | null;
350
+ cover?: CoverConfigRequest | null;
351
+ cover_size?: "small" | "medium" | "large" | null;
352
+ cover_aspect?: "contain" | "cover" | null;
353
+ card_layout?: "list" | "compact" | null;
354
+ };
355
+ /**
356
+ * Group-by configuration based on property type.
357
+ */
358
+ type GroupByConfigRequest = SelectGroupByConfigRequest | StatusGroupByConfigRequest | PersonGroupByConfigRequest | RelationGroupByConfigRequest | DateGroupByConfigRequest | TextGroupByConfigRequest | NumberGroupByConfigRequest | CheckboxGroupByConfigRequest | FormulaGroupByConfigRequest;
359
+ export type GroupFilterOperatorArray = Array<PropertyOrTimestampFilter | {
360
+ or: PropertyOrTimestampFilterArray;
361
+ } | {
362
+ and: PropertyOrTimestampFilterArray;
363
+ }>;
364
+ export type GroupObjectRequest = {
365
+ id: IdRequest;
366
+ name?: string | null;
367
+ object?: "group";
368
+ };
369
+ export type GroupObjectResponse = {
370
+ id: IdResponse;
371
+ object: "group";
372
+ name: string | null;
373
+ };
374
+ type GroupSortRequest = {
375
+ type: "manual" | "ascending" | "descending";
376
+ };
377
+ type IconPageIconResponse = {
378
+ type: "icon";
379
+ icon: NoticonIconResponse;
380
+ };
381
+ export type IdRequest = string;
382
+ export type IdResponse = string;
383
+ export type InitialDataSourceRequest = {
384
+ properties?: Record<string, PropertyConfigurationRequest>;
385
+ };
386
+ type InternalFileRequest = {
387
+ url: string;
388
+ expiry_time?: string;
389
+ };
390
+ export type InternalFileResponse = {
391
+ url: string;
392
+ expiry_time: string;
393
+ };
394
+ export type InternalOrExternalFileWithNameRequest = {
395
+ file: InternalFileRequest;
396
+ name: StringRequest;
397
+ type?: "file";
398
+ } | {
399
+ external: ExternalFileRequest;
400
+ name: StringRequest;
401
+ type?: "external";
402
+ };
403
+ type LastEditedByPropertyConfigurationRequest = {
404
+ type?: "last_edited_by";
405
+ last_edited_by: EmptyObject;
406
+ };
407
+ type LastEditedTimePropertyConfigurationRequest = {
408
+ type?: "last_edited_time";
409
+ last_edited_time: EmptyObject;
410
+ };
411
+ type LastVisitedTimePropertyConfigurationRequest = {
412
+ type?: "last_visited_time";
413
+ last_visited_time: EmptyObject;
414
+ };
415
+ type LinkMentionResponse = {
416
+ href: string;
417
+ title?: string;
418
+ description?: string;
419
+ link_author?: string;
420
+ link_provider?: string;
421
+ thumbnail_url?: string;
422
+ icon_url?: string;
423
+ iframe_url?: string;
424
+ height?: number;
425
+ padding?: number;
426
+ padding_top?: number;
427
+ };
428
+ type LinkPreviewMentionResponse = {
429
+ url: string;
430
+ };
431
+ type ListViewConfigRequest = {
432
+ type: "list";
433
+ properties?: Array<ViewPropertyConfigRequest> | null;
434
+ };
435
+ type LocationPropertyConfigurationRequest = {
436
+ type?: "location";
437
+ location: EmptyObject;
438
+ };
439
+ type MapViewConfigRequest = {
440
+ type: "map";
441
+ height?: "small" | "medium" | "large" | "extra_large" | null;
442
+ map_by?: string | null;
443
+ properties?: Array<ViewPropertyConfigRequest> | null;
444
+ };
445
+ export type MentionRichTextItemResponse = {
446
+ type: "mention";
447
+ mention: {
448
+ type: "user";
449
+ user: UserValueResponse;
450
+ } | {
451
+ type: "date";
452
+ date: DateResponse;
453
+ } | {
454
+ type: "link_preview";
455
+ link_preview: LinkPreviewMentionResponse;
456
+ } | {
457
+ type: "link_mention";
458
+ link_mention: LinkMentionResponse;
459
+ } | {
460
+ type: "page";
461
+ page: {
462
+ id: IdResponse;
463
+ };
464
+ } | {
465
+ type: "database";
466
+ database: {
467
+ id: IdResponse;
468
+ };
469
+ } | {
470
+ type: "template_mention";
471
+ template_mention: TemplateMentionResponse;
472
+ } | {
473
+ type: "custom_emoji";
474
+ custom_emoji: CustomEmojiResponse;
475
+ };
476
+ };
477
+ type MultiSelectPropertyConfigurationRequest = {
478
+ type?: "multi_select";
479
+ multi_select: {
480
+ options?: Array<{
481
+ name: string;
482
+ color?: SelectColor;
483
+ description?: string | null;
484
+ }>;
485
+ };
486
+ };
487
+ type MultiSelectPropertyFilter = {
488
+ contains: string;
489
+ } | {
490
+ does_not_contain: string;
491
+ } | ExistencePropertyFilter;
492
+ /**
493
+ * One of: `gray`, `lightgray`, `brown`, `yellow`, `orange`, `green`, `blue`, `purple`,
494
+ * `pink`, `red`
495
+ */
496
+ type NoticonColor = "gray" | "lightgray" | "brown" | "yellow" | "orange" | "green" | "blue" | "purple" | "pink" | "red";
497
+ type NoticonIconResponse = {
498
+ name: NoticonName;
499
+ color: NoticonColor;
500
+ };
501
+ type NoticonName = string;
502
+ type NumberGroupByConfigRequest = {
503
+ type: "number";
504
+ property_id: string;
505
+ sort: GroupSortRequest;
506
+ hide_empty_groups?: boolean;
507
+ range_start?: number;
508
+ range_end?: number;
509
+ range_size?: number;
510
+ };
511
+ type NumberPropertyConfigurationRequest = {
512
+ type?: "number";
513
+ number: {
514
+ format?: NumberFormat;
515
+ };
516
+ };
517
+ type NumberPropertyFilter = {
518
+ equals: number;
519
+ } | {
520
+ does_not_equal: number;
521
+ } | {
522
+ greater_than: number;
523
+ } | {
524
+ less_than: number;
525
+ } | {
526
+ greater_than_or_equal_to: number;
527
+ } | {
528
+ less_than_or_equal_to: number;
529
+ } | ExistencePropertyFilter;
530
+ export type PageCoverRequest = FileUploadPageCoverRequest | ExternalPageCoverRequest;
531
+ export type PageCoverResponse = FilePageCoverResponse | ExternalPageCoverResponse;
532
+ export type PageIconResponse = EmojiPageIconResponse | FilePageIconResponse | ExternalPageIconResponse | CustomEmojiPageIconResponse | IconPageIconResponse;
533
+ type PageIdParentForBlockBasedObjectResponse = {
534
+ type: "page_id";
535
+ page_id: IdResponse;
536
+ };
537
+ export type PageMarkdownResponse = {
538
+ object: "page_markdown";
539
+ id: IdResponse;
540
+ markdown: string;
541
+ truncated: boolean;
542
+ unknown_block_ids: Array<IdResponse>;
543
+ };
544
+ export type PagePositionSchema = {
545
+ type: "after_block";
546
+ after_block: {
547
+ id: IdRequest;
548
+ };
549
+ } | {
550
+ type: "page_start";
551
+ } | {
552
+ type: "page_end";
553
+ };
554
+ export type ParentForBlockBasedObjectResponse = DatabaseParentResponse | DataSourceParentResponse | PageIdParentForBlockBasedObjectResponse | BlockIdParentForBlockBasedObjectResponse | WorkspaceParentForBlockBasedObjectResponse;
555
+ export type ParentOfDataSourceRequest = {
556
+ type?: "database_id";
557
+ database_id: IdRequest;
558
+ };
559
+ export type ParentOfDatabaseResponse = PageIdParentForBlockBasedObjectResponse | WorkspaceParentForBlockBasedObjectResponse | DatabaseParentResponse | BlockIdParentForBlockBasedObjectResponse;
560
+ export type PartialUserObjectResponse = {
561
+ id: IdResponse;
562
+ object: "user";
563
+ };
564
+ type PeoplePropertyConfigurationRequest = {
565
+ type?: "people";
566
+ people: EmptyObject;
567
+ };
568
+ type PeoplePropertyFilter = {
569
+ contains: IdRequest;
570
+ } | {
571
+ does_not_contain: IdRequest;
572
+ } | ExistencePropertyFilter;
573
+ type PersonGroupByConfigRequest = {
574
+ type: "person" | "created_by" | "last_edited_by";
575
+ property_id: string;
576
+ sort: GroupSortRequest;
577
+ hide_empty_groups?: boolean;
578
+ };
579
+ export type PersonUserObjectResponse = {
580
+ type: "person";
581
+ person: {
582
+ email?: string;
583
+ };
584
+ };
585
+ type PhoneNumberPropertyConfigurationRequest = {
586
+ type?: "phone_number";
587
+ phone_number: EmptyObject;
588
+ };
589
+ type PlacePropertyConfigurationRequest = {
590
+ type?: "place";
591
+ place: EmptyObject;
592
+ };
593
+ export type PropertyConfigurationRequest = PropertyConfigurationRequestCommon & (NumberPropertyConfigurationRequest | FormulaPropertyConfigurationRequest | SelectPropertyConfigurationRequest | MultiSelectPropertyConfigurationRequest | StatusPropertyConfigurationRequest | RelationPropertyConfigurationRequest | RollupPropertyConfigurationRequest | UniqueIdPropertyConfigurationRequest | TitlePropertyConfigurationRequest | RichTextPropertyConfigurationRequest | UrlPropertyConfigurationRequest | PeoplePropertyConfigurationRequest | FilesPropertyConfigurationRequest | EmailPropertyConfigurationRequest | PhoneNumberPropertyConfigurationRequest | DatePropertyConfigurationRequest | CheckboxPropertyConfigurationRequest | CreatedByPropertyConfigurationRequest | CreatedTimePropertyConfigurationRequest | LastEditedByPropertyConfigurationRequest | LastEditedTimePropertyConfigurationRequest | ButtonPropertyConfigurationRequest | LocationPropertyConfigurationRequest | VerificationPropertyConfigurationRequest | LastVisitedTimePropertyConfigurationRequest | PlacePropertyConfigurationRequest);
594
+ type PropertyConfigurationRequestCommon = {
595
+ description?: PropertyDescriptionRequest | null;
596
+ };
597
+ export type PropertyFilter = {
598
+ title: TextPropertyFilter;
599
+ property: string;
600
+ type?: "title";
601
+ } | {
602
+ rich_text: TextPropertyFilter;
603
+ property: string;
604
+ type?: "rich_text";
605
+ } | {
606
+ number: NumberPropertyFilter;
607
+ property: string;
608
+ type?: "number";
609
+ } | {
610
+ checkbox: CheckboxPropertyFilter;
611
+ property: string;
612
+ type?: "checkbox";
613
+ } | {
614
+ select: SelectPropertyFilter;
615
+ property: string;
616
+ type?: "select";
617
+ } | {
618
+ multi_select: MultiSelectPropertyFilter;
619
+ property: string;
620
+ type?: "multi_select";
621
+ } | {
622
+ status: StatusPropertyFilter;
623
+ property: string;
624
+ type?: "status";
625
+ } | {
626
+ date: DatePropertyFilter;
627
+ property: string;
628
+ type?: "date";
629
+ } | {
630
+ people: PeoplePropertyFilter;
631
+ property: string;
632
+ type?: "people";
633
+ } | {
634
+ files: ExistencePropertyFilter;
635
+ property: string;
636
+ type?: "files";
637
+ } | {
638
+ url: TextPropertyFilter;
639
+ property: string;
640
+ type?: "url";
641
+ } | {
642
+ email: TextPropertyFilter;
643
+ property: string;
644
+ type?: "email";
645
+ } | {
646
+ phone_number: TextPropertyFilter;
647
+ property: string;
648
+ type?: "phone_number";
649
+ } | {
650
+ relation: RelationPropertyFilter;
651
+ property: string;
652
+ type?: "relation";
653
+ } | {
654
+ created_by: PeoplePropertyFilter;
655
+ property: string;
656
+ type?: "created_by";
657
+ } | {
658
+ created_time: DatePropertyFilter;
659
+ property: string;
660
+ type?: "created_time";
661
+ } | {
662
+ last_edited_by: PeoplePropertyFilter;
663
+ property: string;
664
+ type?: "last_edited_by";
665
+ } | {
666
+ last_edited_time: DatePropertyFilter;
667
+ property: string;
668
+ type?: "last_edited_time";
669
+ } | {
670
+ formula: FormulaPropertyFilter;
671
+ property: string;
672
+ type?: "formula";
673
+ } | {
674
+ unique_id: NumberPropertyFilter;
675
+ property: string;
676
+ type?: "unique_id";
677
+ } | {
678
+ rollup: RollupPropertyFilter;
679
+ property: string;
680
+ type?: "rollup";
681
+ } | {
682
+ verification: VerificationPropertyStatusFilter;
683
+ property: string;
684
+ type?: "verification";
685
+ };
686
+ type PropertyOrTimestampFilter = PropertyFilter | TimestampFilter;
687
+ type PropertyOrTimestampFilterArray = Array<PropertyOrTimestampFilter>;
688
+ /**
689
+ * A property filter condition. Same shape as a property filter but without the
690
+ * "property" field (the hashmap key identifies the property). For example: { "select": {
691
+ * "equals": "High" } }.
692
+ */
693
+ type QuickFilterConditionRequest = Record<string, never>;
694
+ type RelationGroupByConfigRequest = {
695
+ type: "relation";
696
+ property_id: string;
697
+ sort: GroupSortRequest;
698
+ hide_empty_groups?: boolean;
699
+ };
700
+ type RelationPropertyConfigurationRequest = {
701
+ type?: "relation";
702
+ relation: {
703
+ data_source_id: IdRequest;
704
+ } & ({
705
+ type?: "single_property";
706
+ single_property: EmptyObject;
707
+ } | {
708
+ type?: "dual_property";
709
+ dual_property: {
710
+ synced_property_id?: string;
711
+ synced_property_name?: string;
712
+ };
713
+ });
714
+ };
715
+ type RelationPropertyFilter = {
716
+ contains: IdRequest;
717
+ } | {
718
+ does_not_contain: IdRequest;
719
+ } | ExistencePropertyFilter;
720
+ export type RichTextItemResponse = RichTextItemResponseCommon & (TextRichTextItemResponse | MentionRichTextItemResponse | EquationRichTextItemResponse);
721
+ export type RichTextItemResponseCommon = {
722
+ plain_text: string;
723
+ href: string | null;
724
+ annotations: AnnotationResponse;
725
+ };
726
+ type RichTextPropertyConfigurationRequest = {
727
+ type?: "rich_text";
728
+ rich_text: EmptyObject;
729
+ };
730
+ export type RollupFunction = "count" | "count_values" | "empty" | "not_empty" | "unique" | "show_unique" | "percent_empty" | "percent_not_empty" | "sum" | "average" | "median" | "min" | "max" | "range" | "earliest_date" | "latest_date" | "date_range" | "checked" | "unchecked" | "percent_checked" | "percent_unchecked" | "count_per_group" | "percent_per_group" | "show_original";
731
+ type RollupPropertyConfigurationRequest = {
732
+ type?: "rollup";
733
+ rollup: {
734
+ function: RollupFunction;
735
+ } & ({
736
+ relation_property_name: string;
737
+ rollup_property_name: string;
738
+ } | {
739
+ relation_property_id: string;
740
+ rollup_property_name: string;
741
+ } | {
742
+ relation_property_name: string;
743
+ rollup_property_id: string;
744
+ } | {
745
+ relation_property_id: string;
746
+ rollup_property_id: string;
747
+ });
748
+ };
749
+ type RollupPropertyFilter = {
750
+ any: RollupSubfilterPropertyFilter;
751
+ } | {
752
+ none: RollupSubfilterPropertyFilter;
753
+ } | {
754
+ every: RollupSubfilterPropertyFilter;
755
+ } | {
756
+ date: DatePropertyFilter;
757
+ } | {
758
+ number: NumberPropertyFilter;
759
+ };
760
+ type RollupSubfilterPropertyFilter = {
761
+ rich_text: TextPropertyFilter;
762
+ } | {
763
+ number: NumberPropertyFilter;
764
+ } | {
765
+ checkbox: CheckboxPropertyFilter;
766
+ } | {
767
+ select: SelectPropertyFilter;
768
+ } | {
769
+ multi_select: MultiSelectPropertyFilter;
770
+ } | {
771
+ relation: RelationPropertyFilter;
772
+ } | {
773
+ date: DatePropertyFilter;
774
+ } | {
775
+ people: PeoplePropertyFilter;
776
+ } | {
777
+ files: ExistencePropertyFilter;
778
+ } | {
779
+ status: StatusPropertyFilter;
780
+ };
781
+ /**
782
+ * One of: `default`, `gray`, `brown`, `orange`, `yellow`, `green`, `blue`, `purple`,
783
+ * `pink`, `red`
784
+ */
785
+ export type SelectColor = "default" | "gray" | "brown" | "orange" | "yellow" | "green" | "blue" | "purple" | "pink" | "red";
786
+ type SelectGroupByConfigRequest = {
787
+ type: "select" | "multi_select";
788
+ property_id: string;
789
+ sort: GroupSortRequest;
790
+ hide_empty_groups?: boolean;
791
+ };
792
+ type SelectPropertyConfigurationRequest = {
793
+ type?: "select";
794
+ select: {
795
+ options?: Array<{
796
+ name: string;
797
+ color?: SelectColor;
798
+ description?: string | null;
799
+ }>;
800
+ };
801
+ };
802
+ type SelectPropertyFilter = {
803
+ equals: string;
804
+ } | {
805
+ does_not_equal: string;
806
+ } | ExistencePropertyFilter;
807
+ /**
808
+ * One of: `ascending`, `descending`
809
+ */
810
+ type SortDirectionRequest = "ascending" | "descending";
811
+ type StatusGroupByConfigRequest = {
812
+ type: "status";
813
+ property_id: string;
814
+ group_by: "group" | "option";
815
+ sort: GroupSortRequest;
816
+ hide_empty_groups?: boolean;
817
+ };
818
+ type StatusPropertyConfigRequest = {
819
+ options?: Array<{
820
+ name: string;
821
+ color?: SelectColor;
822
+ description?: string | null;
823
+ }>;
824
+ };
825
+ export type StatusPropertyConfigUpdateRequest = {
826
+ options?: Array<{
827
+ color?: SelectColor;
828
+ description?: string | null;
829
+ } & ({
830
+ name: string;
831
+ id?: string;
832
+ } | {
833
+ id: string;
834
+ name?: string;
835
+ })>;
836
+ };
837
+ type StatusPropertyConfigurationRequest = {
838
+ type?: "status";
839
+ status: StatusPropertyConfigRequest;
840
+ };
841
+ type StatusPropertyFilter = {
842
+ equals: string;
843
+ } | {
844
+ does_not_equal: string;
845
+ } | ExistencePropertyFilter;
846
+ type SubtaskConfigRequest = {
847
+ property_id?: string;
848
+ display_mode?: "show" | "hidden" | "flattened" | "disabled";
849
+ filter_scope?: "parents" | "parents_and_subitems" | "subitems";
850
+ toggle_column_id?: string;
851
+ };
852
+ type TableViewConfigRequest = {
853
+ type: "table";
854
+ properties?: Array<ViewPropertyConfigRequest> | null;
855
+ group_by?: GroupByConfigRequest | null;
856
+ subtasks?: SubtaskConfigRequest | null;
857
+ wrap_cells?: boolean;
858
+ frozen_column_index?: number;
859
+ show_vertical_lines?: boolean;
860
+ };
861
+ type TemplateMentionDateTemplateMentionResponse = {
862
+ type: "template_mention_date";
863
+ template_mention_date: "today" | "now";
864
+ };
865
+ type TemplateMentionResponse = TemplateMentionDateTemplateMentionResponse | TemplateMentionUserTemplateMentionResponse;
866
+ type TemplateMentionUserTemplateMentionResponse = {
867
+ type: "template_mention_user";
868
+ template_mention_user: "me";
869
+ };
870
+ /**
871
+ * IANA timezone to use when resolving template variables like @now and @today (e.g.
872
+ * 'America/New_York'). Defaults to the authorizing user's timezone for public
873
+ * integrations, or UTC for internal integrations.
874
+ */
875
+ export type TemplateTimezone = string;
876
+ type TextGroupByConfigRequest = {
877
+ type: "text" | "title" | "url" | "email" | "phone_number";
878
+ property_id: string;
879
+ group_by: "exact" | "alphabet_prefix";
880
+ sort: GroupSortRequest;
881
+ hide_empty_groups?: boolean;
882
+ };
883
+ type TextPropertyFilter = {
884
+ equals: string;
885
+ } | {
886
+ does_not_equal: string;
887
+ } | {
888
+ contains: string;
889
+ } | {
890
+ does_not_contain: string;
891
+ } | {
892
+ starts_with: string;
893
+ } | {
894
+ ends_with: string;
895
+ } | ExistencePropertyFilter;
896
+ export type TextRichTextItemResponse = {
897
+ type: "text";
898
+ text: {
899
+ content: string;
900
+ link: {
901
+ url: string;
902
+ } | null;
903
+ };
904
+ };
905
+ type TimeZoneRequest = string;
906
+ type TimelineArrowsByRequest = {
907
+ property_id?: string | null;
908
+ };
909
+ type TimelinePreferenceRequest = {
910
+ zoom_level: "hours" | "day" | "week" | "bi_week" | "month" | "quarter" | "year" | "5_years";
911
+ center_timestamp?: number;
912
+ };
913
+ type TimelineViewConfigRequest = {
914
+ type: "timeline";
915
+ date_property_id: string;
916
+ end_date_property_id?: string | null;
917
+ properties?: Array<ViewPropertyConfigRequest> | null;
918
+ show_table?: boolean | null;
919
+ table_properties?: Array<ViewPropertyConfigRequest> | null;
920
+ preference?: TimelinePreferenceRequest | null;
921
+ arrows_by?: TimelineArrowsByRequest | null;
922
+ color_by?: boolean | null;
923
+ };
924
+ type TimestampCreatedTimeFilter = {
925
+ created_time: DatePropertyFilter;
926
+ timestamp: "created_time";
927
+ type?: "created_time";
928
+ };
929
+ export type TimestampFilter = TimestampCreatedTimeFilter | TimestampLastEditedTimeFilter;
930
+ type TimestampLastEditedTimeFilter = {
931
+ last_edited_time: DatePropertyFilter;
932
+ timestamp: "last_edited_time";
933
+ type?: "last_edited_time";
934
+ };
935
+ type TitlePropertyConfigurationRequest = {
936
+ type?: "title";
937
+ title: EmptyObject;
938
+ };
939
+ type UniqueIdPropertyConfigurationRequest = {
940
+ type?: "unique_id";
941
+ unique_id: {
942
+ prefix?: string | null;
943
+ };
944
+ };
945
+ export type UpdateMediaContentWithFileAndCaptionRequest = {
946
+ caption?: Array<RichTextItemRequest>;
947
+ external?: ExternalFileRequest;
948
+ file_upload?: FileUploadIdRequest;
949
+ };
950
+ export type UpdateMediaContentWithFileNameAndCaptionRequest = {
951
+ caption?: Array<RichTextItemRequest>;
952
+ external?: ExternalFileRequest;
953
+ file_upload?: FileUploadIdRequest;
954
+ name?: StringRequest;
955
+ };
956
+ export type UpdateMediaContentWithUrlAndCaptionRequest = {
957
+ url?: string;
958
+ caption?: Array<RichTextItemRequest>;
959
+ };
960
+ export type UpdateViewRequest = {
961
+ name?: string;
962
+ filter?: ViewFilterRequest | null;
963
+ sorts?: ViewPropertySortsRequest | null;
964
+ quick_filters?: Record<string, QuickFilterConditionRequest | null> | null;
965
+ configuration?: ViewConfigRequest;
966
+ };
967
+ type UrlPropertyConfigurationRequest = {
968
+ type?: "url";
969
+ url: EmptyObject;
970
+ };
971
+ export type UserObjectResponse = UserObjectResponseCommon & (PersonUserObjectResponse | BotUserObjectResponse);
972
+ export type UserObjectResponseCommon = {
973
+ id: IdResponse;
974
+ object: "user";
975
+ name: string | null;
976
+ avatar_url: string | null;
977
+ };
978
+ type UserValueResponse = PartialUserObjectResponse | UserObjectResponse;
979
+ type VerificationPropertyConfigurationRequest = {
980
+ type?: "verification";
981
+ verification: EmptyObject;
982
+ };
983
+ type VerificationPropertyStatusFilter = {
984
+ status: "verified" | "expired" | "none";
985
+ };
986
+ /**
987
+ * View configuration, discriminated by the type field.
988
+ */
989
+ type ViewConfigRequest = TableViewConfigRequest | BoardViewConfigRequest | CalendarViewConfigRequest | TimelineViewConfigRequest | GalleryViewConfigRequest | ListViewConfigRequest | MapViewConfigRequest | FormViewConfigRequest | ChartViewConfigRequest;
990
+ /**
991
+ * Filter for the view. Uses the same format as the data source query filter (property
992
+ * filters, timestamp filters, or compound and/or filters). Simple property filters appear
993
+ * in the view's filter bar in the Notion UI. To filter by multiple values on a select or
994
+ * status property, use a compound "or" filter with separate "equals" conditions for each
995
+ * value.
996
+ */
997
+ type ViewFilterRequest = Record<string, never>;
998
+ /**
999
+ * Position of the new view in the database's view tab bar.
1000
+ */
1001
+ type ViewPositionRequest = {
1002
+ type: "start";
1003
+ } | {
1004
+ type: "end";
1005
+ } | {
1006
+ type: "after_view";
1007
+ view_id: IdRequest;
1008
+ };
1009
+ type ViewPropertyConfigRequest = {
1010
+ property_id: string;
1011
+ visible?: boolean;
1012
+ width?: number;
1013
+ wrap?: boolean;
1014
+ status_show_as?: "select" | "checkbox";
1015
+ card_property_width_mode?: "full_line" | "inline";
1016
+ date_format?: "full" | "short" | "month_day_year" | "day_month_year" | "year_month_day" | "relative";
1017
+ time_format?: "12_hour" | "24_hour" | "hidden";
1018
+ };
1019
+ type ViewPropertySortRequest = {
1020
+ property: string;
1021
+ direction: SortDirectionRequest;
1022
+ };
1023
+ type ViewPropertySortsRequest = Array<ViewPropertySortRequest>;
1024
+ /**
1025
+ * Sort for the view. Can be a property sort (with property and direction) or timestamp
1026
+ * sort (with timestamp and direction).
1027
+ */
1028
+ type ViewSortRequest = Record<string, never>;
1029
+ type ViewSortsRequest = Array<ViewSortRequest>;
1030
+ /**
1031
+ * One of: `table`, `board`, `list`, `calendar`, `timeline`, `gallery`, `form`, `chart`,
1032
+ * `map`, `dashboard`
1033
+ */
1034
+ type ViewTypeRequest = "table" | "board" | "list" | "calendar" | "timeline" | "gallery" | "form" | "chart" | "map" | "dashboard";
1035
+ /**
1036
+ * Where to place the new widget in the dashboard. "new_row" creates a new row,
1037
+ * "existing_row" adds to an existing row side-by-side with other widgets.
1038
+ */
1039
+ type WidgetPlacementRequest = {
1040
+ type: "new_row";
1041
+ row_index?: number;
1042
+ } | {
1043
+ type: "existing_row";
1044
+ row_index: number;
1045
+ };
1046
+ type WorkspaceParentForBlockBasedObjectResponse = {
1047
+ type: "workspace";
1048
+ workspace: true;
1049
+ };
1050
+ export type BlockObjectRequest = {
1051
+ embed: MediaContentWithUrlAndCaptionRequest;
1052
+ type?: "embed";
1053
+ object?: "block";
1054
+ } | {
1055
+ bookmark: MediaContentWithUrlAndCaptionRequest;
1056
+ type?: "bookmark";
1057
+ object?: "block";
1058
+ } | {
1059
+ image: MediaContentWithFileAndCaptionRequest;
1060
+ type?: "image";
1061
+ object?: "block";
1062
+ } | {
1063
+ video: MediaContentWithFileAndCaptionRequest;
1064
+ type?: "video";
1065
+ object?: "block";
1066
+ } | {
1067
+ pdf: MediaContentWithFileAndCaptionRequest;
1068
+ type?: "pdf";
1069
+ object?: "block";
1070
+ } | {
1071
+ file: MediaContentWithFileNameAndCaptionRequest;
1072
+ type?: "file";
1073
+ object?: "block";
1074
+ } | {
1075
+ audio: MediaContentWithFileAndCaptionRequest;
1076
+ type?: "audio";
1077
+ object?: "block";
1078
+ } | {
1079
+ code: {
1080
+ rich_text: Array<RichTextItemRequest>;
1081
+ language: LanguageRequest;
1082
+ caption?: Array<RichTextItemRequest>;
1083
+ };
1084
+ type?: "code";
1085
+ object?: "block";
1086
+ } | {
1087
+ equation: ContentWithExpressionRequest;
1088
+ type?: "equation";
1089
+ object?: "block";
1090
+ } | {
1091
+ divider: EmptyObject;
1092
+ type?: "divider";
1093
+ object?: "block";
1094
+ } | {
1095
+ breadcrumb: EmptyObject;
1096
+ type?: "breadcrumb";
1097
+ object?: "block";
1098
+ } | {
1099
+ tab: TabRequestWithNestedTabItemChildren;
1100
+ type?: "tab";
1101
+ object?: "block";
1102
+ } | {
1103
+ table_of_contents: {
1104
+ color?: ApiColor;
1105
+ };
1106
+ type?: "table_of_contents";
1107
+ object?: "block";
1108
+ } | {
1109
+ link_to_page: {
1110
+ page_id: IdRequest;
1111
+ type?: "page_id";
1112
+ } | {
1113
+ database_id: IdRequest;
1114
+ type?: "database_id";
1115
+ } | {
1116
+ comment_id: IdRequest;
1117
+ type?: "comment_id";
1118
+ };
1119
+ type?: "link_to_page";
1120
+ object?: "block";
1121
+ } | {
1122
+ table_row: ContentWithTableRowRequest;
1123
+ type?: "table_row";
1124
+ object?: "block";
1125
+ } | {
1126
+ table: TableRequestWithTableRowChildren;
1127
+ type?: "table";
1128
+ object?: "block";
1129
+ } | {
1130
+ column_list: ColumnListRequest;
1131
+ type?: "column_list";
1132
+ object?: "block";
1133
+ } | {
1134
+ column: ColumnWithChildrenRequest;
1135
+ type?: "column";
1136
+ object?: "block";
1137
+ } | {
1138
+ heading_1: {
1139
+ rich_text: Array<RichTextItemRequest>;
1140
+ color?: ApiColor;
1141
+ is_toggleable?: boolean;
1142
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1143
+ };
1144
+ type?: "heading_1";
1145
+ object?: "block";
1146
+ } | {
1147
+ heading_2: {
1148
+ rich_text: Array<RichTextItemRequest>;
1149
+ color?: ApiColor;
1150
+ is_toggleable?: boolean;
1151
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1152
+ };
1153
+ type?: "heading_2";
1154
+ object?: "block";
1155
+ } | {
1156
+ heading_3: {
1157
+ rich_text: Array<RichTextItemRequest>;
1158
+ color?: ApiColor;
1159
+ is_toggleable?: boolean;
1160
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1161
+ };
1162
+ type?: "heading_3";
1163
+ object?: "block";
1164
+ } | {
1165
+ paragraph: {
1166
+ rich_text: Array<RichTextItemRequest>;
1167
+ color?: ApiColor;
1168
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1169
+ };
1170
+ type?: "paragraph";
1171
+ object?: "block";
1172
+ } | {
1173
+ bulleted_list_item: {
1174
+ rich_text: Array<RichTextItemRequest>;
1175
+ color?: ApiColor;
1176
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1177
+ };
1178
+ type?: "bulleted_list_item";
1179
+ object?: "block";
1180
+ } | {
1181
+ numbered_list_item: {
1182
+ rich_text: Array<RichTextItemRequest>;
1183
+ color?: ApiColor;
1184
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1185
+ };
1186
+ type?: "numbered_list_item";
1187
+ object?: "block";
1188
+ } | {
1189
+ quote: {
1190
+ rich_text: Array<RichTextItemRequest>;
1191
+ color?: ApiColor;
1192
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1193
+ };
1194
+ type?: "quote";
1195
+ object?: "block";
1196
+ } | {
1197
+ to_do: {
1198
+ rich_text: Array<RichTextItemRequest>;
1199
+ color?: ApiColor;
1200
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1201
+ checked?: boolean;
1202
+ };
1203
+ type?: "to_do";
1204
+ object?: "block";
1205
+ } | {
1206
+ toggle: {
1207
+ rich_text: Array<RichTextItemRequest>;
1208
+ color?: ApiColor;
1209
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1210
+ };
1211
+ type?: "toggle";
1212
+ object?: "block";
1213
+ } | {
1214
+ template: {
1215
+ rich_text: Array<RichTextItemRequest>;
1216
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1217
+ };
1218
+ type?: "template";
1219
+ object?: "block";
1220
+ } | {
1221
+ callout: {
1222
+ rich_text: Array<RichTextItemRequest>;
1223
+ color?: ApiColor;
1224
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1225
+ icon?: PageIconRequest;
1226
+ };
1227
+ type?: "callout";
1228
+ object?: "block";
1229
+ } | {
1230
+ synced_block: {
1231
+ synced_from: {
1232
+ block_id: IdRequest;
1233
+ type?: "block_id";
1234
+ } | null;
1235
+ children?: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1236
+ };
1237
+ type?: "synced_block";
1238
+ object?: "block";
1239
+ };
1240
+ export type DateRequest = {
1241
+ start: string;
1242
+ end?: string | null;
1243
+ time_zone?: TimeZoneRequest | null;
1244
+ };
1245
+ export type PageIconRequest = FileUploadPageIconRequest | EmojiPageIconRequest | ExternalPageIconRequest | CustomEmojiPageIconRequest | IconPageIconRequest;
1246
+ export type PartialUserObjectRequest = {
1247
+ id: IdRequest;
1248
+ object?: "user";
1249
+ };
1250
+ export type RichTextItemRequest = RichTextItemRequestCommon & (TextRichTextItemRequest | MentionRichTextItemRequest | EquationRichTextItemRequest);
1251
+ export type StringRequest = string;
1252
+ export type TextRequest = string;
1253
+ export type PartialPageObjectResponse = {
1254
+ object: "page";
1255
+ id: IdResponse;
1256
+ };
1257
+ export type PageObjectResponse = {
1258
+ object: "page";
1259
+ id: IdResponse;
1260
+ created_time: string;
1261
+ last_edited_time: string;
1262
+ in_trash: boolean;
1263
+ /** @deprecated Use `in_trash` instead. Present for backwards compatibility with API versions prior to 2026-03-11. */
1264
+ archived: boolean;
1265
+ is_archived: boolean;
1266
+ is_locked: boolean;
1267
+ url: string;
1268
+ public_url: string | null;
1269
+ parent: ParentForBlockBasedObjectResponse;
1270
+ properties: Record<string, PagePropertyValueWithIdResponse>;
1271
+ icon: PageIconResponse | null;
1272
+ cover: PageCoverResponse | null;
1273
+ created_by: PartialUserObjectResponse;
1274
+ last_edited_by: PartialUserObjectResponse;
1275
+ };
1276
+ type BlockObjectWithSingleLevelOfChildrenRequest = {
1277
+ embed: MediaContentWithUrlAndCaptionRequest;
1278
+ type?: "embed";
1279
+ object?: "block";
1280
+ } | {
1281
+ bookmark: MediaContentWithUrlAndCaptionRequest;
1282
+ type?: "bookmark";
1283
+ object?: "block";
1284
+ } | {
1285
+ image: MediaContentWithFileAndCaptionRequest;
1286
+ type?: "image";
1287
+ object?: "block";
1288
+ } | {
1289
+ video: MediaContentWithFileAndCaptionRequest;
1290
+ type?: "video";
1291
+ object?: "block";
1292
+ } | {
1293
+ pdf: MediaContentWithFileAndCaptionRequest;
1294
+ type?: "pdf";
1295
+ object?: "block";
1296
+ } | {
1297
+ file: MediaContentWithFileNameAndCaptionRequest;
1298
+ type?: "file";
1299
+ object?: "block";
1300
+ } | {
1301
+ audio: MediaContentWithFileAndCaptionRequest;
1302
+ type?: "audio";
1303
+ object?: "block";
1304
+ } | {
1305
+ code: {
1306
+ rich_text: Array<RichTextItemRequest>;
1307
+ language: LanguageRequest;
1308
+ caption?: Array<RichTextItemRequest>;
1309
+ };
1310
+ type?: "code";
1311
+ object?: "block";
1312
+ } | {
1313
+ equation: ContentWithExpressionRequest;
1314
+ type?: "equation";
1315
+ object?: "block";
1316
+ } | {
1317
+ divider: EmptyObject;
1318
+ type?: "divider";
1319
+ object?: "block";
1320
+ } | {
1321
+ breadcrumb: EmptyObject;
1322
+ type?: "breadcrumb";
1323
+ object?: "block";
1324
+ } | {
1325
+ tab: TabRequestWithTabItemChildren;
1326
+ type?: "tab";
1327
+ object?: "block";
1328
+ } | {
1329
+ table_of_contents: {
1330
+ color?: ApiColor;
1331
+ };
1332
+ type?: "table_of_contents";
1333
+ object?: "block";
1334
+ } | {
1335
+ link_to_page: {
1336
+ page_id: IdRequest;
1337
+ type?: "page_id";
1338
+ } | {
1339
+ database_id: IdRequest;
1340
+ type?: "database_id";
1341
+ } | {
1342
+ comment_id: IdRequest;
1343
+ type?: "comment_id";
1344
+ };
1345
+ type?: "link_to_page";
1346
+ object?: "block";
1347
+ } | {
1348
+ table_row: ContentWithTableRowRequest;
1349
+ type?: "table_row";
1350
+ object?: "block";
1351
+ } | {
1352
+ heading_1: HeaderContentWithSingleLevelOfChildrenRequest;
1353
+ type?: "heading_1";
1354
+ object?: "block";
1355
+ } | {
1356
+ heading_2: HeaderContentWithSingleLevelOfChildrenRequest;
1357
+ type?: "heading_2";
1358
+ object?: "block";
1359
+ } | {
1360
+ heading_3: HeaderContentWithSingleLevelOfChildrenRequest;
1361
+ type?: "heading_3";
1362
+ object?: "block";
1363
+ } | {
1364
+ paragraph: ContentWithSingleLevelOfChildrenRequest;
1365
+ type?: "paragraph";
1366
+ object?: "block";
1367
+ } | {
1368
+ bulleted_list_item: ContentWithSingleLevelOfChildrenRequest;
1369
+ type?: "bulleted_list_item";
1370
+ object?: "block";
1371
+ } | {
1372
+ numbered_list_item: ContentWithSingleLevelOfChildrenRequest;
1373
+ type?: "numbered_list_item";
1374
+ object?: "block";
1375
+ } | {
1376
+ quote: ContentWithSingleLevelOfChildrenRequest;
1377
+ type?: "quote";
1378
+ object?: "block";
1379
+ } | {
1380
+ table: TableRequestWithTableRowChildren;
1381
+ type?: "table";
1382
+ object?: "block";
1383
+ } | {
1384
+ to_do: {
1385
+ rich_text: Array<RichTextItemRequest>;
1386
+ color?: ApiColor;
1387
+ children?: Array<BlockObjectRequestWithoutChildren>;
1388
+ checked?: boolean;
1389
+ };
1390
+ type?: "to_do";
1391
+ object?: "block";
1392
+ } | {
1393
+ toggle: ContentWithSingleLevelOfChildrenRequest;
1394
+ type?: "toggle";
1395
+ object?: "block";
1396
+ } | {
1397
+ template: {
1398
+ rich_text: Array<RichTextItemRequest>;
1399
+ children?: Array<BlockObjectRequestWithoutChildren>;
1400
+ };
1401
+ type?: "template";
1402
+ object?: "block";
1403
+ } | {
1404
+ callout: {
1405
+ rich_text: Array<RichTextItemRequest>;
1406
+ color?: ApiColor;
1407
+ children?: Array<BlockObjectRequestWithoutChildren>;
1408
+ icon?: PageIconRequest;
1409
+ };
1410
+ type?: "callout";
1411
+ object?: "block";
1412
+ } | {
1413
+ synced_block: {
1414
+ synced_from: {
1415
+ block_id: IdRequest;
1416
+ type?: "block_id";
1417
+ } | null;
1418
+ children?: Array<BlockObjectRequestWithoutChildren>;
1419
+ };
1420
+ type?: "synced_block";
1421
+ object?: "block";
1422
+ };
1423
+ type ColumnListRequest = {
1424
+ children: Array<ColumnBlockWithChildrenRequest>;
1425
+ };
1426
+ type ColumnWithChildrenRequest = {
1427
+ children: Array<BlockObjectWithSingleLevelOfChildrenRequest>;
1428
+ width_ratio?: number;
1429
+ };
1430
+ export type ContentWithExpressionRequest = {
1431
+ expression: string;
1432
+ };
1433
+ export type ContentWithTableRowRequest = {
1434
+ cells: Array<Array<RichTextItemRequest>>;
1435
+ };
1436
+ type CustomEmojiPageIconRequest = {
1437
+ type?: "custom_emoji";
1438
+ custom_emoji: {
1439
+ id: IdRequest;
1440
+ name?: string;
1441
+ url?: string;
1442
+ };
1443
+ };
1444
+ type EmojiPageIconRequest = {
1445
+ type?: "emoji";
1446
+ emoji: EmojiRequest;
1447
+ };
1448
+ type EquationRichTextItemRequest = {
1449
+ type?: "equation";
1450
+ equation: {
1451
+ expression: string;
1452
+ };
1453
+ };
1454
+ type ExternalFileRequest = {
1455
+ url: TextRequest;
1456
+ };
1457
+ type ExternalPageIconRequest = {
1458
+ type?: "external";
1459
+ external: {
1460
+ url: string;
1461
+ };
1462
+ };
1463
+ type FileUploadIdRequest = {
1464
+ id: IdRequest;
1465
+ };
1466
+ type FileUploadPageIconRequest = {
1467
+ type?: "file_upload";
1468
+ file_upload: {
1469
+ id: string;
1470
+ };
1471
+ };
1472
+ type IconPageIconRequest = {
1473
+ type?: "icon";
1474
+ icon: {
1475
+ name: NoticonName;
1476
+ color?: NoticonColor;
1477
+ };
1478
+ };
1479
+ export type LanguageRequest = "abap" | "abc" | "agda" | "arduino" | "ascii art" | "assembly" | "bash" | "basic" | "bnf" | "c" | "c#" | "c++" | "clojure" | "coffeescript" | "coq" | "css" | "dart" | "dhall" | "diff" | "docker" | "ebnf" | "elixir" | "elm" | "erlang" | "f#" | "flow" | "fortran" | "gherkin" | "glsl" | "go" | "graphql" | "groovy" | "haskell" | "hcl" | "html" | "idris" | "java" | "javascript" | "json" | "julia" | "kotlin" | "latex" | "less" | "lisp" | "livescript" | "llvm ir" | "lua" | "makefile" | "markdown" | "markup" | "matlab" | "mathematica" | "mermaid" | "nix" | "notion formula" | "objective-c" | "ocaml" | "pascal" | "perl" | "php" | "plain text" | "powershell" | "prolog" | "protobuf" | "purescript" | "python" | "r" | "racket" | "reason" | "ruby" | "rust" | "sass" | "scala" | "scheme" | "scss" | "shell" | "smalltalk" | "solidity" | "sql" | "swift" | "toml" | "typescript" | "vb.net" | "verilog" | "vhdl" | "visual basic" | "webassembly" | "xml" | "yaml" | "java/c/c++/c#";
1480
+ type MediaContentWithFileAndCaptionRequest = {
1481
+ external: ExternalFileRequest;
1482
+ type?: "external";
1483
+ caption?: Array<RichTextItemRequest>;
1484
+ } | {
1485
+ file_upload: FileUploadIdRequest;
1486
+ type?: "file_upload";
1487
+ caption?: Array<RichTextItemRequest>;
1488
+ };
1489
+ type MediaContentWithFileNameAndCaptionRequest = {
1490
+ external: ExternalFileRequest;
1491
+ type?: "external";
1492
+ caption?: Array<RichTextItemRequest>;
1493
+ name?: StringRequest;
1494
+ } | {
1495
+ file_upload: FileUploadIdRequest;
1496
+ type?: "file_upload";
1497
+ caption?: Array<RichTextItemRequest>;
1498
+ name?: StringRequest;
1499
+ };
1500
+ type MediaContentWithUrlAndCaptionRequest = {
1501
+ url: string;
1502
+ caption?: Array<RichTextItemRequest>;
1503
+ };
1504
+ type MentionRichTextItemRequest = {
1505
+ type?: "mention";
1506
+ mention: {
1507
+ type?: "user";
1508
+ user: PartialUserObjectRequest;
1509
+ } | {
1510
+ type?: "date";
1511
+ date: DateRequest;
1512
+ } | {
1513
+ type?: "page";
1514
+ page: {
1515
+ id: IdRequest;
1516
+ };
1517
+ } | {
1518
+ type?: "database";
1519
+ database: {
1520
+ id: IdRequest;
1521
+ };
1522
+ } | {
1523
+ type?: "template_mention";
1524
+ template_mention: TemplateMentionRequest;
1525
+ } | {
1526
+ type?: "custom_emoji";
1527
+ custom_emoji: {
1528
+ id: IdRequest;
1529
+ name?: string;
1530
+ url?: string;
1531
+ };
1532
+ };
1533
+ };
1534
+ type RichTextItemRequestCommon = {
1535
+ annotations?: AnnotationRequest;
1536
+ };
1537
+ type TabRequestWithNestedTabItemChildren = {
1538
+ children: Array<TabItemRequestWithSingleLevelOfChildren>;
1539
+ };
1540
+ type TableRequestWithTableRowChildren = {
1541
+ table_width: number;
1542
+ children: Array<TableRowRequest>;
1543
+ has_column_header?: boolean;
1544
+ has_row_header?: boolean;
1545
+ };
1546
+ type TextRichTextItemRequest = {
1547
+ type?: "text";
1548
+ text: {
1549
+ content: string;
1550
+ link?: {
1551
+ url: string;
1552
+ } | null;
1553
+ };
1554
+ };
1555
+ type PagePropertyValueWithIdResponse = IdObjectResponse & (SimpleOrArrayPropertyValueResponse | PartialRollupPropertyResponse);
1556
+ export type NumberFormat = string;
1557
+ export type PropertyDescriptionRequest = string;
1558
+ type AnnotationRequest = {
1559
+ bold?: boolean;
1560
+ italic?: boolean;
1561
+ strikethrough?: boolean;
1562
+ underline?: boolean;
1563
+ code?: boolean;
1564
+ color?: ApiColor;
1565
+ };
1566
+ export type BlockObjectRequestWithoutChildren = {
1567
+ embed: MediaContentWithUrlAndCaptionRequest;
1568
+ type?: "embed";
1569
+ object?: "block";
1570
+ } | {
1571
+ bookmark: MediaContentWithUrlAndCaptionRequest;
1572
+ type?: "bookmark";
1573
+ object?: "block";
1574
+ } | {
1575
+ image: MediaContentWithFileAndCaptionRequest;
1576
+ type?: "image";
1577
+ object?: "block";
1578
+ } | {
1579
+ video: MediaContentWithFileAndCaptionRequest;
1580
+ type?: "video";
1581
+ object?: "block";
1582
+ } | {
1583
+ pdf: MediaContentWithFileAndCaptionRequest;
1584
+ type?: "pdf";
1585
+ object?: "block";
1586
+ } | {
1587
+ file: MediaContentWithFileNameAndCaptionRequest;
1588
+ type?: "file";
1589
+ object?: "block";
1590
+ } | {
1591
+ audio: MediaContentWithFileAndCaptionRequest;
1592
+ type?: "audio";
1593
+ object?: "block";
1594
+ } | {
1595
+ code: {
1596
+ rich_text: Array<RichTextItemRequest>;
1597
+ language: LanguageRequest;
1598
+ caption?: Array<RichTextItemRequest>;
1599
+ };
1600
+ type?: "code";
1601
+ object?: "block";
1602
+ } | {
1603
+ equation: ContentWithExpressionRequest;
1604
+ type?: "equation";
1605
+ object?: "block";
1606
+ } | {
1607
+ divider: EmptyObject;
1608
+ type?: "divider";
1609
+ object?: "block";
1610
+ } | {
1611
+ breadcrumb: EmptyObject;
1612
+ type?: "breadcrumb";
1613
+ object?: "block";
1614
+ } | {
1615
+ tab: EmptyObject;
1616
+ type?: "tab";
1617
+ object?: "block";
1618
+ } | {
1619
+ table_of_contents: {
1620
+ color?: ApiColor;
1621
+ };
1622
+ type?: "table_of_contents";
1623
+ object?: "block";
1624
+ } | {
1625
+ link_to_page: {
1626
+ page_id: IdRequest;
1627
+ type?: "page_id";
1628
+ } | {
1629
+ database_id: IdRequest;
1630
+ type?: "database_id";
1631
+ } | {
1632
+ comment_id: IdRequest;
1633
+ type?: "comment_id";
1634
+ };
1635
+ type?: "link_to_page";
1636
+ object?: "block";
1637
+ } | {
1638
+ table_row: ContentWithTableRowRequest;
1639
+ type?: "table_row";
1640
+ object?: "block";
1641
+ } | {
1642
+ heading_1: HeaderContentWithRichTextAndColorRequest;
1643
+ type?: "heading_1";
1644
+ object?: "block";
1645
+ } | {
1646
+ heading_2: HeaderContentWithRichTextAndColorRequest;
1647
+ type?: "heading_2";
1648
+ object?: "block";
1649
+ } | {
1650
+ heading_3: HeaderContentWithRichTextAndColorRequest;
1651
+ type?: "heading_3";
1652
+ object?: "block";
1653
+ } | {
1654
+ paragraph: ContentWithRichTextAndColorRequest;
1655
+ type?: "paragraph";
1656
+ object?: "block";
1657
+ } | {
1658
+ bulleted_list_item: ContentWithRichTextAndColorRequest;
1659
+ type?: "bulleted_list_item";
1660
+ object?: "block";
1661
+ } | {
1662
+ numbered_list_item: ContentWithRichTextAndColorRequest;
1663
+ type?: "numbered_list_item";
1664
+ object?: "block";
1665
+ } | {
1666
+ quote: ContentWithRichTextAndColorRequest;
1667
+ type?: "quote";
1668
+ object?: "block";
1669
+ } | {
1670
+ to_do: {
1671
+ rich_text: Array<RichTextItemRequest>;
1672
+ checked?: boolean;
1673
+ color?: ApiColor;
1674
+ };
1675
+ type?: "to_do";
1676
+ object?: "block";
1677
+ } | {
1678
+ toggle: ContentWithRichTextAndColorRequest;
1679
+ type?: "toggle";
1680
+ object?: "block";
1681
+ } | {
1682
+ template: ContentWithRichTextRequest;
1683
+ type?: "template";
1684
+ object?: "block";
1685
+ } | {
1686
+ callout: {
1687
+ rich_text: Array<RichTextItemRequest>;
1688
+ icon?: PageIconRequest;
1689
+ color?: ApiColor;
1690
+ };
1691
+ type?: "callout";
1692
+ object?: "block";
1693
+ } | {
1694
+ synced_block: {
1695
+ synced_from: {
1696
+ block_id: IdRequest;
1697
+ type?: "block_id";
1698
+ } | null;
1699
+ };
1700
+ type?: "synced_block";
1701
+ object?: "block";
1702
+ };
1703
+ type ColumnBlockWithChildrenRequest = {
1704
+ column: ColumnWithChildrenRequest;
1705
+ type?: "column";
1706
+ object?: "block";
1707
+ };
1708
+ type ContentWithSingleLevelOfChildrenRequest = {
1709
+ rich_text: Array<RichTextItemRequest>;
1710
+ color?: ApiColor;
1711
+ children?: Array<BlockObjectRequestWithoutChildren>;
1712
+ };
1713
+ type HeaderContentWithSingleLevelOfChildrenRequest = {
1714
+ rich_text: Array<RichTextItemRequest>;
1715
+ color?: ApiColor;
1716
+ is_toggleable?: boolean;
1717
+ children?: Array<BlockObjectRequestWithoutChildren>;
1718
+ };
1719
+ type TabItemRequestWithSingleLevelOfChildren = {
1720
+ paragraph: ContentWithSingleLevelOfChildrenRequest;
1721
+ type?: "paragraph";
1722
+ object?: "block";
1723
+ };
1724
+ type TabRequestWithTabItemChildren = {
1725
+ children: Array<TabItemRequestWithoutChildren>;
1726
+ };
1727
+ type TableRowRequest = {
1728
+ table_row: ContentWithTableRowRequest;
1729
+ type?: "table_row";
1730
+ object?: "block";
1731
+ };
1732
+ type TemplateMentionRequest = TemplateMentionDateTemplateMentionRequest | TemplateMentionUserTemplateMentionRequest;
1733
+ type IdObjectResponse = {
1734
+ id: string;
1735
+ };
1736
+ type PartialRollupPropertyResponse = {
1737
+ type: "rollup";
1738
+ rollup: PartialRollupValueResponse;
1739
+ };
1740
+ type SimpleOrArrayPropertyValueResponse = SimplePropertyValueResponse | ArrayBasedPropertyValueResponse;
1741
+ export type ContentWithRichTextAndColorRequest = {
1742
+ rich_text: Array<RichTextItemRequest>;
1743
+ color?: ApiColor;
1744
+ };
1745
+ export type ContentWithRichTextRequest = {
1746
+ rich_text: Array<RichTextItemRequest>;
1747
+ };
1748
+ export type HeaderContentWithRichTextAndColorRequest = {
1749
+ rich_text: Array<RichTextItemRequest>;
1750
+ color?: ApiColor;
1751
+ is_toggleable?: boolean;
1752
+ };
1753
+ type TabItemRequestWithoutChildren = {
1754
+ paragraph: ContentWithRichTextAndColorRequest;
1755
+ type?: "paragraph";
1756
+ object?: "block";
1757
+ };
1758
+ type TemplateMentionDateTemplateMentionRequest = {
1759
+ type?: "template_mention_date";
1760
+ template_mention_date: "today" | "now";
1761
+ };
1762
+ type TemplateMentionUserTemplateMentionRequest = {
1763
+ type?: "template_mention_user";
1764
+ template_mention_user: "me";
1765
+ };
1766
+ type ArrayBasedPropertyValueResponse = TitleArrayBasedPropertyValueResponse | RichTextArrayBasedPropertyValueResponse | PeopleArrayBasedPropertyValueResponse | RelationArrayBasedPropertyValueResponse;
1767
+ type PartialRollupValueResponse = PartialRollupValueResponseCommon & (NumberPartialRollupValueResponse | DatePartialRollupValueResponse | ArrayPartialRollupValueResponse);
1768
+ type SimplePropertyValueResponse = NumberSimplePropertyValueResponse | UrlSimplePropertyValueResponse | SelectSimplePropertyValueResponse | MultiSelectSimplePropertyValueResponse | StatusSimplePropertyValueResponse | DateSimplePropertyValueResponse | EmailSimplePropertyValueResponse | PhoneNumberSimplePropertyValueResponse | CheckboxSimplePropertyValueResponse | FilesSimplePropertyValueResponse | CreatedBySimplePropertyValueResponse | CreatedTimeSimplePropertyValueResponse | LastEditedBySimplePropertyValueResponse | LastEditedTimeSimplePropertyValueResponse | FormulaSimplePropertyValueResponse | ButtonSimplePropertyValueResponse | UniqueIdSimplePropertyValueResponse | VerificationSimplePropertyValueResponse | PlaceSimplePropertyValueResponse;
1769
+ type ArrayPartialRollupValueResponse = {
1770
+ type: "array";
1771
+ array: Array<SimpleOrArrayPropertyValueResponse>;
1772
+ };
1773
+ type ButtonSimplePropertyValueResponse = {
1774
+ type: "button";
1775
+ button: EmptyObject;
1776
+ };
1777
+ type CheckboxSimplePropertyValueResponse = {
1778
+ type: "checkbox";
1779
+ checkbox: boolean;
1780
+ };
1781
+ type CreatedBySimplePropertyValueResponse = {
1782
+ type: "created_by";
1783
+ created_by: UserValueResponse;
1784
+ };
1785
+ type CreatedTimeSimplePropertyValueResponse = {
1786
+ type: "created_time";
1787
+ created_time: string;
1788
+ };
1789
+ type DatePartialRollupValueResponse = {
1790
+ type: "date";
1791
+ date: DateResponse | null;
1792
+ };
1793
+ type DateSimplePropertyValueResponse = {
1794
+ type: "date";
1795
+ date: DateResponse | null;
1796
+ };
1797
+ type EmailSimplePropertyValueResponse = {
1798
+ type: "email";
1799
+ email: string | null;
1800
+ };
1801
+ type FilesSimplePropertyValueResponse = {
1802
+ type: "files";
1803
+ files: Array<InternalOrExternalFileWithNameResponse>;
1804
+ };
1805
+ type FormulaSimplePropertyValueResponse = {
1806
+ type: "formula";
1807
+ formula: FormulaPropertyValueResponse;
1808
+ };
1809
+ type LastEditedBySimplePropertyValueResponse = {
1810
+ type: "last_edited_by";
1811
+ last_edited_by: UserValueResponse;
1812
+ };
1813
+ type LastEditedTimeSimplePropertyValueResponse = {
1814
+ type: "last_edited_time";
1815
+ last_edited_time: string;
1816
+ };
1817
+ type MultiSelectSimplePropertyValueResponse = {
1818
+ type: "multi_select";
1819
+ multi_select: Array<PartialSelectPropertyValueResponse>;
1820
+ };
1821
+ type NumberPartialRollupValueResponse = {
1822
+ type: "number";
1823
+ number: number | null;
1824
+ };
1825
+ type NumberSimplePropertyValueResponse = {
1826
+ type: "number";
1827
+ number: number | null;
1828
+ };
1829
+ type PartialRollupValueResponseCommon = {
1830
+ function: RollupFunction;
1831
+ };
1832
+ type PeopleArrayBasedPropertyValueResponse = {
1833
+ type: "people";
1834
+ people: Array<UserValueResponse | GroupObjectResponse>;
1835
+ };
1836
+ type PhoneNumberSimplePropertyValueResponse = {
1837
+ type: "phone_number";
1838
+ phone_number: string | null;
1839
+ };
1840
+ type PlaceSimplePropertyValueResponse = {
1841
+ type: "place";
1842
+ place: PlacePropertyValueResponse | null;
1843
+ };
1844
+ type RelationArrayBasedPropertyValueResponse = {
1845
+ type: "relation";
1846
+ relation: Array<RelationItemPropertyValueResponse>;
1847
+ };
1848
+ type RichTextArrayBasedPropertyValueResponse = {
1849
+ type: "rich_text";
1850
+ rich_text: Array<RichTextItemResponse>;
1851
+ };
1852
+ type SelectSimplePropertyValueResponse = {
1853
+ type: "select";
1854
+ select: PartialSelectPropertyValueResponse | null;
1855
+ };
1856
+ type StatusSimplePropertyValueResponse = {
1857
+ type: "status";
1858
+ status: PartialSelectPropertyValueResponse | null;
1859
+ };
1860
+ type TitleArrayBasedPropertyValueResponse = {
1861
+ type: "title";
1862
+ title: Array<RichTextItemResponse>;
1863
+ };
1864
+ type UniqueIdSimplePropertyValueResponse = {
1865
+ type: "unique_id";
1866
+ unique_id: UniqueIdPropertyValueResponse;
1867
+ };
1868
+ type UrlSimplePropertyValueResponse = {
1869
+ type: "url";
1870
+ url: string | null;
1871
+ };
1872
+ type VerificationSimplePropertyValueResponse = {
1873
+ type: "verification";
1874
+ verification: VerificationPropertyValueResponse | null;
1875
+ };
1876
+ type FormulaPropertyValueResponse = BooleanFormulaPropertyValueResponse | DateFormulaPropertyValueResponse | NumberFormulaPropertyValueResponse | StringFormulaPropertyValueResponse;
1877
+ export type InternalOrExternalFileWithNameResponse = InternalOrExternalFileWithNameResponseCommon & (FileInternalOrExternalFileWithNameResponse | ExternalInternalOrExternalFileWithNameResponse);
1878
+ type PartialSelectPropertyValueResponse = {
1879
+ id: string;
1880
+ name: string;
1881
+ color: "default" | "gray" | "brown" | "orange" | "yellow" | "green" | "blue" | "purple" | "pink" | "red";
1882
+ };
1883
+ type PlacePropertyValueResponse = {
1884
+ lat: number;
1885
+ lon: number;
1886
+ name?: string | null;
1887
+ address?: string | null;
1888
+ aws_place_id?: string | null;
1889
+ google_place_id?: string | null;
1890
+ };
1891
+ export type RelationItemPropertyValueResponse = {
1892
+ id: IdRequest;
1893
+ };
1894
+ type UniqueIdPropertyValueResponse = {
1895
+ prefix: string | null;
1896
+ number: number | null;
1897
+ };
1898
+ export type VerificationPropertyValueResponse = VerificationPropertyUnverifiedResponse | VerificationPropertyResponse;
1899
+ type BooleanFormulaPropertyValueResponse = {
1900
+ type: "boolean";
1901
+ boolean: boolean | null;
1902
+ };
1903
+ type DateFormulaPropertyValueResponse = {
1904
+ type: "date";
1905
+ date: DateResponse | null;
1906
+ };
1907
+ type ExternalInternalOrExternalFileWithNameResponse = {
1908
+ type: "external";
1909
+ external: {
1910
+ url: string;
1911
+ };
1912
+ };
1913
+ type FileInternalOrExternalFileWithNameResponse = {
1914
+ type: "file";
1915
+ file: InternalFileResponse;
1916
+ };
1917
+ type InternalOrExternalFileWithNameResponseCommon = {
1918
+ name: string;
1919
+ };
1920
+ type NumberFormulaPropertyValueResponse = {
1921
+ type: "number";
1922
+ number: number | null;
1923
+ };
1924
+ type StringFormulaPropertyValueResponse = {
1925
+ type: "string";
1926
+ string: string | null;
1927
+ };
1928
+ type VerificationPropertyResponse = {
1929
+ state: "verified" | "expired";
1930
+ date: DateResponse | null;
1931
+ verified_by: UserValueResponse | null;
1932
+ };
1933
+ type VerificationPropertyUnverifiedResponse = {
1934
+ state: "unverified";
1935
+ date: null;
1936
+ verified_by: null;
1937
+ };
1938
+ export {};
1939
+ //# sourceMappingURL=common.d.ts.map