@isomorph.ai/app-sdk 1.19.0 → 1.21.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.
package/dist/index.d.ts CHANGED
@@ -176,14 +176,14 @@ export interface WarehouseViewReadRequest {
176
176
  export type WarehouseAppendRow = Record<string, string | number | boolean | null>;
177
177
  /**
178
178
  * Land rows in the warehouse. The resource is an alias IT approved with access `append` (an alias reads or
179
- * appends, never both). Up to 500 rows per call; a larger report is several calls, each with its own fresh key.
179
+ * appends, never both). Up to 5000 rows per call; a larger report is several calls, each with its own fresh key.
180
180
  * On a lane without a warehouse binding the rows are validated and answered as a dry run; nothing is written.
181
181
  */
182
182
  export interface WarehouseTableAppendRequest {
183
183
  operation: 'warehouse.table.append';
184
184
  resource: string;
185
185
  input: {
186
- /** 1 to 500 rows. */
186
+ /** 1 to 5000 rows. */
187
187
  rows: WarehouseAppendRow[];
188
188
  };
189
189
  /** A fresh UUID per append, reused only to retry that same append. */
@@ -523,6 +523,559 @@ export interface SharePointFileUploadRequest {
523
523
  /** A fresh UUID per authorized action, reused only to retry that action. */
524
524
  idempotencyKey: string;
525
525
  }
526
+ /** How Google Sheets reads a written cell string: `user` parses it as a person typing would (dates, numbers, formulas; the default), `raw` stores it verbatim. */
527
+ export type SheetsValueInput = 'raw' | 'user';
528
+ /** How `drive.file.read` renders a Google Docs, Sheets or Slides file: `text` (text/plain, a Docs file), `csv` (text/csv, the first sheet of a Sheets file) or `pdf` (any of them). A binary file ignores it and is downloaded as stored. */
529
+ export type DriveExportFormat = 'text' | 'csv' | 'pdf';
530
+ /** One cell as Sheets and Excel move it: a string of at most 4000 characters, a number, a boolean, or null (an empty cell). */
531
+ export type SpreadsheetCellValue = string | number | boolean | null;
532
+ /** A grid of cells as rows: 1 to 1000 rows of 1 to 100 cells each. An update's grid must fit the range or address it is written to (the provider's check). */
533
+ export type SpreadsheetValues = SpreadsheetCellValue[][];
534
+ /** One find-and-replace of `docs.text.replace`: every occurrence of `find` becomes `replace` (empty deletes it). */
535
+ export interface DocsReplacement {
536
+ /** The text to find, 1 to 512 characters, matched literally. */
537
+ find: string;
538
+ /** The replacement, at most 4000 characters; empty deletes the match. */
539
+ replace: string;
540
+ /** Whether the match is case-sensitive; false when absent. */
541
+ matchCase?: boolean;
542
+ }
543
+ /** The fields a new event is created with, at Google Calendar and at Outlook alike. */
544
+ export interface CalendarEventCreateInput {
545
+ /** The event's title, 1 to 256 characters. */
546
+ title: string;
547
+ /** When the event starts, an RFC 3339 date-time with a zone (`2026-10-20T09:30:00+05:30`); for an all-day event its date part is used. */
548
+ start: string;
549
+ /** When the event ends, the same way; the day after the last day for an all-day event. */
550
+ end: string;
551
+ /** The IANA time zone the event is shown in (e.g. `Asia/Kolkata`); absent keeps the zone of `start`. */
552
+ timeZone?: string;
553
+ /** True makes the event span whole days, from the date of `start` to the day before the date of `end`. */
554
+ allDay?: boolean;
555
+ /** The event's description, at most 8000 characters. */
556
+ description?: string;
557
+ /** Where the event is, as free text, 1 to 512 characters. */
558
+ location?: string;
559
+ /** The people invited, 1 to 100 emails. */
560
+ attendees?: string[];
561
+ /** Whether the attendees are emailed about the event; true when absent. */
562
+ notify?: boolean;
563
+ }
564
+ /** The fields an event update may change; every one optional, `attendees` replaces the invitees. Changing an event between timed and all-day is a recreate, so there is no `allDay`. */
565
+ export interface CalendarEventUpdateInput {
566
+ /** The `id` an event list or create result named. */
567
+ eventId: string;
568
+ title?: string;
569
+ start?: string;
570
+ end?: string;
571
+ timeZone?: string;
572
+ description?: string;
573
+ location?: string;
574
+ attendees?: string[];
575
+ /** Whether the attendees are emailed about the change; true when absent. */
576
+ notify?: boolean;
577
+ }
578
+ /** Lists the calendars the signed-in person can see; resource is the fixed calendar alias. Their `id` is what the event operations take as `calendarId`. */
579
+ export interface CalendarCalendarListRequest {
580
+ operation: 'calendar.calendar.list';
581
+ resource: string;
582
+ input?: {
583
+ /** The `nextPageToken` of the previous page; leave it out to read the first page. */
584
+ pageToken?: string;
585
+ };
586
+ }
587
+ /** Lists the events of one window, recurring events expanded to instances, ordered by start. */
588
+ export interface CalendarEventListRequest {
589
+ operation: 'calendar.event.list';
590
+ resource: string;
591
+ input: {
592
+ /** The calendar to read, as `calendar.calendar.list` named it; the person's own (`primary`) when absent. */
593
+ calendarId?: string;
594
+ /** The start of the window, an RFC 3339 date-time with a zone; events ending after it are listed. */
595
+ timeMin: string;
596
+ /** The end of the window; events starting before it are listed. */
597
+ timeMax: string;
598
+ /** Free text an event must match, 1 to 256 characters. */
599
+ q?: string;
600
+ pageToken?: string;
601
+ };
602
+ }
603
+ /** Reads one event; the result is the event itself (the `CalendarEvent` shape at the top level). */
604
+ export interface CalendarEventReadRequest {
605
+ operation: 'calendar.event.read';
606
+ resource: string;
607
+ input: {
608
+ calendarId?: string;
609
+ eventId: string;
610
+ };
611
+ }
612
+ /** Creates one event as the signed-in person and invites its attendees; an explicit action with its own idempotency key. */
613
+ export interface CalendarEventCreateRequest {
614
+ operation: 'calendar.event.create';
615
+ resource: string;
616
+ input: CalendarEventCreateInput & {
617
+ calendarId?: string;
618
+ };
619
+ /** A fresh UUID per authorized action, reused only to retry that action. */
620
+ idempotencyKey: string;
621
+ }
622
+ /** Changes the named fields of one event; the same outcome however often it runs, so no idempotency key. */
623
+ export interface CalendarEventUpdateRequest {
624
+ operation: 'calendar.event.update';
625
+ resource: string;
626
+ input: CalendarEventUpdateInput & {
627
+ calendarId?: string;
628
+ };
629
+ }
630
+ /** Cancels one event, telling the attendees unless `notify` is false; idempotent, so no key. */
631
+ export interface CalendarEventCancelRequest {
632
+ operation: 'calendar.event.cancel';
633
+ resource: string;
634
+ input: {
635
+ calendarId?: string;
636
+ eventId: string;
637
+ notify?: boolean;
638
+ };
639
+ }
640
+ /** Lists one folder's entries, files and folders alike: the root of My Drive when `folderId` is absent; resource is the fixed Drive alias. */
641
+ export interface DriveFileListRequest {
642
+ operation: 'drive.file.list';
643
+ resource: string;
644
+ input?: {
645
+ /** The `id` of an entry with `isFolder` from an earlier listing. */
646
+ folderId?: string;
647
+ pageToken?: string;
648
+ };
649
+ }
650
+ /** Searches the person's files by name and contents. */
651
+ export interface DriveFileSearchRequest {
652
+ operation: 'drive.file.search';
653
+ resource: string;
654
+ input: {
655
+ /** The words to search for, 1 to 256 characters. */
656
+ q: string;
657
+ pageToken?: string;
658
+ };
659
+ }
660
+ /** Reads one file's bytes (at most 2 MiB); a Google Docs, Sheets or Slides file is exported as `exportAs` says (text, csv and pdf respectively when absent), any other file downloaded as stored. */
661
+ export interface DriveFileReadRequest {
662
+ operation: 'drive.file.read';
663
+ resource: string;
664
+ input: {
665
+ /** A Drive file id from a listing, a search or an upload. */
666
+ fileId: string;
667
+ exportAs?: DriveExportFormat;
668
+ };
669
+ }
670
+ /** Uploads one file (at most 2 MiB) into a folder, or the root of My Drive; an explicit action with its own idempotency key. */
671
+ export interface DriveFileUploadRequest {
672
+ operation: 'drive.file.upload';
673
+ resource: string;
674
+ input: {
675
+ /** The name to store it under, 1 to 255 characters; the result's `filename` is the stored name, which `conflict: 'rename'` may have changed. */
676
+ filename: string;
677
+ /** The file's MIME type, e.g. `application/pdf`. */
678
+ contentType: string;
679
+ /** The bytes as standard base64: at most 2 MiB of bytes (2,796,203 base64 characters). */
680
+ dataBase64: string;
681
+ folderId?: string;
682
+ /** `rename` when absent (Drive itself allows duplicate names; rename and replace are the platform's). */
683
+ conflict?: SharePointConflictBehavior;
684
+ };
685
+ /** A fresh UUID per authorized action, reused only to retry that action. */
686
+ idempotencyKey: string;
687
+ }
688
+ /** Creates one folder under `folderId`, or in the root of My Drive; an explicit action with its own idempotency key. */
689
+ export interface DriveFolderCreateRequest {
690
+ operation: 'drive.folder.create';
691
+ resource: string;
692
+ input: {
693
+ /** The new folder's name, 1 to 256 characters. */
694
+ title: string;
695
+ folderId?: string;
696
+ };
697
+ /** A fresh UUID per authorized action, reused only to retry that action. */
698
+ idempotencyKey: string;
699
+ }
700
+ /** Reads one document's title and body as plain text (cut at 64 KiB with `truncated` set); resource is the fixed Docs alias. */
701
+ export interface DocsDocumentReadRequest {
702
+ operation: 'docs.document.read';
703
+ resource: string;
704
+ input: {
705
+ /** The document id: the `/document/d/<id>` path segment, or a `docs.document.create` result's id. */
706
+ documentId: string;
707
+ };
708
+ }
709
+ /** Creates one document, with `text` as its body when given; an explicit action with its own idempotency key. */
710
+ export interface DocsDocumentCreateRequest {
711
+ operation: 'docs.document.create';
712
+ resource: string;
713
+ input: {
714
+ /** The document's title, 1 to 256 characters. */
715
+ title: string;
716
+ /** The body as plain text, at most 64 KiB. */
717
+ text?: string;
718
+ };
719
+ /** A fresh UUID per authorized action, reused only to retry that action. */
720
+ idempotencyKey: string;
721
+ }
722
+ /** Appends plain text to the end of one document; idempotent at the platform, so no key. */
723
+ export interface DocsDocumentAppendRequest {
724
+ operation: 'docs.document.append';
725
+ resource: string;
726
+ input: {
727
+ documentId: string;
728
+ /** The text appended, 1 character to 64 KiB. */
729
+ text: string;
730
+ };
731
+ }
732
+ /** Applies 1 to 64 find-and-replace pairs over the whole document, in order (a mail merge: `{{customer}}` becomes the name); no key. */
733
+ export interface DocsTextReplaceRequest {
734
+ operation: 'docs.text.replace';
735
+ resource: string;
736
+ input: {
737
+ documentId: string;
738
+ replacements: DocsReplacement[];
739
+ };
740
+ }
741
+ /** Reads one spreadsheet's title and its sheets (tab order, grid sizes); resource is the fixed Sheets alias. */
742
+ export interface SheetsSpreadsheetReadRequest {
743
+ operation: 'sheets.spreadsheet.read';
744
+ resource: string;
745
+ input: {
746
+ /** The spreadsheet id: the `/spreadsheets/d/<id>` path segment, or a `sheets.spreadsheet.create` result's id. */
747
+ spreadsheetId: string;
748
+ };
749
+ }
750
+ /** Reads the cells of one range as rows of unformatted values (a date cell is its serial number). */
751
+ export interface SheetsValuesReadRequest {
752
+ operation: 'sheets.values.read';
753
+ resource: string;
754
+ input: {
755
+ spreadsheetId: string;
756
+ /** The cells in A1 notation, e.g. `Orders!A1:D` or `Sheet1` (the whole sheet), 1 to 256 characters. */
757
+ range: string;
758
+ };
759
+ }
760
+ /** Appends rows below the table the range names; an explicit action with its own idempotency key, since a retry would add the rows again. */
761
+ export interface SheetsValuesAppendRequest {
762
+ operation: 'sheets.values.append';
763
+ resource: string;
764
+ input: {
765
+ spreadsheetId: string;
766
+ /** The table to append to, in A1 notation (`Orders!A:D`, or the sheet's name); the rows go below its last row. */
767
+ range: string;
768
+ values: SpreadsheetValues;
769
+ /** `user` when absent. */
770
+ valueInput?: SheetsValueInput;
771
+ };
772
+ /** A fresh UUID per authorized action, reused only to retry that action. */
773
+ idempotencyKey: string;
774
+ }
775
+ /** Overwrites the cells of one range with the grid; the same outcome however often it runs, so no key. */
776
+ export interface SheetsValuesUpdateRequest {
777
+ operation: 'sheets.values.update';
778
+ resource: string;
779
+ input: {
780
+ spreadsheetId: string;
781
+ range: string;
782
+ /** The grid must fit the range (Google's check). */
783
+ values: SpreadsheetValues;
784
+ valueInput?: SheetsValueInput;
785
+ };
786
+ }
787
+ /** Clears the cells of one range (values only; formatting stays); no key. */
788
+ export interface SheetsValuesClearRequest {
789
+ operation: 'sheets.values.clear';
790
+ resource: string;
791
+ input: {
792
+ spreadsheetId: string;
793
+ range: string;
794
+ };
795
+ }
796
+ /** Creates one spreadsheet, with the named sheets or the one default sheet; an explicit action with its own idempotency key. */
797
+ export interface SheetsSpreadsheetCreateRequest {
798
+ operation: 'sheets.spreadsheet.create';
799
+ resource: string;
800
+ input: {
801
+ /** The spreadsheet's title, 1 to 256 characters. */
802
+ title: string;
803
+ /** The titles of the sheets it starts with, 1 to 20, each 1 to 100 characters. */
804
+ sheets?: string[];
805
+ };
806
+ /** A fresh UUID per authorized action, reused only to retry that action. */
807
+ idempotencyKey: string;
808
+ }
809
+ /** Lists one mail folder's messages, newest first (by relevance for a search), without their bodies; resource is the fixed mailbox alias. */
810
+ export interface OutlookMessageListRequest {
811
+ operation: 'outlook.message.list';
812
+ resource: string;
813
+ input?: {
814
+ /** The mail folder: a well-known name (`inbox`, `sentitems`, `drafts`, `archive`...) or a folder id; the inbox when absent. */
815
+ folder?: string;
816
+ /** A Graph `$search` phrase over the folder's messages, 1 to 256 characters. */
817
+ q?: string;
818
+ pageToken?: string;
819
+ };
820
+ }
821
+ /** Reads one message in the `gmail.message.read` shape: plain text cut at 16 KiB, attachments listed without their bytes, `threadId` the Graph conversationId. */
822
+ export interface OutlookMessageReadRequest {
823
+ operation: 'outlook.message.read';
824
+ resource: string;
825
+ input: {
826
+ /** The Graph message id an `outlook.message.list` result named. */
827
+ messageId: string;
828
+ };
829
+ }
830
+ /** Reads one attachment's bytes (at most 2 MiB); the ids come from a message read. */
831
+ export interface OutlookAttachmentReadRequest {
832
+ operation: 'outlook.attachment.read';
833
+ resource: string;
834
+ input: {
835
+ messageId: string;
836
+ /** The `id` of an entry in the message's `attachments`. */
837
+ attachmentId: string;
838
+ };
839
+ }
840
+ /** Sends one message as the signed-in person; an explicit action with its own idempotency key. Graph returns no message id, so the result's `id` is the platform's receipt. */
841
+ export interface OutlookMessageSendRequest {
842
+ operation: 'outlook.message.send';
843
+ resource: string;
844
+ input: {
845
+ /** 1 to 50 email addresses per recipient list. */
846
+ to: string[];
847
+ cc?: string[];
848
+ bcc?: string[];
849
+ /** 1 to 256 characters. */
850
+ subject: string;
851
+ /** Plain text, 1 to 4000 characters; the plain-text alternative when `html` is sent too. */
852
+ text: string;
853
+ /** An HTML body sent beside `text`, at most 64 KiB. */
854
+ html?: string;
855
+ /** 1 to 5 files, each at most 2 MiB. */
856
+ attachments?: GmailAttachmentInput[];
857
+ };
858
+ /** A fresh UUID per authorized Send action, reused only to retry that action. */
859
+ idempotencyKey: string;
860
+ }
861
+ /** Replies to one message's sender with plain text; an explicit action with its own idempotency key. */
862
+ export interface OutlookMessageReplyRequest {
863
+ operation: 'outlook.message.reply';
864
+ resource: string;
865
+ input: {
866
+ messageId: string;
867
+ /** Plain text, 1 to 4000 characters. */
868
+ text: string;
869
+ };
870
+ /** A fresh UUID per authorized Send action, reused only to retry that action. */
871
+ idempotencyKey: string;
872
+ }
873
+ /** Lists the events of the person's calendar in one window (Graph's calendar view: recurring events expanded), ordered by start. */
874
+ export interface OutlookEventListRequest {
875
+ operation: 'outlook.event.list';
876
+ resource: string;
877
+ input: {
878
+ /** The start of the window, an RFC 3339 date-time with a zone. */
879
+ start: string;
880
+ /** The end of the window. */
881
+ end: string;
882
+ pageToken?: string;
883
+ };
884
+ }
885
+ /** Reads one event; the result is the event itself (the `CalendarEvent` shape at the top level). */
886
+ export interface OutlookEventReadRequest {
887
+ operation: 'outlook.event.read';
888
+ resource: string;
889
+ input: {
890
+ /** The Graph event id an `outlook.event.list` or `outlook.event.create` result named. */
891
+ eventId: string;
892
+ };
893
+ }
894
+ /** Creates one event in the person's calendar and invites its attendees; an explicit action with its own idempotency key. */
895
+ export interface OutlookEventCreateRequest {
896
+ operation: 'outlook.event.create';
897
+ resource: string;
898
+ input: CalendarEventCreateInput;
899
+ /** A fresh UUID per authorized action, reused only to retry that action. */
900
+ idempotencyKey: string;
901
+ }
902
+ /** Changes the named fields of one event; a PATCH, so no idempotency key. */
903
+ export interface OutlookEventUpdateRequest {
904
+ operation: 'outlook.event.update';
905
+ resource: string;
906
+ input: CalendarEventUpdateInput;
907
+ }
908
+ /** Cancels one event, sending the attendees `comment` with the cancellation when given; idempotent, so no key. */
909
+ export interface OutlookEventCancelRequest {
910
+ operation: 'outlook.event.cancel';
911
+ resource: string;
912
+ input: {
913
+ eventId: string;
914
+ /** A note sent to the attendees with the cancellation, 1 to 4000 characters. */
915
+ comment?: string;
916
+ };
917
+ }
918
+ /** Lists one folder's entries of the person's OneDrive, files and folders alike: the drive's root when `folderId` is absent; resource is the fixed OneDrive alias. */
919
+ export interface OneDriveFileListRequest {
920
+ operation: 'onedrive.file.list';
921
+ resource: string;
922
+ input?: {
923
+ folderId?: string;
924
+ pageToken?: string;
925
+ };
926
+ }
927
+ /** Searches the person's OneDrive files by name and contents. */
928
+ export interface OneDriveFileSearchRequest {
929
+ operation: 'onedrive.file.search';
930
+ resource: string;
931
+ input: {
932
+ /** The words to search for, 1 to 256 characters. */
933
+ q: string;
934
+ pageToken?: string;
935
+ };
936
+ }
937
+ /** Reads one file's bytes (at most 2 MiB) as stored. */
938
+ export interface OneDriveFileReadRequest {
939
+ operation: 'onedrive.file.read';
940
+ resource: string;
941
+ input: {
942
+ /** A OneDrive item id from a listing, a search or an upload. */
943
+ fileId: string;
944
+ };
945
+ }
946
+ /** Uploads one file (at most 2 MiB) into a folder, or the drive's root; an explicit action with its own idempotency key. */
947
+ export interface OneDriveFileUploadRequest {
948
+ operation: 'onedrive.file.upload';
949
+ resource: string;
950
+ input: {
951
+ filename: string;
952
+ contentType: string;
953
+ dataBase64: string;
954
+ folderId?: string;
955
+ /** `rename` when absent. */
956
+ conflict?: SharePointConflictBehavior;
957
+ };
958
+ /** A fresh UUID per authorized action, reused only to retry that action. */
959
+ idempotencyKey: string;
960
+ }
961
+ /** Creates one folder under `folderId`, or in the drive's root; an explicit action with its own idempotency key. */
962
+ export interface OneDriveFolderCreateRequest {
963
+ operation: 'onedrive.folder.create';
964
+ resource: string;
965
+ input: {
966
+ /** The new folder's name, 1 to 256 characters. */
967
+ title: string;
968
+ folderId?: string;
969
+ };
970
+ /** A fresh UUID per authorized action, reused only to retry that action. */
971
+ idempotencyKey: string;
972
+ }
973
+ /** Lists one workbook's worksheets in tab order; resource is the fixed workbooks alias. `fileId` is the .xlsx drive item, `driveId` the drive a shared workbook lives in (the person's own OneDrive when absent). */
974
+ export interface ExcelWorksheetListRequest {
975
+ operation: 'excel.worksheet.list';
976
+ resource: string;
977
+ input: {
978
+ fileId: string;
979
+ driveId?: string;
980
+ };
981
+ }
982
+ /** Reads the cells of one range as rows of unformatted values (a date cell is its text at Excel); without `address`, the worksheet's used range. */
983
+ export interface ExcelRangeReadRequest {
984
+ operation: 'excel.range.read';
985
+ resource: string;
986
+ input: {
987
+ fileId: string;
988
+ driveId?: string;
989
+ /** The worksheet, by name or id as `excel.worksheet.list` named it. */
990
+ worksheet: string;
991
+ /** The cells in A1 notation without the sheet name, e.g. `A1:D10`, 1 to 64 characters. */
992
+ address?: string;
993
+ };
994
+ }
995
+ /** Overwrites the cells of one range with the grid, which must fit it (Excel's check); idempotent, so no key. */
996
+ export interface ExcelRangeUpdateRequest {
997
+ operation: 'excel.range.update';
998
+ resource: string;
999
+ input: {
1000
+ fileId: string;
1001
+ driveId?: string;
1002
+ worksheet: string;
1003
+ address: string;
1004
+ values: SpreadsheetValues;
1005
+ };
1006
+ }
1007
+ /** Lists the workbook's tables, or one worksheet's; their `name` is what `excel.row.add` takes as `tableName`. */
1008
+ export interface ExcelTableListRequest {
1009
+ operation: 'excel.table.list';
1010
+ resource: string;
1011
+ input: {
1012
+ fileId: string;
1013
+ driveId?: string;
1014
+ worksheet?: string;
1015
+ };
1016
+ }
1017
+ /** Adds rows below one table's last row; an explicit action with its own idempotency key, since a retry would add them again. */
1018
+ export interface ExcelRowAddRequest {
1019
+ operation: 'excel.row.add';
1020
+ resource: string;
1021
+ input: {
1022
+ fileId: string;
1023
+ driveId?: string;
1024
+ /** The table, by name or id as `excel.table.list` named it. */
1025
+ tableName: string;
1026
+ /** Each row as many cells as the table has columns (Excel's check). */
1027
+ values: SpreadsheetValues;
1028
+ };
1029
+ /** A fresh UUID per authorized action, reused only to retry that action. */
1030
+ idempotencyKey: string;
1031
+ }
1032
+ /** Adds one worksheet to the workbook; an explicit action with its own idempotency key. */
1033
+ export interface ExcelWorksheetAddRequest {
1034
+ operation: 'excel.worksheet.add';
1035
+ resource: string;
1036
+ input: {
1037
+ fileId: string;
1038
+ driveId?: string;
1039
+ /** The new worksheet's name (1 to 31 characters at Excel; its check). */
1040
+ title: string;
1041
+ };
1042
+ /** A fresh UUID per authorized action, reused only to retry that action. */
1043
+ idempotencyKey: string;
1044
+ }
1045
+ /** Lists one channel's top-level messages, newest first; resource is a channel alias IT mapped to one channel of one team. */
1046
+ export interface TeamsMessageListRequest {
1047
+ operation: 'teams.message.list';
1048
+ resource: string;
1049
+ input?: {
1050
+ pageToken?: string;
1051
+ };
1052
+ }
1053
+ /** Posts one message to the channel as the signed-in person; an explicit action with its own idempotency key. */
1054
+ export interface TeamsMessagePostRequest {
1055
+ operation: 'teams.message.post';
1056
+ resource: string;
1057
+ input: {
1058
+ /** Plain text, 1 to 4000 characters; the plain-text alternative when `html` is sent too. */
1059
+ text: string;
1060
+ /** An HTML body sent beside `text`, at most 64 KiB. */
1061
+ html?: string;
1062
+ };
1063
+ /** A fresh UUID per authorized action, reused only to retry that action. */
1064
+ idempotencyKey: string;
1065
+ }
1066
+ /** Replies to one of the channel's messages as the signed-in person; an explicit action with its own idempotency key. */
1067
+ export interface TeamsReplyPostRequest {
1068
+ operation: 'teams.reply.post';
1069
+ resource: string;
1070
+ input: {
1071
+ /** The Teams message id a `teams.message.list` or `teams.message.post` result named. */
1072
+ messageId: string;
1073
+ text: string;
1074
+ html?: string;
1075
+ };
1076
+ /** A fresh UUID per authorized action, reused only to retry that action. */
1077
+ idempotencyKey: string;
1078
+ }
526
1079
  export interface ServiceRequest {
527
1080
  operation: 'service.request';
528
1081
  resource?: never;
@@ -540,7 +1093,7 @@ export interface ServiceRequestResult {
540
1093
  headers: Record<string, string>;
541
1094
  body: unknown;
542
1095
  }
543
- export type IntegrationRequest = ServiceRequest | SlackChannelHistoryRequest | SlackMessagePostRequest | SlackMessageUpdateRequest | SlackMessageDeleteRequest | SlackDmSendRequest | SlackUserLookupRequest | WarehouseViewReadRequest | WarehouseTableAppendRequest | PhoneSmsListRequest | PhoneNumberGetRequest | GmailThreadListRequest | GmailThreadReadRequest | GmailMessageReadRequest | GmailAttachmentReadRequest | GmailMessageSendRequest | BasecampProjectListRequest | BasecampTodolistListRequest | BasecampTodoListRequest | BasecampTodoCreateRequest | BasecampTodoCompleteRequest | BasecampMessageListRequest | BasecampMessagePostRequest | BasecampCommentListRequest | BasecampCommentPostRequest | BasecampCampfirePostRequest | BasecampPeopleListRequest | SharePointListListRequest | SharePointItemListRequest | SharePointItemCreateRequest | SharePointItemUpdateRequest | SharePointDriveListRequest | SharePointFileListRequest | SharePointFileSearchRequest | SharePointFileReadRequest | SharePointFileUploadRequest;
1096
+ export type IntegrationRequest = ServiceRequest | SlackChannelHistoryRequest | SlackMessagePostRequest | SlackMessageUpdateRequest | SlackMessageDeleteRequest | SlackDmSendRequest | SlackUserLookupRequest | WarehouseViewReadRequest | WarehouseTableAppendRequest | PhoneSmsListRequest | PhoneNumberGetRequest | GmailThreadListRequest | GmailThreadReadRequest | GmailMessageReadRequest | GmailAttachmentReadRequest | GmailMessageSendRequest | BasecampProjectListRequest | BasecampTodolistListRequest | BasecampTodoListRequest | BasecampTodoCreateRequest | BasecampTodoCompleteRequest | BasecampMessageListRequest | BasecampMessagePostRequest | BasecampCommentListRequest | BasecampCommentPostRequest | BasecampCampfirePostRequest | BasecampPeopleListRequest | SharePointListListRequest | SharePointItemListRequest | SharePointItemCreateRequest | SharePointItemUpdateRequest | SharePointDriveListRequest | SharePointFileListRequest | SharePointFileSearchRequest | SharePointFileReadRequest | SharePointFileUploadRequest | CalendarCalendarListRequest | CalendarEventListRequest | CalendarEventReadRequest | CalendarEventCreateRequest | CalendarEventUpdateRequest | CalendarEventCancelRequest | DriveFileListRequest | DriveFileSearchRequest | DriveFileReadRequest | DriveFileUploadRequest | DriveFolderCreateRequest | DocsDocumentReadRequest | DocsDocumentCreateRequest | DocsDocumentAppendRequest | DocsTextReplaceRequest | SheetsSpreadsheetReadRequest | SheetsValuesReadRequest | SheetsValuesAppendRequest | SheetsValuesUpdateRequest | SheetsValuesClearRequest | SheetsSpreadsheetCreateRequest | OutlookMessageListRequest | OutlookMessageReadRequest | OutlookAttachmentReadRequest | OutlookMessageSendRequest | OutlookMessageReplyRequest | OutlookEventListRequest | OutlookEventReadRequest | OutlookEventCreateRequest | OutlookEventUpdateRequest | OutlookEventCancelRequest | OneDriveFileListRequest | OneDriveFileSearchRequest | OneDriveFileReadRequest | OneDriveFileUploadRequest | OneDriveFolderCreateRequest | ExcelWorksheetListRequest | ExcelRangeReadRequest | ExcelRangeUpdateRequest | ExcelTableListRequest | ExcelRowAddRequest | ExcelWorksheetAddRequest | TeamsMessageListRequest | TeamsMessagePostRequest | TeamsReplyPostRequest;
544
1097
  export type IntegrationOperation = IntegrationRequest['operation'];
545
1098
  export interface SlackMessage {
546
1099
  id: string;
@@ -817,7 +1370,220 @@ export interface SharePointFileUploadResult {
817
1370
  filename: string;
818
1371
  webUrl: string;
819
1372
  }
820
- export type IntegrationResult<R extends IntegrationRequest> = R extends ServiceRequest ? ServiceRequestResult : R extends SlackChannelHistoryRequest ? SlackChannelHistoryResult : R extends SlackMessagePostRequest | SlackMessageUpdateRequest | SlackMessageDeleteRequest ? SlackMessagePostResult : R extends SlackDmSendRequest ? SlackDmSendResult : R extends SlackUserLookupRequest ? SlackUserLookupResult : R extends WarehouseViewReadRequest ? WarehouseViewReadResult : R extends WarehouseTableAppendRequest ? WarehouseTableAppendResult : R extends PhoneSmsListRequest ? PhoneSmsListResult : R extends PhoneNumberGetRequest ? PhoneNumberGetResult : R extends GmailThreadListRequest ? GmailThreadListResult : R extends GmailThreadReadRequest ? GmailThreadReadResult : R extends GmailMessageReadRequest ? GmailMessageReadResult : R extends GmailAttachmentReadRequest ? GmailAttachmentReadResult : R extends GmailMessageSendRequest ? GmailMessageSendResult : R extends BasecampProjectListRequest ? BasecampProjectListResult : R extends BasecampTodolistListRequest ? BasecampTodolistListResult : R extends BasecampTodoListRequest ? BasecampTodoListResult : R extends BasecampMessageListRequest ? BasecampMessageListResult : R extends BasecampCommentListRequest ? BasecampCommentListResult : R extends BasecampPeopleListRequest ? BasecampPeopleListResult : R extends BasecampTodoCreateRequest | BasecampMessagePostRequest | BasecampCommentPostRequest | BasecampCampfirePostRequest ? BasecampRecordingResult : R extends BasecampTodoCompleteRequest ? BasecampTodoCompleteResult : R extends SharePointListListRequest ? SharePointListListResult : R extends SharePointItemListRequest ? SharePointItemListResult : R extends SharePointItemCreateRequest ? SharePointItemCreateResult : R extends SharePointItemUpdateRequest ? SharePointItemUpdateResult : R extends SharePointDriveListRequest ? SharePointDriveListResult : R extends SharePointFileListRequest | SharePointFileSearchRequest ? SharePointFileListResult : R extends SharePointFileReadRequest ? SharePointFileReadResult : R extends SharePointFileUploadRequest ? SharePointFileUploadResult : never;
1373
+ /** One page of a 0.86.0 list; `nextPageToken` is present only when `hasMore` and is the next read's `pageToken`. */
1374
+ export interface WorkspacePage {
1375
+ hasMore: boolean;
1376
+ nextPageToken?: string;
1377
+ }
1378
+ /** One calendar the person can see; `id` is the `calendarId` the event operations take, `primary` marks the person's own calendar, `accessRole` is Google's (owner, writer, reader, freeBusyReader). */
1379
+ export interface CalendarListEntry {
1380
+ id: string;
1381
+ name: string;
1382
+ primary: boolean;
1383
+ accessRole: string;
1384
+ }
1385
+ /** One invitee (or the organizer): `response` is accepted, declined, tentative or needsAction when the provider reports it. */
1386
+ export interface CalendarAttendee {
1387
+ email: string;
1388
+ name?: string;
1389
+ response?: string;
1390
+ }
1391
+ /** The event's state at the provider; named apart from `status`, the HTTP status of a `service.request` result. */
1392
+ export type CalendarEventStatus = 'confirmed' | 'tentative' | 'cancelled';
1393
+ /** One event, as a list entry and as the whole of an event read. `start` and `end` are RFC 3339 date-times, or YYYY-MM-DD dates when `allDay` (the end is the day after the last day); `description` is plain text cut at 16 KiB; `id` is the `eventId` the read, update and cancel take. */
1394
+ export interface CalendarEvent {
1395
+ id: string;
1396
+ title: string;
1397
+ start: string;
1398
+ end: string;
1399
+ allDay: boolean;
1400
+ timeZone?: string;
1401
+ location?: string;
1402
+ description?: string;
1403
+ /** Who is invited and how they answered; empty when the event has none. */
1404
+ attendees: CalendarAttendee[];
1405
+ organizer?: CalendarAttendee;
1406
+ webUrl: string;
1407
+ eventStatus: CalendarEventStatus;
1408
+ }
1409
+ export interface CalendarCalendarListResult extends WorkspacePage {
1410
+ calendars: CalendarListEntry[];
1411
+ }
1412
+ /** `calendar.event.list` and `outlook.event.list` answer the same page of events. */
1413
+ export interface CalendarEventListResult extends WorkspacePage {
1414
+ events: CalendarEvent[];
1415
+ }
1416
+ /** `calendar.event.read` and `outlook.event.read` answer the event itself. */
1417
+ export type CalendarEventReadResult = CalendarEvent;
1418
+ /** The new event and its page, for a person to open. */
1419
+ export interface CalendarEventCreateResult {
1420
+ id: string;
1421
+ webUrl: string;
1422
+ }
1423
+ /** The event changed or cancelled, by id. */
1424
+ export interface CalendarEventUpdateResult {
1425
+ id: string;
1426
+ }
1427
+ /** One Drive or OneDrive entry: the SharePoint shape. A Google-native file (a Doc, Sheet or Slides deck) has `size` 0 and its `application/vnd.google-apps.*` type. */
1428
+ export type DriveFile = SharePointFile;
1429
+ /** `drive.file.list`, `drive.file.search`, `onedrive.file.list` and `onedrive.file.search` answer the same page of entries. */
1430
+ export interface DriveFileListResult extends WorkspacePage {
1431
+ files: DriveFile[];
1432
+ }
1433
+ /** The Gmail attachment shape plus the file's id; for an exported Google file, `filename` carries the export's extension and `mimeType` the export's type. */
1434
+ export interface DriveFileReadResult extends GmailAttachmentReadResult {
1435
+ id: string;
1436
+ }
1437
+ /** The stored file, under the name `conflict: 'rename'` may have given it, and its page. */
1438
+ export interface DriveFileUploadResult {
1439
+ id: string;
1440
+ filename: string;
1441
+ webUrl: string;
1442
+ }
1443
+ /** The new folder (the app named it) and its page. */
1444
+ export interface DriveFolderCreateResult {
1445
+ id: string;
1446
+ webUrl: string;
1447
+ }
1448
+ /** The document's title and body as plain text, cut at 64 KiB with `truncated` set; `revisionId` is Google's revision after the read. */
1449
+ export interface DocsDocumentReadResult {
1450
+ id: string;
1451
+ title: string;
1452
+ text: string;
1453
+ revisionId: string;
1454
+ webUrl: string;
1455
+ truncated: boolean;
1456
+ }
1457
+ export interface DocsDocumentCreateResult {
1458
+ id: string;
1459
+ webUrl: string;
1460
+ }
1461
+ /** The document and its revision after the append. */
1462
+ export interface DocsDocumentAppendResult {
1463
+ id: string;
1464
+ revisionId: string;
1465
+ }
1466
+ /** How many occurrences were replaced over all the pairs. */
1467
+ export interface DocsTextReplaceResult {
1468
+ id: string;
1469
+ replaced: number;
1470
+ }
1471
+ /** One sheet of a spreadsheet, in tab order: Google's numeric sheet id, its title and its grid size. */
1472
+ export interface SheetProperties {
1473
+ id: number;
1474
+ title: string;
1475
+ rows: number;
1476
+ columns: number;
1477
+ }
1478
+ export interface SheetsSpreadsheetReadResult {
1479
+ id: string;
1480
+ title: string;
1481
+ sheets: SheetProperties[];
1482
+ webUrl: string;
1483
+ }
1484
+ /** The range Google answered with and its cells as rows of unformatted values (a date cell is its serial number); the whole object is cut at 1 MiB by the result cap, never trimmed. */
1485
+ export interface SheetsValuesReadResult {
1486
+ range: string;
1487
+ values: SpreadsheetValues;
1488
+ }
1489
+ /** The cells the appended rows went into and how many rows were written. */
1490
+ export interface SheetsValuesAppendResult {
1491
+ range: string;
1492
+ updatedRows: number;
1493
+ }
1494
+ export interface SheetsValuesUpdateResult {
1495
+ range: string;
1496
+ updatedCells: number;
1497
+ }
1498
+ export interface SheetsValuesClearResult {
1499
+ range: string;
1500
+ }
1501
+ export interface SheetsSpreadsheetCreateResult {
1502
+ id: string;
1503
+ webUrl: string;
1504
+ }
1505
+ /** One message without its body: `preview` is Graph's bodyPreview (at most 255 characters), `from` and `to` addresses as text; `id` is the `messageId` the read, attachment read and reply take. */
1506
+ export interface OutlookMessageSummary {
1507
+ id: string;
1508
+ conversationId: string;
1509
+ subject: string;
1510
+ from: string;
1511
+ to: string;
1512
+ receivedAt: string;
1513
+ preview: string;
1514
+ hasAttachments: boolean;
1515
+ webUrl: string;
1516
+ }
1517
+ /** Named `mailMessages` apart from Slack's `messages` and Gmail's `emails`. */
1518
+ export interface OutlookMessageListResult extends WorkspacePage {
1519
+ mailMessages: OutlookMessageSummary[];
1520
+ }
1521
+ /** The `gmail.message.read` shape; `threadId` is the Graph conversationId. */
1522
+ export type OutlookMessageReadResult = GmailMessageReadResult;
1523
+ /** The Gmail attachment shape plus the attachment's id. */
1524
+ export interface OutlookAttachmentReadResult extends GmailAttachmentReadResult {
1525
+ id: string;
1526
+ }
1527
+ /** The platform's receipt for the send or reply (Graph returns no message id). */
1528
+ export interface OutlookMessageSendResult {
1529
+ id: string;
1530
+ }
1531
+ /** One worksheet, in tab order; `name` or `id` is the `worksheet` the range operations take, `position` its zero-based tab index. */
1532
+ export interface ExcelWorksheet {
1533
+ id: string;
1534
+ name: string;
1535
+ position: number;
1536
+ }
1537
+ /** One table; `name` is the `tableName` `excel.row.add` takes, `worksheet` the sheet it lives on. */
1538
+ export interface ExcelTable {
1539
+ id: string;
1540
+ name: string;
1541
+ worksheet: string;
1542
+ }
1543
+ export interface ExcelWorksheetListResult {
1544
+ worksheets: ExcelWorksheet[];
1545
+ }
1546
+ /** The range Excel answered with (e.g. `Orders!A1:D10`) and its cells as rows of unformatted values (a date cell is its text). */
1547
+ export interface ExcelRangeReadResult {
1548
+ address: string;
1549
+ values: SpreadsheetValues;
1550
+ }
1551
+ export interface ExcelRangeUpdateResult {
1552
+ address: string;
1553
+ updatedCells: number;
1554
+ }
1555
+ export interface ExcelTableListResult {
1556
+ tables: ExcelTable[];
1557
+ }
1558
+ /** The zero-based index, within the table, of the first row added, and how many rows were. */
1559
+ export interface ExcelRowAddResult {
1560
+ index: number;
1561
+ updatedRows: number;
1562
+ }
1563
+ /** The new worksheet's Graph id and name. */
1564
+ export interface ExcelWorksheetAddResult {
1565
+ id: string;
1566
+ name: string;
1567
+ }
1568
+ /** One top-level channel message: `from` the sender's display name, `text` the body as plain text with HTML stripped (cut at 16 KiB), `replyCount` when Graph reports it; `id` is the `messageId` a reply takes. */
1569
+ export interface TeamsMessage {
1570
+ id: string;
1571
+ from: string;
1572
+ text: string;
1573
+ createdAt: string;
1574
+ webUrl: string;
1575
+ replyCount?: number;
1576
+ }
1577
+ /** Named `teamsMessages` apart from Slack's `messages`. */
1578
+ export interface TeamsMessageListResult extends WorkspacePage {
1579
+ teamsMessages: TeamsMessage[];
1580
+ }
1581
+ /** The posted message or reply and its Teams page. */
1582
+ export interface TeamsMessagePostResult {
1583
+ id: string;
1584
+ webUrl: string;
1585
+ }
1586
+ export type IntegrationResult<R extends IntegrationRequest> = R extends ServiceRequest ? ServiceRequestResult : R extends SlackChannelHistoryRequest ? SlackChannelHistoryResult : R extends SlackMessagePostRequest | SlackMessageUpdateRequest | SlackMessageDeleteRequest ? SlackMessagePostResult : R extends SlackDmSendRequest ? SlackDmSendResult : R extends SlackUserLookupRequest ? SlackUserLookupResult : R extends WarehouseViewReadRequest ? WarehouseViewReadResult : R extends WarehouseTableAppendRequest ? WarehouseTableAppendResult : R extends PhoneSmsListRequest ? PhoneSmsListResult : R extends PhoneNumberGetRequest ? PhoneNumberGetResult : R extends GmailThreadListRequest ? GmailThreadListResult : R extends GmailThreadReadRequest ? GmailThreadReadResult : R extends GmailMessageReadRequest ? GmailMessageReadResult : R extends GmailAttachmentReadRequest ? GmailAttachmentReadResult : R extends GmailMessageSendRequest ? GmailMessageSendResult : R extends BasecampProjectListRequest ? BasecampProjectListResult : R extends BasecampTodolistListRequest ? BasecampTodolistListResult : R extends BasecampTodoListRequest ? BasecampTodoListResult : R extends BasecampMessageListRequest ? BasecampMessageListResult : R extends BasecampCommentListRequest ? BasecampCommentListResult : R extends BasecampPeopleListRequest ? BasecampPeopleListResult : R extends BasecampTodoCreateRequest | BasecampMessagePostRequest | BasecampCommentPostRequest | BasecampCampfirePostRequest ? BasecampRecordingResult : R extends BasecampTodoCompleteRequest ? BasecampTodoCompleteResult : R extends SharePointListListRequest ? SharePointListListResult : R extends SharePointItemListRequest ? SharePointItemListResult : R extends SharePointItemCreateRequest ? SharePointItemCreateResult : R extends SharePointItemUpdateRequest ? SharePointItemUpdateResult : R extends SharePointDriveListRequest ? SharePointDriveListResult : R extends SharePointFileListRequest | SharePointFileSearchRequest ? SharePointFileListResult : R extends SharePointFileReadRequest ? SharePointFileReadResult : R extends SharePointFileUploadRequest ? SharePointFileUploadResult : R extends CalendarCalendarListRequest ? CalendarCalendarListResult : R extends CalendarEventListRequest | OutlookEventListRequest ? CalendarEventListResult : R extends CalendarEventReadRequest | OutlookEventReadRequest ? CalendarEventReadResult : R extends CalendarEventCreateRequest | OutlookEventCreateRequest ? CalendarEventCreateResult : R extends CalendarEventUpdateRequest | CalendarEventCancelRequest | OutlookEventUpdateRequest | OutlookEventCancelRequest ? CalendarEventUpdateResult : R extends DriveFileListRequest | DriveFileSearchRequest | OneDriveFileListRequest | OneDriveFileSearchRequest ? DriveFileListResult : R extends DriveFileReadRequest | OneDriveFileReadRequest ? DriveFileReadResult : R extends DriveFileUploadRequest | OneDriveFileUploadRequest ? DriveFileUploadResult : R extends DriveFolderCreateRequest | OneDriveFolderCreateRequest ? DriveFolderCreateResult : R extends DocsDocumentReadRequest ? DocsDocumentReadResult : R extends DocsDocumentCreateRequest ? DocsDocumentCreateResult : R extends DocsDocumentAppendRequest ? DocsDocumentAppendResult : R extends DocsTextReplaceRequest ? DocsTextReplaceResult : R extends SheetsSpreadsheetReadRequest ? SheetsSpreadsheetReadResult : R extends SheetsValuesReadRequest ? SheetsValuesReadResult : R extends SheetsValuesAppendRequest ? SheetsValuesAppendResult : R extends SheetsValuesUpdateRequest ? SheetsValuesUpdateResult : R extends SheetsValuesClearRequest ? SheetsValuesClearResult : R extends SheetsSpreadsheetCreateRequest ? SheetsSpreadsheetCreateResult : R extends OutlookMessageListRequest ? OutlookMessageListResult : R extends OutlookMessageReadRequest ? OutlookMessageReadResult : R extends OutlookAttachmentReadRequest ? OutlookAttachmentReadResult : R extends OutlookMessageSendRequest | OutlookMessageReplyRequest ? OutlookMessageSendResult : R extends ExcelWorksheetListRequest ? ExcelWorksheetListResult : R extends ExcelRangeReadRequest ? ExcelRangeReadResult : R extends ExcelRangeUpdateRequest ? ExcelRangeUpdateResult : R extends ExcelTableListRequest ? ExcelTableListResult : R extends ExcelRowAddRequest ? ExcelRowAddResult : R extends ExcelWorksheetAddRequest ? ExcelWorksheetAddResult : R extends TeamsMessageListRequest ? TeamsMessageListResult : R extends TeamsMessagePostRequest | TeamsReplyPostRequest ? TeamsMessagePostResult : never;
821
1587
  export type IntegrationConnectResult = {
822
1588
  status: 'connected';
823
1589
  accountLabel: string;