@divyacon/piece-telegram-bot 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 (223) hide show
  1. package/LICENSE.MIT-AP +24 -0
  2. package/README.md +8 -2
  3. package/dist/index.d.ts +3 -0
  4. package/dist/index.d.ts.map +1 -0
  5. package/dist/index.js +122 -0
  6. package/dist/index.js.map +1 -0
  7. package/dist/lib/action/answer-callback-query.action.d.ts +8 -0
  8. package/dist/lib/action/answer-callback-query.action.d.ts.map +1 -0
  9. package/dist/lib/action/answer-callback-query.action.js +63 -0
  10. package/dist/lib/action/answer-callback-query.action.js.map +1 -0
  11. package/dist/lib/action/create-invite-link.d.ts +9 -0
  12. package/dist/lib/action/create-invite-link.d.ts.map +1 -0
  13. package/dist/lib/action/create-invite-link.js +66 -0
  14. package/dist/lib/action/create-invite-link.js.map +1 -0
  15. package/dist/lib/action/delete-message.action.d.ts +6 -0
  16. package/dist/lib/action/delete-message.action.d.ts.map +1 -0
  17. package/dist/lib/action/delete-message.action.js +42 -0
  18. package/dist/lib/action/delete-message.action.js.map +1 -0
  19. package/dist/lib/action/edit-message-text.action.d.ts +12 -0
  20. package/dist/lib/action/edit-message-text.action.d.ts.map +1 -0
  21. package/dist/lib/action/edit-message-text.action.js +76 -0
  22. package/dist/lib/action/edit-message-text.action.js.map +1 -0
  23. package/dist/lib/action/forward-message.action.d.ts +10 -0
  24. package/dist/lib/action/forward-message.action.d.ts.map +1 -0
  25. package/dist/lib/action/forward-message.action.js +59 -0
  26. package/dist/lib/action/forward-message.action.js.map +1 -0
  27. package/dist/lib/action/get-chat-member.d.ts +6 -0
  28. package/dist/lib/action/get-chat-member.d.ts.map +1 -0
  29. package/dist/lib/action/get-chat-member.js +49 -0
  30. package/dist/lib/action/get-chat-member.js.map +1 -0
  31. package/dist/lib/action/get-chat.action.d.ts +5 -0
  32. package/dist/lib/action/get-chat.action.d.ts.map +1 -0
  33. package/dist/lib/action/get-chat.action.js +42 -0
  34. package/dist/lib/action/get-chat.action.js.map +1 -0
  35. package/dist/lib/action/get-file.action.d.ts +5 -0
  36. package/dist/lib/action/get-file.action.d.ts.map +1 -0
  37. package/dist/lib/action/get-file.action.js +69 -0
  38. package/dist/lib/action/get-file.action.js.map +1 -0
  39. package/dist/lib/action/pin-message.action.d.ts +7 -0
  40. package/dist/lib/action/pin-message.action.d.ts.map +1 -0
  41. package/dist/lib/action/pin-message.action.js +50 -0
  42. package/dist/lib/action/pin-message.action.js.map +1 -0
  43. package/dist/lib/action/request-approval-message.d.ts +7 -0
  44. package/dist/lib/action/request-approval-message.d.ts.map +1 -0
  45. package/dist/lib/action/request-approval-message.js +84 -0
  46. package/dist/lib/action/request-approval-message.js.map +1 -0
  47. package/dist/lib/action/send-audio.action.d.ts +18 -0
  48. package/dist/lib/action/send-audio.action.d.ts.map +1 -0
  49. package/dist/lib/action/send-audio.action.js +128 -0
  50. package/dist/lib/action/send-audio.action.js.map +1 -0
  51. package/dist/lib/action/send-chat-action.action.d.ts +7 -0
  52. package/dist/lib/action/send-chat-action.action.d.ts.map +1 -0
  53. package/dist/lib/action/send-chat-action.action.js +61 -0
  54. package/dist/lib/action/send-chat-action.action.js.map +1 -0
  55. package/dist/lib/action/send-document.action.d.ts +15 -0
  56. package/dist/lib/action/send-document.action.d.ts.map +1 -0
  57. package/dist/lib/action/send-document.action.js +104 -0
  58. package/dist/lib/action/send-document.action.js.map +1 -0
  59. package/dist/lib/action/send-location.action.d.ts +16 -0
  60. package/dist/lib/action/send-location.action.d.ts.map +1 -0
  61. package/dist/lib/action/send-location.action.js +83 -0
  62. package/dist/lib/action/send-location.action.js.map +1 -0
  63. package/dist/lib/action/send-media-group.action.d.ts +11 -0
  64. package/dist/lib/action/send-media-group.action.d.ts.map +1 -0
  65. package/dist/lib/action/send-media-group.action.js +97 -0
  66. package/dist/lib/action/send-media-group.action.js.map +1 -0
  67. package/dist/lib/action/send-media.action.d.ts +14 -0
  68. package/dist/lib/action/send-media.action.d.ts.map +1 -0
  69. package/dist/lib/action/send-media.action.js +198 -0
  70. package/dist/lib/action/send-media.action.js.map +1 -0
  71. package/dist/lib/action/send-poll.action.d.ts +21 -0
  72. package/dist/lib/action/send-poll.action.d.ts.map +1 -0
  73. package/dist/lib/action/send-poll.action.js +145 -0
  74. package/dist/lib/action/send-poll.action.js.map +1 -0
  75. package/dist/lib/action/send-text-message.action.d.ts +14 -0
  76. package/dist/lib/action/send-text-message.action.d.ts.map +1 -0
  77. package/dist/lib/action/send-text-message.action.js +63 -0
  78. package/dist/lib/action/send-text-message.action.js.map +1 -0
  79. package/dist/lib/action/telegram-answer-callback-query.d.ts +8 -0
  80. package/dist/lib/action/telegram-answer-callback-query.d.ts.map +1 -0
  81. package/dist/lib/action/telegram-answer-callback-query.js +68 -0
  82. package/dist/lib/action/telegram-answer-callback-query.js.map +1 -0
  83. package/dist/lib/action/telegram-create-invite-link.d.ts +8 -0
  84. package/dist/lib/action/telegram-create-invite-link.d.ts.map +1 -0
  85. package/dist/lib/action/telegram-create-invite-link.js +68 -0
  86. package/dist/lib/action/telegram-create-invite-link.js.map +1 -0
  87. package/dist/lib/action/telegram-delete-message.d.ts +5 -0
  88. package/dist/lib/action/telegram-delete-message.d.ts.map +1 -0
  89. package/dist/lib/action/telegram-delete-message.js +44 -0
  90. package/dist/lib/action/telegram-delete-message.js.map +1 -0
  91. package/dist/lib/action/telegram-edit-message-text.d.ts +10 -0
  92. package/dist/lib/action/telegram-edit-message-text.d.ts.map +1 -0
  93. package/dist/lib/action/telegram-edit-message-text.js +93 -0
  94. package/dist/lib/action/telegram-edit-message-text.js.map +1 -0
  95. package/dist/lib/action/telegram-forward-message.d.ts +9 -0
  96. package/dist/lib/action/telegram-forward-message.d.ts.map +1 -0
  97. package/dist/lib/action/telegram-forward-message.js +61 -0
  98. package/dist/lib/action/telegram-forward-message.js.map +1 -0
  99. package/dist/lib/action/telegram-get-bot-info.d.ts +2 -0
  100. package/dist/lib/action/telegram-get-bot-info.d.ts.map +1 -0
  101. package/dist/lib/action/telegram-get-bot-info.js +39 -0
  102. package/dist/lib/action/telegram-get-bot-info.js.map +1 -0
  103. package/dist/lib/action/telegram-get-chat-administrators.d.ts +4 -0
  104. package/dist/lib/action/telegram-get-chat-administrators.d.ts.map +1 -0
  105. package/dist/lib/action/telegram-get-chat-administrators.js +44 -0
  106. package/dist/lib/action/telegram-get-chat-administrators.js.map +1 -0
  107. package/dist/lib/action/telegram-get-chat-member-count.d.ts +4 -0
  108. package/dist/lib/action/telegram-get-chat-member-count.d.ts.map +1 -0
  109. package/dist/lib/action/telegram-get-chat-member-count.js +44 -0
  110. package/dist/lib/action/telegram-get-chat-member-count.js.map +1 -0
  111. package/dist/lib/action/telegram-get-chat-member.d.ts +5 -0
  112. package/dist/lib/action/telegram-get-chat-member.d.ts.map +1 -0
  113. package/dist/lib/action/telegram-get-chat-member.js +51 -0
  114. package/dist/lib/action/telegram-get-chat-member.js.map +1 -0
  115. package/dist/lib/action/telegram-get-chat.d.ts +4 -0
  116. package/dist/lib/action/telegram-get-chat.d.ts.map +1 -0
  117. package/dist/lib/action/telegram-get-chat.js +44 -0
  118. package/dist/lib/action/telegram-get-chat.js.map +1 -0
  119. package/dist/lib/action/telegram-get-file.d.ts +5 -0
  120. package/dist/lib/action/telegram-get-file.d.ts.map +1 -0
  121. package/dist/lib/action/telegram-get-file.js +72 -0
  122. package/dist/lib/action/telegram-get-file.js.map +1 -0
  123. package/dist/lib/action/telegram-pin-message.d.ts +6 -0
  124. package/dist/lib/action/telegram-pin-message.d.ts.map +1 -0
  125. package/dist/lib/action/telegram-pin-message.js +52 -0
  126. package/dist/lib/action/telegram-pin-message.js.map +1 -0
  127. package/dist/lib/action/telegram-send-audio.d.ts +16 -0
  128. package/dist/lib/action/telegram-send-audio.d.ts.map +1 -0
  129. package/dist/lib/action/telegram-send-audio.js +149 -0
  130. package/dist/lib/action/telegram-send-audio.js.map +1 -0
  131. package/dist/lib/action/telegram-send-chat-action.d.ts +6 -0
  132. package/dist/lib/action/telegram-send-chat-action.d.ts.map +1 -0
  133. package/dist/lib/action/telegram-send-chat-action.js +67 -0
  134. package/dist/lib/action/telegram-send-chat-action.js.map +1 -0
  135. package/dist/lib/action/telegram-send-document.d.ts +13 -0
  136. package/dist/lib/action/telegram-send-document.d.ts.map +1 -0
  137. package/dist/lib/action/telegram-send-document.js +125 -0
  138. package/dist/lib/action/telegram-send-document.js.map +1 -0
  139. package/dist/lib/action/telegram-send-location.d.ts +15 -0
  140. package/dist/lib/action/telegram-send-location.d.ts.map +1 -0
  141. package/dist/lib/action/telegram-send-location.js +93 -0
  142. package/dist/lib/action/telegram-send-location.js.map +1 -0
  143. package/dist/lib/action/telegram-send-media-group.d.ts +10 -0
  144. package/dist/lib/action/telegram-send-media-group.d.ts.map +1 -0
  145. package/dist/lib/action/telegram-send-media-group.js +115 -0
  146. package/dist/lib/action/telegram-send-media-group.js.map +1 -0
  147. package/dist/lib/action/telegram-send-message.d.ts +12 -0
  148. package/dist/lib/action/telegram-send-message.d.ts.map +1 -0
  149. package/dist/lib/action/telegram-send-message.js +84 -0
  150. package/dist/lib/action/telegram-send-message.js.map +1 -0
  151. package/dist/lib/action/telegram-send-photo-or-video.d.ts +12 -0
  152. package/dist/lib/action/telegram-send-photo-or-video.d.ts.map +1 -0
  153. package/dist/lib/action/telegram-send-photo-or-video.js +219 -0
  154. package/dist/lib/action/telegram-send-photo-or-video.js.map +1 -0
  155. package/dist/lib/action/telegram-send-poll.d.ts +20 -0
  156. package/dist/lib/action/telegram-send-poll.d.ts.map +1 -0
  157. package/dist/lib/action/telegram-send-poll.js +167 -0
  158. package/dist/lib/action/telegram-send-poll.js.map +1 -0
  159. package/dist/lib/action/telegram-unpin-message.d.ts +5 -0
  160. package/dist/lib/action/telegram-unpin-message.d.ts.map +1 -0
  161. package/dist/lib/action/telegram-unpin-message.js +45 -0
  162. package/dist/lib/action/telegram-unpin-message.js.map +1 -0
  163. package/dist/lib/action/unpin-message.action.d.ts +6 -0
  164. package/dist/lib/action/unpin-message.action.d.ts.map +1 -0
  165. package/dist/lib/action/unpin-message.action.js +43 -0
  166. package/dist/lib/action/unpin-message.action.js.map +1 -0
  167. package/dist/lib/common/index.d.ts +25 -0
  168. package/dist/lib/common/index.d.ts.map +1 -0
  169. package/dist/lib/common/index.js +104 -0
  170. package/dist/lib/common/index.js.map +1 -0
  171. package/dist/lib/output-schemas.d.ts +41 -0
  172. package/dist/lib/output-schemas.d.ts.map +1 -0
  173. package/dist/lib/output-schemas.js +1853 -0
  174. package/dist/lib/output-schemas.js.map +1 -0
  175. package/dist/lib/trigger/new-message.d.ts +15 -0
  176. package/dist/lib/trigger/new-message.d.ts.map +1 -0
  177. package/dist/lib/trigger/new-message.js +121 -0
  178. package/dist/lib/trigger/new-message.js.map +1 -0
  179. package/package.json +44 -3
  180. package/src/index.ts +119 -0
  181. package/src/lib/action/answer-callback-query.action.ts +58 -0
  182. package/src/lib/action/create-invite-link.ts +59 -0
  183. package/src/lib/action/delete-message.action.ts +34 -0
  184. package/src/lib/action/edit-message-text.action.ts +71 -0
  185. package/src/lib/action/forward-message.action.ts +50 -0
  186. package/src/lib/action/get-chat-member.ts +40 -0
  187. package/src/lib/action/get-chat.action.ts +33 -0
  188. package/src/lib/action/get-file.action.ts +79 -0
  189. package/src/lib/action/pin-message.action.ts +41 -0
  190. package/src/lib/action/request-approval-message.ts +85 -0
  191. package/src/lib/action/send-audio.action.ts +123 -0
  192. package/src/lib/action/send-chat-action.action.ts +53 -0
  193. package/src/lib/action/send-document.action.ts +105 -0
  194. package/src/lib/action/send-location.action.ts +76 -0
  195. package/src/lib/action/send-media-group.action.ts +98 -0
  196. package/src/lib/action/send-media.action.ts +209 -0
  197. package/src/lib/action/send-poll.action.ts +140 -0
  198. package/src/lib/action/send-text-message.action.ts +54 -0
  199. package/src/lib/action/telegram-answer-callback-query.ts +64 -0
  200. package/src/lib/action/telegram-create-invite-link.ts +62 -0
  201. package/src/lib/action/telegram-delete-message.ts +37 -0
  202. package/src/lib/action/telegram-edit-message-text.ts +92 -0
  203. package/src/lib/action/telegram-forward-message.ts +54 -0
  204. package/src/lib/action/telegram-get-bot-info.ts +31 -0
  205. package/src/lib/action/telegram-get-chat-administrators.ts +36 -0
  206. package/src/lib/action/telegram-get-chat-member-count.ts +36 -0
  207. package/src/lib/action/telegram-get-chat-member.ts +43 -0
  208. package/src/lib/action/telegram-get-chat.ts +36 -0
  209. package/src/lib/action/telegram-get-file.ts +83 -0
  210. package/src/lib/action/telegram-pin-message.ts +45 -0
  211. package/src/lib/action/telegram-send-audio.ts +157 -0
  212. package/src/lib/action/telegram-send-chat-action.ts +61 -0
  213. package/src/lib/action/telegram-send-document.ts +136 -0
  214. package/src/lib/action/telegram-send-location.ts +89 -0
  215. package/src/lib/action/telegram-send-media-group.ts +119 -0
  216. package/src/lib/action/telegram-send-message.ts +79 -0
  217. package/src/lib/action/telegram-send-photo-or-video.ts +238 -0
  218. package/src/lib/action/telegram-send-poll.ts +170 -0
  219. package/src/lib/action/telegram-unpin-message.ts +38 -0
  220. package/src/lib/action/unpin-message.action.ts +36 -0
  221. package/src/lib/common/index.ts +147 -0
  222. package/src/lib/output-schemas.ts +1909 -0
  223. package/src/lib/trigger/new-message.ts +127 -0
