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
@@ -2,7 +2,11 @@ const BASE_URL = "https://rest.messagebird.com";
2
2
  async function apiRequest(accessKey, method, endpoint, body) {
3
3
  const opts = {
4
4
  method,
5
- headers: { Authorization: `AccessKey ${accessKey}`, Accept: "application/json", "Content-Type": "application/json" },
5
+ headers: {
6
+ Authorization: `AccessKey ${accessKey}`,
7
+ Accept: "application/json",
8
+ "Content-Type": "application/json",
9
+ },
6
10
  };
7
11
  if (body && Object.keys(body).length > 0 && method !== "GET")
8
12
  opts.body = JSON.stringify(body);
@@ -15,33 +19,94 @@ export default function messagebird(rl) {
15
19
  rl.setName("messagebird");
16
20
  rl.setVersion("0.1.0");
17
21
  rl.setConnectionSchema({
18
- accessKey: { type: "string", required: true, description: "MessageBird access key", env: "MESSAGEBIRD_ACCESS_KEY" },
22
+ accessKey: {
23
+ type: "string",
24
+ required: true,
25
+ description: "MessageBird access key",
26
+ env: "MESSAGEBIRD_ACCESS_KEY",
27
+ },
19
28
  });
20
29
  const key = (ctx) => ctx.connection.config.accessKey;
21
30
  rl.registerAction("sms.send", {
22
31
  description: "Send an SMS message",
23
32
  inputSchema: {
24
- originator: { type: "string", required: true, description: "Sender number or alphanumeric (max 11 chars)" },
25
- recipients: { type: "string", required: true, description: "Comma-separated recipient phone numbers (international format)" },
33
+ originator: {
34
+ type: "string",
35
+ required: true,
36
+ description: "Sender number or alphanumeric (max 11 chars)",
37
+ },
38
+ recipients: {
39
+ type: "string",
40
+ required: true,
41
+ description: "Comma-separated recipient phone numbers (international format)",
42
+ },
26
43
  body: { type: "string", required: true, description: "Message text" },
27
- type: { type: "string", required: false, description: "sms (default), binary, or flash" },
28
- datacoding: { type: "string", required: false, description: "auto, plain, or unicode" },
29
- reference: { type: "string", required: false, description: "Client reference" },
30
- reportUrl: { type: "string", required: false, description: "Status report webhook URL (requires reference)" },
31
- validity: { type: "number", required: false, description: "Validity in seconds" },
32
- gateway: { type: "number", required: false, description: "SMS route gateway" },
33
- mclass: { type: "number", required: false, description: "0=normal, 1=flash" },
34
- scheduledDatetime: { type: "string", required: false, description: "Scheduled send time (RFC3339)" },
35
- groupIds: { type: "string", required: false, description: "Comma-separated group IDs (alternative to recipients)" },
44
+ type: {
45
+ type: "string",
46
+ required: false,
47
+ description: "sms (default), binary, or flash",
48
+ },
49
+ datacoding: {
50
+ type: "string",
51
+ required: false,
52
+ description: "auto, plain, or unicode",
53
+ },
54
+ reference: {
55
+ type: "string",
56
+ required: false,
57
+ description: "Client reference",
58
+ },
59
+ reportUrl: {
60
+ type: "string",
61
+ required: false,
62
+ description: "Status report webhook URL (requires reference)",
63
+ },
64
+ validity: {
65
+ type: "number",
66
+ required: false,
67
+ description: "Validity in seconds",
68
+ },
69
+ gateway: {
70
+ type: "number",
71
+ required: false,
72
+ description: "SMS route gateway",
73
+ },
74
+ mclass: {
75
+ type: "number",
76
+ required: false,
77
+ description: "0=normal, 1=flash",
78
+ },
79
+ scheduledDatetime: {
80
+ type: "string",
81
+ required: false,
82
+ description: "Scheduled send time (RFC3339)",
83
+ },
84
+ groupIds: {
85
+ type: "string",
86
+ required: false,
87
+ description: "Comma-separated group IDs (alternative to recipients)",
88
+ },
36
89
  },
37
90
  async execute(input, ctx) {
38
91
  const p = input;
39
92
  const body = {
40
93
  originator: p.originator,
41
94
  body: p.body,
42
- recipients: p.recipients.split(",").map((r) => Number.parseInt(r.trim(), 10)),
95
+ recipients: p.recipients
96
+ .split(",")
97
+ .map((r) => Number.parseInt(r.trim(), 10)),
43
98
  };
44
- for (const k of ["type", "datacoding", "reference", "reportUrl", "validity", "gateway", "mclass", "scheduledDatetime", "groupIds"]) {
99
+ for (const k of [
100
+ "type",
101
+ "datacoding",
102
+ "reference",
103
+ "reportUrl",
104
+ "validity",
105
+ "gateway",
106
+ "mclass",
107
+ "scheduledDatetime",
108
+ "groupIds",
109
+ ]) {
45
110
  if (p[k] !== undefined && p[k] !== null)
46
111
  body[k] = p[k];
47
112
  }
@@ -1,9 +1,15 @@
1
1
  async function apiRequest(baseUrl, sessionToken, method, endpoint, body) {
2
2
  const opts = {
3
3
  method,
4
- headers: { "X-Metabase-Session": sessionToken, "Content-Type": "application/json" },
4
+ headers: {
5
+ "X-Metabase-Session": sessionToken,
6
+ "Content-Type": "application/json",
7
+ },
5
8
  };
6
- if (body && Object.keys(body).length > 0 && method !== "GET" && method !== "DELETE")
9
+ if (body &&
10
+ Object.keys(body).length > 0 &&
11
+ method !== "GET" &&
12
+ method !== "DELETE")
7
13
  opts.body = JSON.stringify(body);
8
14
  const res = await fetch(`${baseUrl}${endpoint}`, opts);
9
15
  if (!res.ok)
@@ -14,8 +20,18 @@ export default function metabase(rl) {
14
20
  rl.setName("metabase");
15
21
  rl.setVersion("0.1.0");
16
22
  rl.setConnectionSchema({
17
- url: { type: "string", required: true, description: "Metabase instance URL (e.g. https://metabase.example.com)", env: "METABASE_URL" },
18
- sessionToken: { type: "string", required: true, description: "Metabase session token (from POST /api/session)", env: "METABASE_SESSION_TOKEN" },
23
+ url: {
24
+ type: "string",
25
+ required: true,
26
+ description: "Metabase instance URL (e.g. https://metabase.example.com)",
27
+ env: "METABASE_URL",
28
+ },
29
+ sessionToken: {
30
+ type: "string",
31
+ required: true,
32
+ description: "Metabase session token (from POST /api/session)",
33
+ env: "METABASE_SESSION_TOKEN",
34
+ },
19
35
  });
20
36
  const conn = (ctx) => ({
21
37
  baseUrl: ctx.connection.config.url.replace(/\/$/, ""),
@@ -41,7 +57,11 @@ export default function metabase(rl) {
41
57
  description: "Get the results of a question as JSON",
42
58
  inputSchema: {
43
59
  questionId: { type: "number", required: true },
44
- format: { type: "string", required: false, description: "json (default), csv, xlsx — note: only json returns structured data" },
60
+ format: {
61
+ type: "string",
62
+ required: false,
63
+ description: "json (default), csv, xlsx — note: only json returns structured data",
64
+ },
45
65
  },
46
66
  async execute(input, ctx) {
47
67
  const { questionId, format = "json" } = input;
@@ -86,16 +106,36 @@ export default function metabase(rl) {
86
106
  description: "Add a new database/datasource",
87
107
  inputSchema: {
88
108
  name: { type: "string", required: true, description: "Display name" },
89
- engine: { type: "string", required: true, description: "postgres, mysql, h2, sqlite, mongo, redshift" },
90
- host: { type: "string", required: false, description: "Database host (for postgres/mysql/mongo/redshift)" },
109
+ engine: {
110
+ type: "string",
111
+ required: true,
112
+ description: "postgres, mysql, h2, sqlite, mongo, redshift",
113
+ },
114
+ host: {
115
+ type: "string",
116
+ required: false,
117
+ description: "Database host (for postgres/mysql/mongo/redshift)",
118
+ },
91
119
  port: { type: "number", required: false, description: "Database port" },
92
120
  user: { type: "string", required: false, description: "Database user" },
93
- password: { type: "string", required: false, description: "Database password" },
94
- dbName: { type: "string", required: false, description: "Database name or file path (for h2/sqlite)" },
95
- isFullSync: { type: "boolean", required: false, description: "Full sync (default true)" },
121
+ password: {
122
+ type: "string",
123
+ required: false,
124
+ description: "Database password",
125
+ },
126
+ dbName: {
127
+ type: "string",
128
+ required: false,
129
+ description: "Database name or file path (for h2/sqlite)",
130
+ },
131
+ isFullSync: {
132
+ type: "boolean",
133
+ required: false,
134
+ description: "Full sync (default true)",
135
+ },
96
136
  },
97
137
  async execute(input, ctx) {
98
- const { name, engine, host, port, user, password, dbName, isFullSync = true } = input;
138
+ const { name, engine, host, port, user, password, dbName, isFullSync = true, } = input;
99
139
  const { baseUrl, token } = conn(ctx);
100
140
  const details = {};
101
141
  if (host)
@@ -108,7 +148,12 @@ export default function metabase(rl) {
108
148
  details.password = password;
109
149
  if (dbName)
110
150
  details.db = dbName;
111
- return apiRequest(baseUrl, token, "POST", "/api/database", { name, engine, details, is_full_sync: isFullSync });
151
+ return apiRequest(baseUrl, token, "POST", "/api/database", {
152
+ name,
153
+ engine,
154
+ details,
155
+ is_full_sync: isFullSync,
156
+ });
112
157
  },
113
158
  });
114
159
  // ── Metric ──────────────────────────────────────────
@@ -1,9 +1,16 @@
1
1
  async function apiRequest(baseUrl, apiKey, method, endpoint, body) {
2
2
  const opts = {
3
3
  method,
4
- headers: { Authorization: apiKey, Accept: "application/json", "Content-Type": "application/json" },
4
+ headers: {
5
+ Authorization: apiKey,
6
+ Accept: "application/json",
7
+ "Content-Type": "application/json",
8
+ },
5
9
  };
6
- if (body && Object.keys(body).length > 0 && method !== "GET" && method !== "DELETE")
10
+ if (body &&
11
+ Object.keys(body).length > 0 &&
12
+ method !== "GET" &&
13
+ method !== "DELETE")
7
14
  opts.body = JSON.stringify(body);
8
15
  const res = await fetch(`${baseUrl}${endpoint}`, opts);
9
16
  if (!res.ok)
@@ -14,8 +21,18 @@ export default function misp(rl) {
14
21
  rl.setName("misp");
15
22
  rl.setVersion("0.1.0");
16
23
  rl.setConnectionSchema({
17
- baseUrl: { type: "string", required: true, description: "MISP instance URL", env: "MISP_URL" },
18
- apiKey: { type: "string", required: true, description: "MISP API key (Authorization header)", env: "MISP_API_KEY" },
24
+ baseUrl: {
25
+ type: "string",
26
+ required: true,
27
+ description: "MISP instance URL",
28
+ env: "MISP_URL",
29
+ },
30
+ apiKey: {
31
+ type: "string",
32
+ required: true,
33
+ description: "MISP API key (Authorization header)",
34
+ env: "MISP_API_KEY",
35
+ },
19
36
  });
20
37
  const conn = (ctx) => ({
21
38
  baseUrl: ctx.connection.config.baseUrl.replace(/\/$/, ""),
@@ -30,9 +47,17 @@ export default function misp(rl) {
30
47
  description: "Add an attribute to an event",
31
48
  inputSchema: {
32
49
  eventId: { type: "string", required: true },
33
- type: { type: "string", required: true, description: "Attribute type (ip-src, domain, md5, etc.)" },
50
+ type: {
51
+ type: "string",
52
+ required: true,
53
+ description: "Attribute type (ip-src, domain, md5, etc.)",
54
+ },
34
55
  value: { type: "string", required: true },
35
- additionalFields: { type: "object", required: false, description: "category, comment, to_ids, distribution, sharing_group_id, etc." },
56
+ additionalFields: {
57
+ type: "object",
58
+ required: false,
59
+ description: "category, comment, to_ids, distribution, sharing_group_id, etc.",
60
+ },
36
61
  },
37
62
  async execute(input, ctx) {
38
63
  const { eventId, type, value, additionalFields } = input;
@@ -65,7 +90,11 @@ export default function misp(rl) {
65
90
  description: "Search attributes via restSearch",
66
91
  inputSchema: {
67
92
  value: { type: "string", required: false },
68
- searchBody: { type: "object", required: false, description: "Full search body (value, type, category, tags, etc.)" },
93
+ searchBody: {
94
+ type: "object",
95
+ required: false,
96
+ description: "Full search body (value, type, category, tags, etc.)",
97
+ },
69
98
  },
70
99
  async execute(input, ctx) {
71
100
  const { value, searchBody } = (input ?? {});
@@ -78,7 +107,10 @@ export default function misp(rl) {
78
107
  });
79
108
  rl.registerAction("attribute.update", {
80
109
  description: "Update an attribute",
81
- inputSchema: { attributeId: { type: "string", required: true }, updateFields: { type: "object", required: true } },
110
+ inputSchema: {
111
+ attributeId: { type: "string", required: true },
112
+ updateFields: { type: "object", required: true },
113
+ },
82
114
  async execute(input, ctx) {
83
115
  const { attributeId, updateFields } = input;
84
116
  const data = (await req(ctx, "PUT", `/attributes/edit/${attributeId}`, updateFields));
@@ -88,15 +120,25 @@ export default function misp(rl) {
88
120
  rl.registerAction("attribute.delete", {
89
121
  description: "Delete an attribute",
90
122
  inputSchema: { attributeId: { type: "string", required: true } },
91
- async execute(input, ctx) { return req(ctx, "DELETE", `/attributes/delete/${input.attributeId}`); },
123
+ async execute(input, ctx) {
124
+ return req(ctx, "DELETE", `/attributes/delete/${input.attributeId}`);
125
+ },
92
126
  });
93
127
  // ── Event ───────────────────────────────────────────
94
128
  rl.registerAction("event.create", {
95
129
  description: "Create an event",
96
130
  inputSchema: {
97
131
  orgId: { type: "string", required: true, description: "Organisation ID" },
98
- info: { type: "string", required: true, description: "Event description/info" },
99
- additionalFields: { type: "object", required: false, description: "distribution, threat_level_id, analysis, date, etc." },
132
+ info: {
133
+ type: "string",
134
+ required: true,
135
+ description: "Event description/info",
136
+ },
137
+ additionalFields: {
138
+ type: "object",
139
+ required: false,
140
+ description: "distribution, threat_level_id, analysis, date, etc.",
141
+ },
100
142
  },
101
143
  async execute(input, ctx) {
102
144
  const { orgId, info, additionalFields } = input;
@@ -131,7 +173,11 @@ export default function misp(rl) {
131
173
  description: "Search events via restSearch",
132
174
  inputSchema: {
133
175
  value: { type: "string", required: false },
134
- searchBody: { type: "object", required: false, description: "Full search body" },
176
+ searchBody: {
177
+ type: "object",
178
+ required: false,
179
+ description: "Full search body",
180
+ },
135
181
  },
136
182
  async execute(input, ctx) {
137
183
  const { value, searchBody } = (input ?? {});
@@ -145,7 +191,10 @@ export default function misp(rl) {
145
191
  });
146
192
  rl.registerAction("event.update", {
147
193
  description: "Update an event",
148
- inputSchema: { eventId: { type: "string", required: true }, updateFields: { type: "object", required: true } },
194
+ inputSchema: {
195
+ eventId: { type: "string", required: true },
196
+ updateFields: { type: "object", required: true },
197
+ },
149
198
  async execute(input, ctx) {
150
199
  const { eventId, updateFields } = input;
151
200
  const data = (await req(ctx, "PUT", `/events/edit/${eventId}`, updateFields));
@@ -157,22 +206,31 @@ export default function misp(rl) {
157
206
  rl.registerAction("event.publish", {
158
207
  description: "Publish an event",
159
208
  inputSchema: { eventId: { type: "string", required: true } },
160
- async execute(input, ctx) { return req(ctx, "POST", `/events/publish/${input.eventId}`); },
209
+ async execute(input, ctx) {
210
+ return req(ctx, "POST", `/events/publish/${input.eventId}`);
211
+ },
161
212
  });
162
213
  rl.registerAction("event.unpublish", {
163
214
  description: "Unpublish an event",
164
215
  inputSchema: { eventId: { type: "string", required: true } },
165
- async execute(input, ctx) { return req(ctx, "POST", `/events/unpublish/${input.eventId}`); },
216
+ async execute(input, ctx) {
217
+ return req(ctx, "POST", `/events/unpublish/${input.eventId}`);
218
+ },
166
219
  });
167
220
  rl.registerAction("event.delete", {
168
221
  description: "Delete an event",
169
222
  inputSchema: { eventId: { type: "string", required: true } },
170
- async execute(input, ctx) { return req(ctx, "DELETE", `/events/delete/${input.eventId}`); },
223
+ async execute(input, ctx) {
224
+ return req(ctx, "DELETE", `/events/delete/${input.eventId}`);
225
+ },
171
226
  });
172
227
  // ── Event Tag ───────────────────────────────────────
173
228
  rl.registerAction("eventTag.add", {
174
229
  description: "Add a tag to an event",
175
- inputSchema: { eventId: { type: "string", required: true }, tagId: { type: "string", required: true } },
230
+ inputSchema: {
231
+ eventId: { type: "string", required: true },
232
+ tagId: { type: "string", required: true },
233
+ },
176
234
  async execute(input, ctx) {
177
235
  const { eventId, tagId } = input;
178
236
  return req(ctx, "POST", "/events/addTag", { event: eventId, tag: tagId });
@@ -180,7 +238,10 @@ export default function misp(rl) {
180
238
  });
181
239
  rl.registerAction("eventTag.remove", {
182
240
  description: "Remove a tag from an event",
183
- inputSchema: { eventId: { type: "string", required: true }, tagId: { type: "string", required: true } },
241
+ inputSchema: {
242
+ eventId: { type: "string", required: true },
243
+ tagId: { type: "string", required: true },
244
+ },
184
245
  async execute(input, ctx) {
185
246
  const { eventId, tagId } = input;
186
247
  return req(ctx, "POST", `/events/removeTag/${eventId}/${tagId}`);
@@ -193,7 +254,11 @@ export default function misp(rl) {
193
254
  name: { type: "string", required: true },
194
255
  provider: { type: "string", required: true },
195
256
  url: { type: "string", required: true },
196
- additionalFields: { type: "object", required: false, description: "input_source, source_format, enabled, distribution, etc." },
257
+ additionalFields: {
258
+ type: "object",
259
+ required: false,
260
+ description: "input_source, source_format, enabled, distribution, etc.",
261
+ },
197
262
  },
198
263
  async execute(input, ctx) {
199
264
  const { name, provider, url, additionalFields } = input;
@@ -225,7 +290,10 @@ export default function misp(rl) {
225
290
  });
226
291
  rl.registerAction("feed.update", {
227
292
  description: "Update a feed",
228
- inputSchema: { feedId: { type: "string", required: true }, updateFields: { type: "object", required: true } },
293
+ inputSchema: {
294
+ feedId: { type: "string", required: true },
295
+ updateFields: { type: "object", required: true },
296
+ },
229
297
  async execute(input, ctx) {
230
298
  const { feedId, updateFields } = input;
231
299
  const data = (await req(ctx, "PUT", `/feeds/edit/${feedId}`, updateFields));
@@ -235,12 +303,16 @@ export default function misp(rl) {
235
303
  rl.registerAction("feed.enable", {
236
304
  description: "Enable a feed",
237
305
  inputSchema: { feedId: { type: "string", required: true } },
238
- async execute(input, ctx) { return req(ctx, "POST", `/feeds/enable/${input.feedId}`); },
306
+ async execute(input, ctx) {
307
+ return req(ctx, "POST", `/feeds/enable/${input.feedId}`);
308
+ },
239
309
  });
240
310
  rl.registerAction("feed.disable", {
241
311
  description: "Disable a feed",
242
312
  inputSchema: { feedId: { type: "string", required: true } },
243
- async execute(input, ctx) { return req(ctx, "POST", `/feeds/disable/${input.feedId}`); },
313
+ async execute(input, ctx) {
314
+ return req(ctx, "POST", `/feeds/disable/${input.feedId}`);
315
+ },
244
316
  });
245
317
  // ── Galaxy ──────────────────────────────────────────
246
318
  rl.registerAction("galaxy.get", {
@@ -265,7 +337,9 @@ export default function misp(rl) {
265
337
  rl.registerAction("galaxy.delete", {
266
338
  description: "Delete a galaxy",
267
339
  inputSchema: { galaxyId: { type: "string", required: true } },
268
- async execute(input, ctx) { return req(ctx, "DELETE", `/galaxies/delete/${input.galaxyId}`); },
340
+ async execute(input, ctx) {
341
+ return req(ctx, "DELETE", `/galaxies/delete/${input.galaxyId}`);
342
+ },
269
343
  });
270
344
  // ── Noticelist ──────────────────────────────────────
271
345
  rl.registerAction("noticelist.get", {
@@ -309,7 +383,11 @@ export default function misp(rl) {
309
383
  description: "Create an organisation",
310
384
  inputSchema: {
311
385
  name: { type: "string", required: true },
312
- additionalFields: { type: "object", required: false, description: "description, type, nationality, sector, contacts, uuid, local" },
386
+ additionalFields: {
387
+ type: "object",
388
+ required: false,
389
+ description: "description, type, nationality, sector, contacts, uuid, local",
390
+ },
313
391
  },
314
392
  async execute(input, ctx) {
315
393
  const { name, additionalFields } = input;
@@ -341,7 +419,10 @@ export default function misp(rl) {
341
419
  });
342
420
  rl.registerAction("organisation.update", {
343
421
  description: "Update an organisation",
344
- inputSchema: { organisationId: { type: "string", required: true }, updateFields: { type: "object", required: true } },
422
+ inputSchema: {
423
+ organisationId: { type: "string", required: true },
424
+ updateFields: { type: "object", required: true },
425
+ },
345
426
  async execute(input, ctx) {
346
427
  const { organisationId, updateFields } = input;
347
428
  const data = (await req(ctx, "PUT", `/admin/organisations/edit/${organisationId}`, updateFields));
@@ -351,20 +432,28 @@ export default function misp(rl) {
351
432
  rl.registerAction("organisation.delete", {
352
433
  description: "Delete an organisation",
353
434
  inputSchema: { organisationId: { type: "string", required: true } },
354
- async execute(input, ctx) { return req(ctx, "DELETE", `/admin/organisations/delete/${input.organisationId}`); },
435
+ async execute(input, ctx) {
436
+ return req(ctx, "DELETE", `/admin/organisations/delete/${input.organisationId}`);
437
+ },
355
438
  });
356
439
  // ── Tag ─────────────────────────────────────────────
357
440
  rl.registerAction("tag.create", {
358
441
  description: "Create a tag",
359
442
  inputSchema: {
360
443
  name: { type: "string", required: true },
361
- colour: { type: "string", required: false, description: "Hex colour (e.g. #ff0000)" },
444
+ colour: {
445
+ type: "string",
446
+ required: false,
447
+ description: "Hex colour (e.g. #ff0000)",
448
+ },
362
449
  },
363
450
  async execute(input, ctx) {
364
451
  const { name, colour } = input;
365
452
  const body = { name };
366
453
  if (colour)
367
- body.colour = colour.startsWith("#") ? colour : `#${colour}`;
454
+ body.colour = colour.startsWith("#")
455
+ ? colour
456
+ : `#${colour}`;
368
457
  const data = (await req(ctx, "POST", "/tags/add", body));
369
458
  return data.Tag;
370
459
  },
@@ -393,7 +482,9 @@ export default function misp(rl) {
393
482
  if (name)
394
483
  body.name = name;
395
484
  if (colour)
396
- body.colour = colour.startsWith("#") ? colour : `#${colour}`;
485
+ body.colour = colour.startsWith("#")
486
+ ? colour
487
+ : `#${colour}`;
397
488
  const data = (await req(ctx, "POST", `/tags/edit/${tagId}`, body));
398
489
  return data.Tag;
399
490
  },
@@ -401,7 +492,9 @@ export default function misp(rl) {
401
492
  rl.registerAction("tag.delete", {
402
493
  description: "Delete a tag",
403
494
  inputSchema: { tagId: { type: "string", required: true } },
404
- async execute(input, ctx) { return req(ctx, "POST", `/tags/delete/${input.tagId}`); },
495
+ async execute(input, ctx) {
496
+ return req(ctx, "POST", `/tags/delete/${input.tagId}`);
497
+ },
405
498
  });
406
499
  // ── User ────────────────────────────────────────────
407
500
  rl.registerAction("user.create", {
@@ -409,7 +502,11 @@ export default function misp(rl) {
409
502
  inputSchema: {
410
503
  email: { type: "string", required: true },
411
504
  roleId: { type: "string", required: true, description: "Role ID" },
412
- additionalFields: { type: "object", required: false, description: "org_id, password, termsaccepted, change_pw, etc." },
505
+ additionalFields: {
506
+ type: "object",
507
+ required: false,
508
+ description: "org_id, password, termsaccepted, change_pw, etc.",
509
+ },
413
510
  },
414
511
  async execute(input, ctx) {
415
512
  const { email, roleId, additionalFields } = input;
@@ -441,7 +538,10 @@ export default function misp(rl) {
441
538
  });
442
539
  rl.registerAction("user.update", {
443
540
  description: "Update a user",
444
- inputSchema: { userId: { type: "string", required: true }, updateFields: { type: "object", required: true } },
541
+ inputSchema: {
542
+ userId: { type: "string", required: true },
543
+ updateFields: { type: "object", required: true },
544
+ },
445
545
  async execute(input, ctx) {
446
546
  const { userId, updateFields } = input;
447
547
  const data = (await req(ctx, "PUT", `/admin/users/edit/${userId}`, updateFields));
@@ -451,7 +551,9 @@ export default function misp(rl) {
451
551
  rl.registerAction("user.delete", {
452
552
  description: "Delete a user",
453
553
  inputSchema: { userId: { type: "string", required: true } },
454
- async execute(input, ctx) { return req(ctx, "DELETE", `/admin/users/delete/${input.userId}`); },
554
+ async execute(input, ctx) {
555
+ return req(ctx, "DELETE", `/admin/users/delete/${input.userId}`);
556
+ },
455
557
  });
456
558
  // ── Warninglist ─────────────────────────────────────
457
559
  rl.registerAction("warninglist.get", {
@@ -20,8 +20,18 @@ export default function mocean(rl) {
20
20
  rl.setName("mocean");
21
21
  rl.setVersion("0.1.0");
22
22
  rl.setConnectionSchema({
23
- apiKey: { type: "string", required: true, description: "Mocean API key", env: "MOCEAN_API_KEY" },
24
- apiSecret: { type: "string", required: true, description: "Mocean API secret", env: "MOCEAN_API_SECRET" },
23
+ apiKey: {
24
+ type: "string",
25
+ required: true,
26
+ description: "Mocean API key",
27
+ env: "MOCEAN_API_KEY",
28
+ },
29
+ apiSecret: {
30
+ type: "string",
31
+ required: true,
32
+ description: "Mocean API secret",
33
+ env: "MOCEAN_API_SECRET",
34
+ },
25
35
  });
26
36
  const creds = (ctx) => ({
27
37
  apiKey: ctx.connection.config.apiKey,
@@ -33,12 +43,20 @@ export default function mocean(rl) {
33
43
  from: { type: "string", required: true, description: "Sender number" },
34
44
  to: { type: "string", required: true, description: "Recipient number" },
35
45
  message: { type: "string", required: true },
36
- dlrUrl: { type: "string", required: false, description: "Delivery report URL" },
46
+ dlrUrl: {
47
+ type: "string",
48
+ required: false,
49
+ description: "Delivery report URL",
50
+ },
37
51
  },
38
52
  async execute(input, ctx) {
39
53
  const { from, to, message, dlrUrl } = input;
40
54
  const { apiKey, apiSecret } = creds(ctx);
41
- const body = { "mocean-from": from, "mocean-to": to, "mocean-text": message };
55
+ const body = {
56
+ "mocean-from": from,
57
+ "mocean-to": to,
58
+ "mocean-text": message,
59
+ };
42
60
  if (dlrUrl) {
43
61
  body["mocean-dlr-url"] = dlrUrl;
44
62
  body["mocean-dlr-mask"] = "1";
@@ -53,13 +71,21 @@ export default function mocean(rl) {
53
71
  from: { type: "string", required: true, description: "Caller number" },
54
72
  to: { type: "string", required: true, description: "Recipient number" },
55
73
  message: { type: "string", required: true, description: "Text to speak" },
56
- language: { type: "string", required: false, description: "Language code: en-US (default), en-GB, cmn-CN, ja-JP, ko-KR" },
74
+ language: {
75
+ type: "string",
76
+ required: false,
77
+ description: "Language code: en-US (default), en-GB, cmn-CN, ja-JP, ko-KR",
78
+ },
57
79
  },
58
80
  async execute(input, ctx) {
59
- const { from, to, message, language = "en-US" } = input;
81
+ const { from, to, message, language = "en-US", } = input;
60
82
  const { apiKey, apiSecret } = creds(ctx);
61
83
  const command = [{ action: "say", language, text: message }];
62
- const body = { "mocean-from": from, "mocean-to": to, "mocean-command": JSON.stringify(command) };
84
+ const body = {
85
+ "mocean-from": from,
86
+ "mocean-to": to,
87
+ "mocean-command": JSON.stringify(command),
88
+ };
63
89
  const data = (await apiRequest(apiKey, apiSecret, "/rest/2/voice/dial", body));
64
90
  return data.voice;
65
91
  },