runline 0.2.1 → 0.2.2

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 (189) hide show
  1. package/dist/plugins/actionNetwork/src/index.js +118 -25
  2. package/dist/plugins/activeCampaign/src/index.js +184 -38
  3. package/dist/plugins/adalo/src/index.js +40 -8
  4. package/dist/plugins/affinity/src/index.js +100 -20
  5. package/dist/plugins/agileCrm/src/index.js +115 -27
  6. package/dist/plugins/airtable/src/index.js +94 -19
  7. package/dist/plugins/airtop/src/index.js +266 -62
  8. package/dist/plugins/apiTemplateIo/src/index.js +25 -5
  9. package/dist/plugins/asana/src/index.js +195 -41
  10. package/dist/plugins/autopilot/src/index.js +39 -8
  11. package/dist/plugins/bambooHr/src/index.js +109 -22
  12. package/dist/plugins/bannerbear/src/index.js +36 -8
  13. package/dist/plugins/baserow/src/index.js +35 -7
  14. package/dist/plugins/beeminder/src/index.js +198 -40
  15. package/dist/plugins/bitly/src/index.js +46 -10
  16. package/dist/plugins/bitwarden/src/index.js +167 -36
  17. package/dist/plugins/box/src/index.js +172 -37
  18. package/dist/plugins/brandfetch/src/index.js +5 -1
  19. package/dist/plugins/brevo/src/index.js +136 -29
  20. package/dist/plugins/bubble/src/index.js +76 -17
  21. package/dist/plugins/chargebee/src/index.js +35 -7
  22. package/dist/plugins/circleci/src/index.js +50 -10
  23. package/dist/plugins/ciscoWebex/src/index.js +131 -27
  24. package/dist/plugins/clearbit/src/index.js +76 -17
  25. package/dist/plugins/clickup/src/index.js +500 -107
  26. package/dist/plugins/clockify/src/index.js +229 -47
  27. package/dist/plugins/cloudflare/src/index.js +28 -6
  28. package/dist/plugins/cockpit/src/index.js +54 -12
  29. package/dist/plugins/coda/src/index.js +81 -19
  30. package/dist/plugins/coingecko/src/index.js +157 -33
  31. package/dist/plugins/contentful/src/index.js +85 -17
  32. package/dist/plugins/convertkit/src/index.js +74 -18
  33. package/dist/plugins/copper/src/index.js +59 -11
  34. package/dist/plugins/cortex/src/index.js +55 -13
  35. package/dist/plugins/currents/src/index.js +310 -71
  36. package/dist/plugins/customerIo/src/index.js +112 -23
  37. package/dist/plugins/databricks/src/index.js +549 -115
  38. package/dist/plugins/deepl/src/index.js +26 -6
  39. package/dist/plugins/demio/src/index.js +56 -11
  40. package/dist/plugins/dhl/src/index.js +16 -3
  41. package/dist/plugins/discord/src/index.js +141 -31
  42. package/dist/plugins/discourse/src/index.js +136 -31
  43. package/dist/plugins/disqus/src/index.js +96 -20
  44. package/dist/plugins/docker/src/index.js +20 -4
  45. package/dist/plugins/drift/src/index.js +19 -5
  46. package/dist/plugins/dropbox/src/index.js +139 -30
  47. package/dist/plugins/dropcontact/src/index.js +21 -4
  48. package/dist/plugins/egoi/src/index.js +61 -15
  49. package/dist/plugins/elasticsearch/src/index.js +59 -13
  50. package/dist/plugins/emelia/src/index.js +95 -19
  51. package/dist/plugins/erpnext/src/index.js +74 -15
  52. package/dist/plugins/facebookGraph/src/index.js +52 -11
  53. package/dist/plugins/freshdesk/src/index.js +220 -48
  54. package/dist/plugins/freshservice/src/index.js +39 -9
  55. package/dist/plugins/freshworksCrm/src/index.js +58 -12
  56. package/dist/plugins/getresponse/src/index.js +87 -18
  57. package/dist/plugins/ghost/src/index.js +114 -26
  58. package/dist/plugins/github/src/index.js +483 -109
  59. package/dist/plugins/gitlab/src/index.js +193 -45
  60. package/dist/plugins/gong/src/index.js +68 -14
  61. package/dist/plugins/gotify/src/index.js +43 -9
  62. package/dist/plugins/gotowebinar/src/index.js +233 -47
  63. package/dist/plugins/grafana/src/index.js +92 -21
  64. package/dist/plugins/graphql/src/index.js +38 -8
  65. package/dist/plugins/grist/src/index.js +52 -10
  66. package/dist/plugins/hackernews/src/index.js +32 -6
  67. package/dist/plugins/halopsa/src/index.js +131 -26
  68. package/dist/plugins/harvest/src/index.js +182 -42
  69. package/dist/plugins/helpscout/src/index.js +153 -31
  70. package/dist/plugins/highlevel/src/index.js +291 -58
  71. package/dist/plugins/homeAssistant/src/index.js +124 -26
  72. package/dist/plugins/hubspot/src/index.js +163 -29
  73. package/dist/plugins/humanticAi/src/index.js +54 -5
  74. package/dist/plugins/hunter/src/index.js +21 -4
  75. package/dist/plugins/intercom/src/index.js +95 -20
  76. package/dist/plugins/iterable/src/index.js +96 -20
  77. package/dist/plugins/jenkins/src/index.js +75 -17
  78. package/dist/plugins/jira/src/index.js +193 -43
  79. package/dist/plugins/keap/src/index.js +222 -56
  80. package/dist/plugins/kobotoolbox/src/index.js +113 -25
  81. package/dist/plugins/lemlist/src/index.js +79 -18
  82. package/dist/plugins/linear/src/index.js +86 -19
  83. package/dist/plugins/lingvanex/src/index.js +38 -8
  84. package/dist/plugins/linkedin/src/index.js +37 -8
  85. package/dist/plugins/lonescale/src/index.js +41 -9
  86. package/dist/plugins/magento/src/index.js +98 -27
  87. package/dist/plugins/mailcheck/src/index.js +11 -2
  88. package/dist/plugins/mailchimp/src/index.js +193 -42
  89. package/dist/plugins/mailerlite/src/index.js +61 -12
  90. package/dist/plugins/mailgun/src/index.js +39 -7
  91. package/dist/plugins/mailjet/src/index.js +141 -30
  92. package/dist/plugins/mandrill/src/index.js +67 -14
  93. package/dist/plugins/marketstack/src/index.js +56 -10
  94. package/dist/plugins/matrix/src/index.js +97 -20
  95. package/dist/plugins/mattermost/src/index.js +124 -26
  96. package/dist/plugins/mautic/src/index.js +129 -26
  97. package/dist/plugins/medium/src/index.js +64 -13
  98. package/dist/plugins/messagebird/src/index.js +80 -15
  99. package/dist/plugins/metabase/src/index.js +57 -12
  100. package/dist/plugins/misp/src/index.js +135 -33
  101. package/dist/plugins/mocean/src/index.js +33 -7
  102. package/dist/plugins/monday/src/index.js +97 -23
  103. package/dist/plugins/monicaCrm/src/index.js +112 -23
  104. package/dist/plugins/msg91/src/index.js +11 -2
  105. package/dist/plugins/nasa/src/index.js +108 -21
  106. package/dist/plugins/netlify/src/index.js +28 -6
  107. package/dist/plugins/netscalerAdc/src/index.js +144 -29
  108. package/dist/plugins/nextcloud/src/index.js +103 -20
  109. package/dist/plugins/nocodb/src/index.js +57 -11
  110. package/dist/plugins/notion/src/index.js +148 -37
  111. package/dist/plugins/npm/src/index.js +59 -12
  112. package/dist/plugins/odoo/src/index.js +102 -20
  113. package/dist/plugins/okta/src/index.js +50 -10
  114. package/dist/plugins/oneSimpleApi/src/index.js +84 -17
  115. package/dist/plugins/onfleet/src/index.js +139 -32
  116. package/dist/plugins/openThesaurus/src/index.js +46 -9
  117. package/dist/plugins/openweathermap/src/index.js +31 -6
  118. package/dist/plugins/oura/src/index.js +36 -7
  119. package/dist/plugins/paddle/src/index.js +80 -17
  120. package/dist/plugins/pagerduty/src/index.js +53 -12
  121. package/dist/plugins/paypal/src/index.js +51 -11
  122. package/dist/plugins/peekalink/src/index.js +12 -3
  123. package/dist/plugins/phantombuster/src/index.js +39 -8
  124. package/dist/plugins/philipsHue/src/index.js +64 -13
  125. package/dist/plugins/pipedrive/src/index.js +167 -45
  126. package/dist/plugins/plivo/src/index.js +43 -8
  127. package/dist/plugins/postbin/src/index.js +9 -2
  128. package/dist/plugins/posthog/src/index.js +50 -13
  129. package/dist/plugins/profitwell/src/index.js +24 -5
  130. package/dist/plugins/pushbullet/src/index.js +45 -9
  131. package/dist/plugins/pushcut/src/index.js +31 -6
  132. package/dist/plugins/pushover/src/index.js +51 -10
  133. package/dist/plugins/quickbase/src/index.js +66 -13
  134. package/dist/plugins/quickbooks/src/index.js +86 -19
  135. package/dist/plugins/quickchart/src/index.js +35 -7
  136. package/dist/plugins/raindrop/src/index.js +54 -13
  137. package/dist/plugins/reddit/src/index.js +73 -18
  138. package/dist/plugins/rocketchat/src/index.js +47 -9
  139. package/dist/plugins/rundeck/src/index.js +26 -5
  140. package/dist/plugins/salesforce/src/index.js +161 -31
  141. package/dist/plugins/salesmate/src/index.js +75 -16
  142. package/dist/plugins/securityScorecard/src/index.js +73 -15
  143. package/dist/plugins/segment/src/index.js +21 -4
  144. package/dist/plugins/sendgrid/src/index.js +102 -24
  145. package/dist/plugins/sendy/src/index.js +54 -11
  146. package/dist/plugins/sentry/src/index.js +174 -34
  147. package/dist/plugins/servicenow/src/index.js +120 -27
  148. package/dist/plugins/shopify/src/index.js +53 -12
  149. package/dist/plugins/signl4/src/index.js +16 -3
  150. package/dist/plugins/slack/src/index.js +407 -105
  151. package/dist/plugins/sms77/src/index.js +26 -5
  152. package/dist/plugins/splunk/src/index.js +186 -45
  153. package/dist/plugins/spotify/src/index.js +265 -66
  154. package/dist/plugins/stackby/src/index.js +18 -6
  155. package/dist/plugins/storyblok/src/index.js +57 -11
  156. package/dist/plugins/strapi/src/index.js +63 -12
  157. package/dist/plugins/strava/src/index.js +58 -13
  158. package/dist/plugins/stripe/src/index.js +143 -30
  159. package/dist/plugins/supabase/src/index.js +49 -10
  160. package/dist/plugins/syncromsp/src/index.js +245 -67
  161. package/dist/plugins/tapfiliate/src/index.js +57 -14
  162. package/dist/plugins/telegram/src/index.js +202 -39
  163. package/dist/plugins/thehive/src/index.js +271 -66
  164. package/dist/plugins/thehiveProject/src/index.js +457 -89
  165. package/dist/plugins/todoist/src/index.js +326 -77
  166. package/dist/plugins/travisci/src/index.js +35 -8
  167. package/dist/plugins/trello/src/index.js +204 -46
  168. package/dist/plugins/twake/src/index.js +10 -2
  169. package/dist/plugins/twilio/src/index.js +56 -11
  170. package/dist/plugins/twist/src/index.js +241 -48
  171. package/dist/plugins/twitter/src/index.js +128 -30
  172. package/dist/plugins/unleashedSoftware/src/index.js +30 -6
  173. package/dist/plugins/uplead/src/index.js +9 -2
  174. package/dist/plugins/uproc/src/index.js +31 -6
  175. package/dist/plugins/uptimerobot/src/index.js +119 -25
  176. package/dist/plugins/urlscanio/src/index.js +25 -6
  177. package/dist/plugins/vero/src/index.js +68 -13
  178. package/dist/plugins/vonage/src/index.js +32 -6
  179. package/dist/plugins/wekan/src/index.js +297 -52
  180. package/dist/plugins/woocommerce/src/index.js +57 -12
  181. package/dist/plugins/wordpress/src/index.js +94 -18
  182. package/dist/plugins/xero/src/index.js +79 -13
  183. package/dist/plugins/yourls/src/index.js +33 -6
  184. package/dist/plugins/zammad/src/index.js +139 -36
  185. package/dist/plugins/zendesk/src/index.js +201 -48
  186. package/dist/plugins/zoho/src/index.js +88 -21
  187. package/dist/plugins/zoom/src/index.js +41 -7
  188. package/dist/plugins/zulip/src/index.js +101 -20
  189. package/package.json +1 -1