@@ -0,0 +1,145 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.telegramSendPollAction = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/telegram-bot/src/lib/action/send-poll.action.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
8
+ const pieces_common_1 = require("@agnocon/pieces-common");
9
+ const common_1 = require("../common");
10
+ const __1 = require("../..");
11
+ const output_schemas_1 = require("../output-schemas");
12
+ exports.telegramSendPollAction = (0, pieces_framework_1.createAction)({
13
+ auth: __1.telegramBotAuth,
14
+ name: 'send_poll',
15
+ displayName: 'Send Poll',
16
+ description: 'Send a native Telegram poll (regular or quiz) to a chat',
17
+ audience: 'human',
18
+ aiMetadata: { description: 'Posts a native Telegram poll (regular or quiz) to a chat with 2–10 answer options. Use to collect votes or run a quiz; quiz polls require a correct_option_id and cannot allow multiple answers, and open_period and close_date are mutually exclusive. Not idempotent: each call creates a new poll.', idempotent: false },
19
+ props: {
20
+ instructions: common_1.telegramCommons.chatIdInstructions(),
21
+ chat_id: common_1.telegramCommons.chatIdProp(),
22
+ message_thread_id: common_1.telegramCommons.messageThreadIdProp(),
23
+ question: pieces_framework_1.Property.ShortText({
24
+ displayName: 'Question',
25
+ description: 'Poll question, 1–300 characters.',
26
+ required: true,
27
+ }),
28
+ options: pieces_framework_1.Property.Array({
29
+ displayName: 'Options',
30
+ description: 'List of answer options (2–10 options, each 1–100 characters).',
31
+ required: true,
32
+ }),
33
+ is_anonymous: pieces_framework_1.Property.Checkbox({
34
+ displayName: 'Anonymous',
35
+ description: 'True, if the poll needs to be anonymous. Default true.',
36
+ required: false,
37
+ defaultValue: true,
38
+ }),
39
+ type: pieces_framework_1.Property.StaticDropdown({
40
+ displayName: 'Poll Type',
41
+ description: 'Poll type. Defaults to "regular".',
42
+ required: false,
43
+ options: {
44
+ options: [
45
+ { label: 'Regular', value: 'regular' },
46
+ { label: 'Quiz', value: 'quiz' },
47
+ ],
48
+ },
49
+ defaultValue: 'regular',
50
+ }),
51
+ allows_multiple_answers: pieces_framework_1.Property.Checkbox({
52
+ displayName: 'Allow Multiple Answers',
53
+ description: 'True if the poll allows multiple answers (regular polls only).',
54
+ required: false,
55
+ defaultValue: false,
56
+ }),
57
+ correct_option_id: pieces_framework_1.Property.Number({
58
+ displayName: 'Correct Option Id (Quiz)',
59
+ description: '0-based index of the correct answer option (required for quizzes).',
60
+ required: false,
61
+ }),
62
+ explanation: pieces_framework_1.Property.LongText({
63
+ displayName: 'Explanation (Quiz)',
64
+ description: 'Explanation shown when a user picks an incorrect answer (0–200 chars).',
65
+ required: false,
66
+ }),
67
+ explanation_parse_mode: common_1.telegramCommons.parseModeProp(),
68
+ open_period: pieces_framework_1.Property.Number({
69
+ displayName: 'Open Period (seconds)',
70
+ description: 'Amount of time in seconds the poll will be active (5–600).',
71
+ required: false,
72
+ }),
73
+ close_date: pieces_framework_1.Property.DateTime({
74
+ displayName: 'Close Date',
75
+ description: 'Point in time when the poll will be automatically closed.',
76
+ required: false,
77
+ }),
78
+ is_closed: pieces_framework_1.Property.Checkbox({
79
+ displayName: 'Closed',
80
+ description: 'Pass True if the poll should be immediately closed. Useful for previews.',
81
+ required: false,
82
+ defaultValue: false,
83
+ }),
84
+ disable_notification: common_1.telegramCommons.disableNotificationProp(),
85
+ protect_content: common_1.telegramCommons.protectContentProp(),
86
+ reply_to_message_id: common_1.telegramCommons.replyToMessageIdProp(),
87
+ reply_markup: common_1.telegramCommons.replyMarkupProp(),
88
+ },
89
+ outputSchema: output_schemas_1.sendPollActionOutputSchema,
90
+ run(ctx) {
91
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
92
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
93
+ const options = ((_a = ctx.propsValue.options) !== null && _a !== void 0 ? _a : []).map((option) => String(option));
94
+ if (options.length < 2 || options.length > 10) {
95
+ throw new Error('A poll requires between 2 and 10 options.');
96
+ }
97
+ const pollType = (_b = ctx.propsValue.type) !== null && _b !== void 0 ? _b : 'regular';
98
+ const correctOptionId = ctx.propsValue.correct_option_id;
99
+ if (pollType === 'quiz') {
100
+ if (correctOptionId === undefined || correctOptionId === null) {
101
+ throw new Error('Quiz polls require "Correct Option Id".');
102
+ }
103
+ if (correctOptionId < 0 || correctOptionId >= options.length) {
104
+ throw new Error(`"Correct Option Id" must be between 0 and ${options.length - 1} (the index of an option).`);
105
+ }
106
+ if (ctx.propsValue.allows_multiple_answers) {
107
+ throw new Error('Quiz polls cannot allow multiple answers.');
108
+ }
109
+ }
110
+ else if (correctOptionId !== undefined && correctOptionId !== null) {
111
+ throw new Error('"Correct Option Id" is only valid for quiz polls. Set "Poll Type" to Quiz or clear this field.');
112
+ }
113
+ if (ctx.propsValue.open_period && ctx.propsValue.close_date) {
114
+ throw new Error('"Open Period" and "Close Date" are mutually exclusive — set at most one.');
115
+ }
116
+ const explanationParseMode = common_1.telegramCommons.resolveParseMode(ctx.propsValue.explanation_parse_mode);
117
+ return yield pieces_common_1.httpClient.sendRequest({
118
+ method: pieces_common_1.HttpMethod.POST,
119
+ url: common_1.telegramCommons.getApiUrl(ctx.auth, 'sendPoll'),
120
+ body: {
121
+ chat_id: ctx.propsValue.chat_id,
122
+ question: ctx.propsValue.question,
123
+ options,
124
+ message_thread_id: (_c = ctx.propsValue.message_thread_id) !== null && _c !== void 0 ? _c : undefined,
125
+ is_anonymous: (_d = ctx.propsValue.is_anonymous) !== null && _d !== void 0 ? _d : true,
126
+ type: (_e = ctx.propsValue.type) !== null && _e !== void 0 ? _e : 'regular',
127
+ allows_multiple_answers: (_f = ctx.propsValue.allows_multiple_answers) !== null && _f !== void 0 ? _f : false,
128
+ correct_option_id: (_g = ctx.propsValue.correct_option_id) !== null && _g !== void 0 ? _g : undefined,
129
+ explanation: (_h = ctx.propsValue.explanation) !== null && _h !== void 0 ? _h : undefined,
130
+ explanation_parse_mode: explanationParseMode,
131
+ open_period: (_j = ctx.propsValue.open_period) !== null && _j !== void 0 ? _j : undefined,
132
+ close_date: ctx.propsValue.close_date
133
+ ? Math.floor(new Date(ctx.propsValue.close_date).getTime() / 1000)
134
+ : undefined,
135
+ is_closed: (_k = ctx.propsValue.is_closed) !== null && _k !== void 0 ? _k : false,
136
+ disable_notification: (_l = ctx.propsValue.disable_notification) !== null && _l !== void 0 ? _l : false,
137
+ protect_content: (_m = ctx.propsValue.protect_content) !== null && _m !== void 0 ? _m : false,
138
+ reply_to_message_id: (_o = ctx.propsValue.reply_to_message_id) !== null && _o !== void 0 ? _o : undefined,
139
+ reply_markup: (_p = ctx.propsValue.reply_markup) !== null && _p !== void 0 ? _p : undefined,
140
+ },
141
+ });
142
+ });
143
+ },
144
+ });
145
+ //# sourceMappingURL=send-poll.action.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"send-poll.action.js","sourceRoot":"","sources":["../../../src/lib/action/send-poll.action.ts"],"names":[],"mappings":";;;;AAAA,8GAA8G;AAC9G,qEAAqE;AACrE,gEAAmE;AACnE,0DAAgE;AAChE,sCAA4C;AAC5C,6BAAwC;AACxC,sDAA+D;AAElD,QAAA,sBAAsB,GAAG,IAAA,+BAAY,EAAC;IACjD,IAAI,EAAE,mBAAe;IACrB,IAAI,EAAE,WAAW;IACjB,WAAW,EAAE,WAAW;IACxB,WAAW,EAAE,yDAAyD;IACtE,QAAQ,EAAE,OAAO;IACjB,UAAU,EAAE,EAAE,WAAW,EAAE,uSAAuS,EAAE,UAAU,EAAE,KAAK,EAAE;IACvV,KAAK,EAAE;QACL,YAAY,EAAE,wBAAe,CAAC,kBAAkB,EAAE;QAClD,OAAO,EAAE,wBAAe,CAAC,UAAU,EAAE;QACrC,iBAAiB,EAAE,wBAAe,CAAC,mBAAmB,EAAE;QACxD,QAAQ,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC3B,WAAW,EAAE,UAAU;YACvB,WAAW,EAAE,kCAAkC;YAC/C,QAAQ,EAAE,IAAI;SACf,CAAC;QACF,OAAO,EAAE,2BAAQ,CAAC,KAAK,CAAC;YACtB,WAAW,EAAE,SAAS;YACtB,WAAW,EAAE,+DAA+D;YAC5E,QAAQ,EAAE,IAAI;SACf,CAAC;QACF,YAAY,EAAE,2BAAQ,CAAC,QAAQ,CAAC;YAC9B,WAAW,EAAE,WAAW;YACxB,WAAW,EAAE,wDAAwD;YACrE,QAAQ,EAAE,KAAK;YACf,YAAY,EAAE,IAAI;SACnB,CAAC;QACF,IAAI,EAAE,2BAAQ,CAAC,cAAc,CAAC;YAC5B,WAAW,EAAE,WAAW;YACxB,WAAW,EAAE,mCAAmC;YAChD,QA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AO,EAAE,GAAG,IAAI,CAAC;wBAClE,CAAC,CAAC,SAAS;oBACb,SAAS,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,SAAS,mCAAI,KAAK;oBAC5C,oBAAoB,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,oBAAoB,mCAAI,KAAK;oBAClE,eAAe,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,eAAe,mCAAI,KAAK;oBACxD,mBAAmB,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,mBAAmB,mCAAI,SAAS;oBACpE,YAAY,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,YAAY,mCAAI,SAAS;iBACvD;aACF,CAAC,CAAC;QACL,CAAC;KAAA;CACF,CAAC,CAAC"}
@@ -0,0 +1,14 @@
1
+ export declare const telegramSendMessageAction: import("@agnocon/pieces-framework").IAction<import("@agnocon/pieces-framework").SecretTextProperty<true>, {
2
+ instructions: import("@agnocon/pieces-framework/dist/lib/property/input/markdown-property").MarkDownProperty;
3
+ chat_id: import("@agnocon/pieces-framework").ShortTextProperty<true>;
4
+ message_thread_id: import("@agnocon/pieces-framework").ShortTextProperty<false>;
5
+ format: import("@agnocon/pieces-framework").StaticDropdownProperty<string, false>;
6
+ instructions_format: import("@agnocon/pieces-framework/dist/lib/property/input/markdown-property").MarkDownProperty;
7
+ web_page_preview: import("@agnocon/pieces-framework").CheckboxProperty<false>;
8
+ disable_notification: import("@agnocon/pieces-framework").CheckboxProperty<false>;
9
+ protect_content: import("@agnocon/pieces-framework").CheckboxProperty<false>;
10
+ reply_to_message_id: import("@agnocon/pieces-framework").NumberProperty<false>;
11
+ message: import("@agnocon/pieces-framework").LongTextProperty<true>;
12
+ reply_markup: import("@agnocon/pieces-framework").JsonProperty<false>;
13
+ }>;
14
+ //# sourceMappingURL=send-text-message.action.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"send-text-message.action.d.ts","sourceRoot":"","sources":["../../../src/lib/action/send-text-message.action.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,yBAAyB;;;;;;;;;;;;EA+CpC,CAAC"}
@@ -0,0 +1,63 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.telegramSendMessageAction = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/telegram-bot/src/lib/action/send-text-message.action.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
8
+ const pieces_common_1 = require("@agnocon/pieces-common");
9
+ const common_1 = require("../common");
10
+ const __1 = require("../..");
11
+ const output_schemas_1 = require("../output-schemas");
12
+ exports.telegramSendMessageAction = (0, pieces_framework_1.createAction)({
13
+ auth: __1.telegramBotAuth,
14
+ name: 'send_text_message',
15
+ description: 'Send a text message through a Telegram bot',
16
+ audience: 'human',
17
+ aiMetadata: { description: 'Posts a text message to a Telegram chat, group, or channel via the bot, addressed by chat_id (numeric id or @channelusername the bot can reach). Use to deliver notifications, replies, or alerts; supports Markdown/HTML formatting and inline keyboards. Not idempotent: each call sends a new message.', idempotent: false },
18
+ displayName: 'Send Text Message',
19
+ props: {
20
+ instructions: common_1.telegramCommons.chatIdInstructions(),
21
+ chat_id: common_1.telegramCommons.chatIdProp(),
22
+ message_thread_id: common_1.telegramCommons.messageThreadIdProp(),
23
+ format: common_1.telegramCommons.parseModeProp(),
24
+ instructions_format: common_1.telegramCommons.formatLinkInstructions(),
25
+ web_page_preview: pieces_framework_1.Property.Checkbox({
26
+ displayName: 'Disable Web Page Preview',
27
+ description: 'Disable link previews for links in this message.',
28
+ required: false,
29
+ defaultValue: false,
30
+ }),
31
+ disable_notification: common_1.telegramCommons.disableNotificationProp(),
32
+ protect_content: common_1.telegramCommons.protectContentProp(),
33
+ reply_to_message_id: common_1.telegramCommons.replyToMessageIdProp(),
34
+ message: pieces_framework_1.Property.LongText({
35
+ displayName: 'Message',
36
+ description: 'The message to be sent',
37
+ required: true,
38
+ }),
39
+ reply_markup: common_1.telegramCommons.replyMarkupProp(),
40
+ },
41
+ outputSchema: output_schemas_1.sendTextMessageActionOutputSchema,
42
+ run(ctx) {
43
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
44
+ var _a, _b, _c, _d, _e, _f;
45
+ return yield pieces_common_1.httpClient.sendRequest({
46
+ method: pieces_common_1.HttpMethod.POST,
47
+ url: common_1.telegramCommons.getApiUrl(ctx.auth, 'sendMessage'),
48
+ body: {
49
+ chat_id: ctx.propsValue['chat_id'],
50
+ text: ctx.propsValue['message'],
51
+ message_thread_id: (_a = ctx.propsValue['message_thread_id']) !== null && _a !== void 0 ? _a : undefined,
52
+ parse_mode: common_1.telegramCommons.resolveParseMode(ctx.propsValue['format']),
53
+ reply_markup: (_b = ctx.propsValue['reply_markup']) !== null && _b !== void 0 ? _b : undefined,
54
+ disable_web_page_preview: (_c = ctx.propsValue['web_page_preview']) !== null && _c !== void 0 ? _c : false,
55
+ disable_notification: (_d = ctx.propsValue['disable_notification']) !== null && _d !== void 0 ? _d : false,
56
+ protect_content: (_e = ctx.propsValue['protect_content']) !== null && _e !== void 0 ? _e : false,
57
+ reply_to_message_id: (_f = ctx.propsValue['reply_to_message_id']) !== null && _f !== void 0 ? _f : undefined,
58
+ },
59
+ });
60
+ });
61
+ },
62
+ });
63
+ //# sourceMappingURL=send-text-message.action.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"send-text-message.action.js","sourceRoot":"","sources":["../../../src/lib/action/send-text-message.action.ts"],"names":[],"mappings":";;;;AAAA,sHAAsH;AACtH,qEAAqE;AACrE,gEAAmE;AACnE,0DAAgE;AAChE,sCAA4C;AAC5C,6BAAwC;AACxC,sDAAsE;AAEzD,QAAA,yBAAyB,GAAG,IAAA,+BAAY,EAAC;IACpD,IAAI,EAAE,mBAAe;IACrB,IAAI,EAAE,mBAAmB;IACzB,WAAW,EAAE,4CAA4C;IACzD,QAAQ,EAAE,OAAO;IACjB,UAAU,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C,mCAAI,SAAS;oBACnE,UAAU,EAAE,wBAAe,CAAC,gBAAgB,CAAC,GAAG,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC;oBACtE,YAAY,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,cAAc,CAAC,mCAAI,SAAS;oBACzD,wBAAwB,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,kBAAkB,CAAC,mCAAI,KAAK;oBACrE,oBAAoB,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,sBAAsB,CAAC,mCAAI,KAAK;oBACrE,eAAe,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,iBAAiB,CAAC,mCAAI,KAAK;oBAC3D,mBAAmB,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,qBAAqB,CAAC,mCAAI,SAAS;iBACxE;aACF,CAAC,CAAC;QACL,CAAC;KAAA;CACF,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ export declare const telegramAnswerCallbackQuery: import("@agnocon/pieces-framework").IAction<import("@agnocon/pieces-framework").SecretTextProperty<true>, {
2
+ callback_query_id: import("@agnocon/pieces-framework").ShortTextProperty<true>;
3
+ text: import("@agnocon/pieces-framework").LongTextProperty<false>;
4
+ show_alert: import("@agnocon/pieces-framework").CheckboxProperty<false>;
5
+ url: import("@agnocon/pieces-framework").ShortTextProperty<false>;
6
+ cache_time: import("@agnocon/pieces-framework").NumberProperty<false>;
7
+ }>;
8
+ //# sourceMappingURL=telegram-answer-callback-query.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telegram-answer-callback-query.d.ts","sourceRoot":"","sources":["../../../src/lib/action/telegram-answer-callback-query.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,2BAA2B;;;;;;EAyDtC,CAAC"}
@@ -0,0 +1,68 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.telegramAnswerCallbackQuery = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/telegram-bot/src/lib/action/telegram-answer-callback-query.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
8
+ const pieces_common_1 = require("@agnocon/pieces-common");
9
+ const common_1 = require("../common");
10
+ const __1 = require("../..");
11
+ const output_schemas_1 = require("../output-schemas");
12
+ exports.telegramAnswerCallbackQuery = (0, pieces_framework_1.createAction)({
13
+ auth: __1.telegramBotAuth,
14
+ name: 'telegram_answer_callback_query',
15
+ displayName: 'Answer Callback Query',
16
+ description: 'Respond to a callback query raised by an inline keyboard button tap.',
17
+ audience: 'ai',
18
+ aiMetadata: {
19
+ description: 'Acknowledges a callback query raised when a user taps an inline keyboard button, identified by callback_query_id (from the callback-query trigger payload), optionally showing a toast or alert. Use to stop the button spinner and give feedback; a given query can be answered only once. Not idempotent: it is a one-time response to that query.',
20
+ idempotent: false,
21
+ },
22
+ outputSchema: output_schemas_1.telegramAnswerCallbackQueryActionOutputSchema,
23
+ props: {
24
+ callback_query_id: pieces_framework_1.Property.ShortText({
25
+ displayName: 'Callback Query Id',
26
+ description: 'Unique identifier of the callback query. Available on callback_query.id in the New Callback Query trigger payload.',
27
+ required: true,
28
+ }),
29
+ text: pieces_framework_1.Property.LongText({
30
+ displayName: 'Text',
31
+ description: 'Text shown to the user. If not specified, nothing is shown (the spinner is just stopped).',
32
+ required: false,
33
+ }),
34
+ show_alert: pieces_framework_1.Property.Checkbox({
35
+ displayName: 'Show Alert',
36
+ description: 'If True, an alert dialog is shown instead of a notification at the top of the screen.',
37
+ required: false,
38
+ defaultValue: false,
39
+ }),
40
+ url: pieces_framework_1.Property.ShortText({
41
+ displayName: 'URL',
42
+ description: 'URL that will be opened by the user.',
43
+ required: false,
44
+ }),
45
+ cache_time: pieces_framework_1.Property.Number({
46
+ displayName: 'Cache Time (seconds)',
47
+ description: 'The maximum amount of time in seconds the result of the callback query may be cached client-side.',
48
+ required: false,
49
+ }),
50
+ },
51
+ run(ctx) {
52
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
53
+ var _a, _b, _c, _d;
54
+ return yield pieces_common_1.httpClient.sendRequest({
55
+ method: pieces_common_1.HttpMethod.POST,
56
+ url: common_1.telegramCommons.getApiUrl(ctx.auth, 'answerCallbackQuery'),
57
+ body: {
58
+ callback_query_id: ctx.propsValue.callback_query_id,
59
+ text: (_a = ctx.propsValue.text) !== null && _a !== void 0 ? _a : undefined,
60
+ show_alert: (_b = ctx.propsValue.show_alert) !== null && _b !== void 0 ? _b : false,
61
+ url: (_c = ctx.propsValue.url) !== null && _c !== void 0 ? _c : undefined,
62
+ cache_time: (_d = ctx.propsValue.cache_time) !== null && _d !== void 0 ? _d : undefined,
63
+ },
64
+ });
65
+ });
66
+ },
67
+ });
68
+ //# sourceMappingURL=telegram-answer-callback-query.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telegram-answer-callback-query.js","sourceRoot":"","sources":["../../../src/lib/action/telegram-answer-callback-query.ts"],"names":[],"mappings":";;;;AAAA,4HAA4H;AAC5H,qEAAqE;AACrE,gEAAmE;AACnE,0DAAgE;AAChE,sCAA4C;AAC5C,6BAAwC;AACxC,sDAAkF;AAErE,QAAA,2BAA2B,GAAG,IAAA,+BAAY,EAAC;IACtD,IAAI,EAAE,mBAAe;IACrB,IAAI,EAAE,gCAAgC;IACtC,WAAW,EAAE,uBAAuB;IACpC,WAAW,EAAE,sEAAsE;IACnF,QAAQ,EAAE,IAAI;IACd,UAAU,EAAE;QACV,WAAW,EACT,sVAAsV;QACxV,UAAU,EAAE,KAAK;KAClB;IACD,YAAY,EAAE,8DAA6C;IAC3D,KAAK,EAAE;QACL,iBAAiB,EAAE,2BAAQ,CAAC,SAAS,CAAC;YACpC,WAAW,EAAE,mBAAmB;YAChC,WAAW,EACT,oHAAoH;YACtH,QAAQ,EAAE,IAAI;SACf,CAAC;QACF,IAAI,EAAE,2BAAQ,CAAC,QAAQ,CAAC;YACtB,WAAW,EAAE,MAAM;YACnB,WAAW,EACT,2FAA2F;YAC7F,QAAQ,EAAE,KAAK;SAChB,CAAC;QACF,UAAU,EAAE,2BAAQ,CAAC,QAAQ,CAAC;YAC5B,WAAW,EAAE,YAAY;YACzB,WAAW,EACT,uFAAuF;YACzF,QAAQ,EAAE,KAAK;YACf,YAAY,EAAE,KAAK;SACpB,CAAC;QACF,GAAG,EAAE,2BAAQ,CAAC,SAAS,CAAC;YACtB,WAAW,EAAE,KAAK;YAClB,WAAW,EAAE,sCAAsC;YACnD,QAAQ,EAAE,KAAK;SAChB,CAAC;QACF,UAAU,EAAE,2BAAQ,CAAC,MAAM,CAAC;YAC1B,WAAW,EAAE,sBAAsB;YACnC,WAAW,EACT,mGAAmG;YACrG,QAAQ,EAAE,KAAK;SAChB,CAAC;KACH;IACK,GAAG,CAAC,GAAG;;;YACX,OAAO,MAAM,0BAAU,CAAC,WAAW,CAAQ;gBACzC,MAAM,EAAE,0BAAU,CAAC,IAAI;gBACvB,GAAG,EAAE,wBAAe,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,EAAE,qBAAqB,CAAC;gBAC/D,IAAI,EAAE;oBACJ,iBAAiB,EAAE,GAAG,CAAC,UAAU,CAAC,iBAAiB;oBACnD,IAAI,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,IAAI,mCAAI,SAAS;oBACtC,UAAU,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,UAAU,mCAAI,KAAK;oBAC9C,GAAG,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,GAAG,mCAAI,SAAS;oBACpC,UAAU,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,UAAU,mCAAI,SAAS;iBACnD;aACF,CAAC,CAAC;QACL,CAAC;KAAA;CACF,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ export declare const telegramCreateInviteLink: import("@agnocon/pieces-framework").IAction<import("@agnocon/pieces-framework").SecretTextProperty<true>, {
2
+ chat_id: import("@agnocon/pieces-framework").ShortTextProperty<true>;
3
+ name: import("@agnocon/pieces-framework").ShortTextProperty<false>;
4
+ expire_date: import("@agnocon/pieces-framework").DateTimeProperty<false>;
5
+ member_limit: import("@agnocon/pieces-framework").NumberProperty<false>;
6
+ creates_join_request: import("@agnocon/pieces-framework").CheckboxProperty<false>;
7
+ }>;
8
+ //# sourceMappingURL=telegram-create-invite-link.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telegram-create-invite-link.d.ts","sourceRoot":"","sources":["../../../src/lib/action/telegram-create-invite-link.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,wBAAwB;;;;;;EAuDnC,CAAC"}
@@ -0,0 +1,68 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.telegramCreateInviteLink = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/telegram-bot/src/lib/action/telegram-create-invite-link.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const pieces_common_1 = require("@agnocon/pieces-common");
8
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
9
+ const __1 = require("../..");
10
+ const common_1 = require("../common");
11
+ const output_schemas_1 = require("../output-schemas");
12
+ exports.telegramCreateInviteLink = (0, pieces_framework_1.createAction)({
13
+ auth: __1.telegramBotAuth,
14
+ name: 'telegram_create_invite_link',
15
+ displayName: 'Create Invite Link',
16
+ description: 'Create a new invite link for a Telegram chat.',
17
+ audience: 'ai',
18
+ aiMetadata: {
19
+ description: 'Creates a new invite link for a chat by chat_id (a numeric id or @channelusername the bot can reach), optionally with a name, expiry, member limit, or join-request approval. Use to generate a shareable join link; the bot must be an administrator with invite rights. Not idempotent: each call mints a distinct new link (it does not reuse or revoke prior links).',
20
+ idempotent: false,
21
+ },
22
+ outputSchema: output_schemas_1.telegramCreateInviteLinkActionOutputSchema,
23
+ props: {
24
+ chat_id: common_1.telegramCommons.chatIdProp(),
25
+ name: pieces_framework_1.Property.ShortText({
26
+ displayName: 'Name',
27
+ description: 'Name of the invite link (max 32 chars).',
28
+ required: false,
29
+ }),
30
+ expire_date: pieces_framework_1.Property.DateTime({
31
+ displayName: 'Expire Date',
32
+ description: 'Point in time when the link will expire.',
33
+ required: false,
34
+ }),
35
+ member_limit: pieces_framework_1.Property.Number({
36
+ displayName: 'Member Limit',
37
+ description: 'Maximum number of users that can be members of the chat simultaneously after joining via this invite link; 1-99999.',
38
+ required: false,
39
+ }),
40
+ creates_join_request: pieces_framework_1.Property.Checkbox({
41
+ displayName: 'Creates Join Request',
42
+ description: 'If True, users joining the chat via the link need to be approved by chat administrators.',
43
+ required: false,
44
+ defaultValue: false,
45
+ }),
46
+ },
47
+ run(ctx) {
48
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
49
+ var _a, _b, _c;
50
+ const response = yield pieces_common_1.httpClient.sendRequest({
51
+ method: pieces_common_1.HttpMethod.POST,
52
+ url: common_1.telegramCommons.getApiUrl(ctx.auth, 'createChatInviteLink'),
53
+ headers: {},
54
+ body: {
55
+ chat_id: ctx.propsValue.chat_id,
56
+ name: (_a = ctx.propsValue.name) !== null && _a !== void 0 ? _a : undefined,
57
+ expire_date: ctx.propsValue.expire_date
58
+ ? Math.floor(new Date(ctx.propsValue.expire_date).getTime() / 1000)
59
+ : undefined,
60
+ member_limit: (_b = ctx.propsValue.member_limit) !== null && _b !== void 0 ? _b : undefined,
61
+ creates_join_request: (_c = ctx.propsValue.creates_join_request) !== null && _c !== void 0 ? _c : false,
62
+ },
63
+ });
64
+ return response.body;
65
+ });
66
+ },
67
+ });
68
+ //# sourceMappingURL=telegram-create-invite-link.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telegram-create-invite-link.js","sourceRoot":"","sources":["../../../src/lib/action/telegram-create-invite-link.ts"],"names":[],"mappings":";;;;AAAA,yHAAyH;AACzH,qEAAqE;AACrE,0DAAgE;AAChE,gEAAmE;AACnE,6BAAwC;AACxC,sCAA4C;AAC5C,sDAA+E;A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UAAU,CAAC,IAAI,mCAAI,SAAS;oBACtC,WAAW,EAAE,GAAG,CAAC,UAAU,CAAC,WAAW;wBACrC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,GAAG,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC,OAAO,EAAE,GAAG,IAAI,CAAC;wBACnE,CAAC,CAAC,SAAS;oBACb,YAAY,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,YAAY,mCAAI,SAAS;oBACtD,oBAAoB,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,oBAAoB,mCAAI,KAAK;iBACnE;aACF,CAAC,CAAC;YACH,OAAO,QAAQ,CAAC,IAAI,CAAC;QACvB,CAAC;KAAA;CACF,CAAC,CAAC"}
@@ -0,0 +1,5 @@
1
+ export declare const telegramDeleteMessage: import("@agnocon/pieces-framework").IAction<import("@agnocon/pieces-framework").SecretTextProperty<true>, {
2
+ chat_id: import("@agnocon/pieces-framework").ShortTextProperty<true>;
3
+ message_id: import("@agnocon/pieces-framework").ShortTextProperty<true>;
4
+ }>;
5
+ //# sourceMappingURL=telegram-delete-message.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telegram-delete-message.d.ts","sourceRoot":"","sources":["../../../src/lib/action/telegram-delete-message.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,qBAAqB;;;EA8BhC,CAAC"}
@@ -0,0 +1,44 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.telegramDeleteMessage = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/telegram-bot/src/lib/action/telegram-delete-message.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
8
+ const pieces_common_1 = require("@agnocon/pieces-common");
9
+ const common_1 = require("../common");
10
+ const __1 = require("../..");
11
+ const output_schemas_1 = require("../output-schemas");
12
+ exports.telegramDeleteMessage = (0, pieces_framework_1.createAction)({
13
+ auth: __1.telegramBotAuth,
14
+ name: 'telegram_delete_message',
15
+ displayName: 'Delete Message',
16
+ description: 'Delete a message from a Telegram chat.',
17
+ audience: 'ai',
18
+ aiMetadata: {
19
+ description: 'Permanently removes a message from a chat, targeted by chat_id (a numeric id or @channelusername the bot can reach) and message_id (from a prior send action\'s return or the New Message trigger payload). Use to clean up or retract content; the bot can delete only its own messages, or any message in groups where it is an administrator. Idempotent in effect: the message ends up gone regardless of how many times this runs.',
20
+ idempotent: true,
21
+ },
22
+ outputSchema: output_schemas_1.telegramDeleteMessageActionOutputSchema,
23
+ props: {
24
+ chat_id: common_1.telegramCommons.chatIdProp(),
25
+ message_id: pieces_framework_1.Property.ShortText({
26
+ displayName: 'Message Id',
27
+ description: 'Identifier of the message to delete.',
28
+ required: true,
29
+ }),
30
+ },
31
+ run(ctx) {
32
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
33
+ return yield pieces_common_1.httpClient.sendRequest({
34
+ method: pieces_common_1.HttpMethod.POST,
35
+ url: common_1.telegramCommons.getApiUrl(ctx.auth, 'deleteMessage'),
36
+ body: {
37
+ chat_id: ctx.propsValue.chat_id,
38
+ message_id: ctx.propsValue.message_id,
39
+ },
40
+ });
41
+ });
42
+ },
43
+ });
44
+ //# sourceMappingURL=telegram-delete-message.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telegram-delete-message.js","sourceRoot":"","sources":["../../../src/lib/action/telegram-delete-message.ts"],"names":[],"mappings":";;;;AAAA,qHAAqH;AACrH,qEAAqE;AACrE,gEAAmE;AACnE,0DAAgE;AAChE,sCAA4C;AAC5C,6BAAwC;AACxC,sDAA4E;AAE/D,QAAA,qBAAqB,GAAG,IAAA,+BAAY,EAAC;IAChD,IAAI,EAAE,mBAAe;IACrB,IAAI,EAAE,yBAAyB;IAC/B,WAAW,EAAE,gBAAgB;IAC7B,WAAW,EAAE,wCAAwC;IACrD,QAAQ,EAAE,IAAI;IACd,UAAU,EAAE;QACV,WAAW,EACT,yaAAya;QAC3a,UAAU,EAAE,IAAI;KACjB;IACD,YAAY,EAAE,wDAAuC;IACrD,KAAK,EAAE;QACL,OAAO,EAAE,wBAAe,CAAC,UAAU,EAAE;QACrC,UAAU,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC7B,WAAW,EAAE,YAAY;YACzB,WAAW,EAAE,sCAAsC;YACnD,QAAQ,EAAE,IAAI;SACf,CAAC;KACH;IACK,GAAG,CAAC,GAAG;;YACX,OAAO,MAAM,0BAAU,CAAC,WAAW,CAAQ;gBACzC,MAAM,EAAE,0BAAU,CAAC,IAAI;gBACvB,GAAG,EAAE,wBAAe,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,EAAE,eAAe,CAAC;gBACzD,IAAI,EAAE;oBACJ,OAAO,EAAE,GAAG,CAAC,UAAU,CAAC,OAAO;oBAC/B,UAAU,EAAE,GAAG,CAAC,UAAU,CAAC,UAAU;iBACtC;aACF,CAAC,CAAC;QACL,CAAC;KAAA;CACF,CAAC,CAAC"}
@@ -0,0 +1,10 @@
1
+ export declare const telegramEditMessageText: import("@agnocon/pieces-framework").IAction<import("@agnocon/pieces-framework").SecretTextProperty<true>, {
2
+ chat_id: import("@agnocon/pieces-framework").ShortTextProperty<false>;
3
+ message_id: import("@agnocon/pieces-framework").ShortTextProperty<false>;
4
+ inline_message_id: import("@agnocon/pieces-framework").ShortTextProperty<false>;
5
+ text: import("@agnocon/pieces-framework").LongTextProperty<true>;
6
+ format: import("@agnocon/pieces-framework").StaticDropdownProperty<string, false>;
7
+ disable_web_page_preview: import("@agnocon/pieces-framework").CheckboxProperty<false>;
8
+ reply_markup: import("@agnocon/pieces-framework").JsonProperty<false>;
9
+ }>;
10
+ //# sourceMappingURL=telegram-edit-message-text.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telegram-edit-message-text.d.ts","sourceRoot":"","sources":["../../../src/lib/action/telegram-edit-message-text.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,uBAAuB;;;;;;;;EAqFlC,CAAC"}
@@ -0,0 +1,93 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.telegramEditMessageText = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Vendored from Activepieces packages/pieces/community/telegram-bot/src/lib/action/telegram-edit-message-text.ts (MIT).
6
+ // Generated by packages/scripts/vendor-ap.mjs - do not edit by hand.
7
+ const pieces_framework_1 = require("@agnocon/pieces-framework");
8
+ const pieces_common_1 = require("@agnocon/pieces-common");
9
+ const common_1 = require("../common");
10
+ const __1 = require("../..");
11
+ const output_schemas_1 = require("../output-schemas");
12
+ exports.telegramEditMessageText = (0, pieces_framework_1.createAction)({
13
+ auth: __1.telegramBotAuth,
14
+ name: 'telegram_edit_message_text',
15
+ displayName: 'Edit Message Text',
16
+ description: 'Edit the text of a message the bot already sent.',
17
+ audience: 'ai',
18
+ aiMetadata: {
19
+ description: 'Replaces the text of a message the bot already sent, targeted by chat_id + message_id OR by inline_message_id (the two modes are mutually exclusive — resolve message_id from the send action\'s return or the New Message trigger payload). Use to update a status or correct a message in place instead of sending a new one. Text is sent as plain text unless format is set; if you set MarkdownV2 or HTML the text must be correctly escaped or Telegram rejects it. Idempotent in effect (the message ends at the given text), but Telegram rejects an edit whose new text matches the current content.',
20
+ idempotent: true,
21
+ },
22
+ outputSchema: output_schemas_1.telegramEditMessageTextActionOutputSchema,
23
+ props: {
24
+ chat_id: pieces_framework_1.Property.ShortText({
25
+ displayName: 'Chat Id',
26
+ description: 'Numeric id or @channelusername of the chat holding the message. Required together with Message Id; leave empty when editing an inline message (use Inline Message Id instead).',
27
+ required: false,
28
+ }),
29
+ message_id: pieces_framework_1.Property.ShortText({
30
+ displayName: 'Message Id',
31
+ description: 'Identifier of the message to edit (used together with Chat Id).',
32
+ required: false,
33
+ }),
34
+ inline_message_id: pieces_framework_1.Property.ShortText({
35
+ displayName: 'Inline Message Id',
36
+ description: 'Identifier of the inline message (mutually exclusive with Chat Id + Message Id).',
37
+ required: false,
38
+ }),
39
+ text: pieces_framework_1.Property.LongText({
40
+ displayName: 'New Text',
41
+ description: 'New text of the message (1–4096 chars).',
42
+ required: true,
43
+ }),
44
+ format: pieces_framework_1.Property.StaticDropdown({
45
+ displayName: 'Format',
46
+ description: 'How the message text should be parsed by Telegram. Defaults to plain text; only set MarkdownV2 or HTML when the text is correctly escaped/tagged.',
47
+ required: false,
48
+ options: {
49
+ options: [
50
+ { label: 'Plain Text', value: 'None' },
51
+ { label: 'Markdown (V2)', value: 'MarkdownV2' },
52
+ { label: 'HTML', value: 'HTML' },
53
+ ],
54
+ },
55
+ defaultValue: 'None',
56
+ }),
57
+ disable_web_page_preview: pieces_framework_1.Property.Checkbox({
58
+ displayName: 'Disable Web Page Preview',
59
+ description: 'Disable link previews for links in this message.',
60
+ required: false,
61
+ defaultValue: false,
62
+ }),
63
+ reply_markup: pieces_framework_1.Property.Json({
64
+ displayName: 'Reply Markup',
65
+ description: 'Advanced/optional. A raw JSON-serialized inline keyboard, e.g. {"inline_keyboard":[[{"text":"Open","url":"https://example.com"}]]}. Malformed markup is rejected by Telegram.',
66
+ required: false,
67
+ }),
68
+ },
69
+ run(ctx) {
70
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
71
+ var _a, _b, _c, _d, _e;
72
+ const hasChatTarget = Boolean(ctx.propsValue.chat_id && ctx.propsValue.message_id);
73
+ const hasInlineTarget = Boolean(ctx.propsValue.inline_message_id);
74
+ if (!hasChatTarget && !hasInlineTarget) {
75
+ throw new Error('Either Chat Id + Message Id, or Inline Message Id, must be provided.');
76
+ }
77
+ return yield pieces_common_1.httpClient.sendRequest({
78
+ method: pieces_common_1.HttpMethod.POST,
79
+ url: common_1.telegramCommons.getApiUrl(ctx.auth, 'editMessageText'),
80
+ body: {
81
+ chat_id: (_a = ctx.propsValue.chat_id) !== null && _a !== void 0 ? _a : undefined,
82
+ message_id: (_b = ctx.propsValue.message_id) !== null && _b !== void 0 ? _b : undefined,
83
+ inline_message_id: (_c = ctx.propsValue.inline_message_id) !== null && _c !== void 0 ? _c : undefined,
84
+ text: ctx.propsValue.text,
85
+ parse_mode: common_1.telegramCommons.resolveParseMode(ctx.propsValue.format),
86
+ disable_web_page_preview: (_d = ctx.propsValue.disable_web_page_preview) !== null && _d !== void 0 ? _d : false,
87
+ reply_markup: (_e = ctx.propsValue.reply_markup) !== null && _e !== void 0 ? _e : undefined,
88
+ },
89
+ });
90
+ });
91
+ },
92
+ });
93
+ //# sourceMappingURL=telegram-edit-message-text.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telegram-edit-message-text.js","sourceRoot":"","sources":["../../../src/lib/action/telegram-edit-message-text.ts"],"names":[],"mappings":";;;;AAAA,wHAAwH;AACxH,qEAAqE;AACrE,gEAAmE;AACnE,0DAAgE;AAChE,sCAA4C;AAC5C,6BAAwC;AACxC,sDAA8E;AAEjE,QAAA,uBAAuB,GAAG,IAAA,+BAAY,EAAC;IAClD,IAAI,EAAE,mBAAe;IACrB,IAAI,EAAE,4BAA4B;IAClC,WAAW,EAAE,mBAAmB;IAChC,WAAW,EAAE,kDAAkD;IAC/D,QAAQ,EAAE,IAAI;IACd,UAAU,EAAE;QACV,WAAW,EACT,+kBAA+kB;QACjlB,UAAU,EAAE,IAAI;KACjB;IACD,YAAY,EAAE,0DAAyC;IACvD,KAAK,EAAE;QACL,OAAO,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC1B,WAAW,EAAE,SAAS;YACtB,WAAW,EACT,gLAAgL;YAClL,QAAQ,EAAE,KAAK;SAChB,CAAC;QACF,UAAU,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC7B,WAAW,EAAE,YAAY;YACzB,WAAW,EAAE,iEAAiE;YAC9E,QAAQ,EAAE,KAAK;SAChB,CAAC;QACF,iBAAiB,EAAE,2BAAQ,CAAC,SAAS,CAAC;YACpC,WAAW,EAAE,mBAAmB;YAChC,WAAW,EACT,kFAAkF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AQ;gBACzC,MAAM,EAAE,0BAAU,CAAC,IAAI;gBACvB,GAAG,EAAE,wBAAe,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,EAAE,iBAAiB,CAAC;gBAC3D,IAAI,EAAE;oBACJ,OAAO,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,OAAO,mCAAI,SAAS;oBAC5C,UAAU,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,UAAU,mCAAI,SAAS;oBAClD,iBAAiB,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,iBAAiB,mCAAI,SAAS;oBAChE,IAAI,EAAE,GAAG,CAAC,UAAU,CAAC,IAAI;oBACzB,UAAU,EAAE,wBAAe,CAAC,gBAAgB,CAAC,GAAG,CAAC,UAAU,CAAC,MAAM,CAAC;oBACnE,wBAAwB,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,wBAAwB,mCAAI,KAAK;oBAC1E,YAAY,EAAE,MAAA,GAAG,CAAC,UAAU,CAAC,YAAY,mCAAI,SAAS;iBACvD;aACF,CAAC,CAAC;QACL,CAAC;KAAA;CACF,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ export declare const telegramForwardMessage: import("@agnocon/pieces-framework").IAction<import("@agnocon/pieces-framework").SecretTextProperty<true>, {
2
+ chat_id: import("@agnocon/pieces-framework").ShortTextProperty<true>;
3
+ from_chat_id: import("@agnocon/pieces-framework").ShortTextProperty<true>;
4
+ message_id: import("@agnocon/pieces-framework").ShortTextProperty<true>;
5
+ message_thread_id: import("@agnocon/pieces-framework").ShortTextProperty<false>;
6
+ disable_notification: import("@agnocon/pieces-framework").CheckboxProperty<false>;
7
+ protect_content: import("@agnocon/pieces-framework").CheckboxProperty<false>;
8
+ }>;
9
+ //# sourceMappingURL=telegram-forward-message.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"telegram-forward-message.d.ts","sourceRoot":"","sources":["../../../src/lib/action/telegram-forward-message.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,sBAAsB;;;;;;;EA+CjC,CAAC"}