@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
|
@@ -0,0 +1,585 @@
|
|
|
1
|
+
import {
|
|
2
|
+
createProviderPlugin,
|
|
3
|
+
requireApiKey,
|
|
4
|
+
upstreamError
|
|
5
|
+
} from "./chunk-WJHG6OK7.js";
|
|
6
|
+
import {
|
|
7
|
+
guardedFetch
|
|
8
|
+
} from "./chunk-2JNAI4OC.js";
|
|
9
|
+
import "./chunk-BADVCN6K.js";
|
|
10
|
+
import {
|
|
11
|
+
TBError
|
|
12
|
+
} from "./chunk-5ICRY3VU.js";
|
|
13
|
+
import "./chunk-U67V476Y.js";
|
|
14
|
+
|
|
15
|
+
// ../plugins/src/stripe/api.ts
|
|
16
|
+
var SERVICE = "stripe";
|
|
17
|
+
var API_BASE = "https://api.stripe.com";
|
|
18
|
+
var API_VERSION = "2024-06-20";
|
|
19
|
+
var ACCOUNT_PATH = "/v1/account";
|
|
20
|
+
function appendParams(params, value, prefix) {
|
|
21
|
+
if (value === void 0 || value === null || value === "") return;
|
|
22
|
+
if (Array.isArray(value)) {
|
|
23
|
+
for (const item of value) appendParams(params, item, prefix);
|
|
24
|
+
return;
|
|
25
|
+
}
|
|
26
|
+
if (typeof value === "object") {
|
|
27
|
+
for (const [key, child] of Object.entries(value)) {
|
|
28
|
+
appendParams(params, child, prefix === void 0 ? key : `${prefix}[${key}]`);
|
|
29
|
+
}
|
|
30
|
+
return;
|
|
31
|
+
}
|
|
32
|
+
if (prefix === void 0) return;
|
|
33
|
+
params.append(prefix, String(value));
|
|
34
|
+
}
|
|
35
|
+
function pathSegment(value, field) {
|
|
36
|
+
if (typeof value !== "string" || value === "") {
|
|
37
|
+
throw new TBError("invalid_argument", `${field} \u4E0D\u80FD\u4E3A\u7A7A`);
|
|
38
|
+
}
|
|
39
|
+
return encodeURIComponent(value);
|
|
40
|
+
}
|
|
41
|
+
async function errorMessage(response) {
|
|
42
|
+
try {
|
|
43
|
+
const payload = await response.clone().json();
|
|
44
|
+
const message = payload.error?.message;
|
|
45
|
+
if (typeof message === "string" && message !== "") return message;
|
|
46
|
+
} catch {
|
|
47
|
+
}
|
|
48
|
+
const text = await response.text().catch(() => "");
|
|
49
|
+
return text.trim() || `Stripe \u8FD4\u56DE HTTP ${response.status}`;
|
|
50
|
+
}
|
|
51
|
+
async function request(ctx, path, input) {
|
|
52
|
+
const url = new URL(`${API_BASE}${path}`);
|
|
53
|
+
appendParams(url.searchParams, input.query);
|
|
54
|
+
const headers = {
|
|
55
|
+
"authorization": `Bearer ${requireApiKey(ctx, SERVICE)}`,
|
|
56
|
+
"stripe-version": API_VERSION
|
|
57
|
+
};
|
|
58
|
+
let body;
|
|
59
|
+
if (input.body !== void 0) {
|
|
60
|
+
const params = new URLSearchParams();
|
|
61
|
+
appendParams(params, input.body);
|
|
62
|
+
body = params.toString();
|
|
63
|
+
headers["content-type"] = "application/x-www-form-urlencoded;charset=UTF-8";
|
|
64
|
+
}
|
|
65
|
+
const response = await guardedFetch(url.toString(), {
|
|
66
|
+
method: input.method,
|
|
67
|
+
headers,
|
|
68
|
+
...body === void 0 ? {} : { body }
|
|
69
|
+
});
|
|
70
|
+
if (!response.ok) throw upstreamError(response.status, await errorMessage(response));
|
|
71
|
+
if (response.status === 204) return {};
|
|
72
|
+
const payload = await response.json();
|
|
73
|
+
if (payload === null || typeof payload !== "object" || Array.isArray(payload)) {
|
|
74
|
+
throw new TBError("unavailable", "Stripe \u8FD4\u56DE\u4E86\u975E\u5BF9\u8C61\u54CD\u5E94", { retryable: true });
|
|
75
|
+
}
|
|
76
|
+
return payload;
|
|
77
|
+
}
|
|
78
|
+
function withoutKeys(input, keys) {
|
|
79
|
+
const drop = new Set(keys);
|
|
80
|
+
return Object.fromEntries(Object.entries(input).filter(([key]) => !drop.has(key)));
|
|
81
|
+
}
|
|
82
|
+
function deletionResult(payload) {
|
|
83
|
+
return {
|
|
84
|
+
deleted: payload.deleted === true,
|
|
85
|
+
object: typeof payload.object === "string" ? payload.object : "unknown",
|
|
86
|
+
id: typeof payload.id === "string" ? payload.id : "unknown",
|
|
87
|
+
raw: payload
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
async function identifyAccount(_input, ctx) {
|
|
91
|
+
const account = await request(ctx, ACCOUNT_PATH, { method: "GET" });
|
|
92
|
+
const text = (value) => typeof value === "string" ? value : null;
|
|
93
|
+
return {
|
|
94
|
+
account,
|
|
95
|
+
accountId: text(account.id),
|
|
96
|
+
email: text(account.email),
|
|
97
|
+
country: text(account.country),
|
|
98
|
+
defaultCurrency: text(account.default_currency)
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
async function createCustomer(input, ctx) {
|
|
102
|
+
return { customer: await request(ctx, "/v1/customers", { method: "POST", body: input }) };
|
|
103
|
+
}
|
|
104
|
+
async function updateCustomer(input, ctx) {
|
|
105
|
+
const path = `/v1/customers/${pathSegment(input.customerId, "customerId")}`;
|
|
106
|
+
return { customer: await request(ctx, path, { method: "POST", body: withoutKeys(input, ["customerId"]) }) };
|
|
107
|
+
}
|
|
108
|
+
async function getCustomer(input, ctx) {
|
|
109
|
+
const path = `/v1/customers/${pathSegment(input.customerId, "customerId")}`;
|
|
110
|
+
return { customer: await request(ctx, path, { method: "GET" }) };
|
|
111
|
+
}
|
|
112
|
+
async function listCustomers(input, ctx) {
|
|
113
|
+
return { customers: await request(ctx, "/v1/customers", { method: "GET", query: input }) };
|
|
114
|
+
}
|
|
115
|
+
async function searchCustomers(input, ctx) {
|
|
116
|
+
return { customers: await request(ctx, "/v1/customers/search", { method: "GET", query: input }) };
|
|
117
|
+
}
|
|
118
|
+
async function deleteCustomer(input, ctx) {
|
|
119
|
+
const path = `/v1/customers/${pathSegment(input.customerId, "customerId")}`;
|
|
120
|
+
return deletionResult(await request(ctx, path, { method: "DELETE" }));
|
|
121
|
+
}
|
|
122
|
+
async function createProduct(input, ctx) {
|
|
123
|
+
return { product: await request(ctx, "/v1/products", { method: "POST", body: input }) };
|
|
124
|
+
}
|
|
125
|
+
async function updateProduct(input, ctx) {
|
|
126
|
+
const path = `/v1/products/${pathSegment(input.productId, "productId")}`;
|
|
127
|
+
return { product: await request(ctx, path, { method: "POST", body: withoutKeys(input, ["productId"]) }) };
|
|
128
|
+
}
|
|
129
|
+
async function getProduct(input, ctx) {
|
|
130
|
+
const path = `/v1/products/${pathSegment(input.productId, "productId")}`;
|
|
131
|
+
return { product: await request(ctx, path, { method: "GET" }) };
|
|
132
|
+
}
|
|
133
|
+
async function listProducts(input, ctx) {
|
|
134
|
+
return { products: await request(ctx, "/v1/products", { method: "GET", query: input }) };
|
|
135
|
+
}
|
|
136
|
+
async function searchProducts(input, ctx) {
|
|
137
|
+
return { products: await request(ctx, "/v1/products/search", { method: "GET", query: input }) };
|
|
138
|
+
}
|
|
139
|
+
async function deleteProduct(input, ctx) {
|
|
140
|
+
const path = `/v1/products/${pathSegment(input.productId, "productId")}`;
|
|
141
|
+
return deletionResult(await request(ctx, path, { method: "DELETE" }));
|
|
142
|
+
}
|
|
143
|
+
async function createPrice(input, ctx) {
|
|
144
|
+
if (input.product === void 0 && input.product_data === void 0) {
|
|
145
|
+
throw new TBError("invalid_argument", "create_price \u9700\u8981 product \u6216 product_data");
|
|
146
|
+
}
|
|
147
|
+
if (input.unit_amount === void 0 && input.unit_amount_decimal === void 0 && input.custom_unit_amount === void 0) {
|
|
148
|
+
throw new TBError(
|
|
149
|
+
"invalid_argument",
|
|
150
|
+
"create_price \u9700\u8981 unit_amount\u3001unit_amount_decimal \u6216 custom_unit_amount \u4E4B\u4E00"
|
|
151
|
+
);
|
|
152
|
+
}
|
|
153
|
+
if (input.custom_unit_amount !== void 0 && (input.unit_amount !== void 0 || input.unit_amount_decimal !== void 0)) {
|
|
154
|
+
throw new TBError(
|
|
155
|
+
"invalid_argument",
|
|
156
|
+
"create_price \u7684 custom_unit_amount \u4E0D\u80FD\u4E0E unit_amount / unit_amount_decimal \u540C\u65F6\u7ED9\u51FA"
|
|
157
|
+
);
|
|
158
|
+
}
|
|
159
|
+
return { price: await request(ctx, "/v1/prices", { method: "POST", body: input }) };
|
|
160
|
+
}
|
|
161
|
+
async function updatePrice(input, ctx) {
|
|
162
|
+
const path = `/v1/prices/${pathSegment(input.priceId, "priceId")}`;
|
|
163
|
+
return { price: await request(ctx, path, { method: "POST", body: withoutKeys(input, ["priceId"]) }) };
|
|
164
|
+
}
|
|
165
|
+
async function getPrice(input, ctx) {
|
|
166
|
+
const path = `/v1/prices/${pathSegment(input.priceId, "priceId")}`;
|
|
167
|
+
return { price: await request(ctx, path, { method: "GET" }) };
|
|
168
|
+
}
|
|
169
|
+
async function listPrices(input, ctx) {
|
|
170
|
+
return { prices: await request(ctx, "/v1/prices", { method: "GET", query: input }) };
|
|
171
|
+
}
|
|
172
|
+
async function searchPrices(input, ctx) {
|
|
173
|
+
return { prices: await request(ctx, "/v1/prices/search", { method: "GET", query: input }) };
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
// ../plugins/src/stripe/schema.ts
|
|
177
|
+
import { z } from "zod/v4";
|
|
178
|
+
var identifyAccountInput = z.strictObject({}).describe("No input is required to identify a Stripe account.");
|
|
179
|
+
var identifyAccountOutput = z.strictObject({
|
|
180
|
+
account: z.looseObject({}).describe("A raw Stripe object returned by the API."),
|
|
181
|
+
accountId: z.string().describe("The Stripe account ID.").nullable(),
|
|
182
|
+
email: z.string().describe("The Stripe account email address.").nullable(),
|
|
183
|
+
country: z.string().describe("The Stripe account country.").nullable(),
|
|
184
|
+
defaultCurrency: z.string().describe("The Stripe account default currency.").nullable()
|
|
185
|
+
}).describe("Stripe account metadata.");
|
|
186
|
+
var createCustomerInput = z.strictObject({
|
|
187
|
+
name: z.string().max(256).describe("The customer's full name or business name.").optional(),
|
|
188
|
+
email: z.email().describe("The customer's email address.").optional(),
|
|
189
|
+
description: z.string().describe("An arbitrary customer description displayed in the Stripe Dashboard.").optional(),
|
|
190
|
+
phone: z.string().max(20).describe("The customer's phone number.").optional(),
|
|
191
|
+
balance: z.int().describe("The customer balance in the smallest currency unit.").optional(),
|
|
192
|
+
address: z.strictObject({
|
|
193
|
+
city: z.string().describe("City, district, suburb, town, or village.").optional(),
|
|
194
|
+
country: z.string().describe("Two-letter country code, or a freeform country value where Stripe allows it.").optional(),
|
|
195
|
+
line1: z.string().describe("Address line 1, such as the street, PO Box, or company name.").optional(),
|
|
196
|
+
line2: z.string().describe("Address line 2, such as the apartment, suite, unit, or building.").optional(),
|
|
197
|
+
postal_code: z.string().describe("ZIP or postal code.").optional(),
|
|
198
|
+
state: z.string().describe("State, county, province, or region.").optional()
|
|
199
|
+
}).describe("A Stripe address object.").optional(),
|
|
200
|
+
metadata: z.record(z.string(), z.union([z.string(), z.number(), z.boolean()])).describe("Stripe metadata key-value pairs. Values are forwarded as strings, numbers, booleans, or empty strings.").optional(),
|
|
201
|
+
tax_exempt: z.enum(["none", "exempt", "reverse"]).describe("The customer's tax exemption status.").optional()
|
|
202
|
+
}).describe("Input for creating a Stripe customer.");
|
|
203
|
+
var createCustomerOutput = z.strictObject({
|
|
204
|
+
customer: z.looseObject({}).describe("A raw Stripe object returned by the API.").nullable()
|
|
205
|
+
}).describe("A Stripe customer result.");
|
|
206
|
+
var updateCustomerInput = z.strictObject({
|
|
207
|
+
customerId: z.string().min(1).describe("The Stripe customer ID to update."),
|
|
208
|
+
name: z.string().max(256).describe("The customer's full name or business name.").optional(),
|
|
209
|
+
email: z.email().describe("The customer's email address.").optional(),
|
|
210
|
+
description: z.string().describe("An arbitrary customer description displayed in the Stripe Dashboard.").optional(),
|
|
211
|
+
phone: z.string().max(20).describe("The customer's phone number.").optional(),
|
|
212
|
+
balance: z.int().describe("The customer balance in the smallest currency unit.").optional(),
|
|
213
|
+
address: z.strictObject({
|
|
214
|
+
city: z.string().describe("City, district, suburb, town, or village.").optional(),
|
|
215
|
+
country: z.string().describe("Two-letter country code, or a freeform country value where Stripe allows it.").optional(),
|
|
216
|
+
line1: z.string().describe("Address line 1, such as the street, PO Box, or company name.").optional(),
|
|
217
|
+
line2: z.string().describe("Address line 2, such as the apartment, suite, unit, or building.").optional(),
|
|
218
|
+
postal_code: z.string().describe("ZIP or postal code.").optional(),
|
|
219
|
+
state: z.string().describe("State, county, province, or region.").optional()
|
|
220
|
+
}).describe("A Stripe address object.").optional(),
|
|
221
|
+
metadata: z.record(z.string(), z.union([z.string(), z.number(), z.boolean()])).describe("Stripe metadata key-value pairs. Values are forwarded as strings, numbers, booleans, or empty strings.").optional(),
|
|
222
|
+
tax_exempt: z.enum(["none", "exempt", "reverse"]).describe("The customer's tax exemption status.").optional()
|
|
223
|
+
}).describe("Input for updating a Stripe customer.");
|
|
224
|
+
var updateCustomerOutput = z.strictObject({
|
|
225
|
+
customer: z.looseObject({}).describe("A raw Stripe object returned by the API.").nullable()
|
|
226
|
+
}).describe("A Stripe customer result.");
|
|
227
|
+
var getCustomerInput = z.strictObject({
|
|
228
|
+
customerId: z.string().min(1).describe("The Stripe customer ID to retrieve.")
|
|
229
|
+
}).describe("Input for retrieving a Stripe customer.");
|
|
230
|
+
var getCustomerOutput = z.strictObject({
|
|
231
|
+
customer: z.looseObject({}).describe("A raw Stripe object returned by the API.").nullable()
|
|
232
|
+
}).describe("A Stripe customer result.");
|
|
233
|
+
var listCustomersInput = z.strictObject({
|
|
234
|
+
limit: z.int().min(1).max(100).describe("The maximum number of objects to return. Stripe accepts values from 1 to 100.").optional(),
|
|
235
|
+
starting_after: z.string().min(1).describe("A cursor object ID that fetches the next page after that object.").optional(),
|
|
236
|
+
ending_before: z.string().min(1).describe("A cursor object ID that fetches the previous page before that object.").optional(),
|
|
237
|
+
email: z.email().describe("Filter customers by an exact, case-sensitive email address.").optional(),
|
|
238
|
+
created: z.strictObject({
|
|
239
|
+
gt: z.int().describe("Return objects created after this Unix timestamp, exclusive.").optional(),
|
|
240
|
+
gte: z.int().describe("Return objects created after or at this Unix timestamp.").optional(),
|
|
241
|
+
lt: z.int().describe("Return objects created before this Unix timestamp, exclusive.").optional(),
|
|
242
|
+
lte: z.int().describe("Return objects created before or at this Unix timestamp.").optional()
|
|
243
|
+
}).describe("A Stripe created timestamp interval filter.").optional()
|
|
244
|
+
}).describe("Input for listing Stripe customers.");
|
|
245
|
+
var listCustomersOutput = z.strictObject({
|
|
246
|
+
customers: z.strictObject({
|
|
247
|
+
object: z.string().describe("The Stripe response object type."),
|
|
248
|
+
url: z.string().describe("The Stripe API URL for this list."),
|
|
249
|
+
has_more: z.boolean().describe("Whether more objects are available after this page."),
|
|
250
|
+
data: z.array(z.looseObject({}).describe("A raw Stripe object returned by the API.")).describe("Stripe objects returned on this page.")
|
|
251
|
+
}).describe("A Stripe list response.")
|
|
252
|
+
}).describe("Stripe customers page.");
|
|
253
|
+
var searchCustomersInput = z.strictObject({
|
|
254
|
+
query: z.string().min(1).describe("A Stripe customer search query, such as email:'jenny@example.com'."),
|
|
255
|
+
limit: z.int().min(1).max(100).describe("The maximum number of objects to return. Stripe accepts values from 1 to 100.").optional(),
|
|
256
|
+
page: z.string().describe("A Stripe search pagination token returned by a previous search response.").optional()
|
|
257
|
+
}).describe("Input for searching Stripe customers.");
|
|
258
|
+
var searchCustomersOutput = z.strictObject({
|
|
259
|
+
customers: z.strictObject({
|
|
260
|
+
object: z.string().describe("The Stripe response object type."),
|
|
261
|
+
url: z.string().describe("The Stripe API URL for this list."),
|
|
262
|
+
has_more: z.boolean().describe("Whether more objects are available after this page."),
|
|
263
|
+
data: z.array(z.looseObject({}).describe("A raw Stripe object returned by the API.")).describe("Stripe objects returned on this page.")
|
|
264
|
+
}).describe("A Stripe list response.")
|
|
265
|
+
}).describe("Stripe customer search results.");
|
|
266
|
+
var deleteCustomerInput = z.strictObject({
|
|
267
|
+
customerId: z.string().min(1).describe("The Stripe customer ID to delete.")
|
|
268
|
+
}).describe("Input for deleting a Stripe customer.");
|
|
269
|
+
var deleteCustomerOutput = z.strictObject({
|
|
270
|
+
deleted: z.boolean().describe("Whether Stripe deleted the object."),
|
|
271
|
+
object: z.string().describe("The deleted Stripe object type."),
|
|
272
|
+
id: z.string().describe("The deleted Stripe object ID."),
|
|
273
|
+
raw: z.looseObject({}).describe("A raw Stripe object returned by the API.")
|
|
274
|
+
}).describe("A Stripe delete result.");
|
|
275
|
+
var createProductInput = z.strictObject({
|
|
276
|
+
name: z.string().min(1).describe("The product's display name."),
|
|
277
|
+
active: z.boolean().describe("Whether the product is available for purchase.").optional(),
|
|
278
|
+
description: z.string().describe("The product description.").optional(),
|
|
279
|
+
id: z.string().describe("A caller-supplied product ID. Stripe normally generates this when omitted.").optional(),
|
|
280
|
+
images: z.array(z.url().describe("One public product image URL.")).max(8).describe("Public image URLs for the product.").optional(),
|
|
281
|
+
metadata: z.record(z.string(), z.union([z.string(), z.number(), z.boolean()])).describe("Stripe metadata key-value pairs. Values are forwarded as strings, numbers, booleans, or empty strings.").optional(),
|
|
282
|
+
shippable: z.boolean().describe("Whether this product is shipped as a physical good.").optional(),
|
|
283
|
+
statement_descriptor: z.string().max(22).describe("Statement descriptor for subscription payments.").optional(),
|
|
284
|
+
tax_code: z.string().describe("Stripe tax code ID for this product.").optional(),
|
|
285
|
+
unit_label: z.string().max(12).describe("A label that represents units of this product.").optional(),
|
|
286
|
+
url: z.url().describe("A publicly accessible product webpage URL.").optional()
|
|
287
|
+
}).describe("Input for creating a Stripe product.");
|
|
288
|
+
var createProductOutput = z.strictObject({
|
|
289
|
+
product: z.looseObject({}).describe("A raw Stripe object returned by the API.").nullable()
|
|
290
|
+
}).describe("A Stripe product result.");
|
|
291
|
+
var updateProductInput = z.strictObject({
|
|
292
|
+
productId: z.string().min(1).describe("The Stripe product ID to update."),
|
|
293
|
+
name: z.string().min(1).describe("The product's display name.").optional(),
|
|
294
|
+
active: z.boolean().describe("Whether the product is available for purchase.").optional(),
|
|
295
|
+
description: z.string().describe("The product description.").optional(),
|
|
296
|
+
id: z.string().describe("A caller-supplied product ID. Stripe normally generates this when omitted.").optional(),
|
|
297
|
+
images: z.array(z.url().describe("One public product image URL.")).max(8).describe("Public image URLs for the product.").optional(),
|
|
298
|
+
metadata: z.record(z.string(), z.union([z.string(), z.number(), z.boolean()])).describe("Stripe metadata key-value pairs. Values are forwarded as strings, numbers, booleans, or empty strings.").optional(),
|
|
299
|
+
shippable: z.boolean().describe("Whether this product is shipped as a physical good.").optional(),
|
|
300
|
+
statement_descriptor: z.string().max(22).describe("Statement descriptor for subscription payments.").optional(),
|
|
301
|
+
tax_code: z.string().describe("Stripe tax code ID for this product.").optional(),
|
|
302
|
+
unit_label: z.string().max(12).describe("A label that represents units of this product.").optional(),
|
|
303
|
+
url: z.url().describe("A publicly accessible product webpage URL.").optional()
|
|
304
|
+
}).describe("Input for updating a Stripe product.");
|
|
305
|
+
var updateProductOutput = z.strictObject({
|
|
306
|
+
product: z.looseObject({}).describe("A raw Stripe object returned by the API.").nullable()
|
|
307
|
+
}).describe("A Stripe product result.");
|
|
308
|
+
var getProductInput = z.strictObject({
|
|
309
|
+
productId: z.string().min(1).describe("The Stripe product ID to retrieve.")
|
|
310
|
+
}).describe("Input for retrieving a Stripe product.");
|
|
311
|
+
var getProductOutput = z.strictObject({
|
|
312
|
+
product: z.looseObject({}).describe("A raw Stripe object returned by the API.").nullable()
|
|
313
|
+
}).describe("A Stripe product result.");
|
|
314
|
+
var listProductsInput = z.strictObject({
|
|
315
|
+
limit: z.int().min(1).max(100).describe("The maximum number of objects to return. Stripe accepts values from 1 to 100.").optional(),
|
|
316
|
+
starting_after: z.string().min(1).describe("A cursor object ID that fetches the next page after that object.").optional(),
|
|
317
|
+
ending_before: z.string().min(1).describe("A cursor object ID that fetches the previous page before that object.").optional(),
|
|
318
|
+
active: z.boolean().describe("Filter products by active status.").optional(),
|
|
319
|
+
ids: z.array(z.string().min(1).describe("A Stripe product ID.")).describe("Filter products by Stripe product IDs.").optional(),
|
|
320
|
+
created: z.strictObject({
|
|
321
|
+
gt: z.int().describe("Return objects created after this Unix timestamp, exclusive.").optional(),
|
|
322
|
+
gte: z.int().describe("Return objects created after or at this Unix timestamp.").optional(),
|
|
323
|
+
lt: z.int().describe("Return objects created before this Unix timestamp, exclusive.").optional(),
|
|
324
|
+
lte: z.int().describe("Return objects created before or at this Unix timestamp.").optional()
|
|
325
|
+
}).describe("A Stripe created timestamp interval filter.").optional()
|
|
326
|
+
}).describe("Input for listing Stripe products.");
|
|
327
|
+
var listProductsOutput = z.strictObject({
|
|
328
|
+
products: z.strictObject({
|
|
329
|
+
object: z.string().describe("The Stripe response object type."),
|
|
330
|
+
url: z.string().describe("The Stripe API URL for this list."),
|
|
331
|
+
has_more: z.boolean().describe("Whether more objects are available after this page."),
|
|
332
|
+
data: z.array(z.looseObject({}).describe("A raw Stripe object returned by the API.")).describe("Stripe objects returned on this page.")
|
|
333
|
+
}).describe("A Stripe list response.")
|
|
334
|
+
}).describe("Stripe products page.");
|
|
335
|
+
var searchProductsInput = z.strictObject({
|
|
336
|
+
query: z.string().min(1).describe("A Stripe product search query, such as active:'true'."),
|
|
337
|
+
limit: z.int().min(1).max(100).describe("The maximum number of objects to return. Stripe accepts values from 1 to 100.").optional(),
|
|
338
|
+
page: z.string().describe("A Stripe search pagination token returned by a previous search response.").optional()
|
|
339
|
+
}).describe("Input for searching Stripe products.");
|
|
340
|
+
var searchProductsOutput = z.strictObject({
|
|
341
|
+
products: z.strictObject({
|
|
342
|
+
object: z.string().describe("The Stripe response object type."),
|
|
343
|
+
url: z.string().describe("The Stripe API URL for this list."),
|
|
344
|
+
has_more: z.boolean().describe("Whether more objects are available after this page."),
|
|
345
|
+
data: z.array(z.looseObject({}).describe("A raw Stripe object returned by the API.")).describe("Stripe objects returned on this page.")
|
|
346
|
+
}).describe("A Stripe list response.")
|
|
347
|
+
}).describe("Stripe product search results.");
|
|
348
|
+
var deleteProductInput = z.strictObject({
|
|
349
|
+
productId: z.string().min(1).describe("The Stripe product ID to delete.")
|
|
350
|
+
}).describe("Input for deleting a Stripe product.");
|
|
351
|
+
var deleteProductOutput = z.strictObject({
|
|
352
|
+
deleted: z.boolean().describe("Whether Stripe deleted the object."),
|
|
353
|
+
object: z.string().describe("The deleted Stripe object type."),
|
|
354
|
+
id: z.string().describe("The deleted Stripe object ID."),
|
|
355
|
+
raw: z.looseObject({}).describe("A raw Stripe object returned by the API.")
|
|
356
|
+
}).describe("A Stripe delete result.");
|
|
357
|
+
var createPriceInput = z.strictObject({
|
|
358
|
+
currency: z.string().min(3).max(3).describe("Three-letter ISO currency code in lowercase."),
|
|
359
|
+
product: z.string().min(1).describe("The Stripe product ID this price belongs to.").optional(),
|
|
360
|
+
product_data: z.strictObject({
|
|
361
|
+
name: z.string().min(1).describe("The product's display name."),
|
|
362
|
+
active: z.boolean().describe("Whether the product is available for purchase.").optional(),
|
|
363
|
+
metadata: z.record(z.string(), z.union([z.string(), z.number(), z.boolean()])).describe("Stripe metadata key-value pairs. Values are forwarded as strings, numbers, booleans, or empty strings.").optional(),
|
|
364
|
+
statement_descriptor: z.string().max(22).describe("Statement descriptor for subscription payments.").optional(),
|
|
365
|
+
tax_code: z.string().describe("Stripe tax code ID for this product.").optional(),
|
|
366
|
+
unit_label: z.string().max(12).describe("A label that represents units of this product.").optional()
|
|
367
|
+
}).describe("Inline product data for creating a product while creating a price.").optional(),
|
|
368
|
+
unit_amount: z.int().describe("Unit amount in the smallest currency unit.").optional(),
|
|
369
|
+
unit_amount_decimal: z.string().describe("Decimal unit amount in the smallest currency unit.").optional(),
|
|
370
|
+
custom_unit_amount: z.strictObject({
|
|
371
|
+
enabled: z.literal(true).describe("Whether customer-defined pricing is enabled for this price."),
|
|
372
|
+
minimum: z.int().describe("The minimum allowed amount in the smallest currency unit.").optional(),
|
|
373
|
+
maximum: z.int().describe("The maximum allowed amount in the smallest currency unit.").optional(),
|
|
374
|
+
preset: z.int().describe("The suggested amount in the smallest currency unit.").optional()
|
|
375
|
+
}).describe("Custom unit amount configuration that lets the payer choose the price amount.").optional(),
|
|
376
|
+
active: z.boolean().describe("Whether the price can be used for new purchases.").optional(),
|
|
377
|
+
lookup_key: z.string().max(200).describe("A lookup key used to retrieve this price dynamically.").optional(),
|
|
378
|
+
metadata: z.record(z.string(), z.union([z.string(), z.number(), z.boolean()])).describe("Stripe metadata key-value pairs. Values are forwarded as strings, numbers, booleans, or empty strings.").optional(),
|
|
379
|
+
nickname: z.string().describe("A brief internal description of the price.").optional(),
|
|
380
|
+
recurring: z.strictObject({
|
|
381
|
+
interval: z.enum(["day", "week", "month", "year"]).describe("The billing frequency interval."),
|
|
382
|
+
interval_count: z.int().describe("The number of intervals between subscription billings.").optional(),
|
|
383
|
+
usage_type: z.enum(["licensed", "metered"]).describe("How usage is billed for this price.").optional()
|
|
384
|
+
}).describe("Recurring billing configuration for a Stripe price.").optional(),
|
|
385
|
+
tax_behavior: z.enum(["exclusive", "inclusive", "unspecified"]).describe("How Stripe should handle tax for this price.").optional()
|
|
386
|
+
}).describe("Input for creating a Stripe price.");
|
|
387
|
+
var createPriceOutput = z.strictObject({
|
|
388
|
+
price: z.looseObject({}).describe("A raw Stripe object returned by the API.").nullable()
|
|
389
|
+
}).describe("A Stripe price result.");
|
|
390
|
+
var updatePriceInput = z.strictObject({
|
|
391
|
+
priceId: z.string().min(1).describe("The Stripe price ID to update."),
|
|
392
|
+
active: z.boolean().describe("Whether the price can be used for new purchases.").optional(),
|
|
393
|
+
lookup_key: z.string().max(200).describe("A lookup key used to retrieve this price dynamically.").optional(),
|
|
394
|
+
metadata: z.record(z.string(), z.union([z.string(), z.number(), z.boolean()])).describe("Stripe metadata key-value pairs. Values are forwarded as strings, numbers, booleans, or empty strings.").optional(),
|
|
395
|
+
nickname: z.string().describe("A brief internal description of the price.").optional(),
|
|
396
|
+
tax_behavior: z.enum(["exclusive", "inclusive", "unspecified"]).describe("How Stripe should handle tax for this price.").optional()
|
|
397
|
+
}).describe("Input for updating a Stripe price.");
|
|
398
|
+
var updatePriceOutput = z.strictObject({
|
|
399
|
+
price: z.looseObject({}).describe("A raw Stripe object returned by the API.").nullable()
|
|
400
|
+
}).describe("A Stripe price result.");
|
|
401
|
+
var getPriceInput = z.strictObject({
|
|
402
|
+
priceId: z.string().min(1).describe("The Stripe price ID to retrieve.")
|
|
403
|
+
}).describe("Input for retrieving a Stripe price.");
|
|
404
|
+
var getPriceOutput = z.strictObject({
|
|
405
|
+
price: z.looseObject({}).describe("A raw Stripe object returned by the API.").nullable()
|
|
406
|
+
}).describe("A Stripe price result.");
|
|
407
|
+
var listPricesInput = z.strictObject({
|
|
408
|
+
limit: z.int().min(1).max(100).describe("The maximum number of objects to return. Stripe accepts values from 1 to 100.").optional(),
|
|
409
|
+
starting_after: z.string().min(1).describe("A cursor object ID that fetches the next page after that object.").optional(),
|
|
410
|
+
ending_before: z.string().min(1).describe("A cursor object ID that fetches the previous page before that object.").optional(),
|
|
411
|
+
active: z.boolean().describe("Filter prices by active status.").optional(),
|
|
412
|
+
currency: z.string().min(3).max(3).describe("Filter prices by three-letter ISO currency code in lowercase.").optional(),
|
|
413
|
+
product: z.string().min(1).describe("Filter prices by Stripe product ID.").optional(),
|
|
414
|
+
type: z.enum(["one_time", "recurring"]).describe("Filter prices by one-time or recurring type.").optional(),
|
|
415
|
+
created: z.strictObject({
|
|
416
|
+
gt: z.int().describe("Return objects created after this Unix timestamp, exclusive.").optional(),
|
|
417
|
+
gte: z.int().describe("Return objects created after or at this Unix timestamp.").optional(),
|
|
418
|
+
lt: z.int().describe("Return objects created before this Unix timestamp, exclusive.").optional(),
|
|
419
|
+
lte: z.int().describe("Return objects created before or at this Unix timestamp.").optional()
|
|
420
|
+
}).describe("A Stripe created timestamp interval filter.").optional()
|
|
421
|
+
}).describe("Input for listing Stripe prices.");
|
|
422
|
+
var listPricesOutput = z.strictObject({
|
|
423
|
+
prices: z.strictObject({
|
|
424
|
+
object: z.string().describe("The Stripe response object type."),
|
|
425
|
+
url: z.string().describe("The Stripe API URL for this list."),
|
|
426
|
+
has_more: z.boolean().describe("Whether more objects are available after this page."),
|
|
427
|
+
data: z.array(z.looseObject({}).describe("A raw Stripe object returned by the API.")).describe("Stripe objects returned on this page.")
|
|
428
|
+
}).describe("A Stripe list response.")
|
|
429
|
+
}).describe("Stripe prices page.");
|
|
430
|
+
var searchPricesInput = z.strictObject({
|
|
431
|
+
query: z.string().min(1).describe("A Stripe price search query, such as active:'true'."),
|
|
432
|
+
limit: z.int().min(1).max(100).describe("The maximum number of objects to return. Stripe accepts values from 1 to 100.").optional(),
|
|
433
|
+
page: z.string().describe("A Stripe search pagination token returned by a previous search response.").optional()
|
|
434
|
+
}).describe("Input for searching Stripe prices.");
|
|
435
|
+
var searchPricesOutput = z.strictObject({
|
|
436
|
+
prices: z.strictObject({
|
|
437
|
+
object: z.string().describe("The Stripe response object type."),
|
|
438
|
+
url: z.string().describe("The Stripe API URL for this list."),
|
|
439
|
+
has_more: z.boolean().describe("Whether more objects are available after this page."),
|
|
440
|
+
data: z.array(z.looseObject({}).describe("A raw Stripe object returned by the API.")).describe("Stripe objects returned on this page.")
|
|
441
|
+
}).describe("A Stripe list response.")
|
|
442
|
+
}).describe("Stripe price search results.");
|
|
443
|
+
var stripeActions = {
|
|
444
|
+
identify_account: {
|
|
445
|
+
description: "Retrieve the Stripe account associated with the current secret API key.",
|
|
446
|
+
effect: "read",
|
|
447
|
+
inputSchema: identifyAccountInput,
|
|
448
|
+
outputSchema: z.toJSONSchema(identifyAccountOutput, { io: "output", unrepresentable: "any" })
|
|
449
|
+
},
|
|
450
|
+
create_customer: {
|
|
451
|
+
description: "Create a Stripe customer with common profile and metadata fields.",
|
|
452
|
+
effect: "write",
|
|
453
|
+
inputSchema: createCustomerInput,
|
|
454
|
+
outputSchema: z.toJSONSchema(createCustomerOutput, { io: "output", unrepresentable: "any" })
|
|
455
|
+
},
|
|
456
|
+
update_customer: {
|
|
457
|
+
description: "Update a Stripe customer with common profile and metadata fields.",
|
|
458
|
+
effect: "write",
|
|
459
|
+
inputSchema: updateCustomerInput,
|
|
460
|
+
outputSchema: z.toJSONSchema(updateCustomerOutput, { io: "output", unrepresentable: "any" })
|
|
461
|
+
},
|
|
462
|
+
get_customer: {
|
|
463
|
+
description: "Retrieve a Stripe customer by ID.",
|
|
464
|
+
effect: "read",
|
|
465
|
+
inputSchema: getCustomerInput,
|
|
466
|
+
outputSchema: z.toJSONSchema(getCustomerOutput, { io: "output", unrepresentable: "any" })
|
|
467
|
+
},
|
|
468
|
+
list_customers: {
|
|
469
|
+
description: "List Stripe customers with optional email, created timestamp, and cursor filters.",
|
|
470
|
+
effect: "read",
|
|
471
|
+
inputSchema: listCustomersInput,
|
|
472
|
+
outputSchema: z.toJSONSchema(listCustomersOutput, { io: "output", unrepresentable: "any" })
|
|
473
|
+
},
|
|
474
|
+
search_customers: {
|
|
475
|
+
description: "Search Stripe customers with Stripe's search query syntax.",
|
|
476
|
+
effect: "read",
|
|
477
|
+
inputSchema: searchCustomersInput,
|
|
478
|
+
outputSchema: z.toJSONSchema(searchCustomersOutput, { io: "output", unrepresentable: "any" })
|
|
479
|
+
},
|
|
480
|
+
delete_customer: {
|
|
481
|
+
description: "Delete a Stripe customer by ID.",
|
|
482
|
+
effect: "destructive",
|
|
483
|
+
inputSchema: deleteCustomerInput,
|
|
484
|
+
outputSchema: z.toJSONSchema(deleteCustomerOutput, { io: "output", unrepresentable: "any" })
|
|
485
|
+
},
|
|
486
|
+
create_product: {
|
|
487
|
+
description: "Create a Stripe product with common catalog fields.",
|
|
488
|
+
effect: "write",
|
|
489
|
+
inputSchema: createProductInput,
|
|
490
|
+
outputSchema: z.toJSONSchema(createProductOutput, { io: "output", unrepresentable: "any" })
|
|
491
|
+
},
|
|
492
|
+
update_product: {
|
|
493
|
+
description: "Update a Stripe product with common catalog fields.",
|
|
494
|
+
effect: "write",
|
|
495
|
+
inputSchema: updateProductInput,
|
|
496
|
+
outputSchema: z.toJSONSchema(updateProductOutput, { io: "output", unrepresentable: "any" })
|
|
497
|
+
},
|
|
498
|
+
get_product: {
|
|
499
|
+
description: "Retrieve a Stripe product by ID.",
|
|
500
|
+
effect: "read",
|
|
501
|
+
inputSchema: getProductInput,
|
|
502
|
+
outputSchema: z.toJSONSchema(getProductOutput, { io: "output", unrepresentable: "any" })
|
|
503
|
+
},
|
|
504
|
+
list_products: {
|
|
505
|
+
description: "List Stripe products with optional active and cursor filters.",
|
|
506
|
+
effect: "read",
|
|
507
|
+
inputSchema: listProductsInput,
|
|
508
|
+
outputSchema: z.toJSONSchema(listProductsOutput, { io: "output", unrepresentable: "any" })
|
|
509
|
+
},
|
|
510
|
+
search_products: {
|
|
511
|
+
description: "Search Stripe products with Stripe's search query syntax.",
|
|
512
|
+
effect: "read",
|
|
513
|
+
inputSchema: searchProductsInput,
|
|
514
|
+
outputSchema: z.toJSONSchema(searchProductsOutput, { io: "output", unrepresentable: "any" })
|
|
515
|
+
},
|
|
516
|
+
delete_product: {
|
|
517
|
+
description: "Delete a Stripe product by ID.",
|
|
518
|
+
effect: "destructive",
|
|
519
|
+
inputSchema: deleteProductInput,
|
|
520
|
+
outputSchema: z.toJSONSchema(deleteProductOutput, { io: "output", unrepresentable: "any" })
|
|
521
|
+
},
|
|
522
|
+
create_price: {
|
|
523
|
+
description: "Create a Stripe one-time or recurring price for an existing or inline product.",
|
|
524
|
+
effect: "write",
|
|
525
|
+
inputSchema: createPriceInput,
|
|
526
|
+
outputSchema: z.toJSONSchema(createPriceOutput, { io: "output", unrepresentable: "any" })
|
|
527
|
+
},
|
|
528
|
+
update_price: {
|
|
529
|
+
description: "Update mutable fields on a Stripe price.",
|
|
530
|
+
effect: "write",
|
|
531
|
+
inputSchema: updatePriceInput,
|
|
532
|
+
outputSchema: z.toJSONSchema(updatePriceOutput, { io: "output", unrepresentable: "any" })
|
|
533
|
+
},
|
|
534
|
+
get_price: {
|
|
535
|
+
description: "Retrieve a Stripe price by ID.",
|
|
536
|
+
effect: "read",
|
|
537
|
+
inputSchema: getPriceInput,
|
|
538
|
+
outputSchema: z.toJSONSchema(getPriceOutput, { io: "output", unrepresentable: "any" })
|
|
539
|
+
},
|
|
540
|
+
list_prices: {
|
|
541
|
+
description: "List Stripe prices with optional product, active, type, and cursor filters.",
|
|
542
|
+
effect: "read",
|
|
543
|
+
inputSchema: listPricesInput,
|
|
544
|
+
outputSchema: z.toJSONSchema(listPricesOutput, { io: "output", unrepresentable: "any" })
|
|
545
|
+
},
|
|
546
|
+
search_prices: {
|
|
547
|
+
description: "Search Stripe prices with Stripe's search query syntax.",
|
|
548
|
+
effect: "read",
|
|
549
|
+
inputSchema: searchPricesInput,
|
|
550
|
+
outputSchema: z.toJSONSchema(searchPricesOutput, { io: "output", unrepresentable: "any" })
|
|
551
|
+
}
|
|
552
|
+
};
|
|
553
|
+
|
|
554
|
+
// ../plugins/src/stripe/index.ts
|
|
555
|
+
function createStripePlugin() {
|
|
556
|
+
return createProviderPlugin({
|
|
557
|
+
description: "Stripe",
|
|
558
|
+
actions: stripeActions,
|
|
559
|
+
handlers: {
|
|
560
|
+
identify_account: identifyAccount,
|
|
561
|
+
create_customer: createCustomer,
|
|
562
|
+
update_customer: updateCustomer,
|
|
563
|
+
get_customer: getCustomer,
|
|
564
|
+
list_customers: listCustomers,
|
|
565
|
+
search_customers: searchCustomers,
|
|
566
|
+
delete_customer: deleteCustomer,
|
|
567
|
+
create_product: createProduct,
|
|
568
|
+
update_product: updateProduct,
|
|
569
|
+
get_product: getProduct,
|
|
570
|
+
list_products: listProducts,
|
|
571
|
+
search_products: searchProducts,
|
|
572
|
+
delete_product: deleteProduct,
|
|
573
|
+
create_price: createPrice,
|
|
574
|
+
update_price: updatePrice,
|
|
575
|
+
get_price: getPrice,
|
|
576
|
+
list_prices: listPrices,
|
|
577
|
+
search_prices: searchPrices
|
|
578
|
+
}
|
|
579
|
+
});
|
|
580
|
+
}
|
|
581
|
+
var stripe_default = createStripePlugin();
|
|
582
|
+
export {
|
|
583
|
+
createStripePlugin,
|
|
584
|
+
stripe_default as default
|
|
585
|
+
};
|