@tool-bridge/server 0.21.1 → 0.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/admin.js +170 -0
- package/dist/airtable-VMQVXLHK.js +790 -0
- package/dist/{alt_text_generator_ai-W7O34SNG.js → alt_text_generator_ai-FTWY4RU4.js} +12 -11
- package/dist/{amap-VOX4T2AW.js → amap-OK5VBHYC.js} +221 -220
- package/dist/anthropic-S67AZFZ3.js +203 -0
- package/dist/apify-ZE6MYQI3.js +248 -0
- package/dist/brave_search-TG2M2KOD.js +302 -0
- package/dist/chunk-2JNAI4OC.js +161 -0
- package/dist/{chunk-KMTT3I6D.js → chunk-4XJPN3DY.js} +19392 -26136
- package/dist/chunk-5ICRY3VU.js +8432 -0
- package/dist/chunk-7CTWGTDU.js +302 -0
- package/dist/chunk-BADVCN6K.js +378 -0
- package/dist/{chunk-XYBU3WZH.js → chunk-TDAWLMDE.js} +3 -3
- package/dist/chunk-U7PTOA3U.js +7320 -0
- package/dist/{chunk-E6JCVKW6.js → chunk-VWRUGUSU.js} +3 -3
- package/dist/{chunk-ATK45BXV.js → chunk-WJHG6OK7.js} +4 -2
- package/dist/circleci-3L3WJVSK.js +389 -0
- package/dist/clerk-EZPF2V7T.js +1019 -0
- package/dist/cohere-U27DPO64.js +185 -0
- package/dist/{confluence-B3EWPZVE.js → confluence-G2KL6ERH.js} +105 -104
- package/dist/{convertapi-EUWSQYPF.js → convertapi-L4CLJ2M3.js} +32 -31
- package/dist/{currencyapi-KVTIK3GL.js → currencyapi-YPYXG7YY.js} +71 -71
- package/dist/deepseek-6HT6WF3M.js +210 -0
- package/dist/docker_hub-LPE3PCVB.js +933 -0
- package/dist/dropbox-V56ABHTA.js +1305 -0
- package/dist/dub-6OKQ7MHT.js +680 -0
- package/dist/e2b-JS2U2QFU.js +278 -0
- package/dist/exa-DPWVYXSP.js +332 -0
- package/dist/{fal_ai-23E7JPNT.js → fal_ai-DK6Y27ZF.js} +81 -80
- package/dist/{feishu-7QRIDUV6.js → feishu-K7EGSRF3.js} +528 -572
- package/dist/{feishu_custom_bot-TJ4K7QNJ.js → feishu_custom_bot-2JUGFYNG.js} +57 -53
- package/dist/figma-FT5I7ITD.js +777 -0
- package/dist/firehydrant-EIKLKHX2.js +563 -0
- package/dist/{fixer-BWON27UO.js → fixer-U5QXIAKD.js} +34 -33
- package/dist/fly-T3JYFZ2M.js +469 -0
- package/dist/{front-QCGXYEDJ.js → front-D72MGVOR.js} +104 -104
- package/dist/geocodio-BOTD5TI5.js +213 -0
- package/dist/ghost-KYP7SZGB.js +338 -0
- package/dist/github-AGMZT3VY.js +5421 -0
- package/dist/gmail-BLJNJOBG.js +1887 -0
- package/dist/googlecalendar-GTHWNCF6.js +2524 -0
- package/dist/{googledocs-BUHL4J2H.js → googledocs-6EEDMEBQ.js} +341 -340
- package/dist/{grafana-GLU2DWF2.js → grafana-GMW6EKSQ.js} +221 -220
- package/dist/graphhopper-6OLGBDGB.js +325 -0
- package/dist/index.d.ts +1132 -332
- package/dist/index.js +31 -14
- package/dist/{ip2proxy-EZ64Y4ZH.js → ip2proxy-4QN42E6T.js} +28 -27
- package/dist/ipgeolocation_io-SK4XKDA2.js +315 -0
- package/dist/ipqualityscore-6ANBPXKT.js +279 -0
- package/dist/{jina_ai-EFBHTBXL.js → jina_ai-IHPSVRM5.js} +23 -23
- package/dist/{jira-HQSHAA5K.js → jira-46KKM4LC.js} +118 -117
- package/dist/langsmith-JZA345I5.js +593 -0
- package/dist/lemlist-43IV7DK6.js +289 -0
- package/dist/{linear-K7RYFYAD.js → linear-5LFH7XNL.js} +327 -326
- package/dist/logsnag-5RMYAHIL.js +150 -0
- package/dist/main.js +57 -280
- package/dist/{mattermost-S2BRCWLQ.js → mattermost-XFL6SHGG.js} +59 -58
- package/dist/mem0-NYO4DTP6.js +544 -0
- package/dist/memos-37MPQOLV.js +744 -0
- package/dist/{metabase-MMSEPCOF.js → metabase-KYBKZFMG.js} +90 -89
- package/dist/mistral_ai-6PL3K4PM.js +1196 -0
- package/dist/{mother_duck-H7PCQNZ2.js → mother_duck-2NH7W5M5.js} +94 -93
- package/dist/ngrok-UO6CDYCA.js +356 -0
- package/dist/{notes-PFMKRO33.js → notes-I3P32WP4.js} +11 -9
- package/dist/notion-BEAJFUOE.js +940 -0
- package/dist/open_exchange_rates-CMF62JB4.js +215 -0
- package/dist/openai-IHOMKVND.js +800 -0
- package/dist/opengraph_io-ZQ2FGLHX.js +362 -0
- package/dist/openrouter-HXLW3NR5.js +441 -0
- package/dist/outline-ELCP4NEU.js +599 -0
- package/dist/paddle-O77LALVN.js +454 -0
- package/dist/perplexity-JCU654QV.js +220 -0
- package/dist/pinecone-W5W4LRKL.js +571 -0
- package/dist/{pipedrive-Y2O7QGFF.js → pipedrive-ITMJLLPZ.js} +99 -98
- package/dist/polar-R33XU4L3.js +395 -0
- package/dist/posthog-JVNTOLTV.js +3464 -0
- package/dist/postmark-6SBG7HWV.js +427 -0
- package/dist/{prerender-MENYM2TY.js → prerender-GPNKTNFC.js} +31 -30
- package/dist/{pubmed-GOXUVVH5.js → pubmed-UP6ZEEIH.js} +239 -238
- package/dist/{railway-V2SID4WV.js → railway-KWEWXHTY.js} +118 -117
- package/dist/readwise-BLATSMC3.js +470 -0
- package/dist/render-QYRVIXII.js +461 -0
- package/dist/{replicate-756MXPYX.js → replicate-JYTWH4NF.js} +81 -80
- package/dist/{resend-ZKH3BTBI.js → resend-L5N75SZM.js} +20 -16
- package/dist/rootly-MHCPEQ26.js +336 -0
- package/dist/{scrapfly-NSRHFDIQ.js → scrapfly-PTPGYSJM.js} +62 -61
- package/dist/{scrapingbee-OQHLAVEY.js → scrapingbee-JN6UH5PY.js} +56 -56
- package/dist/{screenshot_fyi-DVWG3AXC.js → screenshot_fyi-4QRVSV55.js} +16 -16
- package/dist/semantic_scholar-LRSWA2GE.js +611 -0
- package/dist/{sentry-546MNDJG.js → sentry-2G6PF5W6.js} +208 -207
- package/dist/{shodan-C3OON3Z3.js → shodan-WKKPP5C6.js} +62 -61
- package/dist/shopify-64YDK5T2.js +610 -0
- package/dist/stripe-QAIGGOTF.js +585 -0
- package/dist/{supabase-U2SL4D63.js → supabase-WHTGR6ND.js} +245 -244
- package/dist/tavily-QIXCDDWO.js +326 -0
- package/dist/telegram-E6G7CWI6.js +1767 -0
- package/dist/{telnyx-CXQ4EZUX.js → telnyx-ZDVVS7PK.js} +57 -56
- package/dist/todoist-DMYF3G7J.js +664 -0
- package/dist/trello-HY2RYIRP.js +1080 -0
- package/dist/turso-HAQWMGRP.js +416 -0
- package/dist/{twilio-4PDBJKWX.js → twilio-MLXYPHJE.js} +70 -69
- package/dist/umami-DZHBLPVG.js +389 -0
- package/dist/unsplash-GS2OPXKE.js +351 -0
- package/dist/{upstash_redis-G4LQBYHA.js → upstash_redis-XMXWTNAJ.js} +51 -50
- package/dist/uptimerobot-TF5WRZ4G.js +483 -0
- package/dist/v2ex-2BVXAPDF.js +667 -0
- package/dist/vercel-YMJGQYJE.js +1076 -0
- package/dist/{wolfram_alpha_api-3G4PUJWB.js → wolfram_alpha_api-I56SXWFZ.js} +36 -35
- package/dist/wordpress-R7TDFZ2P.js +812 -0
- package/dist/workos-HDNHWVMS.js +664 -0
- package/dist/zhihu-LX6AGGDS.js +254 -0
- package/package.json +18 -9
- package/dist/airtable-LLZDFN7M.js +0 -789
- package/dist/anthropic-G23NN3X5.js +0 -202
- package/dist/apify-Y3SS734K.js +0 -247
- package/dist/brave_search-ZC7OAPSZ.js +0 -301
- package/dist/chunk-R6P4XAE5.js +0 -248
- package/dist/chunk-U7B6DS2O.js +0 -977
- package/dist/chunk-UZM2RXZH.js +0 -23436
- package/dist/circleci-3BAX5FCG.js +0 -388
- package/dist/clerk-6LEM6TNU.js +0 -1019
- package/dist/cloudflare_dns-KINYTJUD.js +0 -588
- package/dist/cohere-XCJ5AJ6B.js +0 -185
- package/dist/deepseek-PC5YGNC5.js +0 -209
- package/dist/docker_hub-C3MA5FU6.js +0 -932
- package/dist/dropbox-XBV7Z2IR.js +0 -1304
- package/dist/dub-LDOFG3HC.js +0 -679
- package/dist/e2b-JMCPSVBW.js +0 -277
- package/dist/exa-RAK7O7RD.js +0 -331
- package/dist/figma-E6IX5DTH.js +0 -773
- package/dist/firehydrant-ZBLPQREE.js +0 -562
- package/dist/fly-ZH3HFCZJ.js +0 -468
- package/dist/geocodio-YGNI7DA4.js +0 -212
- package/dist/ghost-EVSGKH2Q.js +0 -337
- package/dist/github-MA2BGRCJ.js +0 -5420
- package/dist/gmail-E5E6AADE.js +0 -1886
- package/dist/googlecalendar-BTLFPXTD.js +0 -2523
- package/dist/graphhopper-WSMB3TCD.js +0 -324
- package/dist/ipgeolocation_io-AA7HAS22.js +0 -315
- package/dist/ipqualityscore-BHJXVTJT.js +0 -277
- package/dist/langsmith-5W6SCT6F.js +0 -592
- package/dist/lemlist-HJWH6UMK.js +0 -288
- package/dist/logsnag-4KFOHL37.js +0 -150
- package/dist/mem0-CAW43CIC.js +0 -543
- package/dist/memos-TWEGPKFM.js +0 -740
- package/dist/mistral_ai-64BGZQHP.js +0 -1195
- package/dist/ngrok-GQCUGZKJ.js +0 -356
- package/dist/notion-DQWZWP4N.js +0 -936
- package/dist/open_exchange_rates-QMMD735E.js +0 -214
- package/dist/openai-W6PX32NZ.js +0 -799
- package/dist/opengraph_io-HNDBXYNW.js +0 -361
- package/dist/openrouter-JJYMEAUL.js +0 -437
- package/dist/outline-MCBNQZYY.js +0 -595
- package/dist/paddle-D2SKLUDN.js +0 -453
- package/dist/perplexity-XIFMKUAE.js +0 -219
- package/dist/pinecone-HUFTALV2.js +0 -570
- package/dist/polar-TYTOMOSR.js +0 -394
- package/dist/posthog-43JAR3VW.js +0 -3463
- package/dist/postmark-KL2QJYSG.js +0 -426
- package/dist/readwise-CI4GIMMJ.js +0 -469
- package/dist/render-SUBJ6YRZ.js +0 -460
- package/dist/rootly-CD2LJHPI.js +0 -336
- package/dist/semantic_scholar-T4A252KW.js +0 -610
- package/dist/shopify-Y2HN2MCQ.js +0 -609
- package/dist/stripe-VE3CD3AY.js +0 -584
- package/dist/tavily-KCZHK6HE.js +0 -326
- package/dist/telegram-3URFBCMY.js +0 -1766
- package/dist/todoist-HNPWNYTD.js +0 -663
- package/dist/trello-3W2MIXRP.js +0 -1079
- package/dist/turso-2EQF7C2Z.js +0 -415
- package/dist/umami-5REN7TGP.js +0 -388
- package/dist/unsplash-EIXL424F.js +0 -350
- package/dist/uptimerobot-KNJ3EYLY.js +0 -482
- package/dist/v2ex-RHJ234PZ.js +0 -666
- package/dist/vercel-AS6NCIC7.js +0 -1075
- package/dist/wordpress-KNDAAUV7.js +0 -811
- package/dist/workos-R6UITSJ7.js +0 -663
- package/dist/zhihu-AGK4HILK.js +0 -253
package/dist/rootly-CD2LJHPI.js
DELETED
|
@@ -1,336 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
createAuthedClient
|
|
3
|
-
} from "./chunk-XYBU3WZH.js";
|
|
4
|
-
import "./chunk-E6JCVKW6.js";
|
|
5
|
-
import {
|
|
6
|
-
asJsonObject,
|
|
7
|
-
compactDefined,
|
|
8
|
-
trimmedText
|
|
9
|
-
} from "./chunk-JXHMDBAY.js";
|
|
10
|
-
import {
|
|
11
|
-
createProviderPlugin,
|
|
12
|
-
upstreamError
|
|
13
|
-
} from "./chunk-ATK45BXV.js";
|
|
14
|
-
import "./chunk-U7B6DS2O.js";
|
|
15
|
-
import {
|
|
16
|
-
external_exports
|
|
17
|
-
} from "./chunk-UZM2RXZH.js";
|
|
18
|
-
import "./chunk-U67V476Y.js";
|
|
19
|
-
|
|
20
|
-
// ../plugins/src/rootly/api.ts
|
|
21
|
-
var SERVICE = "rootly";
|
|
22
|
-
var API_BASE = "https://api.rootly.com/v1";
|
|
23
|
-
var JSON_API_CONTENT_TYPE = "application/vnd.api+json";
|
|
24
|
-
function requireRecord(value, label) {
|
|
25
|
-
const record = asJsonObject(value);
|
|
26
|
-
if (record === void 0) throw upstreamError(502, `${label} was not an object`);
|
|
27
|
-
return record;
|
|
28
|
-
}
|
|
29
|
-
function errorMessage(payload, status) {
|
|
30
|
-
const object = asJsonObject(payload);
|
|
31
|
-
const errors = Array.isArray(object?.errors) ? object.errors : [];
|
|
32
|
-
const first = asJsonObject(errors[0]);
|
|
33
|
-
return trimmedText(first?.detail) ?? trimmedText(first?.title) ?? `Rootly request failed with ${status}`;
|
|
34
|
-
}
|
|
35
|
-
var http = createAuthedClient({
|
|
36
|
-
baseUrl: `${API_BASE}/`,
|
|
37
|
-
service: SERVICE,
|
|
38
|
-
auth: { kind: "bearer" },
|
|
39
|
-
headers: { "accept": JSON_API_CONTENT_TYPE, "content-type": JSON_API_CONTENT_TYPE },
|
|
40
|
-
// JSON:API 的消息在 `errors[0].detail/title`,非 JSON 体还要包成同形再提取,整段覆写。
|
|
41
|
-
mapError: ({ bodyKind, data, status }) => upstreamError(
|
|
42
|
-
status,
|
|
43
|
-
errorMessage(bodyKind === "json" ? data : { errors: [{ detail: data }] }, status)
|
|
44
|
-
)
|
|
45
|
-
});
|
|
46
|
-
async function requestJson(ctx, path, query) {
|
|
47
|
-
const response = await http.request(ctx, {
|
|
48
|
-
path,
|
|
49
|
-
query: Object.entries(query),
|
|
50
|
-
invalidJson: "text"
|
|
51
|
-
});
|
|
52
|
-
if (response.bodyKind === "empty") return {};
|
|
53
|
-
if (response.bodyKind !== "json") throw upstreamError(502, "Rootly returned invalid JSON");
|
|
54
|
-
return response.data;
|
|
55
|
-
}
|
|
56
|
-
function readResource(value, label) {
|
|
57
|
-
const object = requireRecord(value, label);
|
|
58
|
-
const data = object.data === void 0 ? object : requireRecord(object.data, `${label} data`);
|
|
59
|
-
const id = trimmedText(data.id);
|
|
60
|
-
const type = trimmedText(data.type);
|
|
61
|
-
if (id === void 0 || type === void 0) {
|
|
62
|
-
throw upstreamError(502, `${label} did not include JSON:API id and type`);
|
|
63
|
-
}
|
|
64
|
-
return {
|
|
65
|
-
...data,
|
|
66
|
-
id,
|
|
67
|
-
type,
|
|
68
|
-
attributes: asJsonObject(data.attributes) ?? {},
|
|
69
|
-
relationships: asJsonObject(data.relationships) ?? {}
|
|
70
|
-
};
|
|
71
|
-
}
|
|
72
|
-
function readSidecars(payload) {
|
|
73
|
-
const object = requireRecord(payload, "Rootly response");
|
|
74
|
-
const included = Array.isArray(object.included) ? object.included : void 0;
|
|
75
|
-
const links = asJsonObject(object.links);
|
|
76
|
-
const meta = asJsonObject(object.meta);
|
|
77
|
-
return {
|
|
78
|
-
...included === void 0 ? {} : { included },
|
|
79
|
-
...links === void 0 ? {} : { links },
|
|
80
|
-
...meta === void 0 ? {} : { meta }
|
|
81
|
-
};
|
|
82
|
-
}
|
|
83
|
-
async function getSingleResource(ctx, path, query) {
|
|
84
|
-
const payload = await requestJson(ctx, path, query);
|
|
85
|
-
return { resource: readResource(payload, "Rootly resource"), ...readSidecars(payload), raw: payload };
|
|
86
|
-
}
|
|
87
|
-
async function getList(ctx, path, query) {
|
|
88
|
-
const payload = await requestJson(ctx, path, query);
|
|
89
|
-
const object = requireRecord(payload, "Rootly list response");
|
|
90
|
-
if (!Array.isArray(object.data)) {
|
|
91
|
-
throw upstreamError(502, "Rootly list response did not include data array");
|
|
92
|
-
}
|
|
93
|
-
return {
|
|
94
|
-
resources: object.data.map((item) => readResource(item, "Rootly list resource")),
|
|
95
|
-
...readSidecars(payload),
|
|
96
|
-
raw: payload
|
|
97
|
-
};
|
|
98
|
-
}
|
|
99
|
-
function includeQuery(include) {
|
|
100
|
-
return { include: include === void 0 || include.length === 0 ? void 0 : include.join(",") };
|
|
101
|
-
}
|
|
102
|
-
function pageQuery(input, options = {}) {
|
|
103
|
-
return {
|
|
104
|
-
...options.cursor === true ? { "page[after]": trimmedText(input.pageAfter) } : {},
|
|
105
|
-
"page[number]": input.pageNumber === void 0 ? void 0 : String(input.pageNumber),
|
|
106
|
-
"page[size]": input.pageSize === void 0 ? void 0 : String(input.pageSize)
|
|
107
|
-
};
|
|
108
|
-
}
|
|
109
|
-
function configurationQuery(input, options = {}) {
|
|
110
|
-
return compactDefined({
|
|
111
|
-
...includeQuery(input.include),
|
|
112
|
-
...pageQuery(input),
|
|
113
|
-
"filter[search]": trimmedText(input.search),
|
|
114
|
-
"filter[name]": trimmedText(input.name),
|
|
115
|
-
"filter[slug]": trimmedText(input.slug),
|
|
116
|
-
"filter[external_id]": trimmedText(input.externalId),
|
|
117
|
-
...options.includeColor === true ? { "filter[color]": trimmedText(input.color) } : {},
|
|
118
|
-
"filter[alert_broadcast_enabled]": input.alertBroadcastEnabled === void 0 ? void 0 : String(input.alertBroadcastEnabled),
|
|
119
|
-
"filter[incident_broadcast_enabled]": input.incidentBroadcastEnabled === void 0 ? void 0 : String(input.incidentBroadcastEnabled),
|
|
120
|
-
"filter[created_at][gt]": trimmedText(input.createdAtGt),
|
|
121
|
-
"filter[created_at][gte]": trimmedText(input.createdAtGte),
|
|
122
|
-
"filter[created_at][lt]": trimmedText(input.createdAtLt),
|
|
123
|
-
"filter[created_at][lte]": trimmedText(input.createdAtLte),
|
|
124
|
-
"sort": trimmedText(input.sort)
|
|
125
|
-
});
|
|
126
|
-
}
|
|
127
|
-
function getCurrentUser(_input, ctx) {
|
|
128
|
-
return getSingleResource(ctx, "/users/me", {});
|
|
129
|
-
}
|
|
130
|
-
function listIncidents(input, ctx) {
|
|
131
|
-
return getList(ctx, "/incidents", compactDefined({
|
|
132
|
-
...pageQuery(input, { cursor: true }),
|
|
133
|
-
"filter[search]": trimmedText(input.search),
|
|
134
|
-
"filter[kind]": trimmedText(input.kind),
|
|
135
|
-
"filter[status]": trimmedText(input.status),
|
|
136
|
-
"filter[private]": input.private === void 0 ? void 0 : String(input.private),
|
|
137
|
-
"filter[user_id]": input.userId === void 0 ? void 0 : String(input.userId),
|
|
138
|
-
"filter[severity]": trimmedText(input.severity),
|
|
139
|
-
"filter[severity_id]": trimmedText(input.severityId),
|
|
140
|
-
"filter[labels]": trimmedText(input.labels),
|
|
141
|
-
"filter[service_ids]": trimmedText(input.serviceIds),
|
|
142
|
-
"filter[service_names]": trimmedText(input.serviceNames),
|
|
143
|
-
"filter[team_ids]": trimmedText(input.teamIds),
|
|
144
|
-
"filter[team_names]": trimmedText(input.teamNames),
|
|
145
|
-
"filter[created_at][gt]": trimmedText(input.createdAtGt),
|
|
146
|
-
"filter[created_at][gte]": trimmedText(input.createdAtGte),
|
|
147
|
-
"filter[created_at][lt]": trimmedText(input.createdAtLt),
|
|
148
|
-
"filter[created_at][lte]": trimmedText(input.createdAtLte),
|
|
149
|
-
"sort": trimmedText(input.sort)
|
|
150
|
-
}));
|
|
151
|
-
}
|
|
152
|
-
function getIncident(input, ctx) {
|
|
153
|
-
return getSingleResource(
|
|
154
|
-
ctx,
|
|
155
|
-
`/incidents/${encodeURIComponent(input.id)}`,
|
|
156
|
-
compactDefined(includeQuery(input.include))
|
|
157
|
-
);
|
|
158
|
-
}
|
|
159
|
-
function listServices(input, ctx) {
|
|
160
|
-
return getList(ctx, "/services", configurationQuery(input));
|
|
161
|
-
}
|
|
162
|
-
function listTeams(input, ctx) {
|
|
163
|
-
return getList(ctx, "/teams", configurationQuery(input, { includeColor: true }));
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
// ../plugins/src/rootly/schema.ts
|
|
167
|
-
var getCurrentUserInput = external_exports.strictObject({}).describe("This action does not require input.");
|
|
168
|
-
var getCurrentUserOutput = external_exports.strictObject({
|
|
169
|
-
resource: external_exports.looseObject({
|
|
170
|
-
id: external_exports.string().min(1).describe("The Rootly resource ID.").optional(),
|
|
171
|
-
type: external_exports.string().min(1).describe("The Rootly resource type.").optional(),
|
|
172
|
-
attributes: external_exports.looseObject({}).describe("The Rootly resource attributes.").optional(),
|
|
173
|
-
relationships: external_exports.looseObject({}).describe("The Rootly resource relationships.").optional()
|
|
174
|
-
}).describe("A Rootly JSON:API resource."),
|
|
175
|
-
included: external_exports.array(external_exports.looseObject({}).describe("One included Rootly JSON:API resource.")).describe("Included Rootly JSON:API resources.").optional(),
|
|
176
|
-
raw: external_exports.looseObject({}).describe("The raw Rootly JSON:API response.")
|
|
177
|
-
}).describe("A Rootly single-resource response.");
|
|
178
|
-
var listIncidentsInput = external_exports.strictObject({
|
|
179
|
-
pageAfter: external_exports.string().min(1).describe("The Rootly cursor from meta.next_cursor.").optional(),
|
|
180
|
-
pageNumber: external_exports.int().min(1).describe("The page number to request.").optional(),
|
|
181
|
-
pageSize: external_exports.int().min(1).describe("The number of records to request per page.").optional(),
|
|
182
|
-
search: external_exports.string().min(1).describe("Search text for Rootly incident filtering.").optional(),
|
|
183
|
-
kind: external_exports.string().min(1).describe("Rootly incident kind filter.").optional(),
|
|
184
|
-
status: external_exports.string().min(1).describe("Rootly incident status filter.").optional(),
|
|
185
|
-
private: external_exports.boolean().describe("Whether to filter private incidents.").optional(),
|
|
186
|
-
userId: external_exports.int().min(1).describe("Rootly user ID filter.").optional(),
|
|
187
|
-
severity: external_exports.string().min(1).describe("Rootly severity name filter.").optional(),
|
|
188
|
-
severityId: external_exports.string().min(1).describe("Rootly severity ID filter.").optional(),
|
|
189
|
-
labels: external_exports.string().min(1).describe("Comma-separated Rootly label filter.").optional(),
|
|
190
|
-
serviceIds: external_exports.string().min(1).describe("Comma-separated Rootly service ID filter.").optional(),
|
|
191
|
-
serviceNames: external_exports.string().min(1).describe("Comma-separated Rootly service name filter.").optional(),
|
|
192
|
-
teamIds: external_exports.string().min(1).describe("Comma-separated Rootly team ID filter.").optional(),
|
|
193
|
-
teamNames: external_exports.string().min(1).describe("Comma-separated Rootly team name filter.").optional(),
|
|
194
|
-
createdAtGt: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
195
|
-
createdAtGte: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
196
|
-
createdAtLt: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
197
|
-
createdAtLte: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
198
|
-
sort: external_exports.string().min(1).describe("The Rootly sort expression, such as name or -created_at.").optional()
|
|
199
|
-
}).describe("Input for listing Rootly incidents.");
|
|
200
|
-
var listIncidentsOutput = external_exports.strictObject({
|
|
201
|
-
resources: external_exports.array(external_exports.looseObject({
|
|
202
|
-
id: external_exports.string().min(1).describe("The Rootly resource ID.").optional(),
|
|
203
|
-
type: external_exports.string().min(1).describe("The Rootly resource type.").optional(),
|
|
204
|
-
attributes: external_exports.looseObject({}).describe("The Rootly resource attributes.").optional(),
|
|
205
|
-
relationships: external_exports.looseObject({}).describe("The Rootly resource relationships.").optional()
|
|
206
|
-
}).describe("A Rootly JSON:API resource.")).describe("Rootly JSON:API resources."),
|
|
207
|
-
included: external_exports.array(external_exports.looseObject({}).describe("One included Rootly JSON:API resource.")).describe("Included Rootly JSON:API resources.").optional(),
|
|
208
|
-
links: external_exports.looseObject({}).describe("Rootly pagination or resource links.").optional(),
|
|
209
|
-
meta: external_exports.looseObject({}).describe("Rootly response metadata.").optional(),
|
|
210
|
-
raw: external_exports.looseObject({}).describe("The raw Rootly JSON:API response.")
|
|
211
|
-
}).describe("A Rootly list response.");
|
|
212
|
-
var getIncidentInput = external_exports.strictObject({
|
|
213
|
-
id: external_exports.string().min(1).describe("The Rootly resource UUID or slug."),
|
|
214
|
-
include: external_exports.array(external_exports.string().min(1).describe("One Rootly include value.")).min(1).describe("Related Rootly resources to include in the JSON:API response.").optional()
|
|
215
|
-
}).describe("Input for retrieving one Rootly resource.");
|
|
216
|
-
var getIncidentOutput = external_exports.strictObject({
|
|
217
|
-
resource: external_exports.looseObject({
|
|
218
|
-
id: external_exports.string().min(1).describe("The Rootly resource ID.").optional(),
|
|
219
|
-
type: external_exports.string().min(1).describe("The Rootly resource type.").optional(),
|
|
220
|
-
attributes: external_exports.looseObject({}).describe("The Rootly resource attributes.").optional(),
|
|
221
|
-
relationships: external_exports.looseObject({}).describe("The Rootly resource relationships.").optional()
|
|
222
|
-
}).describe("A Rootly JSON:API resource."),
|
|
223
|
-
included: external_exports.array(external_exports.looseObject({}).describe("One included Rootly JSON:API resource.")).describe("Included Rootly JSON:API resources.").optional(),
|
|
224
|
-
raw: external_exports.looseObject({}).describe("The raw Rootly JSON:API response.")
|
|
225
|
-
}).describe("A Rootly single-resource response.");
|
|
226
|
-
var listServicesInput = external_exports.strictObject({
|
|
227
|
-
include: external_exports.array(external_exports.string().min(1).describe("One Rootly include value.")).min(1).describe("Related Rootly resources to include in the JSON:API response.").optional(),
|
|
228
|
-
pageNumber: external_exports.int().min(1).describe("The page number to request.").optional(),
|
|
229
|
-
pageSize: external_exports.int().min(1).describe("The number of records to request per page.").optional(),
|
|
230
|
-
search: external_exports.string().min(1).describe("Search text for Rootly filtering.").optional(),
|
|
231
|
-
name: external_exports.string().min(1).describe("Rootly name filter.").optional(),
|
|
232
|
-
slug: external_exports.string().min(1).describe("Rootly slug filter.").optional(),
|
|
233
|
-
externalId: external_exports.string().min(1).describe("Rootly external ID filter.").optional(),
|
|
234
|
-
alertBroadcastEnabled: external_exports.boolean().describe("Whether alert broadcast is enabled.").optional(),
|
|
235
|
-
incidentBroadcastEnabled: external_exports.boolean().describe("Whether incident broadcast is enabled.").optional(),
|
|
236
|
-
createdAtGt: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
237
|
-
createdAtGte: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
238
|
-
createdAtLt: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
239
|
-
createdAtLte: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
240
|
-
sort: external_exports.string().min(1).describe("The Rootly sort expression, such as name or -created_at.").optional()
|
|
241
|
-
}).describe("Input for listing Rootly services.");
|
|
242
|
-
var listServicesOutput = external_exports.strictObject({
|
|
243
|
-
resources: external_exports.array(external_exports.looseObject({
|
|
244
|
-
id: external_exports.string().min(1).describe("The Rootly resource ID.").optional(),
|
|
245
|
-
type: external_exports.string().min(1).describe("The Rootly resource type.").optional(),
|
|
246
|
-
attributes: external_exports.looseObject({}).describe("The Rootly resource attributes.").optional(),
|
|
247
|
-
relationships: external_exports.looseObject({}).describe("The Rootly resource relationships.").optional()
|
|
248
|
-
}).describe("A Rootly JSON:API resource.")).describe("Rootly JSON:API resources."),
|
|
249
|
-
included: external_exports.array(external_exports.looseObject({}).describe("One included Rootly JSON:API resource.")).describe("Included Rootly JSON:API resources.").optional(),
|
|
250
|
-
links: external_exports.looseObject({}).describe("Rootly pagination or resource links.").optional(),
|
|
251
|
-
meta: external_exports.looseObject({}).describe("Rootly response metadata.").optional(),
|
|
252
|
-
raw: external_exports.looseObject({}).describe("The raw Rootly JSON:API response.")
|
|
253
|
-
}).describe("A Rootly list response.");
|
|
254
|
-
var listTeamsInput = external_exports.strictObject({
|
|
255
|
-
include: external_exports.array(external_exports.string().min(1).describe("One Rootly include value.")).min(1).describe("Related Rootly resources to include in the JSON:API response.").optional(),
|
|
256
|
-
pageNumber: external_exports.int().min(1).describe("The page number to request.").optional(),
|
|
257
|
-
pageSize: external_exports.int().min(1).describe("The number of records to request per page.").optional(),
|
|
258
|
-
search: external_exports.string().min(1).describe("Search text for Rootly filtering.").optional(),
|
|
259
|
-
name: external_exports.string().min(1).describe("Rootly name filter.").optional(),
|
|
260
|
-
slug: external_exports.string().min(1).describe("Rootly slug filter.").optional(),
|
|
261
|
-
externalId: external_exports.string().min(1).describe("Rootly external ID filter.").optional(),
|
|
262
|
-
alertBroadcastEnabled: external_exports.boolean().describe("Whether alert broadcast is enabled.").optional(),
|
|
263
|
-
incidentBroadcastEnabled: external_exports.boolean().describe("Whether incident broadcast is enabled.").optional(),
|
|
264
|
-
createdAtGt: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
265
|
-
createdAtGte: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
266
|
-
createdAtLt: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
267
|
-
createdAtLte: external_exports.iso.datetime({ offset: true }).describe("The ISO 8601 timestamp for this filter.").optional(),
|
|
268
|
-
sort: external_exports.string().min(1).describe("The Rootly sort expression, such as name or -created_at.").optional(),
|
|
269
|
-
color: external_exports.string().min(1).describe("Rootly team color filter.").optional()
|
|
270
|
-
}).describe("Input for listing Rootly teams.");
|
|
271
|
-
var listTeamsOutput = external_exports.strictObject({
|
|
272
|
-
resources: external_exports.array(external_exports.looseObject({
|
|
273
|
-
id: external_exports.string().min(1).describe("The Rootly resource ID.").optional(),
|
|
274
|
-
type: external_exports.string().min(1).describe("The Rootly resource type.").optional(),
|
|
275
|
-
attributes: external_exports.looseObject({}).describe("The Rootly resource attributes.").optional(),
|
|
276
|
-
relationships: external_exports.looseObject({}).describe("The Rootly resource relationships.").optional()
|
|
277
|
-
}).describe("A Rootly JSON:API resource.")).describe("Rootly JSON:API resources."),
|
|
278
|
-
included: external_exports.array(external_exports.looseObject({}).describe("One included Rootly JSON:API resource.")).describe("Included Rootly JSON:API resources.").optional(),
|
|
279
|
-
links: external_exports.looseObject({}).describe("Rootly pagination or resource links.").optional(),
|
|
280
|
-
meta: external_exports.looseObject({}).describe("Rootly response metadata.").optional(),
|
|
281
|
-
raw: external_exports.looseObject({}).describe("The raw Rootly JSON:API response.")
|
|
282
|
-
}).describe("A Rootly list response.");
|
|
283
|
-
var rootlyActions = {
|
|
284
|
-
get_current_user: {
|
|
285
|
-
description: "Get the Rootly user associated with the API key.",
|
|
286
|
-
effect: "read",
|
|
287
|
-
inputSchema: getCurrentUserInput,
|
|
288
|
-
outputSchema: external_exports.toJSONSchema(getCurrentUserOutput, { io: "output", unrepresentable: "any" })
|
|
289
|
-
},
|
|
290
|
-
list_incidents: {
|
|
291
|
-
description: "List Rootly incidents with common filters and pagination.",
|
|
292
|
-
effect: "read",
|
|
293
|
-
inputSchema: listIncidentsInput,
|
|
294
|
-
outputSchema: external_exports.toJSONSchema(listIncidentsOutput, { io: "output", unrepresentable: "any" })
|
|
295
|
-
},
|
|
296
|
-
get_incident: {
|
|
297
|
-
description: "Retrieve one Rootly incident by UUID or slug.",
|
|
298
|
-
effect: "read",
|
|
299
|
-
inputSchema: getIncidentInput,
|
|
300
|
-
outputSchema: external_exports.toJSONSchema(getIncidentOutput, { io: "output", unrepresentable: "any" })
|
|
301
|
-
},
|
|
302
|
-
list_services: {
|
|
303
|
-
description: "List Rootly services with common filters and pagination.",
|
|
304
|
-
effect: "read",
|
|
305
|
-
inputSchema: listServicesInput,
|
|
306
|
-
outputSchema: external_exports.toJSONSchema(listServicesOutput, { io: "output", unrepresentable: "any" })
|
|
307
|
-
},
|
|
308
|
-
list_teams: {
|
|
309
|
-
description: "List Rootly teams with common filters and pagination.",
|
|
310
|
-
effect: "read",
|
|
311
|
-
inputSchema: listTeamsInput,
|
|
312
|
-
outputSchema: external_exports.toJSONSchema(listTeamsOutput, { io: "output", unrepresentable: "any" })
|
|
313
|
-
}
|
|
314
|
-
};
|
|
315
|
-
|
|
316
|
-
// ../plugins/src/rootly/index.ts
|
|
317
|
-
function createRootlyPlugin() {
|
|
318
|
-
return createProviderPlugin({
|
|
319
|
-
description: "Rootly",
|
|
320
|
-
actions: rootlyActions,
|
|
321
|
-
// 上游 credentialValidators 打的就是 /users/me,与 get_current_user 同一个接口。
|
|
322
|
-
credentialProbe: "get_current_user",
|
|
323
|
-
handlers: {
|
|
324
|
-
get_current_user: getCurrentUser,
|
|
325
|
-
list_incidents: listIncidents,
|
|
326
|
-
get_incident: getIncident,
|
|
327
|
-
list_services: listServices,
|
|
328
|
-
list_teams: listTeams
|
|
329
|
-
}
|
|
330
|
-
});
|
|
331
|
-
}
|
|
332
|
-
var rootly_default = createRootlyPlugin();
|
|
333
|
-
export {
|
|
334
|
-
createRootlyPlugin,
|
|
335
|
-
rootly_default as default
|
|
336
|
-
};
|