@divyacon/piece-google-docs 0.0.0-stage → 0.1.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 (243) hide show
  1. package/LICENSE.MIT-AP +24 -0
  2. package/dist/index.d.ts +6 -0
  3. package/dist/index.d.ts.map +1 -0
  4. package/dist/index.js +128 -0
  5. package/dist/index.js.map +1 -0
  6. package/dist/lib/actions/append-text.d.ts +8 -0
  7. package/dist/lib/actions/append-text.d.ts.map +1 -0
  8. package/dist/lib/actions/append-text.js +40 -0
  9. package/dist/lib/actions/append-text.js.map +1 -0
  10. package/dist/lib/actions/batch-update.action.d.ts +8 -0
  11. package/dist/lib/actions/batch-update.action.d.ts.map +1 -0
  12. package/dist/lib/actions/batch-update.action.js +63 -0
  13. package/dist/lib/actions/batch-update.action.js.map +1 -0
  14. package/dist/lib/actions/copy-document.action.d.ts +12 -0
  15. package/dist/lib/actions/copy-document.action.d.ts.map +1 -0
  16. package/dist/lib/actions/copy-document.action.js +72 -0
  17. package/dist/lib/actions/copy-document.action.js.map +1 -0
  18. package/dist/lib/actions/create-and-populate-table.action.d.ts +8 -0
  19. package/dist/lib/actions/create-and-populate-table.action.d.ts.map +1 -0
  20. package/dist/lib/actions/create-and-populate-table.action.js +138 -0
  21. package/dist/lib/actions/create-and-populate-table.action.js.map +1 -0
  22. package/dist/lib/actions/create-document-based-on-template.action.d.ts +10 -0
  23. package/dist/lib/actions/create-document-based-on-template.action.d.ts.map +1 -0
  24. package/dist/lib/actions/create-document-based-on-template.action.js +107 -0
  25. package/dist/lib/actions/create-document-based-on-template.action.js.map +1 -0
  26. package/dist/lib/actions/create-document-from-markdown.action.d.ts +8 -0
  27. package/dist/lib/actions/create-document-from-markdown.action.d.ts.map +1 -0
  28. package/dist/lib/actions/create-document-from-markdown.action.js +69 -0
  29. package/dist/lib/actions/create-document-from-markdown.action.js.map +1 -0
  30. package/dist/lib/actions/create-document.d.ts +8 -0
  31. package/dist/lib/actions/create-document.d.ts.map +1 -0
  32. package/dist/lib/actions/create-document.js +35 -0
  33. package/dist/lib/actions/create-document.js.map +1 -0
  34. package/dist/lib/actions/create-footer.action.d.ts +8 -0
  35. package/dist/lib/actions/create-footer.action.d.ts.map +1 -0
  36. package/dist/lib/actions/create-footer.action.js +66 -0
  37. package/dist/lib/actions/create-footer.action.js.map +1 -0
  38. package/dist/lib/actions/create-footnote.action.d.ts +8 -0
  39. package/dist/lib/actions/create-footnote.action.d.ts.map +1 -0
  40. package/dist/lib/actions/create-footnote.action.js +58 -0
  41. package/dist/lib/actions/create-footnote.action.js.map +1 -0
  42. package/dist/lib/actions/create-header.action.d.ts +8 -0
  43. package/dist/lib/actions/create-header.action.d.ts.map +1 -0
  44. package/dist/lib/actions/create-header.action.js +66 -0
  45. package/dist/lib/actions/create-header.action.js.map +1 -0
  46. package/dist/lib/actions/create-named-range.action.d.ts +10 -0
  47. package/dist/lib/actions/create-named-range.action.d.ts.map +1 -0
  48. package/dist/lib/actions/create-named-range.action.js +74 -0
  49. package/dist/lib/actions/create-named-range.action.js.map +1 -0
  50. package/dist/lib/actions/create-paragraph-bullets.action.d.ts +10 -0
  51. package/dist/lib/actions/create-paragraph-bullets.action.d.ts.map +1 -0
  52. package/dist/lib/actions/create-paragraph-bullets.action.js +98 -0
  53. package/dist/lib/actions/create-paragraph-bullets.action.js.map +1 -0
  54. package/dist/lib/actions/create-text-document.action.d.ts +8 -0
  55. package/dist/lib/actions/create-text-document.action.d.ts.map +1 -0
  56. package/dist/lib/actions/create-text-document.action.js +42 -0
  57. package/dist/lib/actions/create-text-document.action.js.map +1 -0
  58. package/dist/lib/actions/delete-content-range.action.d.ts +9 -0
  59. package/dist/lib/actions/delete-content-range.action.d.ts.map +1 -0
  60. package/dist/lib/actions/delete-content-range.action.js +64 -0
  61. package/dist/lib/actions/delete-content-range.action.js.map +1 -0
  62. package/dist/lib/actions/delete-footer.action.d.ts +8 -0
  63. package/dist/lib/actions/delete-footer.action.d.ts.map +1 -0
  64. package/dist/lib/actions/delete-footer.action.js +56 -0
  65. package/dist/lib/actions/delete-footer.action.js.map +1 -0
  66. package/dist/lib/actions/delete-header.action.d.ts +8 -0
  67. package/dist/lib/actions/delete-header.action.d.ts.map +1 -0
  68. package/dist/lib/actions/delete-header.action.js +56 -0
  69. package/dist/lib/actions/delete-header.action.js.map +1 -0
  70. package/dist/lib/actions/delete-named-range.action.d.ts +9 -0
  71. package/dist/lib/actions/delete-named-range.action.d.ts.map +1 -0
  72. package/dist/lib/actions/delete-named-range.action.js +69 -0
  73. package/dist/lib/actions/delete-named-range.action.js.map +1 -0
  74. package/dist/lib/actions/delete-paragraph-bullets.action.d.ts +9 -0
  75. package/dist/lib/actions/delete-paragraph-bullets.action.d.ts.map +1 -0
  76. package/dist/lib/actions/delete-paragraph-bullets.action.js +66 -0
  77. package/dist/lib/actions/delete-paragraph-bullets.action.js.map +1 -0
  78. package/dist/lib/actions/delete-table-column.action.d.ts +10 -0
  79. package/dist/lib/actions/delete-table-column.action.d.ts.map +1 -0
  80. package/dist/lib/actions/delete-table-column.action.js +72 -0
  81. package/dist/lib/actions/delete-table-column.action.js.map +1 -0
  82. package/dist/lib/actions/delete-table-row.action.d.ts +10 -0
  83. package/dist/lib/actions/delete-table-row.action.d.ts.map +1 -0
  84. package/dist/lib/actions/delete-table-row.action.js +72 -0
  85. package/dist/lib/actions/delete-table-row.action.js.map +1 -0
  86. package/dist/lib/actions/export-as-pdf.action.d.ts +7 -0
  87. package/dist/lib/actions/export-as-pdf.action.d.ts.map +1 -0
  88. package/dist/lib/actions/export-as-pdf.action.js +61 -0
  89. package/dist/lib/actions/export-as-pdf.action.js.map +1 -0
  90. package/dist/lib/actions/find-document.d.ts +16 -0
  91. package/dist/lib/actions/find-document.d.ts.map +1 -0
  92. package/dist/lib/actions/find-document.js +127 -0
  93. package/dist/lib/actions/find-document.js.map +1 -0
  94. package/dist/lib/actions/get-document-end-index.action.d.ts +7 -0
  95. package/dist/lib/actions/get-document-end-index.action.d.ts.map +1 -0
  96. package/dist/lib/actions/get-document-end-index.action.js +54 -0
  97. package/dist/lib/actions/get-document-end-index.action.js.map +1 -0
  98. package/dist/lib/actions/get-document-plaintext.action.d.ts +7 -0
  99. package/dist/lib/actions/get-document-plaintext.action.d.ts.map +1 -0
  100. package/dist/lib/actions/get-document-plaintext.action.js +76 -0
  101. package/dist/lib/actions/get-document-plaintext.action.js.map +1 -0
  102. package/dist/lib/actions/get-document.action.d.ts +7 -0
  103. package/dist/lib/actions/get-document.action.d.ts.map +1 -0
  104. package/dist/lib/actions/get-document.action.js +45 -0
  105. package/dist/lib/actions/get-document.action.js.map +1 -0
  106. package/dist/lib/actions/insert-image-in-table-cell.action.d.ts +13 -0
  107. package/dist/lib/actions/insert-image-in-table-cell.action.d.ts.map +1 -0
  108. package/dist/lib/actions/insert-image-in-table-cell.action.js +128 -0
  109. package/dist/lib/actions/insert-image-in-table-cell.action.js.map +1 -0
  110. package/dist/lib/actions/insert-inline-image.action.d.ts +11 -0
  111. package/dist/lib/actions/insert-inline-image.action.d.ts.map +1 -0
  112. package/dist/lib/actions/insert-inline-image.action.js +84 -0
  113. package/dist/lib/actions/insert-inline-image.action.js.map +1 -0
  114. package/dist/lib/actions/insert-page-break.action.d.ts +8 -0
  115. package/dist/lib/actions/insert-page-break.action.d.ts.map +1 -0
  116. package/dist/lib/actions/insert-page-break.action.js +60 -0
  117. package/dist/lib/actions/insert-page-break.action.js.map +1 -0
  118. package/dist/lib/actions/insert-table-column.action.d.ts +11 -0
  119. package/dist/lib/actions/insert-table-column.action.d.ts.map +1 -0
  120. package/dist/lib/actions/insert-table-column.action.js +86 -0
  121. package/dist/lib/actions/insert-table-column.action.js.map +1 -0
  122. package/dist/lib/actions/insert-table-row.action.d.ts +11 -0
  123. package/dist/lib/actions/insert-table-row.action.d.ts.map +1 -0
  124. package/dist/lib/actions/insert-table-row.action.js +86 -0
  125. package/dist/lib/actions/insert-table-row.action.js.map +1 -0
  126. package/dist/lib/actions/insert-table.action.d.ts +10 -0
  127. package/dist/lib/actions/insert-table.action.d.ts.map +1 -0
  128. package/dist/lib/actions/insert-table.action.js +72 -0
  129. package/dist/lib/actions/insert-table.action.js.map +1 -0
  130. package/dist/lib/actions/insert-text-in-table-cell.action.d.ts +11 -0
  131. package/dist/lib/actions/insert-text-in-table-cell.action.d.ts.map +1 -0
  132. package/dist/lib/actions/insert-text-in-table-cell.action.js +115 -0
  133. package/dist/lib/actions/insert-text-in-table-cell.action.js.map +1 -0
  134. package/dist/lib/actions/insert-text.action.d.ts +9 -0
  135. package/dist/lib/actions/insert-text.action.d.ts.map +1 -0
  136. package/dist/lib/actions/insert-text.action.js +66 -0
  137. package/dist/lib/actions/insert-text.action.js.map +1 -0
  138. package/dist/lib/actions/read-document.action.d.ts +7 -0
  139. package/dist/lib/actions/read-document.action.d.ts.map +1 -0
  140. package/dist/lib/actions/read-document.action.js +44 -0
  141. package/dist/lib/actions/read-document.action.js.map +1 -0
  142. package/dist/lib/actions/replace-all-text.action.d.ts +10 -0
  143. package/dist/lib/actions/replace-all-text.action.d.ts.map +1 -0
  144. package/dist/lib/actions/replace-all-text.action.js +92 -0
  145. package/dist/lib/actions/replace-all-text.action.js.map +1 -0
  146. package/dist/lib/actions/replace-body-with-markdown.action.d.ts +8 -0
  147. package/dist/lib/actions/replace-body-with-markdown.action.d.ts.map +1 -0
  148. package/dist/lib/actions/replace-body-with-markdown.action.js +79 -0
  149. package/dist/lib/actions/replace-body-with-markdown.action.js.map +1 -0
  150. package/dist/lib/actions/replace-image.action.d.ts +9 -0
  151. package/dist/lib/actions/replace-image.action.d.ts.map +1 -0
  152. package/dist/lib/actions/replace-image.action.js +65 -0
  153. package/dist/lib/actions/replace-image.action.js.map +1 -0
  154. package/dist/lib/actions/replace-section-with-markdown.action.d.ts +10 -0
  155. package/dist/lib/actions/replace-section-with-markdown.action.d.ts.map +1 -0
  156. package/dist/lib/actions/replace-section-with-markdown.action.js +106 -0
  157. package/dist/lib/actions/replace-section-with-markdown.action.js.map +1 -0
  158. package/dist/lib/actions/search-documents.action.d.ts +11 -0
  159. package/dist/lib/actions/search-documents.action.d.ts.map +1 -0
  160. package/dist/lib/actions/search-documents.action.js +121 -0
  161. package/dist/lib/actions/search-documents.action.js.map +1 -0
  162. package/dist/lib/actions/unmerge-table-cells.action.d.ts +12 -0
  163. package/dist/lib/actions/unmerge-table-cells.action.d.ts.map +1 -0
  164. package/dist/lib/actions/unmerge-table-cells.action.js +94 -0
  165. package/dist/lib/actions/unmerge-table-cells.action.js.map +1 -0
  166. package/dist/lib/actions/update-document-style.action.d.ts +11 -0
  167. package/dist/lib/actions/update-document-style.action.d.ts.map +1 -0
  168. package/dist/lib/actions/update-document-style.action.js +95 -0
  169. package/dist/lib/actions/update-document-style.action.js.map +1 -0
  170. package/dist/lib/actions/update-table-row-style.action.d.ts +10 -0
  171. package/dist/lib/actions/update-table-row-style.action.d.ts.map +1 -0
  172. package/dist/lib/actions/update-table-row-style.action.js +78 -0
  173. package/dist/lib/actions/update-table-row-style.action.js.map +1 -0
  174. package/dist/lib/auth.d.ts +11 -0
  175. package/dist/lib/auth.d.ts.map +1 -0
  176. package/dist/lib/auth.js +92 -0
  177. package/dist/lib/auth.js.map +1 -0
  178. package/dist/lib/common/index.d.ts +11 -0
  179. package/dist/lib/common/index.d.ts.map +1 -0
  180. package/dist/lib/common/index.js +124 -0
  181. package/dist/lib/common/index.js.map +1 -0
  182. package/dist/lib/common/props.d.ts +5 -0
  183. package/dist/lib/common/props.d.ts.map +1 -0
  184. package/dist/lib/common/props.js +53 -0
  185. package/dist/lib/common/props.js.map +1 -0
  186. package/dist/lib/output-schemas.d.ts +43 -0
  187. package/dist/lib/output-schemas.d.ts.map +1 -0
  188. package/dist/lib/output-schemas.js +554 -0
  189. package/dist/lib/output-schemas.js.map +1 -0
  190. package/dist/lib/triggers/new-document.d.ts +35 -0
  191. package/dist/lib/triggers/new-document.d.ts.map +1 -0
  192. package/dist/lib/triggers/new-document.js +104 -0
  193. package/dist/lib/triggers/new-document.js.map +1 -0
  194. package/package.json +47 -3
  195. package/src/index.ts +120 -0
  196. package/src/lib/actions/append-text.ts +37 -0
  197. package/src/lib/actions/batch-update.action.ts +58 -0
  198. package/src/lib/actions/copy-document.action.ts +74 -0
  199. package/src/lib/actions/create-and-populate-table.action.ts +141 -0
  200. package/src/lib/actions/create-document-based-on-template.action.ts +110 -0
  201. package/src/lib/actions/create-document-from-markdown.action.ts +63 -0
  202. package/src/lib/actions/create-document.ts +36 -0
  203. package/src/lib/actions/create-footer.action.ts +59 -0
  204. package/src/lib/actions/create-footnote.action.ts +53 -0
  205. package/src/lib/actions/create-header.action.ts +59 -0
  206. package/src/lib/actions/create-named-range.action.ts +70 -0
  207. package/src/lib/actions/create-paragraph-bullets.action.ts +95 -0
  208. package/src/lib/actions/create-text-document.action.ts +35 -0
  209. package/src/lib/actions/delete-content-range.action.ts +59 -0
  210. package/src/lib/actions/delete-footer.action.ts +51 -0
  211. package/src/lib/actions/delete-header.action.ts +51 -0
  212. package/src/lib/actions/delete-named-range.action.ts +65 -0
  213. package/src/lib/actions/delete-paragraph-bullets.action.ts +62 -0
  214. package/src/lib/actions/delete-table-column.action.ts +67 -0
  215. package/src/lib/actions/delete-table-row.action.ts +67 -0
  216. package/src/lib/actions/export-as-pdf.action.ts +59 -0
  217. package/src/lib/actions/find-document.ts +136 -0
  218. package/src/lib/actions/get-document-end-index.action.ts +47 -0
  219. package/src/lib/actions/get-document-plaintext.action.ts +74 -0
  220. package/src/lib/actions/get-document.action.ts +37 -0
  221. package/src/lib/actions/insert-image-in-table-cell.action.ts +139 -0
  222. package/src/lib/actions/insert-inline-image.action.ts +83 -0
  223. package/src/lib/actions/insert-page-break.action.ts +56 -0
  224. package/src/lib/actions/insert-table-column.action.ts +80 -0
  225. package/src/lib/actions/insert-table-row.action.ts +80 -0
  226. package/src/lib/actions/insert-table.action.ts +68 -0
  227. package/src/lib/actions/insert-text-in-table-cell.action.ts +120 -0
  228. package/src/lib/actions/insert-text.action.ts +62 -0
  229. package/src/lib/actions/read-document.action.ts +40 -0
  230. package/src/lib/actions/replace-all-text.action.ts +95 -0
  231. package/src/lib/actions/replace-body-with-markdown.action.ts +76 -0
  232. package/src/lib/actions/replace-image.action.ts +60 -0
  233. package/src/lib/actions/replace-section-with-markdown.action.ts +104 -0
  234. package/src/lib/actions/search-documents.action.ts +131 -0
  235. package/src/lib/actions/unmerge-table-cells.action.ts +88 -0
  236. package/src/lib/actions/update-document-style.action.ts +93 -0
  237. package/src/lib/actions/update-table-row-style.action.ts +73 -0
  238. package/src/lib/auth.ts +84 -0
  239. package/src/lib/common/index.ts +126 -0
  240. package/src/lib/common/props.ts +55 -0
  241. package/src/lib/output-schemas.ts +593 -0
  242. package/src/lib/triggers/new-document.ts +108 -0
  243. package/README.md +0 -3