@@ -1,5 +1,7 @@
1
1
  async function apiRequest(apiKey, isPro, method, endpoint, params) {
2
- const baseUrl = isPro ? "https://api.deepl.com/v2" : "https://api-free.deepl.com/v2";
2
+ const baseUrl = isPro
3
+ ? "https://api.deepl.com/v2"
4
+ : "https://api-free.deepl.com/v2";
3
5
  const url = new URL(`${baseUrl}${endpoint}`);
4
6
  const opts = {
5
7
  method,
@@ -54,9 +56,21 @@ export default function deepl(rl) {
54
56
  rl.registerAction("language.translate", {
55
57
  description: "Translate text to a target language",
56
58
  inputSchema: {
57
- text: { type: "string", required: true, description: "Text to translate" },
58
- targetLang: { type: "string", required: true, description: "Target language code (e.g. DE, FR, ES, EN-US, EN-GB, JA, ZH)" },
59
- sourceLang: { type: "string", required: false, description: "Source language code (auto-detected if omitted)" },
59
+ text: {
60
+ type: "string",
61
+ required: true,
62
+ description: "Text to translate",
63
+ },
64
+ targetLang: {
65
+ type: "string",
66
+ required: true,
67
+ description: "Target language code (e.g. DE, FR, ES, EN-US, EN-GB, JA, ZH)",
68
+ },
69
+ sourceLang: {
70
+ type: "string",
71
+ required: false,
72
+ description: "Source language code (auto-detected if omitted)",
73
+ },
60
74
  },
61
75
  async execute(input, ctx) {
62
76
  const { text, targetLang, sourceLang } = input;
@@ -66,7 +80,9 @@ export default function deepl(rl) {
66
80
  target_lang: targetLang,
67
81
  };
68
82
  if (sourceLang) {
69
- params.source_lang = ["EN-GB", "EN-US"].includes(sourceLang) ? "EN" : sourceLang;
83
+ params.source_lang = ["EN-GB", "EN-US"].includes(sourceLang)
84
+ ? "EN"
85
+ : sourceLang;
70
86
  }
71
87
  const data = (await apiRequest(apiKey, isPro, "POST", "/translate", params));
72
88
  const translations = data.translations;
@@ -76,7 +92,11 @@ export default function deepl(rl) {
76
92
  rl.registerAction("language.list", {
77
93
  description: "List available target languages",
78
94
  inputSchema: {
79
- type: { type: "string", required: false, description: "'source' or 'target' (default: target)" },
95
+ type: {
96
+ type: "string",
97
+ required: false,
98
+ description: "'source' or 'target' (default: target)",
99
+ },
80
100
  },
81
101
  async execute(input, ctx) {
82
102
  const { type = "target" } = (input ?? {});
@@ -15,7 +15,10 @@ async function apiRequest(apiKey, apiSecret, method, endpoint, body, qs) {
15
15
  "Api-Secret": apiSecret,
16
16
  },
17
17
  };
18
- if (body && Object.keys(body).length > 0 && method !== "GET" && method !== "DELETE") {
18
+ if (body &&
19
+ Object.keys(body).length > 0 &&
20
+ method !== "GET" &&
21
+ method !== "DELETE") {
19
22
  opts.body = JSON.stringify(body);
20
23
  }
21
24
  const res = await fetch(url.toString(), opts);
@@ -33,14 +36,28 @@ export default function demio(rl) {
33
36
  rl.setName("demio");
34
37
  rl.setVersion("0.1.0");
35
38
  rl.setConnectionSchema({
36
- apiKey: { type: "string", required: true, description: "Demio API key", env: "DEMIO_API_KEY" },
37
- apiSecret: { type: "string", required: true, description: "Demio API secret", env: "DEMIO_API_SECRET" },
39
+ apiKey: {
40
+ type: "string",
41
+ required: true,
42
+ description: "Demio API key",
43
+ env: "DEMIO_API_KEY",
44
+ },
45
+ apiSecret: {
46
+ type: "string",
47
+ required: true,
48
+ description: "Demio API secret",
49
+ env: "DEMIO_API_SECRET",
50
+ },
38
51
  });
39
52
  rl.registerAction("event.get", {
40
53
  description: "Get an event (optionally a specific session/date)",
41
54
  inputSchema: {
42
55
  eventId: { type: "string", required: true, description: "Event ID" },
43
- dateId: { type: "string", required: false, description: "Date/session ID (for specific session)" },
56
+ dateId: {
57
+ type: "string",
58
+ required: false,
59
+ description: "Date/session ID (for specific session)",
60
+ },
44
61
  },
45
62
  async execute(input, ctx) {
46
63
  const { eventId, dateId } = input;
@@ -54,7 +71,11 @@ export default function demio(rl) {
54
71
  rl.registerAction("event.list", {
55
72
  description: "List events",
56
73
  inputSchema: {
57
- type: { type: "string", required: false, description: "Filter: upcoming, past, all" },
74
+ type: {
75
+ type: "string",
76
+ required: false,
77
+ description: "Filter: upcoming, past, all",
78
+ },
58
79
  limit: { type: "number", required: false, description: "Max results" },
59
80
  },
60
81
  async execute(input, ctx) {
@@ -73,16 +94,32 @@ export default function demio(rl) {
73
94
  description: "Register a person for an event",
74
95
  inputSchema: {
75
96
  eventId: { type: "string", required: true, description: "Event ID" },
76
- email: { type: "string", required: true, description: "Registrant email" },
97
+ email: {
98
+ type: "string",
99
+ required: true,
100
+ description: "Registrant email",
101
+ },
77
102
  firstName: { type: "string", required: true, description: "First name" },
78
103
  lastName: { type: "string", required: false, description: "Last name" },
79
- dateId: { type: "string", required: false, description: "Specific session date ID" },
80
- customFields: { type: "object", required: false, description: "Custom field key-value pairs" },
104
+ dateId: {
105
+ type: "string",
106
+ required: false,
107
+ description: "Specific session date ID",
108
+ },
109
+ customFields: {
110
+ type: "object",
111
+ required: false,
112
+ description: "Custom field key-value pairs",
113
+ },
81
114
  },
82
115
  async execute(input, ctx) {
83
116
  const { eventId, email, firstName, lastName, dateId, customFields } = input;
84
117
  const { apiKey, apiSecret } = getConn(ctx);
85
- const body = { id: eventId, email, name: firstName };
118
+ const body = {
119
+ id: eventId,
120
+ email,
121
+ name: firstName,
122
+ };
86
123
  if (lastName)
87
124
  body.last_name = lastName;
88
125
  if (dateId)
@@ -95,8 +132,16 @@ export default function demio(rl) {
95
132
  rl.registerAction("report.getParticipants", {
96
133
  description: "Get participants report for a session",
97
134
  inputSchema: {
98
- dateId: { type: "string", required: true, description: "Session/date ID" },
99
- status: { type: "string", required: false, description: "Filter: attended, did-not-attend, banned, left-early" },
135
+ dateId: {
136
+ type: "string",
137
+ required: true,
138
+ description: "Session/date ID",
139
+ },
140
+ status: {
141
+ type: "string",
142
+ required: false,
143
+ description: "Filter: attended, did-not-attend, banned, left-early",
144
+ },
100
145
  },
101
146
  async execute(input, ctx) {
102
147
  const { dateId, status } = (input ?? {});
@@ -19,13 +19,26 @@ export default function dhl(rl) {
19
19
  rl.setName("dhl");
20
20
  rl.setVersion("0.1.0");
21
21
  rl.setConnectionSchema({
22
- apiKey: { type: "string", required: true, description: "DHL API key", env: "DHL_API_KEY" },
22
+ apiKey: {
23
+ type: "string",
24
+ required: true,
25
+ description: "DHL API key",
26
+ env: "DHL_API_KEY",
27
+ },
23
28
  });
24
29
  rl.registerAction("shipment.track", {
25
30
  description: "Get tracking details for a shipment",
26
31
  inputSchema: {
27
- trackingNumber: { type: "string", required: true, description: "DHL tracking number" },
28
- recipientPostalCode: { type: "string", required: false, description: "Recipient postal code for more detailed info" },
32
+ trackingNumber: {
33
+ type: "string",
34
+ required: true,
35
+ description: "DHL tracking number",
36
+ },
37
+ recipientPostalCode: {
38
+ type: "string",
39
+ required: false,
40
+ description: "Recipient postal code for more detailed info",
41
+ },
29
42
  },
30
43
  async execute(input, ctx) {
31
44
  const { trackingNumber, recipientPostalCode } = input;
@@ -14,7 +14,10 @@ async function apiRequest(botToken, method, endpoint, body, qs) {
14
14
  "Content-Type": "application/json",
15
15
  },
16
16
  };
17
- if (body && Object.keys(body).length > 0 && method !== "GET" && method !== "DELETE") {
17
+ if (body &&
18
+ Object.keys(body).length > 0 &&
19
+ method !== "GET" &&
20
+ method !== "DELETE") {
18
21
  opts.body = JSON.stringify(body);
19
22
  }
20
23
  const res = await fetch(url.toString(), opts);
@@ -34,26 +37,64 @@ export default function discord(rl) {
34
37
  rl.setName("discord");
35
38
  rl.setVersion("0.1.0");
36
39
  rl.setConnectionSchema({
37
- botToken: { type: "string", required: true, description: "Discord bot token", env: "DISCORD_BOT_TOKEN" },
38
- guildId: { type: "string", required: true, description: "Default guild (server) ID", env: "DISCORD_GUILD_ID" },
40
+ botToken: {
41
+ type: "string",
42
+ required: true,
43
+ description: "Discord bot token",
44
+ env: "DISCORD_BOT_TOKEN",
45
+ },
46
+ guildId: {
47
+ type: "string",
48
+ required: true,
49
+ description: "Default guild (server) ID",
50
+ env: "DISCORD_GUILD_ID",
51
+ },
39
52
  });
40
53
  // ── Channel ─────────────────────────────────────────
41
54
  rl.registerAction("channel.create", {
42
55
  description: "Create a channel in the guild",
43
56
  inputSchema: {
44
57
  name: { type: "string", required: true, description: "Channel name" },
45
- type: { type: "number", required: false, description: "Type: 0=text (default), 2=voice, 4=category" },
46
- topic: { type: "string", required: false, description: "Channel topic (0-1024 chars)" },
47
- parentId: { type: "string", required: false, description: "Category ID to nest under" },
48
- position: { type: "number", required: false, description: "Sorting position" },
58
+ type: {
59
+ type: "number",
60
+ required: false,
61
+ description: "Type: 0=text (default), 2=voice, 4=category",
62
+ },
63
+ topic: {
64
+ type: "string",
65
+ required: false,
66
+ description: "Channel topic (0-1024 chars)",
67
+ },
68
+ parentId: {
69
+ type: "string",
70
+ required: false,
71
+ description: "Category ID to nest under",
72
+ },
73
+ position: {
74
+ type: "number",
75
+ required: false,
76
+ description: "Sorting position",
77
+ },
49
78
  nsfw: { type: "boolean", required: false, description: "Mark as NSFW" },
50
- bitrate: { type: "number", required: false, description: "Bitrate for voice channels (8000-96000)" },
51
- userLimit: { type: "number", required: false, description: "User limit for voice channels (0=no limit)" },
52
- rateLimitPerUser: { type: "number", required: false, description: "Slowmode seconds" },
79
+ bitrate: {
80
+ type: "number",
81
+ required: false,
82
+ description: "Bitrate for voice channels (8000-96000)",
83
+ },
84
+ userLimit: {
85
+ type: "number",
86
+ required: false,
87
+ description: "User limit for voice channels (0=no limit)",
88
+ },
89
+ rateLimitPerUser: {
90
+ type: "number",
91
+ required: false,
92
+ description: "Slowmode seconds",
93
+ },
53
94
  },
54
95
  async execute(input, ctx) {
55
96
  const { botToken, guildId } = getConn(ctx);
56
- const { name, type, topic, parentId, position, nsfw, bitrate, userLimit, rateLimitPerUser } = input;
97
+ const { name, type, topic, parentId, position, nsfw, bitrate, userLimit, rateLimitPerUser, } = input;
57
98
  const body = { name, type: type ?? 0 };
58
99
  if (topic)
59
100
  body.topic = topic;
@@ -74,7 +115,9 @@ export default function discord(rl) {
74
115
  });
75
116
  rl.registerAction("channel.get", {
76
117
  description: "Get a channel by ID",
77
- inputSchema: { channelId: { type: "string", required: true, description: "Channel ID" } },
118
+ inputSchema: {
119
+ channelId: { type: "string", required: true, description: "Channel ID" },
120
+ },
78
121
  async execute(input, ctx) {
79
122
  const { botToken } = getConn(ctx);
80
123
  return apiRequest(botToken, "GET", `/channels/${input.channelId}`);
@@ -84,7 +127,11 @@ export default function discord(rl) {
84
127
  description: "List all channels in the guild",
85
128
  inputSchema: {
86
129
  limit: { type: "number", required: false, description: "Max results" },
87
- filterType: { type: "array", required: false, description: "Filter by type numbers [0,2,4]" },
130
+ filterType: {
131
+ type: "array",
132
+ required: false,
133
+ description: "Filter by type numbers [0,2,4]",
134
+ },
88
135
  },
89
136
  async execute(input, ctx) {
90
137
  const { botToken, guildId } = getConn(ctx);
@@ -104,16 +151,36 @@ export default function discord(rl) {
104
151
  channelId: { type: "string", required: true, description: "Channel ID" },
105
152
  name: { type: "string", required: false, description: "New name" },
106
153
  topic: { type: "string", required: false, description: "New topic" },
107
- parentId: { type: "string", required: false, description: "New category ID" },
108
- position: { type: "number", required: false, description: "New position" },
154
+ parentId: {
155
+ type: "string",
156
+ required: false,
157
+ description: "New category ID",
158
+ },
159
+ position: {
160
+ type: "number",
161
+ required: false,
162
+ description: "New position",
163
+ },
109
164
  nsfw: { type: "boolean", required: false, description: "NSFW flag" },
110
- bitrate: { type: "number", required: false, description: "Bitrate (voice)" },
111
- userLimit: { type: "number", required: false, description: "User limit (voice)" },
112
- rateLimitPerUser: { type: "number", required: false, description: "Slowmode seconds" },
165
+ bitrate: {
166
+ type: "number",
167
+ required: false,
168
+ description: "Bitrate (voice)",
169
+ },
170
+ userLimit: {
171
+ type: "number",
172
+ required: false,
173
+ description: "User limit (voice)",
174
+ },
175
+ rateLimitPerUser: {
176
+ type: "number",
177
+ required: false,
178
+ description: "Slowmode seconds",
179
+ },
113
180
  },
114
181
  async execute(input, ctx) {
115
182
  const { botToken } = getConn(ctx);
116
- const { channelId, name, topic, parentId, position, nsfw, bitrate, userLimit, rateLimitPerUser } = input;
183
+ const { channelId, name, topic, parentId, position, nsfw, bitrate, userLimit, rateLimitPerUser, } = input;
117
184
  const body = {};
118
185
  if (name)
119
186
  body.name = name;
@@ -136,7 +203,9 @@ export default function discord(rl) {
136
203
  });
137
204
  rl.registerAction("channel.delete", {
138
205
  description: "Delete a channel",
139
- inputSchema: { channelId: { type: "string", required: true, description: "Channel ID" } },
206
+ inputSchema: {
207
+ channelId: { type: "string", required: true, description: "Channel ID" },
208
+ },
140
209
  async execute(input, ctx) {
141
210
  const { botToken } = getConn(ctx);
142
211
  return apiRequest(botToken, "DELETE", `/channels/${input.channelId}`);
@@ -146,8 +215,16 @@ export default function discord(rl) {
146
215
  rl.registerAction("member.list", {
147
216
  description: "List members in the guild",
148
217
  inputSchema: {
149
- limit: { type: "number", required: false, description: "Max results (default: 100, max: 1000)" },
150
- after: { type: "string", required: false, description: "Fetch members after this user ID (pagination)" },
218
+ limit: {
219
+ type: "number",
220
+ required: false,
221
+ description: "Max results (default: 100, max: 1000)",
222
+ },
223
+ after: {
224
+ type: "string",
225
+ required: false,
226
+ description: "Fetch members after this user ID (pagination)",
227
+ },
151
228
  },
152
229
  async execute(input, ctx) {
153
230
  const { botToken, guildId } = getConn(ctx);
@@ -191,10 +268,22 @@ export default function discord(rl) {
191
268
  description: "Send a message to a channel",
192
269
  inputSchema: {
193
270
  channelId: { type: "string", required: true, description: "Channel ID" },
194
- content: { type: "string", required: true, description: "Message content (up to 2000 chars)" },
271
+ content: {
272
+ type: "string",
273
+ required: true,
274
+ description: "Message content (up to 2000 chars)",
275
+ },
195
276
  tts: { type: "boolean", required: false, description: "Text-to-speech" },
196
- replyTo: { type: "string", required: false, description: "Message ID to reply to" },
197
- embeds: { type: "array", required: false, description: "Array of embed objects" },
277
+ replyTo: {
278
+ type: "string",
279
+ required: false,
280
+ description: "Message ID to reply to",
281
+ },
282
+ embeds: {
283
+ type: "array",
284
+ required: false,
285
+ description: "Array of embed objects",
286
+ },
198
287
  },
199
288
  async execute(input, ctx) {
200
289
  const { botToken } = getConn(ctx);
@@ -225,14 +314,31 @@ export default function discord(rl) {
225
314
  description: "List messages in a channel",
226
315
  inputSchema: {
227
316
  channelId: { type: "string", required: true, description: "Channel ID" },
228
- limit: { type: "number", required: false, description: "Max results (default: 50, max: 100)" },
229
- before: { type: "string", required: false, description: "Get messages before this ID" },
230
- after: { type: "string", required: false, description: "Get messages after this ID" },
231
- around: { type: "string", required: false, description: "Get messages around this ID" },
317
+ limit: {
318
+ type: "number",
319
+ required: false,
320
+ description: "Max results (default: 50, max: 100)",
321
+ },
322
+ before: {
323
+ type: "string",
324
+ required: false,
325
+ description: "Get messages before this ID",
326
+ },
327
+ after: {
328
+ type: "string",
329
+ required: false,
330
+ description: "Get messages after this ID",
331
+ },
332
+ around: {
333
+ type: "string",
334
+ required: false,
335
+ description: "Get messages around this ID",
336
+ },
232
337
  },
233
338
  async execute(input, ctx) {
234
339
  const { botToken } = getConn(ctx);
235
- const { channelId, limit, before, after, around } = (input ?? {});
340
+ const { channelId, limit, before, after, around } = (input ??
341
+ {});
236
342
  const qs = {};
237
343
  if (limit)
238
344
  qs.limit = limit;
@@ -263,7 +369,11 @@ export default function discord(rl) {
263
369
  inputSchema: {
264
370
  channelId: { type: "string", required: true, description: "Channel ID" },
265
371
  messageId: { type: "string", required: true, description: "Message ID" },
266
- emoji: { type: "string", required: true, description: "Emoji to react with (Unicode or name:id for custom)" },
372
+ emoji: {
373
+ type: "string",
374
+ required: true,
375
+ description: "Emoji to react with (Unicode or name:id for custom)",
376
+ },
267
377
  },
268
378
  async execute(input, ctx) {
269
379
  const { botToken } = getConn(ctx);