@oomol-lab/open-connector 1.6.5 → 1.8.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/README.md +4 -0
- package/assets/open-connector/catalog/apps/airtable.json +134 -0
- package/assets/open-connector/catalog/apps/aisa.json +6985 -319
- package/assets/open-connector/catalog/apps/baizhi_mcp.json +135 -0
- package/assets/open-connector/catalog/apps/cal.json +24 -6
- package/assets/open-connector/catalog/apps/discordbot.json +2888 -248
- package/assets/open-connector/catalog/apps/drawio_mcp.json +192 -0
- package/assets/open-connector/catalog/apps/enormail.json +411 -0
- package/assets/open-connector/catalog/apps/feishu_app_bot.json +158 -0
- package/assets/open-connector/catalog/apps/firecrawl.json +176 -32
- package/assets/open-connector/catalog/apps/framejet.json +273 -0
- package/assets/open-connector/catalog/apps/futunn.json +2967 -0
- package/assets/open-connector/catalog/apps/github.json +275 -0
- package/assets/open-connector/catalog/apps/gitlab.json +125 -0
- package/assets/open-connector/catalog/apps/gmail.json +376 -0
- package/assets/open-connector/catalog/apps/google_analytics.json +4 -1
- package/assets/open-connector/catalog/apps/google_bigquery.json +4 -1
- package/assets/open-connector/catalog/apps/google_search_console.json +4 -1
- package/assets/open-connector/catalog/apps/googlecalendar.json +210 -1
- package/assets/open-connector/catalog/apps/googlechat.json +694 -7
- package/assets/open-connector/catalog/apps/googledocs.json +4 -1
- package/assets/open-connector/catalog/apps/googledrive.json +479 -0
- package/assets/open-connector/catalog/apps/googlesheets.json +148 -1
- package/assets/open-connector/catalog/apps/granola.json +23 -0
- package/assets/open-connector/catalog/apps/hithink_finance.json +6 -3
- package/assets/open-connector/catalog/apps/indexed.json +1115 -0
- package/assets/open-connector/catalog/apps/keepa.json +3534 -987
- package/assets/open-connector/catalog/apps/linear.json +133 -0
- package/assets/open-connector/catalog/apps/linear_mcp.json +510 -0
- package/assets/open-connector/catalog/apps/moneyforward_mcp.json +1432 -0
- package/assets/open-connector/catalog/apps/notion.json +588 -1
- package/assets/open-connector/catalog/apps/notion_mcp.json +490 -0
- package/assets/open-connector/catalog/apps/odoo.json +619 -0
- package/assets/open-connector/catalog/apps/one_drive.json +185 -0
- package/assets/open-connector/catalog/apps/outlook.json +212 -8
- package/assets/open-connector/catalog/apps/outlook_calendar.json +23 -2
- package/assets/open-connector/catalog/apps/postiz.json +334 -0
- package/assets/open-connector/catalog/apps/proworkflow.json +529 -0
- package/assets/open-connector/catalog/apps/sellersprite_mcp.json +2 -1
- package/assets/open-connector/catalog/apps/shopify.json +282 -0
- package/assets/open-connector/catalog/apps/slack.json +405 -0
- package/assets/open-connector/catalog/apps/slackbot.json +214 -0
- package/assets/open-connector/catalog/apps/spotify.json +46 -43
- package/assets/open-connector/catalog/apps/stripe.json +96 -0
- package/assets/open-connector/catalog/apps/telegram.json +138 -0
- package/assets/open-connector/catalog/apps/tencent_docs.json +3 -0
- package/assets/open-connector/catalog/apps/weixin_store.json +543 -2
- package/assets/open-connector/catalog/apps/wisburg.json +1528 -0
- package/assets/open-connector/catalog/apps/woocommerce.json +127 -0
- package/assets/open-connector/catalog/apps/youtube.json +4 -1
- package/assets/open-connector/catalog/apps/zendesk.json +152 -0
- package/assets/open-connector/catalog/apps/zerotier.json +3319 -0
- package/assets/open-connector/catalog/apps-index.json +1 -1
- package/assets/open-connector/migrations/0014_saas_project.sql +55 -0
- package/assets/open-connector/migrations/0015_saas_cleanup_runtime.sql +8 -0
- package/assets/open-connector/migrations/0016_trigger_policy.sql +1 -0
- package/assets/open-connector/migrations/0017_trigger_subscriptions.sql +17 -0
- package/assets/open-connector/migrations/postgresql/0014_saas_project.sql +55 -0
- package/assets/open-connector/migrations/postgresql/0015_saas_cleanup_runtime.sql +8 -0
- package/assets/open-connector/migrations/postgresql/0016_trigger_policy.sql +1 -0
- package/assets/open-connector/migrations/postgresql/0017_trigger_subscriptions.sql +17 -0
- package/package.json +2 -2
- package/src/connection-service.d.ts +40 -7
- package/src/connection-service.js +60 -18
- package/src/core/action-policy.d.ts +8 -1
- package/src/core/action-policy.js +51 -0
- package/src/core/cast.d.ts +13 -0
- package/src/core/cast.js +18 -1
- package/src/core/guarded-fetch.d.ts +11 -3
- package/src/core/guarded-fetch.js +19 -7
- package/src/core/provider-scenarios.js +67 -13
- package/src/core/remote-http.d.ts +33 -0
- package/src/core/remote-http.js +104 -0
- package/src/core/request.d.ts +1 -0
- package/src/core/request.js +11 -1
- package/src/core/types.d.ts +5 -1
- package/src/marketplace/marketplace-service.d.ts +0 -1
- package/src/marketplace/marketplace-service.js +80 -92
- package/src/mcp.js +26 -9
- package/src/oauth/oauth-client-config-service.d.ts +16 -1
- package/src/oauth/oauth-client-config-service.js +59 -3
- package/src/oauth/oauth-flow-service.d.ts +14 -1
- package/src/oauth/oauth-flow-service.js +14 -6
- package/src/providers/17track/runtime.js +1 -1
- package/src/providers/action-contracts.generated.d.ts +20 -6
- package/src/providers/aifinmarket/runtime.js +1 -1
- package/src/providers/airtable/executors.d.ts +3 -0
- package/src/providers/airtable/executors.js +2 -0
- package/src/providers/airtable/trigger-on-record-changed.d.ts +2 -0
- package/src/providers/airtable/trigger-on-record-changed.definition.d.ts +4 -0
- package/src/providers/airtable/trigger-on-record-changed.definition.js +54 -0
- package/src/providers/airtable/trigger-on-record-changed.js +235 -0
- package/src/providers/aisa/executors.js +912 -50
- package/src/providers/aliyun_ack/runtime.js +1 -1
- package/src/providers/aliyun_sls/runtime.js +1 -1
- package/src/providers/app_store_server/runtime-helpers.js +1 -1
- package/src/providers/baizhi_mcp/actions.d.ts +2 -0
- package/src/providers/baizhi_mcp/actions.js +40 -0
- package/src/providers/baizhi_mcp/executors.d.ts +3 -0
- package/src/providers/baizhi_mcp/executors.js +102 -0
- package/src/providers/bazhuayu/runtime.js +2 -2
- package/src/providers/bilibili/runtime.js +2 -4
- package/src/providers/bilibili/upload.js +9 -7
- package/src/providers/cal/actions.js +5 -1
- package/src/providers/cloudflare_browser_rendering/executors.js +1 -1
- package/src/providers/cloudflare_dns/executors.js +1 -1
- package/src/providers/{cloudflare-current-user.js → cloudflare_dns/runtime-user.js} +2 -2
- package/src/providers/cloudflare_dns/runtime.d.ts +1 -1
- package/src/providers/cloudflare_dns/runtime.js +1 -1
- package/src/providers/cloudflare_r2/executors.js +1 -1
- package/src/providers/cloudflare_r2/runtime.d.ts +1 -1
- package/src/providers/cloudflare_r2/runtime.js +1 -1
- package/src/providers/cloudflare_worker/executors.js +1 -1
- package/src/providers/cloudflare_worker/runtime.d.ts +1 -1
- package/src/providers/cloudflare_worker/runtime.js +1 -1
- package/src/providers/dingtalk_mcp/runtime.js +1 -1
- package/src/providers/discordbot/executors.d.ts +0 -9
- package/src/providers/discordbot/executors.js +9 -101
- package/src/providers/discordbot/runtime-guilds.d.ts +3 -0
- package/src/providers/discordbot/runtime-guilds.js +464 -0
- package/src/providers/discordbot/runtime.d.ts +42 -0
- package/src/providers/discordbot/runtime.js +124 -0
- package/src/providers/drawio_mcp/executors.d.ts +3 -0
- package/src/providers/drawio_mcp/executors.js +19 -0
- package/src/providers/drawio_mcp/runtime.d.ts +8 -0
- package/src/providers/drawio_mcp/runtime.js +175 -0
- package/src/providers/enormail/executors.d.ts +4 -0
- package/src/providers/enormail/executors.js +97 -0
- package/src/providers/fastmoss_mcp/executors.js +2 -2
- package/src/providers/feishu_app_bot/executors.d.ts +3 -0
- package/src/providers/feishu_app_bot/executors.js +2 -0
- package/src/providers/feishu_app_bot/trigger-config.d.ts +1 -0
- package/src/providers/feishu_app_bot/trigger-config.js +10 -0
- package/src/providers/feishu_app_bot/trigger-on-event.d.ts +2 -0
- package/src/providers/feishu_app_bot/trigger-on-event.definition.d.ts +4 -0
- package/src/providers/feishu_app_bot/trigger-on-event.definition.js +63 -0
- package/src/providers/feishu_app_bot/trigger-on-event.js +29 -0
- package/src/providers/feishu_app_bot/trigger-subscriptions.d.ts +5 -0
- package/src/providers/feishu_app_bot/trigger-subscriptions.js +70 -0
- package/src/providers/finchina/executors.js +1 -1
- package/src/providers/framejet/executors.d.ts +4 -0
- package/src/providers/framejet/executors.js +19 -0
- package/src/providers/framejet/runtime.d.ts +16 -0
- package/src/providers/framejet/runtime.js +148 -0
- package/src/providers/futunn/actions.d.ts +2 -0
- package/src/providers/futunn/actions.js +152 -0
- package/src/providers/futunn/actions.research.d.ts +2 -0
- package/src/providers/futunn/actions.research.js +423 -0
- package/src/providers/futunn/actions.trading.d.ts +2 -0
- package/src/providers/futunn/actions.trading.js +204 -0
- package/src/providers/futunn/executors.d.ts +3 -0
- package/src/providers/futunn/executors.js +24 -0
- package/src/providers/futunn/runtime-research.d.ts +3 -0
- package/src/providers/futunn/runtime-research.js +133 -0
- package/src/providers/futunn/runtime-trading.d.ts +3 -0
- package/src/providers/futunn/runtime-trading.js +39 -0
- package/src/providers/futunn/runtime.d.ts +2 -0
- package/src/providers/futunn/runtime.js +50 -0
- package/src/providers/futunn/transport.d.ts +11 -0
- package/src/providers/futunn/transport.js +76 -0
- package/src/providers/gildata/executors.js +1 -1
- package/src/providers/github/executors.d.ts +3 -0
- package/src/providers/github/executors.js +6 -0
- package/src/providers/github/trigger-on-repo-event.d.ts +2 -0
- package/src/providers/github/trigger-on-repo-event.definition.d.ts +4 -0
- package/src/providers/github/trigger-on-repo-event.definition.js +94 -0
- package/src/providers/github/trigger-on-repo-event.js +168 -0
- package/src/providers/github/trigger-watch-pull-request.d.ts +2 -0
- package/src/providers/github/trigger-watch-pull-request.definition.d.ts +4 -0
- package/src/providers/github/trigger-watch-pull-request.definition.js +49 -0
- package/src/providers/github/trigger-watch-pull-request.js +106 -0
- package/src/providers/gitlab/executors.d.ts +3 -0
- package/src/providers/gitlab/executors.js +2 -0
- package/src/providers/gitlab/trigger-on-project-event.d.ts +2 -0
- package/src/providers/gitlab/trigger-on-project-event.definition.d.ts +5 -0
- package/src/providers/gitlab/trigger-on-project-event.definition.js +63 -0
- package/src/providers/gitlab/trigger-on-project-event.js +186 -0
- package/src/providers/gmail/executors.d.ts +3 -0
- package/src/providers/gmail/executors.js +5 -3
- package/src/providers/gmail/message.d.ts +6 -8
- package/src/providers/gmail/message.js +4 -0
- package/src/providers/gmail/scopes.d.ts +32 -0
- package/src/providers/gmail/scopes.js +37 -0
- package/src/providers/gmail/trigger-on-message-received.d.ts +2 -0
- package/src/providers/gmail/trigger-on-message-received.definition.d.ts +4 -0
- package/src/providers/gmail/trigger-on-message-received.definition.js +74 -0
- package/src/providers/gmail/trigger-on-message-received.js +232 -0
- package/src/providers/google_analytics/executors.js +2 -2
- package/src/providers/google_analytics/scopes.js +6 -1
- package/src/providers/google_bigquery/executors.js +2 -2
- package/src/providers/google_bigquery/scopes.js +2 -0
- package/src/providers/google_search_console/executors.js +2 -2
- package/src/providers/google_search_console/scopes.js +2 -0
- package/src/providers/googleads/executors.js +1 -1
- package/src/providers/googleads/scopes.d.ts +1 -3
- package/src/providers/googleads/scopes.js +2 -4
- package/src/providers/googlecalendar/executors.d.ts +3 -0
- package/src/providers/googlecalendar/executors.js +3 -1
- package/src/providers/googlecalendar/runtime-shared.js +2 -2
- package/src/providers/googlecalendar/scopes.js +2 -0
- package/src/providers/googlecalendar/trigger-on-event-changed.d.ts +2 -0
- package/src/providers/googlecalendar/trigger-on-event-changed.definition.d.ts +4 -0
- package/src/providers/googlecalendar/trigger-on-event-changed.definition.js +74 -0
- package/src/providers/googlecalendar/trigger-on-event-changed.js +233 -0
- package/src/providers/googlechat/executors.d.ts +1 -3
- package/src/providers/googlechat/executors.js +219 -28
- package/src/providers/googlechat/members.d.ts +55 -0
- package/src/providers/googlechat/members.js +293 -0
- package/src/providers/googlechat/runtime.d.ts +16 -0
- package/src/providers/googlechat/runtime.js +25 -0
- package/src/providers/googlechat/scopes.d.ts +22 -3
- package/src/providers/googlechat/scopes.js +30 -7
- package/src/providers/googledocs/executors.js +1 -1
- package/src/providers/googledrive/executors.d.ts +3 -0
- package/src/providers/googledrive/executors.js +9 -2
- package/src/providers/{google-auth.d.ts → googledrive/runtime-auth.d.ts} +2 -2
- package/src/providers/{google-auth.js → googledrive/runtime-auth.js} +3 -3
- package/src/providers/googledrive/runtime-collaboration.js +1 -1
- package/src/providers/{google-runtime.d.ts → googledrive/runtime-request.d.ts} +1 -1
- package/src/providers/{google-runtime.js → googledrive/runtime-request.js} +2 -2
- package/src/providers/googledrive/trigger-changes.d.ts +12 -0
- package/src/providers/googledrive/trigger-changes.definition.d.ts +7 -0
- package/src/providers/googledrive/trigger-changes.definition.js +101 -0
- package/src/providers/googledrive/trigger-changes.js +452 -0
- package/src/providers/googledrive/trigger-on-file-change.d.ts +2 -0
- package/src/providers/googledrive/trigger-on-file-change.definition.d.ts +4 -0
- package/src/providers/googledrive/trigger-on-file-change.definition.js +77 -0
- package/src/providers/googledrive/trigger-on-file-change.js +258 -0
- package/src/providers/googleforms/executors.js +2 -2
- package/src/providers/googleforms/scopes.d.ts +0 -3
- package/src/providers/googleforms/scopes.js +2 -6
- package/src/providers/googlemeet/executors.js +2 -2
- package/src/providers/googlemeet/scopes.d.ts +0 -3
- package/src/providers/googlemeet/scopes.js +2 -6
- package/src/providers/googlesheets/executors.d.ts +3 -0
- package/src/providers/googlesheets/executors.js +3 -1
- package/src/providers/googlesheets/scopes.js +2 -0
- package/src/providers/googlesheets/trigger-on-row-added.d.ts +2 -0
- package/src/providers/googlesheets/trigger-on-row-added.definition.d.ts +4 -0
- package/src/providers/googlesheets/trigger-on-row-added.definition.js +54 -0
- package/src/providers/googlesheets/trigger-on-row-added.js +234 -0
- package/src/providers/googleslides/executors.js +2 -2
- package/src/providers/googleslides/scopes.d.ts +0 -3
- package/src/providers/googleslides/scopes.js +2 -6
- package/src/providers/googletasks/executors.js +2 -2
- package/src/providers/googletasks/scopes.d.ts +0 -3
- package/src/providers/googletasks/scopes.js +2 -6
- package/src/providers/granola/actions.js +2 -0
- package/src/providers/granola/runtime-mcp.js +2 -0
- package/src/providers/granola/runtime.js +2 -2
- package/src/providers/hithink_finance/runtime.js +1 -1
- package/src/providers/indexed/executors.d.ts +4 -0
- package/src/providers/indexed/executors.js +16 -0
- package/src/providers/indexed/runtime.d.ts +26 -0
- package/src/providers/indexed/runtime.js +129 -0
- package/src/providers/indiegogo/executors.js +1 -1
- package/src/providers/investoday_mcp/executors.js +2 -2
- package/src/providers/iyunbiao/runtime.js +2 -2
- package/src/providers/keepa/actions.d.ts +1 -1
- package/src/providers/keepa/actions.js +371 -149
- package/src/providers/keepa/deal-attributes.d.ts +1 -0
- package/src/providers/keepa/deal-attributes.js +26 -0
- package/src/providers/keepa/runtime.js +212 -18
- package/src/providers/kingdee/executors.js +1 -1
- package/src/providers/kingdee/runtime.js +2 -2
- package/src/providers/kuaidi100/runtime.js +1 -1
- package/src/providers/linear/executors.d.ts +3 -0
- package/src/providers/linear/executors.js +14 -9
- package/src/providers/linear/trigger-on-issue-changed.d.ts +2 -0
- package/src/providers/linear/trigger-on-issue-changed.definition.d.ts +5 -0
- package/src/providers/linear/trigger-on-issue-changed.definition.js +43 -0
- package/src/providers/linear/trigger-on-issue-changed.js +215 -0
- package/src/providers/linear_mcp/actions.d.ts +47 -0
- package/src/providers/linear_mcp/actions.js +102 -0
- package/src/providers/linear_mcp/endpoints.d.ts +3 -0
- package/src/providers/linear_mcp/endpoints.js +3 -0
- package/src/providers/linear_mcp/executors.d.ts +3 -0
- package/src/providers/linear_mcp/executors.js +9 -0
- package/src/providers/linear_mcp/runtime-mcp.d.ts +15 -0
- package/src/providers/linear_mcp/runtime-mcp.js +238 -0
- package/src/providers/lingxing_mcp/runtime.js +1 -1
- package/src/providers/mcdonalds_cn_mcp/runtime.js +1 -1
- package/src/providers/metabase/mcp-runtime.js +1 -1
- package/src/providers/moneyforward_mcp/executors.d.ts +3 -0
- package/src/providers/moneyforward_mcp/executors.js +11 -0
- package/src/providers/moneyforward_mcp/manifest.d.ts +31 -0
- package/src/providers/moneyforward_mcp/manifest.js +204 -0
- package/src/providers/moneyforward_mcp/runtime.d.ts +18 -0
- package/src/providers/moneyforward_mcp/runtime.js +296 -0
- package/src/providers/notion/executors.d.ts +3 -0
- package/src/providers/notion/executors.js +41 -3
- package/src/providers/notion/trigger-on-database-page-event.d.ts +2 -0
- package/src/providers/notion/trigger-on-database-page-event.definition.d.ts +4 -0
- package/src/providers/notion/trigger-on-database-page-event.definition.js +63 -0
- package/src/providers/notion/trigger-on-database-page-event.js +293 -0
- package/src/providers/notion_mcp/endpoints.d.ts +3 -0
- package/src/providers/notion_mcp/endpoints.js +3 -0
- package/src/providers/notion_mcp/executors.d.ts +3 -0
- package/src/providers/notion_mcp/executors.js +176 -0
- package/src/providers/notion_mcp/mcp-response.d.ts +86 -0
- package/src/providers/notion_mcp/mcp-response.js +314 -0
- package/src/providers/odoo/executors.d.ts +3 -0
- package/src/providers/odoo/executors.js +32 -0
- package/src/providers/odoo/runtime.d.ts +16 -0
- package/src/providers/odoo/runtime.js +140 -0
- package/src/providers/one_drive/executors.d.ts +3 -0
- package/src/providers/one_drive/executors.js +2 -0
- package/src/providers/one_drive/trigger-on-item-changed.d.ts +2 -0
- package/src/providers/one_drive/trigger-on-item-changed.definition.d.ts +4 -0
- package/src/providers/one_drive/trigger-on-item-changed.definition.js +63 -0
- package/src/providers/one_drive/trigger-on-item-changed.js +214 -0
- package/src/providers/outlook/executors.d.ts +3 -0
- package/src/providers/outlook/executors.js +29 -6
- package/src/providers/outlook/microsoft-graph.js +17 -6
- package/src/providers/outlook/trigger-on-message-received.d.ts +2 -0
- package/src/providers/outlook/trigger-on-message-received.definition.d.ts +4 -0
- package/src/providers/outlook/trigger-on-message-received.definition.js +93 -0
- package/src/providers/outlook/trigger-on-message-received.js +226 -0
- package/src/providers/outlook_calendar/executors.js +30 -7
- package/src/providers/patsnap_mcp/executors.js +2 -2
- package/src/providers/postiz/executors.d.ts +4 -0
- package/src/providers/postiz/executors.js +83 -0
- package/src/providers/provider-loader.d.ts +5 -0
- package/src/providers/provider-loader.js +4 -0
- package/src/providers/provider-runtime.d.ts +15 -0
- package/src/providers/provider-runtime.js +57 -4
- package/src/providers/proworkflow/executors.d.ts +4 -0
- package/src/providers/proworkflow/executors.js +135 -0
- package/src/providers/registry.generated.js +14 -0
- package/src/providers/scrape_creators/catalog.js +1 -1
- package/src/providers/scrape_creators/runtime.js +1 -1
- package/src/providers/sellersprite_mcp/executors.js +2 -2
- package/src/providers/sellersprite_mcp/official-actions.js +3 -2
- package/src/providers/sentry/runtime.js +6 -7
- package/src/providers/shopify/executors.d.ts +3 -0
- package/src/providers/shopify/executors.js +2 -0
- package/src/providers/shopify/trigger-on-shop-event.d.ts +2 -0
- package/src/providers/shopify/trigger-on-shop-event.definition.d.ts +4 -0
- package/src/providers/shopify/trigger-on-shop-event.definition.js +214 -0
- package/src/providers/shopify/trigger-on-shop-event.js +165 -0
- package/src/providers/slack/actions.js +52 -3
- package/src/providers/slack/executors.d.ts +3 -0
- package/src/providers/slack/executors.js +2 -0
- package/src/providers/slack/runtime.js +58 -21
- package/src/providers/slack/trigger-on-message-posted.d.ts +2 -0
- package/src/providers/slack/trigger-on-message-posted.definition.d.ts +4 -0
- package/src/providers/slack/trigger-on-message-posted.definition.js +80 -0
- package/src/providers/slack/trigger-on-message-posted.js +176 -0
- package/src/providers/slickdeals/runtime.js +1 -1
- package/src/providers/sorftime_mcp/executors.js +2 -2
- package/src/providers/spotify/runtime.js +15 -4
- package/src/providers/stripe/executors.d.ts +3 -0
- package/src/providers/stripe/executors.js +2 -0
- package/src/providers/stripe/trigger-on-event.d.ts +2 -0
- package/src/providers/stripe/trigger-on-event.definition.d.ts +4 -0
- package/src/providers/stripe/trigger-on-event.definition.js +43 -0
- package/src/providers/stripe/trigger-on-event.js +212 -0
- package/src/providers/telegram/executors.d.ts +3 -0
- package/src/providers/telegram/executors.js +2 -0
- package/src/providers/telegram/trigger-on-update.d.ts +2 -0
- package/src/providers/telegram/trigger-on-update.definition.d.ts +5 -0
- package/src/providers/telegram/trigger-on-update.definition.js +78 -0
- package/src/providers/telegram/trigger-on-update.js +141 -0
- package/src/providers/tikhub/bounded-response.d.ts +1 -1
- package/src/providers/tikhub/bounded-response.js +8 -34
- package/src/providers/tikhub/endpoint-catalog.js +1 -1
- package/src/providers/tikhub/runtime.js +2 -2
- package/src/providers/tongdaxin/executors.js +79 -15
- package/src/providers/uspto/executors.js +1 -1
- package/src/providers/waffo/executors.js +1 -1
- package/src/providers/waffo/runtime.js +1 -1
- package/src/providers/wecom_mcp/runtime.js +1 -1
- package/src/providers/weixin_store/access-token.d.ts +2 -1
- package/src/providers/weixin_store/access-token.js +15 -4
- package/src/providers/weixin_store/executors.js +97 -12
- package/src/providers/wisburg/executors.d.ts +4 -0
- package/src/providers/wisburg/executors.js +13 -0
- package/src/providers/wisburg/runtime.d.ts +12 -0
- package/src/providers/wisburg/runtime.js +133 -0
- package/src/providers/woocommerce/executors.d.ts +3 -0
- package/src/providers/woocommerce/executors.js +2 -0
- package/src/providers/woocommerce/trigger-on-store-event.d.ts +2 -0
- package/src/providers/woocommerce/trigger-on-store-event.definition.d.ts +4 -0
- package/src/providers/woocommerce/trigger-on-store-event.definition.js +55 -0
- package/src/providers/woocommerce/trigger-on-store-event.js +179 -0
- package/src/providers/xydc_mcp/executors.js +2 -2
- package/src/providers/youtube/executors.js +1 -1
- package/src/providers/youtube/runtime.js +1 -1
- package/src/providers/zendesk/executors.d.ts +3 -0
- package/src/providers/zendesk/executors.js +2 -0
- package/src/providers/zendesk/trigger-on-event.d.ts +2 -0
- package/src/providers/zendesk/trigger-on-event.definition.d.ts +5 -0
- package/src/providers/zendesk/trigger-on-event.definition.js +101 -0
- package/src/providers/zendesk/trigger-on-event.js +188 -0
- package/src/providers/zerotier/executors.d.ts +9 -0
- package/src/providers/zerotier/executors.js +629 -0
- package/src/providers/zerotier/runtime.d.ts +54 -0
- package/src/providers/zerotier/runtime.js +207 -0
- package/src/saas/saas-cleanup-service.d.ts +26 -0
- package/src/saas/saas-cleanup-service.js +124 -0
- package/src/saas/saas-client.d.ts +86 -0
- package/src/saas/saas-client.js +369 -0
- package/src/saas/saas-execution-service.d.ts +15 -0
- package/src/saas/saas-execution-service.js +21 -0
- package/src/saas/saas-oauth-service.d.ts +25 -0
- package/src/saas/saas-oauth-service.js +197 -0
- package/src/saas/saas-project-service.d.ts +61 -0
- package/src/saas/saas-project-service.js +211 -0
- package/src/server/actions/action-idempotency.d.ts +1 -0
- package/src/server/actions/action-idempotency.js +1 -0
- package/src/server/actions/action-runner.d.ts +7 -0
- package/src/server/actions/action-runner.js +43 -7
- package/src/server/actions/run-log-summary.js +9 -0
- package/src/server/api/auth.d.ts +1 -0
- package/src/server/api/auth.js +13 -2
- package/src/server/api/cache-policy.js +4 -1
- package/src/server/api/connection-input.d.ts +7 -1
- package/src/server/api/connection-input.js +7 -1
- package/src/server/api/connection-routes.d.ts +3 -1
- package/src/server/api/connection-routes.js +21 -3
- package/src/server/api/http-utils.d.ts +4 -3
- package/src/server/api/oauth-completion-page.d.ts +124 -0
- package/src/server/api/oauth-completion-page.js +113 -18
- package/src/server/api/openapi.js +123 -15
- package/src/server/api/policy-input.js +6 -0
- package/src/server/api/runtime-api.d.ts +18 -3
- package/src/server/api/runtime-api.js +36 -5
- package/src/server/api/saas-completion-page.d.ts +2 -0
- package/src/server/api/saas-completion-page.js +103 -0
- package/src/server/connect-app.d.ts +5 -0
- package/src/server/connect-app.js +50 -0
- package/src/server/connect-server.d.ts +12 -0
- package/src/server/connect-server.js +157 -15
- package/src/server/connector-runtime.d.ts +3 -1
- package/src/server/connector-runtime.js +5 -2
- package/src/server/files/transit-files.js +16 -7
- package/src/server/proxy/proxy-runner.d.ts +5 -1
- package/src/server/proxy/proxy-runner.js +72 -26
- package/src/server/storage/connection-request-store.d.ts +41 -1
- package/src/server/storage/connection-request-store.js +245 -20
- package/src/server/storage/connection-store.d.ts +16 -0
- package/src/server/storage/connection-store.js +119 -0
- package/src/server/storage/node-runtime-database.js +3 -3
- package/src/server/storage/{postgres-migrations.d.ts → postgres/migrations.d.ts} +2 -2
- package/src/server/storage/{postgres-migrations.js → postgres/migrations.js} +1 -1
- package/src/server/storage/postgres/runtime-store.d.ts +43 -0
- package/src/server/storage/{postgres-runtime-store.js → postgres/runtime-store.js} +59 -94
- package/src/server/storage/runtime-database.d.ts +4 -0
- package/src/server/storage/runtime-sql.d.ts +1 -1
- package/src/server/storage/runtime-sql.js +2 -1
- package/src/server/storage/runtime-store.d.ts +1 -0
- package/src/server/storage/runtime-token-service.d.ts +2 -0
- package/src/server/storage/runtime-token-service.js +3 -0
- package/src/server/storage/saas-project-store.d.ts +77 -0
- package/src/server/storage/saas-project-store.js +273 -0
- package/src/server/storage/{sqlite-runtime-store.d.ts → sqlite/runtime-store.d.ts} +21 -25
- package/src/server/storage/{sqlite-runtime-store.js → sqlite/runtime-store.js} +100 -115
- package/src/server/storage/trigger-store.d.ts +16 -0
- package/src/server/storage/trigger-store.js +96 -0
- package/src/triggers/common/config.d.ts +2 -0
- package/src/triggers/common/config.js +17 -0
- package/src/triggers/common/configOptions.d.ts +13 -0
- package/src/triggers/common/configOptions.js +1 -0
- package/src/triggers/common/encoding.d.ts +3 -0
- package/src/triggers/common/encoding.js +19 -0
- package/src/triggers/common/integration.d.ts +115 -0
- package/src/triggers/common/integration.js +31 -0
- package/src/triggers/common/json.d.ts +6 -0
- package/src/triggers/common/json.js +91 -0
- package/src/triggers/common/poll.d.ts +41 -0
- package/src/triggers/common/poll.js +15 -0
- package/src/triggers/common/proxy.d.ts +14 -0
- package/src/triggers/common/proxy.js +1 -0
- package/src/triggers/common/types.d.ts +42 -0
- package/src/triggers/common/types.js +1 -0
- package/src/triggers/maintenance.d.ts +40 -0
- package/src/triggers/maintenance.js +120 -0
- package/src/triggers/metadata.d.ts +8 -0
- package/src/triggers/metadata.js +1 -0
- package/src/triggers/request.d.ts +33 -0
- package/src/triggers/request.js +52 -0
- package/src/triggers/resources.d.ts +12 -0
- package/src/triggers/resources.js +121 -0
- package/src/triggers/signature.d.ts +4 -0
- package/src/triggers/signature.js +48 -0
- package/src/triggers/store.d.ts +29 -0
- package/src/triggers/store.js +1 -0
- package/src/triggers/subscriptions.d.ts +22 -0
- package/src/triggers/subscriptions.js +220 -0
- package/src/triggers/trigger-runner.d.ts +34 -0
- package/src/triggers/trigger-runner.js +169 -0
- package/src/providers/sentry/scopes.d.ts +0 -1
- package/src/providers/sentry/scopes.js +0 -7
- package/src/server/storage/postgres-runtime-store.d.ts +0 -39
- /package/src/providers/{cloudflare-current-user.d.ts → cloudflare_dns/runtime-user.d.ts} +0 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ProtocolError, SdkHttpError, UnauthorizedError } from "@modelcontextprotocol/client";
|
|
2
2
|
import { createHash } from "node:crypto";
|
|
3
|
-
import { optionalRecord } from "../../core/cast.js";
|
|
3
|
+
import { optionalNumber, optionalRecord, optionalString } from "../../core/cast.js";
|
|
4
|
+
import { readBoundedResponseBytes } from "../../core/request.js";
|
|
4
5
|
import { withMcpClient } from "../mcp-client.js";
|
|
5
6
|
import { defineApiKeyProviderExecutors, providerUserAgent, ProviderRequestError, requiredInputString, } from "../provider-runtime.js";
|
|
6
7
|
import { tongdaxinActions, tongdaxinReadOnlyToolNames } from "./actions.js";
|
|
@@ -9,10 +10,15 @@ import { isTongdaxinNamedActionName, resolveTongdaxinNamedToolCall } from "./nam
|
|
|
9
10
|
const service = "tongdaxin";
|
|
10
11
|
const endpoint = new URL("https://txmcp.tdx.com.cn:3001/txmcp");
|
|
11
12
|
const requestTimeoutMs = 60_000;
|
|
13
|
+
const errorResponseMaxBytes = 64 * 1024;
|
|
14
|
+
const insufficientPointsToolError = "MCP error -32603: Your usage quota has been reached";
|
|
15
|
+
const insufficientPointsDescription = "TDX MCP quota is below 10. Please recharge before continuing.";
|
|
16
|
+
const rechargeOrigin = "https://vip.tdx.com.cn";
|
|
17
|
+
const rechargePath = "/site/app/pc-mall/main.html";
|
|
12
18
|
const supportedToolNames = new Set(tongdaxinReadOnlyToolNames);
|
|
13
19
|
const handlers = {
|
|
14
20
|
async list_tools(_input, context) {
|
|
15
|
-
return { tools: await discoverSupportedTools(context
|
|
21
|
+
return { tools: await discoverSupportedTools(context) };
|
|
16
22
|
},
|
|
17
23
|
async call_tool(input, context) {
|
|
18
24
|
const toolName = requiredInputString(input.toolName, "toolName");
|
|
@@ -20,7 +26,8 @@ const handlers = {
|
|
|
20
26
|
if (!argumentsValue)
|
|
21
27
|
throw new ProviderRequestError(400, "arguments must be a JSON object");
|
|
22
28
|
assertToolArgumentsSize(argumentsValue);
|
|
23
|
-
const result = await withTongdaxinClient(context,
|
|
29
|
+
const result = await withTongdaxinClient(context, false, (client) => client.callTool({ name: toolName, arguments: argumentsValue }, { timeout: requestTimeoutMs, signal: context.signal }));
|
|
30
|
+
assertSufficientTongdaxinCredit(result);
|
|
24
31
|
if (!("toolResult" in result) && result.isError) {
|
|
25
32
|
throw new ProviderRequestError(502, `Tongdaxin MCP tool ${toolName} returned an error`, result);
|
|
26
33
|
}
|
|
@@ -37,7 +44,7 @@ for (const actionName of Object.keys(resolveNamedHandlers())) {
|
|
|
37
44
|
throw new ProviderRequestError(400, `Unknown action: ${actionName}`);
|
|
38
45
|
const toolCall = resolveTongdaxinNamedToolCall(actionName, input);
|
|
39
46
|
assertToolArgumentsSize(toolCall.arguments);
|
|
40
|
-
const tools = await discoverSupportedTools(context
|
|
47
|
+
const tools = await discoverSupportedTools(context);
|
|
41
48
|
const tool = tools.find((candidate) => candidate.name === toolCall.toolName);
|
|
42
49
|
if (!tool && toolCall.toolName !== "wenda_macro_query") {
|
|
43
50
|
throw new ProviderRequestError(409, `Tongdaxin action ${actionName} is unavailable because this connection does not expose ${toolCall.toolName}`);
|
|
@@ -48,7 +55,8 @@ for (const actionName of Object.keys(resolveNamedHandlers())) {
|
|
|
48
55
|
tool.annotations.destructiveHint === true)) {
|
|
49
56
|
throw new ProviderRequestError(403, `Tongdaxin MCP does not currently affirm ${tool.name} as a non-destructive read-only tool`);
|
|
50
57
|
}
|
|
51
|
-
const result = await withTongdaxinClient(context,
|
|
58
|
+
const result = await withTongdaxinClient(context, true, (client) => client.callTool({ name: toolCall.toolName, arguments: toolCall.arguments }, { timeout: requestTimeoutMs, signal: context.signal }));
|
|
59
|
+
assertSufficientTongdaxinCredit(result);
|
|
52
60
|
if (!("toolResult" in result) && result.isError) {
|
|
53
61
|
throw new ProviderRequestError(502, `Tongdaxin MCP tool ${toolCall.toolName} returned an error`, result);
|
|
54
62
|
}
|
|
@@ -62,7 +70,7 @@ export const executors = defineApiKeyProviderExecutors(service, handlers, {
|
|
|
62
70
|
export const credentialValidators = {
|
|
63
71
|
async apiKey(input, { fetcher, signal }) {
|
|
64
72
|
const context = { apiKey: input.apiKey, fetcher, signal };
|
|
65
|
-
const tools = await discoverSupportedTools(context
|
|
73
|
+
const tools = await discoverSupportedTools(context);
|
|
66
74
|
if (tools.length === 0) {
|
|
67
75
|
throw new ProviderRequestError(400, "Tongdaxin MCP did not expose any supported read-only tools");
|
|
68
76
|
}
|
|
@@ -77,8 +85,8 @@ export const credentialValidators = {
|
|
|
77
85
|
};
|
|
78
86
|
},
|
|
79
87
|
};
|
|
80
|
-
async function discoverSupportedTools(context
|
|
81
|
-
const result = await withTongdaxinClient(context,
|
|
88
|
+
async function discoverSupportedTools(context) {
|
|
89
|
+
const result = await withTongdaxinClient(context, true, (client) => client.listTools({}, { timeout: requestTimeoutMs, signal: context.signal }));
|
|
82
90
|
return result.tools.map((tool) => ({
|
|
83
91
|
name: tool.name,
|
|
84
92
|
description: tool.description,
|
|
@@ -86,30 +94,30 @@ async function discoverSupportedTools(context, phase) {
|
|
|
86
94
|
inputSchema: tool.inputSchema,
|
|
87
95
|
}));
|
|
88
96
|
}
|
|
89
|
-
async function withTongdaxinClient(context,
|
|
97
|
+
async function withTongdaxinClient(context, retryOnSessionNotFound, run) {
|
|
90
98
|
return withMcpClient({
|
|
91
99
|
endpoint,
|
|
92
100
|
transport: "streamable_http",
|
|
93
|
-
fetcher: context.fetcher,
|
|
101
|
+
fetcher: createTongdaxinFetcher(context.fetcher),
|
|
94
102
|
headers: {
|
|
95
103
|
authorization: `Bearer ${context.apiKey}`,
|
|
96
104
|
"user-agent": providerUserAgent,
|
|
97
105
|
},
|
|
98
|
-
redirect: "
|
|
106
|
+
redirect: "manual",
|
|
99
107
|
signal: context.signal,
|
|
100
108
|
retryOnSessionNotFound,
|
|
101
|
-
mapError:
|
|
109
|
+
mapError: mapTongdaxinError,
|
|
102
110
|
}, run);
|
|
103
111
|
}
|
|
104
|
-
function mapTongdaxinError(error
|
|
112
|
+
function mapTongdaxinError(error) {
|
|
105
113
|
if (error instanceof ProviderRequestError)
|
|
106
114
|
return error;
|
|
107
115
|
if (error instanceof UnauthorizedError) {
|
|
108
|
-
return new ProviderRequestError(
|
|
116
|
+
return new ProviderRequestError(401, "Tongdaxin MCP denied this request");
|
|
109
117
|
}
|
|
110
118
|
if (error instanceof SdkHttpError) {
|
|
111
119
|
if (error.status === 401) {
|
|
112
|
-
return new ProviderRequestError(
|
|
120
|
+
return new ProviderRequestError(401, "Tongdaxin MCP denied this request");
|
|
113
121
|
}
|
|
114
122
|
const status = 400 <= error.status && error.status < 500 ? error.status : 502;
|
|
115
123
|
return new ProviderRequestError(status, `Tongdaxin MCP request failed: ${error.message}`, error);
|
|
@@ -119,6 +127,62 @@ function mapTongdaxinError(error, phase) {
|
|
|
119
127
|
}
|
|
120
128
|
return new ProviderRequestError(502, error instanceof Error ? `Tongdaxin MCP request failed: ${error.message}` : "Tongdaxin MCP request failed", error);
|
|
121
129
|
}
|
|
130
|
+
function createTongdaxinFetcher(fetcher) {
|
|
131
|
+
return (async (...arguments_) => {
|
|
132
|
+
const response = await fetcher(...arguments_);
|
|
133
|
+
const details = await readInsufficientPoints(response);
|
|
134
|
+
if (details) {
|
|
135
|
+
void response.body?.cancel().catch(() => undefined);
|
|
136
|
+
throw insufficientCreditError(details);
|
|
137
|
+
}
|
|
138
|
+
return response;
|
|
139
|
+
});
|
|
140
|
+
}
|
|
141
|
+
async function readInsufficientPoints(response) {
|
|
142
|
+
if (response.status !== 401)
|
|
143
|
+
return undefined;
|
|
144
|
+
try {
|
|
145
|
+
const bytes = await readBoundedResponseBytes(response.clone(), {
|
|
146
|
+
maxBytes: errorResponseMaxBytes,
|
|
147
|
+
fieldName: "Tongdaxin MCP error response",
|
|
148
|
+
createError: (message) => new Error(message),
|
|
149
|
+
});
|
|
150
|
+
const payload = optionalRecord(JSON.parse(new TextDecoder().decode(bytes)));
|
|
151
|
+
const remainingCredit = optionalNumber(payload?.leftValue);
|
|
152
|
+
const rechargeUrl = optionalString(payload?.recharge_url);
|
|
153
|
+
if (payload?.error !== "unauthorized" ||
|
|
154
|
+
payload?.error_description !== insufficientPointsDescription ||
|
|
155
|
+
remainingCredit === undefined ||
|
|
156
|
+
!isOfficialRechargeUrl(rechargeUrl)) {
|
|
157
|
+
return undefined;
|
|
158
|
+
}
|
|
159
|
+
return { remainingCredit, rechargeUrl };
|
|
160
|
+
}
|
|
161
|
+
catch {
|
|
162
|
+
return undefined;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
function isOfficialRechargeUrl(value) {
|
|
166
|
+
if (!value)
|
|
167
|
+
return false;
|
|
168
|
+
try {
|
|
169
|
+
const url = new URL(value);
|
|
170
|
+
return url.origin === rechargeOrigin && url.pathname === rechargePath;
|
|
171
|
+
}
|
|
172
|
+
catch {
|
|
173
|
+
return false;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
function assertSufficientTongdaxinCredit(result) {
|
|
177
|
+
if (!("content" in result) || result.isError !== true)
|
|
178
|
+
return;
|
|
179
|
+
const exhausted = result.content.some((content) => content.type === "text" && content.text === insufficientPointsToolError);
|
|
180
|
+
if (exhausted)
|
|
181
|
+
throw insufficientCreditError();
|
|
182
|
+
}
|
|
183
|
+
function insufficientCreditError(details) {
|
|
184
|
+
return new ProviderRequestError(402, "Tongdaxin AI points are insufficient. Recharge the account before retrying.", details ?? { rechargeUrl: `${rechargeOrigin}${rechargePath}#/page_product_ai_jfb` }, "insufficient_credit");
|
|
185
|
+
}
|
|
122
186
|
function resolveNamedHandlers() {
|
|
123
187
|
return Object.fromEntries(tongdaxinActions
|
|
124
188
|
.filter((action) => action.name !== "list_tools" && action.name !== "call_tool")
|
|
@@ -2,7 +2,7 @@ import { defineApiKeyProviderExecutors, defineProviderProxy, ProviderRequestErro
|
|
|
2
2
|
async function get(path, accept, apiKey, fetcher, signal) {
|
|
3
3
|
const response = await fetcher(new URL(path, "https://tsdrapi.uspto.gov"), {
|
|
4
4
|
headers: { accept, "USPTO-API-KEY": apiKey, "user-agent": providerUserAgent },
|
|
5
|
-
redirect: "
|
|
5
|
+
redirect: "manual",
|
|
6
6
|
signal,
|
|
7
7
|
});
|
|
8
8
|
const text = await response.text();
|
|
@@ -37,7 +37,7 @@ export const proxy = async (input, context) => {
|
|
|
37
37
|
method: input.method,
|
|
38
38
|
headers,
|
|
39
39
|
body: input.method === "GET" || input.body == null ? undefined : signingBody,
|
|
40
|
-
redirect: "
|
|
40
|
+
redirect: "manual",
|
|
41
41
|
signal: context.signal,
|
|
42
42
|
});
|
|
43
43
|
if (!response.ok) {
|
|
@@ -173,7 +173,7 @@ async function withWeComMcpClient(context, run) {
|
|
|
173
173
|
transport: "streamable_http",
|
|
174
174
|
fetcher: createWeComRateLimitedFetch(context.fetcher, hashWeComRateLimitKey(context)),
|
|
175
175
|
headers,
|
|
176
|
-
redirect: "
|
|
176
|
+
redirect: "manual",
|
|
177
177
|
signal: context.signal,
|
|
178
178
|
mapError: mapWeComMcpError,
|
|
179
179
|
}, run);
|
|
@@ -45,7 +45,8 @@ export declare function isWechatTokenError(errcode: number | null): boolean;
|
|
|
45
45
|
/**
|
|
46
46
|
* Map a failed WeChat API call to the shared provider error. Rate limits
|
|
47
47
|
* (45009/45011) become 429, the missing-permission 48001 becomes 403, the
|
|
48
|
-
* 4xxxx client errcodes
|
|
48
|
+
* 4xxxx client errcodes and the documented invalid-input store errcodes become
|
|
49
|
+
* 400, and everything else becomes a 502.
|
|
49
50
|
*/
|
|
50
51
|
export declare function normalizeWechatApiError(result: WechatApiResult): ProviderRequestError;
|
|
51
52
|
export {};
|
|
@@ -1,9 +1,19 @@
|
|
|
1
1
|
import { createHash } from "node:crypto";
|
|
2
|
-
import {
|
|
2
|
+
import { optionalIntegerOrNull, optionalNumber, optionalRecord, optionalString } from "../../core/cast.js";
|
|
3
3
|
import { ProviderRequestError, providerResponseError, providerUserAgent, requiredInputString, runProviderRequest, } from "../provider-runtime.js";
|
|
4
4
|
const wechatStableTokenUrl = "https://api.weixin.qq.com/cgi-bin/stable_token";
|
|
5
5
|
const defaultAccessTokenTtlSeconds = 7200;
|
|
6
6
|
const accessTokenRefreshSkewMs = 120_000;
|
|
7
|
+
/**
|
|
8
|
+
* WeChat Store errcodes outside the 4xxxx range that the category and
|
|
9
|
+
* qualification docs describe as bad parameters or materials, such as an
|
|
10
|
+
* invalid or non-leaf category id, a mismatched certificate group, or a file id
|
|
11
|
+
* that did not come from the qualification upload. The caller has to fix the
|
|
12
|
+
* input, so they map to 400 instead of an upstream failure.
|
|
13
|
+
*/
|
|
14
|
+
const wechatInvalidInputErrcodes = new Set([
|
|
15
|
+
9401020, 9700234, 10020017, 10020059, 10020060, 10020062, 10020063, 10020087, 10020094, 10020127, 10020504,
|
|
16
|
+
]);
|
|
7
17
|
const accessTokenCache = new Map();
|
|
8
18
|
const accessTokenInFlight = new Map();
|
|
9
19
|
const accessTokenRefreshInFlight = new Map();
|
|
@@ -115,7 +125,7 @@ export function parseWechatJson(rawText) {
|
|
|
115
125
|
}
|
|
116
126
|
/** Read the numeric errcode of a WeChat envelope; absent or non-numeric reads as null. */
|
|
117
127
|
export function readWechatErrcode(record) {
|
|
118
|
-
return
|
|
128
|
+
return optionalIntegerOrNull(record?.errcode);
|
|
119
129
|
}
|
|
120
130
|
/** Whether the errcode marks the access token as invalid, so the caller can refresh and retry once. */
|
|
121
131
|
export function isWechatTokenError(errcode) {
|
|
@@ -124,7 +134,8 @@ export function isWechatTokenError(errcode) {
|
|
|
124
134
|
/**
|
|
125
135
|
* Map a failed WeChat API call to the shared provider error. Rate limits
|
|
126
136
|
* (45009/45011) become 429, the missing-permission 48001 becomes 403, the
|
|
127
|
-
* 4xxxx client errcodes
|
|
137
|
+
* 4xxxx client errcodes and the documented invalid-input store errcodes become
|
|
138
|
+
* 400, and everything else becomes a 502.
|
|
128
139
|
*/
|
|
129
140
|
export function normalizeWechatApiError(result) {
|
|
130
141
|
const errcode = readWechatErrcode(result.record);
|
|
@@ -142,7 +153,7 @@ export function normalizeWechatApiError(result) {
|
|
|
142
153
|
if (errcode === 48001) {
|
|
143
154
|
return new ProviderRequestError(403, message, result.record);
|
|
144
155
|
}
|
|
145
|
-
if (errcode !== null && errcode >= 40000 && errcode < 50000) {
|
|
156
|
+
if (errcode !== null && ((errcode >= 40000 && errcode < 50000) || wechatInvalidInputErrcodes.has(errcode))) {
|
|
146
157
|
return new ProviderRequestError(400, message, result.record);
|
|
147
158
|
}
|
|
148
159
|
if (result.status >= 400 && result.status < 500) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { compactObject, objectArray, optionalBoolean, optionalInteger, optionalString } from "../../core/cast.js";
|
|
1
|
+
import { compactObject, objectArray, optionalBoolean, optionalInteger, optionalRecord, optionalString, positiveInteger, } from "../../core/cast.js";
|
|
2
2
|
import { createProviderFetch, defineProviderExecutors, providerInputError, providerUserAgent, readTransitFileInput, requireCustomCredential, requiredInputString, runProviderRequest, } from "../provider-runtime.js";
|
|
3
3
|
import { getWechatAccessToken, isWechatTokenError, normalizeWechatApiError, parseWechatJson, readWechatErrcode, readWeixinStoreCredential, } from "./access-token.js";
|
|
4
4
|
const service = "weixin_store";
|
|
@@ -35,6 +35,20 @@ const deliveryProductFieldMap = {
|
|
|
35
35
|
productCnt: "product_cnt",
|
|
36
36
|
};
|
|
37
37
|
const weixinStoreActionHandlers = {
|
|
38
|
+
async upload_qualification_image(input, context) {
|
|
39
|
+
const file = await readTransitFileInput(input.file, context);
|
|
40
|
+
if (file.sizeBytes > 2 * 1024 * 1024) {
|
|
41
|
+
throw providerInputError("file must be at most 2 MB");
|
|
42
|
+
}
|
|
43
|
+
const formData = new FormData();
|
|
44
|
+
formData.set("media", file.file, file.name);
|
|
45
|
+
return callWechatApi(context, {
|
|
46
|
+
method: "POST",
|
|
47
|
+
path: "/shop/ec/basics/qualification/upload",
|
|
48
|
+
body: formData,
|
|
49
|
+
timeoutMs: wechatImageUploadTimeoutMs,
|
|
50
|
+
});
|
|
51
|
+
},
|
|
38
52
|
upload_image(input, context) {
|
|
39
53
|
const imageUrl = optionalString(input.imageUrl);
|
|
40
54
|
if ((imageUrl === undefined) === (input.file === undefined)) {
|
|
@@ -61,7 +75,53 @@ const weixinStoreActionHandlers = {
|
|
|
61
75
|
return callWechatApi(context, {
|
|
62
76
|
method: "POST",
|
|
63
77
|
path: "/shop/ec/category/detail",
|
|
64
|
-
body: { cat_id:
|
|
78
|
+
body: { cat_id: positiveInteger(input.catId, "catId", providerInputError) },
|
|
79
|
+
});
|
|
80
|
+
},
|
|
81
|
+
apply_category(input, context) {
|
|
82
|
+
const categoryInfo = optionalRecord(input.categoryInfo);
|
|
83
|
+
if (!categoryInfo) {
|
|
84
|
+
throw providerInputError("categoryInfo must be an object");
|
|
85
|
+
}
|
|
86
|
+
return callWechatApi(context, {
|
|
87
|
+
method: "POST",
|
|
88
|
+
path: "/channels/ec/category/add",
|
|
89
|
+
body: { category_info: mapCategoryApplication(categoryInfo) },
|
|
90
|
+
});
|
|
91
|
+
},
|
|
92
|
+
get_category_application(input, context) {
|
|
93
|
+
return callWechatApi(context, {
|
|
94
|
+
method: "POST",
|
|
95
|
+
path: "/shop/ec/category/getbizcatflowdetail",
|
|
96
|
+
body: { audit_id: positiveInteger(input.auditId, "auditId", providerInputError) },
|
|
97
|
+
});
|
|
98
|
+
},
|
|
99
|
+
list_category_permissions(input, context) {
|
|
100
|
+
const status = optionalInteger(input.status);
|
|
101
|
+
return callWechatApi(context, {
|
|
102
|
+
method: "POST",
|
|
103
|
+
path: "/shop/ec/category/get_category_relation_list",
|
|
104
|
+
body: compactObject({ is_filter_status: status !== undefined, status }),
|
|
105
|
+
});
|
|
106
|
+
},
|
|
107
|
+
precheck_product_category(input, context) {
|
|
108
|
+
return callWechatApi(context, {
|
|
109
|
+
method: "POST",
|
|
110
|
+
path: "/channels/ec/product/categoryprecheck",
|
|
111
|
+
body: compactObject({
|
|
112
|
+
cat_id: input.catId === undefined ? undefined : positiveInteger(input.catId, "catId", providerInputError),
|
|
113
|
+
}),
|
|
114
|
+
});
|
|
115
|
+
},
|
|
116
|
+
get_category_product_rule(input, context) {
|
|
117
|
+
return callWechatApi(context, {
|
|
118
|
+
method: "POST",
|
|
119
|
+
path: "/shop/ec/category/getcategoryproductrule",
|
|
120
|
+
body: compactObject({
|
|
121
|
+
cat_id: positiveInteger(input.catId, "catId", providerInputError),
|
|
122
|
+
release_mode: optionalInteger(input.releaseMode),
|
|
123
|
+
brand_id: input.brandId === undefined ? undefined : positiveInteger(input.brandId, "brandId", providerInputError),
|
|
124
|
+
}),
|
|
65
125
|
});
|
|
66
126
|
},
|
|
67
127
|
list_valid_brands(input, context) {
|
|
@@ -260,7 +320,7 @@ const weixinStoreActionHandlers = {
|
|
|
260
320
|
path: "/channels/ec/aftersale/rejectapply",
|
|
261
321
|
body: compactObject({
|
|
262
322
|
after_sale_order_id: requiredInputString(input.afterSaleOrderId, "afterSaleOrderId"),
|
|
263
|
-
reject_reason_type:
|
|
323
|
+
reject_reason_type: positiveInteger(input.rejectReasonType, "rejectReasonType", providerInputError),
|
|
264
324
|
reject_reason: optionalString(input.rejectReason),
|
|
265
325
|
}),
|
|
266
326
|
});
|
|
@@ -299,8 +359,8 @@ export const credentialValidators = {
|
|
|
299
359
|
};
|
|
300
360
|
/** Upload a local transit file as a store image, which WeChat sizes from the required pixel dimensions. */
|
|
301
361
|
async function uploadImageFile(context, input) {
|
|
302
|
-
const width =
|
|
303
|
-
const height =
|
|
362
|
+
const width = positiveInteger(input.width, "width", providerInputError);
|
|
363
|
+
const height = positiveInteger(input.height, "height", providerInputError);
|
|
304
364
|
const file = await readTransitFileInput(input.file, context);
|
|
305
365
|
const formData = new FormData();
|
|
306
366
|
formData.set("media", file.file, file.name);
|
|
@@ -362,6 +422,38 @@ async function executeWechatJsonRequest(context, request, accessToken) {
|
|
|
362
422
|
return { status: response.status, record: parseWechatJson(rawText), rawText };
|
|
363
423
|
});
|
|
364
424
|
}
|
|
425
|
+
/**
|
|
426
|
+
* Build the category_info of a category application: force the certificate-group
|
|
427
|
+
* protocol and send every id as the number WeChat documents, since callers often
|
|
428
|
+
* copy them from responses that carry numeric ids as strings.
|
|
429
|
+
*/
|
|
430
|
+
function mapCategoryApplication(categoryInfo) {
|
|
431
|
+
return {
|
|
432
|
+
...categoryInfo,
|
|
433
|
+
cats_v2: objectArray(categoryInfo.cats_v2, "categoryInfo.cats_v2", providerInputError).map((cat) => ({
|
|
434
|
+
...cat,
|
|
435
|
+
cat_id: positiveInteger(cat.cat_id, "categoryInfo.cats_v2[].cat_id", providerInputError),
|
|
436
|
+
})),
|
|
437
|
+
license_group_list: objectArray(categoryInfo.license_group_list, "categoryInfo.license_group_list", providerInputError).map((group) => {
|
|
438
|
+
const license = optionalRecord(group.license) ?? {};
|
|
439
|
+
return {
|
|
440
|
+
...group,
|
|
441
|
+
license_group_id: positiveInteger(group.license_group_id, "categoryInfo.license_group_list[].license_group_id", providerInputError),
|
|
442
|
+
license: {
|
|
443
|
+
...license,
|
|
444
|
+
license_id: positiveInteger(license.license_id, "categoryInfo.license_group_list[].license.license_id", providerInputError),
|
|
445
|
+
},
|
|
446
|
+
};
|
|
447
|
+
}),
|
|
448
|
+
brand_list: categoryInfo.brand_list === undefined
|
|
449
|
+
? undefined
|
|
450
|
+
: objectArray(categoryInfo.brand_list, "categoryInfo.brand_list", providerInputError).map((brand) => ({
|
|
451
|
+
...brand,
|
|
452
|
+
brand_id: positiveInteger(brand.brand_id, "categoryInfo.brand_list[].brand_id", providerInputError),
|
|
453
|
+
})),
|
|
454
|
+
is_new_apply_cat: true,
|
|
455
|
+
};
|
|
456
|
+
}
|
|
365
457
|
/** WeChat only reads deliver_acct_type when deliver_method is 3, and then it is required. */
|
|
366
458
|
function checkProductPayload(input) {
|
|
367
459
|
if (optionalInteger(input.deliverMethod) === 3 && input.deliverAcctType === undefined) {
|
|
@@ -447,13 +539,6 @@ function readOffsetLimit(input) {
|
|
|
447
539
|
function readPageSize(input, max, defaultValue) {
|
|
448
540
|
return readBoundedInteger(input.pageSize, "pageSize", 1, max) ?? defaultValue;
|
|
449
541
|
}
|
|
450
|
-
function readPositiveInteger(value, fieldName) {
|
|
451
|
-
const parsed = optionalInteger(value);
|
|
452
|
-
if (parsed === undefined || parsed < 1) {
|
|
453
|
-
throw providerInputError(`${fieldName} must be a positive integer`);
|
|
454
|
-
}
|
|
455
|
-
return parsed;
|
|
456
|
-
}
|
|
457
542
|
/** Read a WeChat id that the docs type inconsistently as string or number; numbers are sent in string form. */
|
|
458
543
|
function readIdString(value, fieldName) {
|
|
459
544
|
const stringId = optionalString(value);
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { CredentialValidators, ProviderExecutors, ProviderProxyExecutor } from "../../core/types.ts";
|
|
2
|
+
export declare const executors: ProviderExecutors;
|
|
3
|
+
export declare const proxy: ProviderProxyExecutor;
|
|
4
|
+
export declare const credentialValidators: CredentialValidators;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { defineApiKeyProviderExecutors, defineProviderProxy } from "../provider-runtime.js";
|
|
2
|
+
import { validateWisburgCredential, wisburgActionHandlers, wisburgApiBaseUrl } from "./runtime.js";
|
|
3
|
+
const service = "wisburg";
|
|
4
|
+
export const executors = defineApiKeyProviderExecutors(service, wisburgActionHandlers, {
|
|
5
|
+
skipDnsValidation: true,
|
|
6
|
+
});
|
|
7
|
+
export const proxy = defineProviderProxy({
|
|
8
|
+
service,
|
|
9
|
+
baseUrl: wisburgApiBaseUrl,
|
|
10
|
+
auth: { type: "api_key_authorization", prefix: "Bearer " },
|
|
11
|
+
skipDnsValidation: true,
|
|
12
|
+
});
|
|
13
|
+
export const credentialValidators = { apiKey: validateWisburgCredential };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { CredentialValidationResult } from "../../core/types.ts";
|
|
2
|
+
import type { ApiKeyProviderContext, ProviderActionHandlers, ProviderRuntimeHandler } from "../provider-runtime.ts";
|
|
3
|
+
/** Output key a detail action nests its resource under. */
|
|
4
|
+
export type WisburgDetailKey = "report" | "article" | "log";
|
|
5
|
+
export declare const wisburgApiBaseUrl = "https://api-omen.wisburg.com";
|
|
6
|
+
export declare const wisburgActionHandlers: ProviderActionHandlers<"wisburg", ProviderRuntimeHandler<ApiKeyProviderContext>>;
|
|
7
|
+
export declare function validateWisburgCredential(input: {
|
|
8
|
+
apiKey: string;
|
|
9
|
+
}, { fetcher, signal }: {
|
|
10
|
+
fetcher: typeof fetch;
|
|
11
|
+
signal?: AbortSignal;
|
|
12
|
+
}): Promise<CredentialValidationResult>;
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
import { sha256Hex } from "../../core/aws-sigv4.js";
|
|
2
|
+
import { objectArray, optionalInteger, optionalNumber, optionalRecord, optionalString } from "../../core/cast.js";
|
|
3
|
+
import { ProviderRequestError, parseProviderJsonBodyText, providerResponseError, providerUserAgent, readProviderErrorTextBody, readProviderJsonBody, requiredInputNumber, requiredResponseRecord, runProviderRequest, setSearchParams, } from "../provider-runtime.js";
|
|
4
|
+
export const wisburgApiBaseUrl = "https://api-omen.wisburg.com";
|
|
5
|
+
export const wisburgActionHandlers = {
|
|
6
|
+
list_reports: (input, context) => listWisburgResource(input, context, "api/reports"),
|
|
7
|
+
get_report: (input, context) => getWisburgResource(input, context, "api/reports", "report"),
|
|
8
|
+
list_archives: (input, context) => listWisburgResource(input, context, "api/archives"),
|
|
9
|
+
get_archive: (input, context) => getWisburgResource(input, context, "api/archives", "report"),
|
|
10
|
+
list_company_reports: (input, context) => listWisburgResource(input, context, "api/company-reports"),
|
|
11
|
+
get_company_report: (input, context) => getWisburgResource(input, context, "api/company-reports", "report"),
|
|
12
|
+
list_earnings_calls: (input, context) => listWisburgResource(input, context, "api/earningscalls"),
|
|
13
|
+
get_earnings_call: (input, context) => getWisburgResource(input, context, "api/earningscalls", "report"),
|
|
14
|
+
list_articles: (input, context) => listWisburgResource(input, context, "api/articles"),
|
|
15
|
+
get_article: (input, context) => getWisburgResource(input, context, "api/articles", "article"),
|
|
16
|
+
list_market_daily: (input, context) => listWisburgResource(input, context, "api/market-daily"),
|
|
17
|
+
list_feed: (input, context) => listWisburgResource(input, context, "api/feed"),
|
|
18
|
+
list_images: (input, context) => listWisburgResource(input, context, "api/images"),
|
|
19
|
+
list_am_reports: (input, context) => listWisburgResource(input, context, "api/am-reports"),
|
|
20
|
+
get_am_report: (input, context) => getWisburgResource(input, context, "api/am-reports", "report"),
|
|
21
|
+
list_mikko_logs: (input, context) => listWisburgResource(input, context, "api/mikko-logs"),
|
|
22
|
+
get_mikko_log: (input, context) => getWisburgResource(input, context, "api/mikko-logs", "log"),
|
|
23
|
+
};
|
|
24
|
+
export async function validateWisburgCredential(input, { fetcher, signal }) {
|
|
25
|
+
try {
|
|
26
|
+
await wisburgRequest({ apiKey: input.apiKey, fetcher, signal }, { path: "api/feed", query: { first: "1" } });
|
|
27
|
+
}
|
|
28
|
+
catch (error) {
|
|
29
|
+
if (error instanceof ProviderRequestError && error.status === 401) {
|
|
30
|
+
throw new ProviderRequestError(400, error.message, error.details);
|
|
31
|
+
}
|
|
32
|
+
// A 403 proves the key was accepted; the feed is simply outside this key's subscription.
|
|
33
|
+
if (!(error instanceof ProviderRequestError) || error.status !== 403)
|
|
34
|
+
throw error;
|
|
35
|
+
}
|
|
36
|
+
return {
|
|
37
|
+
profile: {
|
|
38
|
+
accountId: `wisburg:${sha256Hex(input.apiKey).slice(0, 32)}`,
|
|
39
|
+
displayName: "Wisburg API Key",
|
|
40
|
+
},
|
|
41
|
+
grantedScopes: [],
|
|
42
|
+
metadata: {
|
|
43
|
+
apiBaseUrl: wisburgApiBaseUrl,
|
|
44
|
+
validationEndpoint: "/api/feed",
|
|
45
|
+
credentialHelpUrl: "https://open-docs.wisburg.com/docs/getting-started/first-call",
|
|
46
|
+
},
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
async function listWisburgResource(input, context, path) {
|
|
50
|
+
const envelope = await wisburgRequest(context, {
|
|
51
|
+
path,
|
|
52
|
+
query: {
|
|
53
|
+
first: optionalInteger(input.first)?.toString(),
|
|
54
|
+
after: optionalString(input.after),
|
|
55
|
+
query: optionalString(input.query),
|
|
56
|
+
startTime: optionalString(input.startTime),
|
|
57
|
+
endTime: optionalString(input.endTime),
|
|
58
|
+
},
|
|
59
|
+
});
|
|
60
|
+
const data = requiredResponseRecord(envelope.data, "Wisburg list data");
|
|
61
|
+
const pageInfo = requiredResponseRecord(data.page_info, "Wisburg list page_info");
|
|
62
|
+
const endCursor = pageInfo.end_cursor;
|
|
63
|
+
if (endCursor != null && typeof endCursor !== "string") {
|
|
64
|
+
throw providerResponseError("Wisburg list page_info.end_cursor must be a string");
|
|
65
|
+
}
|
|
66
|
+
return {
|
|
67
|
+
requestId: optionalString(envelope.request_id) ?? "",
|
|
68
|
+
items: objectArray(data.items, "Wisburg list data.items", providerResponseError),
|
|
69
|
+
pageInfo: { endCursor: optionalString(endCursor) },
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
async function getWisburgResource(input, context, path, key) {
|
|
73
|
+
const id = requiredInputNumber(input.id, "id");
|
|
74
|
+
const envelope = await wisburgRequest(context, { path: `${path}/${id}` });
|
|
75
|
+
return {
|
|
76
|
+
requestId: optionalString(envelope.request_id) ?? "",
|
|
77
|
+
[key]: requiredResponseRecord(envelope.data, "Wisburg detail data"),
|
|
78
|
+
};
|
|
79
|
+
}
|
|
80
|
+
async function wisburgRequest(context, input) {
|
|
81
|
+
return runProviderRequest({ signal: context.signal, label: "Wisburg" }, async (signal) => {
|
|
82
|
+
const url = new URL(input.path, `${wisburgApiBaseUrl}/`);
|
|
83
|
+
setSearchParams(url, input.query ?? {});
|
|
84
|
+
const response = await context.fetcher(url, {
|
|
85
|
+
headers: {
|
|
86
|
+
accept: "application/json",
|
|
87
|
+
authorization: `Bearer ${context.apiKey}`,
|
|
88
|
+
"user-agent": providerUserAgent,
|
|
89
|
+
},
|
|
90
|
+
signal,
|
|
91
|
+
});
|
|
92
|
+
if (!response.ok) {
|
|
93
|
+
throw await readWisburgHttpError(response);
|
|
94
|
+
}
|
|
95
|
+
const payload = await readProviderJsonBody(response, {
|
|
96
|
+
emptyBody: {},
|
|
97
|
+
invalidJsonMessage: "Wisburg returned invalid JSON",
|
|
98
|
+
});
|
|
99
|
+
const envelope = requiredResponseRecord(payload, "Wisburg response");
|
|
100
|
+
const code = optionalNumber(envelope.code);
|
|
101
|
+
if (code !== undefined && code !== 200) {
|
|
102
|
+
throw mapWisburgError(code, envelope);
|
|
103
|
+
}
|
|
104
|
+
// The envelope marks failure as status 1 even when the code field disagrees; fall back to the 1002 internal-error code when none is present.
|
|
105
|
+
if (optionalNumber(envelope.status) === 1) {
|
|
106
|
+
throw mapWisburgError(code ?? 1002, envelope);
|
|
107
|
+
}
|
|
108
|
+
return envelope;
|
|
109
|
+
});
|
|
110
|
+
}
|
|
111
|
+
// Keep the HTTP status for non-JSON gateway error pages; the JSON envelope, when present, only supplies the code and message.
|
|
112
|
+
async function readWisburgHttpError(response) {
|
|
113
|
+
const text = await readProviderErrorTextBody(response, "Wisburg error response");
|
|
114
|
+
const parsed = parseProviderJsonBodyText(text, {
|
|
115
|
+
emptyBody: {},
|
|
116
|
+
invalidJsonMessage: "Wisburg returned invalid JSON",
|
|
117
|
+
invalidJsonFallback: () => ({}),
|
|
118
|
+
});
|
|
119
|
+
const envelope = optionalRecord(parsed) ?? {};
|
|
120
|
+
return mapWisburgError(optionalNumber(envelope.code) ?? response.status, envelope);
|
|
121
|
+
}
|
|
122
|
+
function mapWisburgError(code, envelope) {
|
|
123
|
+
const message = optionalString(envelope.message) ?? `Wisburg request failed (${code})`;
|
|
124
|
+
// Besides the documented 401/403/404/429 codes, a bare gateway 4xx such as 414 stays a client error.
|
|
125
|
+
if (code >= 400 && code < 500) {
|
|
126
|
+
return new ProviderRequestError(code, message, envelope);
|
|
127
|
+
}
|
|
128
|
+
// 1001 marks invalid parameters and 1004 an out-of-range pagination cursor.
|
|
129
|
+
if (code === 1001 || code === 1004) {
|
|
130
|
+
return new ProviderRequestError(400, message, envelope);
|
|
131
|
+
}
|
|
132
|
+
return new ProviderRequestError(502, message, envelope);
|
|
133
|
+
}
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import type { CredentialValidators, ProviderExecutors, ProviderProxyExecutor } from "../../core/types.ts";
|
|
2
|
+
import type { IntegrationDefinition } from "../../triggers/common/integration.ts";
|
|
3
|
+
import type { PollDefinition } from "../../triggers/common/poll.ts";
|
|
2
4
|
export declare const executors: ProviderExecutors;
|
|
3
5
|
export declare const proxy: ProviderProxyExecutor;
|
|
4
6
|
export declare const credentialValidators: CredentialValidators;
|
|
7
|
+
export declare const triggers: readonly (IntegrationDefinition | PollDefinition)[];
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { isPrivateNetworkAccessAllowed } from "../../core/request.js";
|
|
2
2
|
import { basicAuthorizationHeader, createProviderFetch, createProviderProxyUrl, defineProviderExecutors, normalizeProviderProxyHeaders, ProviderRequestError, providerUserAgent, readProviderProxyErrorMessage, readProviderProxyResponse, requireCustomCredential, toProviderProxyError, } from "../provider-runtime.js";
|
|
3
3
|
import { resolveWooCommerceCredentialContext, validateWooCommerceCredential, woocommerceActionHandlers, } from "./runtime.js";
|
|
4
|
+
import { wooCommerceStoreEvent } from "./trigger-on-store-event.js";
|
|
4
5
|
const service = "woocommerce";
|
|
5
6
|
const proxyFetch = createProviderFetch({ allowPrivateNetwork: isPrivateNetworkAccessAllowed });
|
|
6
7
|
export const executors = defineProviderExecutors({
|
|
@@ -49,3 +50,4 @@ export const credentialValidators = {
|
|
|
49
50
|
return validateWooCommerceCredential(input.values, guardedFetcher, signal);
|
|
50
51
|
},
|
|
51
52
|
};
|
|
53
|
+
export const triggers = [wooCommerceStoreEvent];
|