@@ -0,0 +1,72 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.deleteTableColumn = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/google-docs/src/lib/actions/delete-table-column.action.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const auth_1 = require("../auth");
8
+ const common_1 = require("../common");
9
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
10
+ const docs_1 = require("@googleapis/docs");
11
+ const output_schemas_1 = require("../output-schemas");
12
+ exports.deleteTableColumn = (0, pieces_framework_1.createAction)({
13
+ auth: auth_1.googleDocsAuth,
14
+ name: 'delete_table_column',
15
+ displayName: 'Delete Table Column',
16
+ description: 'Delete a column from a table in a Google Docs document',
17
+ audience: 'ai',
18
+ aiMetadata: {
19
+ description: 'Permanently deletes a column from a table in a Google Docs document. The column to delete is addressed by the table\'s start index plus the row and column coordinates of any cell in that column. All three index values (tableStartIndex, rowIndex, columnIndex) must be obtained from Read Document (gdocs_get_document) — they cannot be guessed. Destructive and not idempotent: all content in the column is permanently removed.',
20
+ idempotent: false,
21
+ },
22
+ outputSchema: output_schemas_1.deleteTableColumnActionOutputSchema,
23
+ props: {
24
+ documentId: pieces_framework_1.Property.ShortText({
25
+ displayName: 'Document ID',
26
+ description: 'The ID of the document to edit.',
27
+ required: true,
28
+ }),
29
+ tableStartIndex: pieces_framework_1.Property.Number({
30
+ displayName: 'Table Start Index',
31
+ description: 'The character index of the start of the table in the document body. Obtain from Read Document (gdocs_get_document) — cannot be guessed.',
32
+ required: true,
33
+ }),
34
+ rowIndex: pieces_framework_1.Property.Number({
35
+ displayName: 'Row Index',
36
+ description: 'Zero-based row index of any cell in the column to delete. Obtain from Read Document (gdocs_get_document).',
37
+ required: true,
38
+ }),
39
+ columnIndex: pieces_framework_1.Property.Number({
40
+ displayName: 'Column Index',
41
+ description: 'Zero-based column index of the column to delete. Obtain from Read Document (gdocs_get_document).',
42
+ required: true,
43
+ }),
44
+ },
45
+ run(context) {
46
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
47
+ const { documentId, tableStartIndex, rowIndex, columnIndex } = context.propsValue;
48
+ const authClient = yield (0, auth_1.createGoogleClient)(context.auth);
49
+ const docs = (0, docs_1.docs)({ version: 'v1', auth: authClient });
50
+ const request = {
51
+ deleteTableColumn: {
52
+ tableCellLocation: {
53
+ tableStartLocation: { index: tableStartIndex },
54
+ rowIndex,
55
+ columnIndex,
56
+ },
57
+ },
58
+ };
59
+ try {
60
+ yield docs.documents.batchUpdate({
61
+ documentId,
62
+ requestBody: { requests: [request] },
63
+ });
64
+ return { success: true, documentId, tableStartIndex, deletedColumnIndex: columnIndex };
65
+ }
66
+ catch (error) {
67
+ throw new Error(common_1.docsCommon.formatError(error, 'delete the table column from'));
68
+ }
69
+ });
70
+ },
71
+ });
72
+ //# sourceMappingURL=delete-table-column.action.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"delete-table-column.action.js","sourceRoot":"","sources":["../../../src/lib/actions/delete-table-column.action.ts"],"names":[],"mappings":";;;;AAAA,wHAAwH;AACxH,qEAAqE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AAO,GAA2B;gBACtC,iBAAiB,EAAE;oBACjB,iBAAiB,EAAE;wBACjB,kBAAkB,EAAE,EAAE,KAAK,EAAE,eAAe,EAAE;wBAC9C,QAAQ;wBACR,WAAW;qBACZ;iBACF;aACF,CAAC;YAEF,IAAI,CAAC;gBACH,MAAM,IAAI,CAAC,SAAS,CAAC,WAAW,CAAC;oBAC/B,UAAU;oBACV,WAAW,EAAE,EAAE,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE;iBACrC,CAAC,CAAC;gBACH,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,eAAe,EAAE,kBAAkB,EAAE,WAAW,EAAE,CAAC;YACzF,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBACf,MAAM,IAAI,KAAK,CAAC,mBAAU,CAAC,WAAW,CAAC,KAAK,EAAE,8BAA8B,CAAC,CAAC,CAAC;YACjF,CAAC;QACH,CAAC;KAAA;CACF,CAAC,CAAC"}
@@ -0,0 +1,10 @@
1
+ export declare const deleteTableRow: import("@agnocon/pieces-framework").IAction<(import("@agnocon/pieces-framework").OAuth2Property<import("@agnocon/pieces-framework").OAuth2Props> | import("@agnocon/pieces-framework").CustomAuthProperty<{
2
+ serviceAccount: import("@agnocon/pieces-framework").LongTextProperty<true>;
3
+ userEmail: import("@agnocon/pieces-framework").ShortTextProperty<false>;
4
+ }>)[], {
5
+ documentId: import("@agnocon/pieces-framework").ShortTextProperty<true>;
6
+ tableStartIndex: import("@agnocon/pieces-framework").NumberProperty<true>;
7
+ rowIndex: import("@agnocon/pieces-framework").NumberProperty<true>;
8
+ columnIndex: import("@agnocon/pieces-framework").NumberProperty<true>;
9
+ }>;
10
+ //# sourceMappingURL=delete-table-row.action.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"delete-table-row.action.d.ts","sourceRoot":"","sources":["../../../src/lib/actions/delete-table-row.action.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,cAAc;;;;;;;;EA4DzB,CAAC"}
@@ -0,0 +1,72 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.deleteTableRow = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/google-docs/src/lib/actions/delete-table-row.action.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const auth_1 = require("../auth");
8
+ const common_1 = require("../common");
9
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
10
+ const docs_1 = require("@googleapis/docs");
11
+ const output_schemas_1 = require("../output-schemas");
12
+ exports.deleteTableRow = (0, pieces_framework_1.createAction)({
13
+ auth: auth_1.googleDocsAuth,
14
+ name: 'delete_table_row',
15
+ displayName: 'Delete Table Row',
16
+ description: 'Delete a row from a table in a Google Docs document',
17
+ audience: 'ai',
18
+ aiMetadata: {
19
+ description: 'Permanently deletes a row from a table in a Google Docs document. The row to delete is addressed by the table\'s start index plus the row and column coordinates of any cell in that row. All three index values (tableStartIndex, rowIndex, columnIndex) must be obtained from Read Document (gdocs_get_document) — they cannot be guessed. Destructive and not idempotent: all content in the row is permanently removed.',
20
+ idempotent: false,
21
+ },
22
+ outputSchema: output_schemas_1.deleteTableRowActionOutputSchema,
23
+ props: {
24
+ documentId: pieces_framework_1.Property.ShortText({
25
+ displayName: 'Document ID',
26
+ description: 'The ID of the document to edit.',
27
+ required: true,
28
+ }),
29
+ tableStartIndex: pieces_framework_1.Property.Number({
30
+ displayName: 'Table Start Index',
31
+ description: 'The character index of the start of the table in the document body. Obtain from Read Document (gdocs_get_document) — cannot be guessed.',
32
+ required: true,
33
+ }),
34
+ rowIndex: pieces_framework_1.Property.Number({
35
+ displayName: 'Row Index',
36
+ description: 'Zero-based row index of the row to delete. Obtain from Read Document (gdocs_get_document).',
37
+ required: true,
38
+ }),
39
+ columnIndex: pieces_framework_1.Property.Number({
40
+ displayName: 'Column Index',
41
+ description: 'Zero-based column index of any cell in the row to delete. Obtain from Read Document (gdocs_get_document).',
42
+ required: true,
43
+ }),
44
+ },
45
+ run(context) {
46
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
47
+ const { documentId, tableStartIndex, rowIndex, columnIndex } = context.propsValue;
48
+ const authClient = yield (0, auth_1.createGoogleClient)(context.auth);
49
+ const docs = (0, docs_1.docs)({ version: 'v1', auth: authClient });
50
+ const request = {
51
+ deleteTableRow: {
52
+ tableCellLocation: {
53
+ tableStartLocation: { index: tableStartIndex },
54
+ rowIndex,
55
+ columnIndex,
56
+ },
57
+ },
58
+ };
59
+ try {
60
+ yield docs.documents.batchUpdate({
61
+ documentId,
62
+ requestBody: { requests: [request] },
63
+ });
64
+ return { success: true, documentId, tableStartIndex, deletedRowIndex: rowIndex };
65
+ }
66
+ catch (error) {
67
+ throw new Error(common_1.docsCommon.formatError(error, 'delete the table row from'));
68
+ }
69
+ });
70
+ },
71
+ });
72
+ //# sourceMappingURL=delete-table-row.action.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"delete-table-row.action.js","sourceRoot":"","sources":["../../../src/lib/actions/delete-table-row.action.ts"],"names":[],"mappings":";;;;AAAA,qHAAqH;AACrH,qEAAqE;AACrE,kCAA6D;AAC7D,sCAAuC;AACvC,gEAAmE;AACnE,2CAA+D;AAC/D,sDAAqE;AAExD,QAAA,cAAc,GAAG,IAAA,+BAAY,EAAC;IACzC,IAAI,EAAE,qBAAc;IACpB,IAAI,EAAE,kBAAkB;IACxB,WAAW,EAAE,kBAAkB;IAC/B,WAAW,EAAE,qDAAqD;IAClE,QAAQ,EAAE,IAAI;IACd,UAAU,EAAE;QACV,WAAW,EACT,6ZAA6Z;QAC/Z,UAAU,EAAE,KAAK;KAClB;IACD,YAAY,EAAE,iDAAgC;IAC9C,KAAK,EAAE;QACL,UAAU,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC7B,WAAW,EAAE,aAAa;YAC1B,WAAW,EAAE,iCAAiC;YAC9C,QAAQ,EAAE,IAAI;SACf,CAAC;QACF,eAAe,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K,EAAE,2BAA2B,CAAC,CAAC,CAAC;YAC9E,CAAC;QACH,CAAC;KAAA;CACF,CAAC,CAAC"}
@@ -0,0 +1,7 @@
1
+ export declare const exportAsPdf: import("@agnocon/pieces-framework").IAction<(import("@agnocon/pieces-framework").OAuth2Property<import("@agnocon/pieces-framework").OAuth2Props> | import("@agnocon/pieces-framework").CustomAuthProperty<{
2
+ serviceAccount: import("@agnocon/pieces-framework").LongTextProperty<true>;
3
+ userEmail: import("@agnocon/pieces-framework").ShortTextProperty<false>;
4
+ }>)[], {
5
+ documentId: import("@agnocon/pieces-framework").ShortTextProperty<true>;
6
+ }>;
7
+ //# sourceMappingURL=export-as-pdf.action.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"export-as-pdf.action.d.ts","sourceRoot":"","sources":["../../../src/lib/actions/export-as-pdf.action.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,WAAW;;;;;EAmDtB,CAAC"}
@@ -0,0 +1,61 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.exportAsPdf = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/google-docs/src/lib/actions/export-as-pdf.action.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const auth_1 = require("../auth");
8
+ const common_1 = require("../common");
9
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
10
+ const drive_1 = require("@googleapis/drive");
11
+ const docs_1 = require("@googleapis/docs");
12
+ const output_schemas_1 = require("../output-schemas");
13
+ exports.exportAsPdf = (0, pieces_framework_1.createAction)({
14
+ auth: auth_1.googleDocsAuth,
15
+ name: 'export_as_pdf',
16
+ displayName: 'Export as PDF',
17
+ description: 'Export a Google Docs document as a PDF file.',
18
+ audience: 'ai',
19
+ aiMetadata: {
20
+ description: 'Exports a Google Docs document as a PDF and returns the file for use in later steps (e.g. sending via email or uploading to storage). Uses the Drive export endpoint, so the document must not exceed the Drive 10 MB export limit. Read-only and idempotent — it never modifies the document.',
21
+ idempotent: true,
22
+ },
23
+ outputSchema: output_schemas_1.exportAsPdfActionOutputSchema,
24
+ props: {
25
+ documentId: pieces_framework_1.Property.ShortText({
26
+ displayName: 'Document ID',
27
+ description: 'The ID of the document to export as PDF.',
28
+ required: true,
29
+ }),
30
+ },
31
+ run(context) {
32
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
33
+ var _a;
34
+ const { documentId } = context.propsValue;
35
+ const authClient = yield (0, auth_1.createGoogleClient)(context.auth);
36
+ // Fetch document title for the file name
37
+ const docs = (0, docs_1.docs)({ version: 'v1', auth: authClient });
38
+ let title = documentId;
39
+ try {
40
+ const docResponse = yield docs.documents.get({ documentId, fields: 'title' });
41
+ title = (_a = docResponse.data.title) !== null && _a !== void 0 ? _a : documentId;
42
+ }
43
+ catch (_b) {
44
+ // Fall back to documentId as the file name if the title fetch fails
45
+ }
46
+ const drive = (0, drive_1.drive)({ version: 'v3', auth: authClient });
47
+ try {
48
+ const response = yield drive.files.export({ fileId: documentId, mimeType: 'application/pdf' }, { responseType: 'arraybuffer' });
49
+ const file = yield context.files.write({
50
+ fileName: `${title}.pdf`,
51
+ data: Buffer.from(response.data),
52
+ });
53
+ return { success: true, documentId, file };
54
+ }
55
+ catch (error) {
56
+ throw new Error(common_1.docsCommon.formatError(error, 'export'));
57
+ }
58
+ });
59
+ },
60
+ });
61
+ //# sourceMappingURL=export-as-pdf.action.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"export-as-pdf.action.js","sourceRoot":"","sources":["../../../src/lib/actions/export-as-pdf.action.ts"],"names":[],"mappings":";;;;AAAA,kHAAkH;AAClH,qEAAqE;AACrE,kCAA6D;AAC7D,sCAAuC;AACvC,gEAAmE;AACnE,6CAAyD;AACzD,2CAAsD;AACtD,sDAAkE;AAErD,QAAA,WAAW,GAAG,IAAA,+BAAY,EAAC;IACvC,IAAI,EAAE,qBAAc;IACpB,IAAI,EAAE,eAAe;IACrB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AEF,MAAM,IAAI,GAAG,MAAM,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC;oBACtC,QAAQ,EAAE,GAAG,KAAK,MAAM;oBACxB,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAmB,CAAC;iBAC/C,CAAC,CAAC;gBAEH,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAE,CAAC;YAC5C,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBAChB,MAAM,IAAI,KAAK,CAAC,mBAAU,CAAC,WAAW,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC;YAC1D,CAAC;QACF,CAAC;KAAA;CACD,CAAC,CAAC"}
@@ -0,0 +1,16 @@
1
+ export declare const findDocumentAction: import("@agnocon/pieces-framework").IAction<(import("@agnocon/pieces-framework").OAuth2Property<import("@agnocon/pieces-framework").OAuth2Props> | import("@agnocon/pieces-framework").CustomAuthProperty<{
2
+ serviceAccount: import("@agnocon/pieces-framework").LongTextProperty<true>;
3
+ userEmail: import("@agnocon/pieces-framework").ShortTextProperty<false>;
4
+ }>)[], {
5
+ name: import("@agnocon/pieces-framework").ShortTextProperty<true>;
6
+ folderId: import("@agnocon/pieces-framework").DropdownProperty<string, false, (import("@agnocon/pieces-framework").OAuth2Property<import("@agnocon/pieces-framework").OAuth2Props> | import("@agnocon/pieces-framework").CustomAuthProperty<{
7
+ serviceAccount: import("@agnocon/pieces-framework").LongTextProperty<true>;
8
+ userEmail: import("@agnocon/pieces-framework").ShortTextProperty<false>;
9
+ }>)[]>;
10
+ createIfNotFound: import("@agnocon/pieces-framework").CheckboxProperty<false>;
11
+ newDocumentProps: import("@agnocon/pieces-framework").DynamicProperties<false, (import("@agnocon/pieces-framework").OAuth2Property<import("@agnocon/pieces-framework").OAuth2Props> | import("@agnocon/pieces-framework").CustomAuthProperty<{
12
+ serviceAccount: import("@agnocon/pieces-framework").LongTextProperty<true>;
13
+ userEmail: import("@agnocon/pieces-framework").ShortTextProperty<false>;
14
+ }>)[]>;
15
+ }>;
16
+ //# sourceMappingURL=find-document.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"find-document.d.ts","sourceRoot":"","sources":["../../../src/lib/actions/find-document.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;EA4H7B,CAAC"}
@@ -0,0 +1,127 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.findDocumentAction = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/google-docs/src/lib/actions/find-document.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const auth_1 = require("../auth");
8
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
9
+ const drive_1 = require("@googleapis/drive");
10
+ const docs_1 = require("@googleapis/docs");
11
+ const props_1 = require("../common/props");
12
+ const output_schemas_1 = require("../output-schemas");
13
+ exports.findDocumentAction = (0, pieces_framework_1.createAction)({
14
+ auth: auth_1.googleDocsAuth,
15
+ name: 'google-docs-find-document',
16
+ displayName: 'Find Document',
17
+ description: 'Search for document by name.',
18
+ audience: 'human',
19
+ aiMetadata: {
20
+ description: 'Searches Google Drive for a Google Docs document whose name contains the given text, optionally scoped to a folder, and returns the first match. Use when an agent has a document name but not its ID and needs to resolve it. Idempotent only when used purely for lookup; enabling "Create a new document if not found" makes it create (and optionally move) a new document on each miss, which is a mutating side effect.',
21
+ idempotent: false,
22
+ },
23
+ props: {
24
+ name: pieces_framework_1.Property.ShortText({
25
+ displayName: 'Document Name',
26
+ required: true,
27
+ }),
28
+ folderId: props_1.folderIdProp,
29
+ createIfNotFound: pieces_framework_1.Property.Checkbox({
30
+ displayName: 'Create a new document if not found?',
31
+ defaultValue: false,
32
+ required: false,
33
+ }),
34
+ newDocumentProps: pieces_framework_1.Property.DynamicProperties({
35
+ auth: auth_1.googleDocsAuth,
36
+ displayName: 'New Document Properties',
37
+ required: false,
38
+ refreshers: ['createIfNotFound'],
39
+ props: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth, createIfNotFound }) {
40
+ if (!auth)
41
+ return {};
42
+ if (!createIfNotFound)
43
+ return {};
44
+ const props = {};
45
+ if (createIfNotFound) {
46
+ props['content'] = pieces_framework_1.Property.LongText({
47
+ displayName: 'Document Content',
48
+ required: true,
49
+ });
50
+ }
51
+ return props;
52
+ }),
53
+ }),
54
+ },
55
+ outputSchema: output_schemas_1.findDocumentActionOutputSchema,
56
+ run(context) {
57
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
58
+ var _a, _b;
59
+ const { name: documentName, folderId, createIfNotFound, newDocumentProps } = context.propsValue;
60
+ const newDocumentContent = newDocumentProps === null || newDocumentProps === void 0 ? void 0 : newDocumentProps['content'];
61
+ const authClient = yield (0, auth_1.createGoogleClient)(context.auth);
62
+ const drive = (0, drive_1.drive)({ version: 'v3', auth: authClient });
63
+ const docs = (0, docs_1.docs)({ version: 'v1', auth: authClient });
64
+ // Search for the document in Google Drive
65
+ const query = [
66
+ `name contains '${documentName}'`,
67
+ `mimeType='application/vnd.google-apps.document'`,
68
+ 'trashed=false',
69
+ ];
70
+ if (folderId)
71
+ query.push(`'${folderId}' in parents`);
72
+ const response = yield drive.files.list({
73
+ q: query.join(' and '),
74
+ supportsAllDrives: true,
75
+ fields: '*',
76
+ pageSize: 1,
77
+ includeItemsFromAllDrives: true,
78
+ corpora: 'allDrives',
79
+ });
80
+ const existingFile = (_a = response.data.files) === null || _a === void 0 ? void 0 : _a[0];
81
+ if (existingFile) {
82
+ return { found: true, file: existingFile };
83
+ }
84
+ // Create a new document if not found
85
+ if (!createIfNotFound)
86
+ return { found: false, file: {} };
87
+ //creating new Document
88
+ const createdDoc = yield docs.documents.create({ requestBody: { title: documentName } });
89
+ const documentId = createdDoc.data.documentId;
90
+ if (!documentId)
91
+ throw new Error('Failed to create document');
92
+ // Insert content into the new document
93
+ if (newDocumentContent) {
94
+ // appending text
95
+ yield docs.documents.batchUpdate({
96
+ documentId,
97
+ requestBody: {
98
+ requests: [{ insertText: { text: newDocumentContent, endOfSegmentLocation: {} } }],
99
+ },
100
+ });
101
+ }
102
+ // Move the document to the specified folder
103
+ if (folderId) {
104
+ const fileData = yield drive.files.get({
105
+ fileId: documentId,
106
+ supportsAllDrives: true,
107
+ fields: 'id, parents',
108
+ });
109
+ yield drive.files.update({
110
+ fileId: documentId,
111
+ fields: 'id, name, parents',
112
+ removeParents: (_b = fileData.data.parents) === null || _b === void 0 ? void 0 : _b.join(','),
113
+ addParents: folderId,
114
+ supportsAllDrives: true,
115
+ });
116
+ }
117
+ // Fetch document details
118
+ const finalFile = yield drive.files.get({
119
+ fileId: documentId,
120
+ supportsAllDrives: true,
121
+ fields: '*',
122
+ });
123
+ return { found: false, file: finalFile.data };
124
+ });
125
+ },
126
+ });
127
+ //# sourceMappingURL=find-document.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"find-document.js","sourceRoot":"","sources":["../../../src/lib/actions/find-document.ts"],"names":[],"mappings":";;;;AAAA,2GAA2G;AAC3G,qEAAqE;AACrE,kCAA6D;AAC7D,gEAImC;AACnC,6CAAyD;AACzD,2CAAsD;AACtD,2CAA+C;AAC/C,sDAAmE;AAEtD,QAAA,kBAAkB,GAAG,IAAA,+BAAY,EAAC;IAC9C,IAAI,EAAE,qBAAc;IACpB,IAAI,EAAE,2BAA2B;IACjC,WAAW,EAAE,eAAe;IAC5B,WAAW,EAAE,8BAA8B;IAC3C,QAAQ,EAAE,OAAO;IACjB,UAAU,EAAE;QACX,WAAW,EACV,+ZAA+Z;QACha,UAAU,EAAE,KAAK;KACjB;IACD,KAAK,EAAE;QACN,IAAI,EAAE,2BAAQ,CAAC,SAAS,CAAC;YACxB,WAAW,EAAE,eAAe;YAC5B,QAAQ,EAAE,IAAI;SACd,CAAC;QACF,QAAQ,EAAE,oBAAY;QACtB,gBAAgB,EAAE,2BAAQ,CAA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ChC,UAAU;oBACV,WAAW,EAAE;wBACZ,QAAQ,EAAE,CAAC,EAAE,UAAU,EAAE,EAAE,IAAI,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,EAAE,EAAE,EAAE,CAAC;qBAClF;iBACD,CAAC,CAAC;YACJ,CAAC;YAED,4CAA4C;YAC5C,IAAI,QAAQ,EAAE,CAAC;gBACd,MAAM,QAAQ,GAAG,MAAM,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC;oBACtC,MAAM,EAAE,UAAU;oBAClB,iBAAiB,EAAE,IAAI;oBACvB,MAAM,EAAE,aAAa;iBACrB,CAAC,CAAC;gBAEH,MAAM,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC;oBACxB,MAAM,EAAE,UAAU;oBAClB,MAAM,EAAE,mBAAmB;oBAC3B,aAAa,EAAE,MAAA,QAAQ,CAAC,IAAI,CAAC,OAAO,0CAAE,IAAI,CAAC,GAAG,CAAC;oBAC/C,UAAU,EAAE,QAAQ;oBACpB,iBAAiB,EAAE,IAAI;iBACvB,CAAC,CAAC;YACJ,CAAC;YAED,yBAAyB;YACzB,MAAM,SAAS,GAAG,MAAM,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC;gBACvC,MAAM,EAAE,UAAU;gBAClB,iBAAiB,EAAE,IAAI;gBACvB,MAAM,EAAE,GAAG;aACX,CAAC,CAAC;YAEH,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,SAAS,CAAC,IAAI,EAAE,CAAC;QAC/C,CAAC;KAAA;CACD,CAAC,CAAC"}
@@ -0,0 +1,7 @@
1
+ export declare const getDocumentEndIndex: import("@agnocon/pieces-framework").IAction<(import("@agnocon/pieces-framework").OAuth2Property<import("@agnocon/pieces-framework").OAuth2Props> | import("@agnocon/pieces-framework").CustomAuthProperty<{
2
+ serviceAccount: import("@agnocon/pieces-framework").LongTextProperty<true>;
3
+ userEmail: import("@agnocon/pieces-framework").ShortTextProperty<false>;
4
+ }>)[], {
5
+ documentId: import("@agnocon/pieces-framework").ShortTextProperty<true>;
6
+ }>;
7
+ //# sourceMappingURL=get-document-end-index.action.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-document-end-index.action.d.ts","sourceRoot":"","sources":["../../../src/lib/actions/get-document-end-index.action.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,mBAAmB;;;;;EAwC9B,CAAC"}
@@ -0,0 +1,54 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getDocumentEndIndex = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/google-docs/src/lib/actions/get-document-end-index.action.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const auth_1 = require("../auth");
8
+ const common_1 = require("../common");
9
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
10
+ const docs_1 = require("@googleapis/docs");
11
+ const output_schemas_1 = require("../output-schemas");
12
+ exports.getDocumentEndIndex = (0, pieces_framework_1.createAction)({
13
+ auth: auth_1.googleDocsAuth,
14
+ name: 'get_document_end_index',
15
+ displayName: 'Get Document End Index',
16
+ description: 'Get the end index of a Google Docs document body',
17
+ audience: 'ai',
18
+ aiMetadata: {
19
+ description: 'Returns the end index of a Google Docs document body (the highest character position) so an agent can compute where to insert, delete, or style content. Call this FIRST before any index-based editing atomic (Insert Text with an explicit index, Delete Content Range, etc.) — Google Docs edits are addressed by an integer character index that cannot be guessed. Requires the document ID; read-only and idempotent.',
20
+ idempotent: true,
21
+ },
22
+ outputSchema: output_schemas_1.getDocumentEndIndexActionOutputSchema,
23
+ props: {
24
+ documentId: pieces_framework_1.Property.ShortText({
25
+ displayName: 'Document ID',
26
+ description: 'The ID of the document to inspect (from the document URL or Search Documents).',
27
+ required: true,
28
+ }),
29
+ },
30
+ run(context) {
31
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
32
+ var _a, _b, _c, _d;
33
+ const { documentId } = context.propsValue;
34
+ const authClient = yield (0, auth_1.createGoogleClient)(context.auth);
35
+ const docs = (0, docs_1.docs)({ version: 'v1', auth: authClient });
36
+ try {
37
+ const response = yield docs.documents.get({ documentId });
38
+ const content = (_b = (_a = response.data.body) === null || _a === void 0 ? void 0 : _a.content) !== null && _b !== void 0 ? _b : [];
39
+ const lastElement = content[content.length - 1];
40
+ const endIndex = (_c = lastElement === null || lastElement === void 0 ? void 0 : lastElement.endIndex) !== null && _c !== void 0 ? _c : 1;
41
+ return {
42
+ documentId,
43
+ title: (_d = response.data.title) !== null && _d !== void 0 ? _d : null,
44
+ endIndex,
45
+ maxInsertIndex: Math.max(1, endIndex - 1),
46
+ };
47
+ }
48
+ catch (error) {
49
+ throw new Error(common_1.docsCommon.formatError(error, 'read'));
50
+ }
51
+ });
52
+ },
53
+ });
54
+ //# sourceMappingURL=get-document-end-index.action.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-document-end-index.action.js","sourceRoot":"","sources":["../../../src/lib/actions/get-document-end-index.action.ts"],"names":[],"mappings":";;;;AAAA,2HAA2H;AAC3H,qEAAqE;AACrE,kCAA6D;AAC7D,sCAAuC;AACvC,gEAAmE;AACnE,2CAAsD;AACtD,sDAA0E;AAE7D,QAAA,mBAAmB,GAAG,IAAA,+BAAY,EAAC;IAC9C,IAAI,EAAE,qBAAc;IACpB,IAAI,EAAE,wBAAwB;IAC9B,WAAW,EAAE,wBAAwB;IACrC,WAAW,EAAE,kDAAkD;IAC/D,QAAQ,EAAE,IAAI;IACd,UAAU,EAAE;QACV,WAAW,EACT,6ZAA6Z;QAC/Z,UAAU,EAAE,IAAI;KACjB;IACD,YAAY,EAAE,sDAAqC;IACnD,KAAK,EAAE;QACL,UAAU,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC7B,WAAW,EAAE,aAAa;YAC1B,WAAW,EAAE,gFAAgF;YAC7F,QAAQ,EAAE,IAAI;SACf,CAAC;KACH;IACK,GAAG,CAAC,OAAO;;;YACf,MAAM,EAAE,UAAU,EAAE,GAAG,OAAO,CAAC,UAAU,CAAC;YAC1C,MAAM,UAAU,GAAG,MAAM,IAAA,yBAAkB,EAAC,OAAO,CAAC,IAAI,CAAC,CAAC;YAC1D,MAAM,IAAI,GAAG,IAAA,WAAU,EAAC,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,UAAU,EAAE,CAAC,CAAC;YAE7D,IAAI,CAAC;gBACH,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,EAAE,UAAU,EAAE,CAAC,CAAC;gBAC1D,MAAM,OAAO,GAAG,MAAA,MAAA,QAAQ,CAAC,IAAI,CAAC,IAAI,0CAAE,OAAO,mCAAI,EAAE,CAAC;gBAClD,MAAM,WAAW,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;gBAChD,MAAM,QAAQ,GAAG,MAAA,WAAW,aAAX,WAAW,uBAAX,WAAW,CAAE,QAAQ,mCAAI,CAAC,CAAC;gBAE5C,OAAO;oBACL,UAAU;oBACV,KAAK,EAAE,MAAA,QAAQ,CAAC,IAAI,CAAC,KAAK,mCAAI,IAAI;oBAClC,QAAQ;oBACR,cAAc,EAAE,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,QAAQ,GAAG,CAAC,CAAC;iBAC1C,CAAC;YACJ,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBACf,MAAM,IAAI,KAAK,CAAC,mBAAU,CAAC,WAAW,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;YACzD,CAAC;QACH,CAAC;KAAA;CACF,CAAC,CAAC"}
@@ -0,0 +1,7 @@
1
+ export declare const getDocumentPlaintext: import("@agnocon/pieces-framework").IAction<(import("@agnocon/pieces-framework").OAuth2Property<import("@agnocon/pieces-framework").OAuth2Props> | import("@agnocon/pieces-framework").CustomAuthProperty<{
2
+ serviceAccount: import("@agnocon/pieces-framework").LongTextProperty<true>;
3
+ userEmail: import("@agnocon/pieces-framework").ShortTextProperty<false>;
4
+ }>)[], {
5
+ documentId: import("@agnocon/pieces-framework").ShortTextProperty<true>;
6
+ }>;
7
+ //# sourceMappingURL=get-document-plaintext.action.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-document-plaintext.action.d.ts","sourceRoot":"","sources":["../../../src/lib/actions/get-document-plaintext.action.ts"],"names":[],"mappings":"AAwBA,eAAO,MAAM,oBAAoB;;;;;EAmD/B,CAAC"}
@@ -0,0 +1,76 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getDocumentPlaintext = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/google-docs/src/lib/actions/get-document-plaintext.action.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const auth_1 = require("../auth");
8
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
9
+ const docs_1 = require("@googleapis/docs");
10
+ const output_schemas_1 = require("../output-schemas");
11
+ // Minimal prose projection: only top-level body paragraph text runs are
12
+ // flattened. Content inside tables, headers, footers, footnotes, and tabs is
13
+ // intentionally NOT included — keep the contract unambiguous for agents that
14
+ // just want the document prose. Use read_document for the full structural JSON.
15
+ function flattenBodyToPlainText(body) {
16
+ var _a, _b;
17
+ const lines = [];
18
+ for (const element of (_a = body === null || body === void 0 ? void 0 : body.content) !== null && _a !== void 0 ? _a : []) {
19
+ const paragraph = element.paragraph;
20
+ if (!paragraph)
21
+ continue;
22
+ const text = ((_b = paragraph.elements) !== null && _b !== void 0 ? _b : [])
23
+ .map((paragraphElement) => { var _a, _b; return (_b = (_a = paragraphElement.textRun) === null || _a === void 0 ? void 0 : _a.content) !== null && _b !== void 0 ? _b : ''; })
24
+ .join('');
25
+ lines.push(text);
26
+ }
27
+ return lines.join('').replace(/\n+$/, '');
28
+ }
29
+ exports.getDocumentPlaintext = (0, pieces_framework_1.createAction)({
30
+ auth: auth_1.googleDocsAuth,
31
+ name: 'get_document_plaintext',
32
+ displayName: 'Get Document Plain Text',
33
+ description: 'Get the plain text content of a Google Docs document.',
34
+ audience: 'ai',
35
+ aiMetadata: {
36
+ description: 'Returns just the body prose of a Google Docs document as a plain string, flattened from the document.get response. Pick this over Read Document when you only need the text to summarize/extract/classify and want to avoid the large nested structural JSON. Only top-level paragraph text is included — tables, headers, footers, footnotes, and tabs are omitted. Read-only and idempotent.',
37
+ idempotent: true,
38
+ },
39
+ outputSchema: output_schemas_1.getDocumentPlaintextActionOutputSchema,
40
+ props: {
41
+ documentId: pieces_framework_1.Property.ShortText({
42
+ displayName: 'Document ID',
43
+ description: "The ID of the document to read, found in its URL: 'https://docs.google.com/document/d/<documentId>/edit'. Obtain it from Search Documents or Find Document if you only have a name.",
44
+ required: true,
45
+ }),
46
+ },
47
+ run(context) {
48
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
49
+ var _a, _b;
50
+ const authClient = yield (0, auth_1.createGoogleClient)(context.auth);
51
+ const docs = (0, docs_1.docs)({ version: 'v1', auth: authClient });
52
+ try {
53
+ const response = yield docs.documents.get({
54
+ documentId: context.propsValue.documentId,
55
+ });
56
+ const plainText = flattenBodyToPlainText(response.data.body);
57
+ return {
58
+ documentId: (_a = response.data.documentId) !== null && _a !== void 0 ? _a : context.propsValue.documentId,
59
+ title: (_b = response.data.title) !== null && _b !== void 0 ? _b : '',
60
+ plainText,
61
+ };
62
+ }
63
+ catch (e) {
64
+ const error = e;
65
+ if (error.code === 403) {
66
+ throw new Error('Permission denied reading the document. Ensure the connected account has access to this document.');
67
+ }
68
+ if (error.code === 404) {
69
+ throw new Error(`Document not found for ID '${context.propsValue.documentId}'. Verify the document ID.`);
70
+ }
71
+ throw e;
72
+ }
73
+ });
74
+ },
75
+ });
76
+ //# sourceMappingURL=get-document-plaintext.action.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-document-plaintext.action.js","sourceRoot":"","sources":["../../../src/lib/actions/get-document-plaintext.action.ts"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YACtL,QAAQ,EAAE,IAAI;SACd,CAAC;KACF;IACK,GAAG,CAAC,OAAO;;;YAChB,MAAM,UAAU,GAAG,MAAM,IAAA,yBAAkB,EAAC,OAAO,CAAC,IAAI,CAAC,CAAC;YAC1D,MAAM,IAAI,GAAG,IAAA,WAAU,EAAC,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,UAAU,EAAE,CAAC,CAAC;YAE7D,IAAI,CAAC;gBACJ,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC;oBACzC,UAAU,EAAE,OAAO,CAAC,UAAU,CAAC,UAAU;iBACzC,CAAC,CAAC;gBAEH,MAAM,SAAS,GAAG,sBAAsB,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;gBAE7D,OAAO;oBACN,UAAU,EAAE,MAAA,QAAQ,CAAC,IAAI,CAAC,UAAU,mCAAI,OAAO,CAAC,UAAU,CAAC,UAAU;oBACrE,KAAK,EAAE,MAAA,QAAQ,CAAC,IAAI,CAAC,KAAK,mCAAI,EAAE;oBAChC,SAAS;iBACT,CAAC;YACH,CAAC;YAAC,OAAO,CAAC,EAAE,CAAC;gBACZ,MAAM,KAAK,GAAG,CAAwC,CAAC;gBACvD,IAAI,KAAK,CAAC,IAAI,KAAK,GAAG,EAAE,CAAC;oBACxB,MAAM,IAAI,KAAK,CACd,mGAAmG,CACnG,CAAC;gBACH,CAAC;gBACD,IAAI,KAAK,CAAC,IAAI,KAAK,GAAG,EAAE,CAAC;oBACxB,MAAM,IAAI,KAAK,CACd,8BAA8B,OAAO,CAAC,UAAU,CAAC,UAAU,4BAA4B,CACvF,CAAC;gBACH,CAAC;gBACD,MAAM,CAAC,CAAC;YACT,CAAC;QACF,CAAC;KAAA;CACD,CAAC,CAAC"}
@@ -0,0 +1,7 @@
1
+ export declare const getDocument: import("@agnocon/pieces-framework").IAction<(import("@agnocon/pieces-framework").OAuth2Property<import("@agnocon/pieces-framework").OAuth2Props> | import("@agnocon/pieces-framework").CustomAuthProperty<{
2
+ serviceAccount: import("@agnocon/pieces-framework").LongTextProperty<true>;
3
+ userEmail: import("@agnocon/pieces-framework").ShortTextProperty<false>;
4
+ }>)[], {
5
+ documentId: import("@agnocon/pieces-framework").ShortTextProperty<true>;
6
+ }>;
7
+ //# sourceMappingURL=get-document.action.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-document.action.d.ts","sourceRoot":"","sources":["../../../src/lib/actions/get-document.action.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,WAAW;;;;;EA8BtB,CAAC"}