@oomol-lab/open-connector 1.9.2 → 1.9.3
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 -2
- package/assets/open-connector/catalog/apps/allratestoday.json +174 -0
- package/assets/open-connector/catalog/apps/slackbot.json +20 -1
- package/assets/open-connector/catalog/apps-index.json +1 -1
- package/package.json +1 -1
- package/src/connection-error.d.ts +7 -0
- package/src/connection-error.js +10 -0
- package/src/connection-service.d.ts +2 -50
- package/src/connection-service.js +6 -130
- package/src/connection-store.d.ts +41 -0
- package/src/connection-store.js +1 -0
- package/src/core/guarded-fetch.d.ts +3 -0
- package/src/core/guarded-fetch.js +8 -1
- package/src/core/provider-network-policy.d.ts +15 -0
- package/src/core/provider-network-policy.js +11 -0
- package/src/core/request.d.ts +18 -14
- package/src/core/request.js +11 -35
- package/src/credential-resolver.d.ts +24 -0
- package/src/credential-resolver.js +131 -0
- package/src/mcp.js +1 -1
- package/src/oauth/oauth-client-config-service.d.ts +1 -1
- package/src/oauth/oauth-client-config-service.js +14 -2
- package/src/oauth/oauth-credential-refresh-service.js +1 -1
- package/src/oauth/oauth-flow-service.d.ts +9 -1
- package/src/oauth/oauth-flow-service.js +11 -1
- package/src/providers/abuseipdb/executors.js +3 -4
- package/src/providers/action-contracts.generated.d.ts +1 -0
- package/src/providers/addressfinder/executors.js +2 -3
- package/src/providers/aeroleads/executors.js +3 -3
- package/src/providers/affinity/runtime.js +6 -7
- package/src/providers/aftership/executors.js +2 -2
- package/src/providers/agent_mail/runtime.js +2 -2
- package/src/providers/agentql/runtime.js +2 -2
- package/src/providers/agenty/runtime.js +5 -6
- package/src/providers/agiled/runtime.d.ts +0 -1
- package/src/providers/agiled/runtime.js +2 -3
- package/src/providers/agility/runtime.js +2 -3
- package/src/providers/ahrefs/runtime.js +3 -3
- package/src/providers/aifinmarket/runtime.js +6 -7
- package/src/providers/airtable/executors.js +3 -3
- package/src/providers/alchemy/runtime.js +2 -2
- package/src/providers/algolia/runtime.js +3 -3
- package/src/providers/aliyun_oss/executors.js +7 -7
- package/src/providers/allratestoday/executors.d.ts +3 -0
- package/src/providers/allratestoday/executors.js +18 -0
- package/src/providers/allratestoday/runtime.d.ts +17 -0
- package/src/providers/allratestoday/runtime.js +104 -0
- package/src/providers/alpaca/runtime.js +2 -3
- package/src/providers/alpha_vantage/runtime.js +2 -2
- package/src/providers/alt_text_ai/runtime.js +2 -2
- package/src/providers/altiria/executors.js +3 -3
- package/src/providers/amap/runtime.js +3 -3
- package/src/providers/ambee/runtime.js +2 -2
- package/src/providers/ambivo/executors.js +3 -3
- package/src/providers/amilia/runtime.js +1 -1
- package/src/providers/amplemarket/runtime.js +2 -2
- package/src/providers/amplitude/runtime.js +3 -3
- package/src/providers/anysearch/runtime.js +4 -4
- package/src/providers/apaleo/runtime.js +2 -2
- package/src/providers/api_sports/executors.js +3 -4
- package/src/providers/apiverve/executors.js +2 -3
- package/src/providers/apollo/executors.js +2 -3
- package/src/providers/appcircle/runtime.js +5 -5
- package/src/providers/appdrag/executors.js +2 -3
- package/src/providers/arcgis_online/executors.js +2 -2
- package/src/providers/auth0_management/runtime.js +2 -3
- package/src/providers/autoblogger/executors.js +3 -3
- package/src/providers/baidu_maps/runtime.js +3 -3
- package/src/providers/baidu_netdisk/runtime-mcp.js +3 -4
- package/src/providers/bark/executors.js +5 -5
- package/src/providers/bitrise/runtime.js +3 -3
- package/src/providers/bouncer/executors.js +3 -4
- package/src/providers/browse_ai/runtime.js +3 -4
- package/src/providers/browserstack/executors.js +6 -7
- package/src/providers/buildkite/runtime.js +3 -3
- package/src/providers/bunnycdn/runtime.js +3 -3
- package/src/providers/businessmap/runtime.js +6 -7
- package/src/providers/buttondown/runtime.js +2 -2
- package/src/providers/byteforms/runtime.js +2 -2
- package/src/providers/calendly/runtime.js +2 -2
- package/src/providers/captainbi/runtime.js +6 -6
- package/src/providers/castingwords/runtime.js +1 -1
- package/src/providers/chatpdf/runtime.js +4 -4
- package/src/providers/check/executors.js +3 -4
- package/src/providers/checkly/executors.js +3 -4
- package/src/providers/chengxin/runtime.js +3 -3
- package/src/providers/cincopa/executors.js +3 -4
- package/src/providers/circle/executors.js +3 -4
- package/src/providers/clearout/executors.js +1 -2
- package/src/providers/clickhelp/runtime.js +5 -5
- package/src/providers/clickhouse/runtime.js +4 -4
- package/src/providers/clinicalkey/runtime.js +3 -3
- package/src/providers/clinicaltrials_gov/runtime.js +4 -5
- package/src/providers/clockify/runtime.js +4 -4
- package/src/providers/close/runtime.js +3 -3
- package/src/providers/cloudconvert/runtime.js +8 -9
- package/src/providers/cloudflare_dns/runtime.js +2 -2
- package/src/providers/cloudflare_email_routing/runtime.js +2 -2
- package/src/providers/cloudflare_r2/runtime.js +5 -5
- package/src/providers/cloudflare_worker/runtime.js +10 -10
- package/src/providers/cloudinary/runtime.js +4 -4
- package/src/providers/cloudlayer/runtime.js +5 -5
- package/src/providers/codacy/runtime.js +2 -2
- package/src/providers/codemagic/runtime.js +2 -2
- package/src/providers/confluence/executors.js +4 -4
- package/src/providers/confluence/runtime.d.ts +0 -1
- package/src/providers/confluence/runtime.js +6 -7
- package/src/providers/contactout/runtime.js +5 -5
- package/src/providers/contentful/runtime.js +2 -2
- package/src/providers/contentstack_content_delivery/runtime.js +1 -1
- package/src/providers/cronly/runtime.js +2 -2
- package/src/providers/crossref/runtime.js +3 -3
- package/src/providers/cutt_ly/runtime.js +3 -3
- package/src/providers/cyberimpact/runtime.js +3 -3
- package/src/providers/dachser/executors.js +2 -2
- package/src/providers/dailybot/runtime.js +1 -1
- package/src/providers/databox/runtime.js +2 -2
- package/src/providers/databricks/runtime.js +2 -2
- package/src/providers/datacite/runtime.js +1 -1
- package/src/providers/datadog/executors.js +3 -4
- package/src/providers/datascope/runtime.js +2 -2
- package/src/providers/daytona/executors.js +3 -3
- package/src/providers/deepgram/runtime.js +2 -2
- package/src/providers/deepl/runtime.js +4 -4
- package/src/providers/detrack/executors.js +5 -5
- package/src/providers/deutschlandgpt/runtime.js +2 -2
- package/src/providers/dialmycalls/runtime.js +4 -4
- package/src/providers/diffbot/executors.js +4 -4
- package/src/providers/digistore24/executors.js +3 -3
- package/src/providers/dingtalk_bot/executors.js +1 -1
- package/src/providers/discourse/executors.d.ts +0 -1
- package/src/providers/discourse/executors.js +6 -7
- package/src/providers/docugenerate/runtime.js +3 -3
- package/src/providers/doppler/runtime.shared.js +3 -3
- package/src/providers/doppler_marketing_automation/runtime.js +4 -4
- package/src/providers/dovetail/runtime.js +2 -2
- package/src/providers/dropcontact/runtime.js +3 -3
- package/src/providers/dub/executors.js +6 -6
- package/src/providers/dumplingai/runtime.js +2 -2
- package/src/providers/elevenlabs/executors.js +4 -4
- package/src/providers/elevenreader/runtime.js +1 -1
- package/src/providers/emailoctopus/runtime.js +4 -4
- package/src/providers/embase/runtime.js +3 -3
- package/src/providers/emelia/executors.js +2 -2
- package/src/providers/enigma/executors.js +3 -3
- package/src/providers/eodhd_apis/executors.js +2 -2
- package/src/providers/eventzilla/runtime.js +3 -4
- package/src/providers/evervault/runtime.js +1 -1
- package/src/providers/excalidraw_mcp/runtime.js +3 -4
- package/src/providers/excel/runtime.js +6 -6
- package/src/providers/expofp/runtime.js +2 -2
- package/src/providers/faktoora/runtime.js +5 -5
- package/src/providers/fast_note_sync/runtime.js +2 -2
- package/src/providers/feathery/executors.js +2 -3
- package/src/providers/feishu_app_bot/executors.js +2 -3
- package/src/providers/feishu_custom_bot/executors.js +2 -3
- package/src/providers/ffhub/executors.js +2 -3
- package/src/providers/fidel_api/executors.js +2 -3
- package/src/providers/files_com/executors.js +2 -3
- package/src/providers/fireberry/runtime.d.ts +0 -1
- package/src/providers/fireberry/runtime.js +3 -4
- package/src/providers/firehydrant/executors.js +2 -3
- package/src/providers/float/executors.js +2 -3
- package/src/providers/flomo/executors.js +5 -6
- package/src/providers/flowiseai/executors.js +2 -3
- package/src/providers/fluxguard/executors.js +2 -3
- package/src/providers/folk/executors.js +2 -3
- package/src/providers/football_data/executors.js +2 -3
- package/src/providers/forem/executors.js +2 -3
- package/src/providers/formbricks/executors.js +2 -3
- package/src/providers/formsite/executors.js +3 -4
- package/src/providers/formspree/executors.js +2 -2
- package/src/providers/freshdesk/executors.js +3 -4
- package/src/providers/freshservice/executors.js +3 -4
- package/src/providers/freshteam/runtime.js +3 -4
- package/src/providers/full_contact/executors.js +3 -3
- package/src/providers/fusion-api/runtime.js +2 -3
- package/src/providers/gagelist/executors.js +3 -3
- package/src/providers/gainsight_nxt/executors.js +2 -2
- package/src/providers/gamma/executors.js +4 -3
- package/src/providers/gangtise/runtime.js +3 -4
- package/src/providers/gatherup/runtime.js +1 -1
- package/src/providers/geckoboard/executors.js +2 -3
- package/src/providers/gemini/runtime.d.ts +0 -1
- package/src/providers/gemini/runtime.js +5 -6
- package/src/providers/genpage/runtime.js +2 -2
- package/src/providers/geokeo/executors.js +4 -4
- package/src/providers/getnote/runtime.js +2 -3
- package/src/providers/github/runtime-shared.js +2 -2
- package/src/providers/glyphic/runtime.js +3 -4
- package/src/providers/gmail/executors.js +125 -27
- package/src/providers/gong/runtime.js +6 -7
- package/src/providers/googlecalendar/runtime-shared.js +3 -4
- package/src/providers/googledrive/runtime-request.js +2 -3
- package/src/providers/googlesheets/runtime-shared.js +3 -4
- package/src/providers/gorgias/runtime.js +4 -4
- package/src/providers/gotify/executors.js +7 -8
- package/src/providers/greenhouse/executors.js +3 -3
- package/src/providers/gumloop/executors.js +2 -3
- package/src/providers/gumroad/executors.js +2 -3
- package/src/providers/habitica/executors.js +2 -3
- package/src/providers/hackerrank_work/executors.js +2 -3
- package/src/providers/harvest/executors.js +3 -4
- package/src/providers/haveibeenpwned/executors.js +2 -3
- package/src/providers/headout/executors.js +3 -4
- package/src/providers/healthchecks_io/executors.js +2 -3
- package/src/providers/helium10/runtime.js +4 -5
- package/src/providers/helpdesk/runtime.js +4 -4
- package/src/providers/home_assistant/runtime-ws.js +9 -10
- package/src/providers/hotjar/executors.js +4 -4
- package/src/providers/httpsms/runtime.js +3 -4
- package/src/providers/hub_planner/executors.js +3 -3
- package/src/providers/hubspot/runtime.js +3 -4
- package/src/providers/humaans/runtime.js +3 -3
- package/src/providers/hunter/runtime.js +3 -3
- package/src/providers/icypeas/executors.js +3 -4
- package/src/providers/ima/runtime.js +7 -7
- package/src/providers/infolobby/runtime.js +6 -6
- package/src/providers/instabot/runtime.js +6 -6
- package/src/providers/instatus/runtime.js +4 -4
- package/src/providers/intuiface/executors.js +3 -3
- package/src/providers/iplocate/runtime.js +4 -5
- package/src/providers/ipregistry/executors.js +2 -2
- package/src/providers/jiminny/runtime.js +4 -4
- package/src/providers/jin10/executors.js +4 -5
- package/src/providers/jira/executors.js +4 -4
- package/src/providers/kaleido/runtime.js +2 -2
- package/src/providers/kandji/runtime.js +2 -2
- package/src/providers/keygen/executors.js +4 -4
- package/src/providers/keyword/runtime.js +2 -2
- package/src/providers/kie_ai/executors.js +1 -1
- package/src/providers/kintone/runtime.js +1 -1
- package/src/providers/kit/runtime.js +2 -2
- package/src/providers/klangio/runtime.js +4 -4
- package/src/providers/klaviyo/executors.js +1 -1
- package/src/providers/klazify/executors.js +3 -3
- package/src/providers/klipfolio/runtime.js +3 -3
- package/src/providers/knack/executors.js +1 -1
- package/src/providers/kommo/runtime.js +2 -2
- package/src/providers/kontent_ai/executors.js +3 -4
- package/src/providers/l2s/executors.js +3 -4
- package/src/providers/latchshot/executors.js +2 -2
- package/src/providers/leadboxer/runtime.js +4 -4
- package/src/providers/leadiq/runtime.js +4 -4
- package/src/providers/linguapop/runtime.js +1 -1
- package/src/providers/lingvanex_translation_api/runtime.js +5 -6
- package/src/providers/lingxing_mcp/runtime.js +3 -4
- package/src/providers/linkup/runtime.js +5 -6
- package/src/providers/liveagent/executors.js +6 -6
- package/src/providers/loops/executors.js +2 -2
- package/src/providers/loyjoy/runtime.js +2 -2
- package/src/providers/loyverse/executors.js +4 -4
- package/src/providers/lusha/runtime.js +3 -3
- package/src/providers/mailbluster/runtime.js +3 -4
- package/src/providers/mailcoach/runtime.js +4 -4
- package/src/providers/mailgenius/executors.js +3 -4
- package/src/providers/mailjet/runtime.js +3 -3
- package/src/providers/mails_so/runtime.js +1 -1
- package/src/providers/mailsoftly/runtime.js +5 -5
- package/src/providers/mailtrap/runtime.js +4 -5
- package/src/providers/manus/runtime.js +3 -3
- package/src/providers/mautic/runtime.js +3 -3
- package/src/providers/megaventory/runtime.js +3 -3
- package/src/providers/memberstack/runtime.js +2 -2
- package/src/providers/mendeley/executors.js +2 -3
- package/src/providers/mindbody/runtime.js +3 -3
- package/src/providers/minerstat/executors.js +3 -3
- package/src/providers/mintlify/runtime.js +3 -3
- package/src/providers/missive/executors.js +3 -5
- package/src/providers/mixpanel/executors.js +3 -3
- package/src/providers/mobile_text_alerts/runtime.js +3 -3
- package/src/providers/mocean/executors.js +3 -3
- package/src/providers/moco/executors.js +5 -5
- package/src/providers/moesif/runtime.js +4 -4
- package/src/providers/monday/runtime-common.js +3 -3
- package/src/providers/monica_crm/runtime.js +4 -4
- package/src/providers/moorcheh/runtime.js +3 -3
- package/src/providers/more_trees/runtime.d.ts +0 -1
- package/src/providers/more_trees/runtime.js +7 -8
- package/src/providers/moxie/runtime.js +2 -2
- package/src/providers/msg91/runtime.js +4 -4
- package/src/providers/mx/runtime.js +1 -1
- package/src/providers/needle/runtime.js +3 -4
- package/src/providers/netlify/runtime.js +2 -3
- package/src/providers/niftyimages/executors.js +2 -2
- package/src/providers/northbeam/runtime.js +1 -1
- package/src/providers/nozbe_teams/executors.js +4 -4
- package/src/providers/npm/runtime.js +4 -4
- package/src/providers/nusii_proposals/runtime.js +2 -2
- package/src/providers/ocr_web_service/executors.js +4 -4
- package/src/providers/octopus_deploy/executors.js +3 -3
- package/src/providers/oksign/runtime.js +3 -4
- package/src/providers/one_drive/executors.js +6 -6
- package/src/providers/one_password_events/runtime.js +1 -1
- package/src/providers/onfleet/runtime.js +3 -3
- package/src/providers/onlyoffice_docspace/runtime.js +4 -4
- package/src/providers/oomnitza/runtime.js +3 -4
- package/src/providers/otter_ai/executors.js +2 -2
- package/src/providers/oura/runtime.js +1 -1
- package/src/providers/paddle/executors.js +3 -3
- package/src/providers/pagerduty/runtime.js +2 -2
- package/src/providers/paradym/runtime.js +4 -4
- package/src/providers/parallel/runtime.js +3 -3
- package/src/providers/partner_stack_partner/runtime.js +1 -1
- package/src/providers/payrexx/runtime.js +5 -6
- package/src/providers/permit_io/runtime.js +2 -2
- package/src/providers/pinboard/executors.js +5 -6
- package/src/providers/pinpoint/runtime.js +2 -2
- package/src/providers/placid/runtime.js +3 -3
- package/src/providers/plain/runtime.js +5 -5
- package/src/providers/planetscale/runtime.js +2 -2
- package/src/providers/planhat/executors.js +6 -6
- package/src/providers/plausible_analytics/runtime.js +3 -3
- package/src/providers/posthog/runtime.js +3 -3
- package/src/providers/predis_ai/executors.js +3 -3
- package/src/providers/printavo/runtime.js +2 -2
- package/src/providers/prospeo/runtime.js +2 -3
- package/src/providers/provider-runtime.d.ts +13 -1
- package/src/providers/provider-runtime.js +25 -10
- package/src/providers/push_by_techulus/executors.js +3 -4
- package/src/providers/pushover/runtime.js +4 -5
- package/src/providers/pushsafer/runtime.js +4 -5
- package/src/providers/pylon/runtime.js +2 -2
- package/src/providers/qase/runtime.js +3 -3
- package/src/providers/qdrant/runtime.js +1 -1
- package/src/providers/qichacha/runtime.js +2 -2
- package/src/providers/qingflow/runtime.js +2 -2
- package/src/providers/quickchart/runtime.js +2 -2
- package/src/providers/quintadb/runtime.js +2 -2
- package/src/providers/quo/runtime.js +2 -2
- package/src/providers/rawg/runtime.js +4 -4
- package/src/providers/razorpay/runtime.js +4 -5
- package/src/providers/readme/runtime.js +6 -6
- package/src/providers/referralhero/runtime.js +3 -3
- package/src/providers/registry.generated.js +1 -0
- package/src/providers/render/executors.js +3 -3
- package/src/providers/respond_io/executors.js +3 -3
- package/src/providers/reversecontact/runtime.js +3 -3
- package/src/providers/ritekit/executors.js +2 -2
- package/src/providers/riveter/executors.js +2 -3
- package/src/providers/rocket_chat/executors.js +3 -4
- package/src/providers/rocket_reach/executors.js +3 -4
- package/src/providers/saucelabs/runtime.js +4 -4
- package/src/providers/scopus/runtime.js +3 -3
- package/src/providers/scrape_do/executors.js +2 -2
- package/src/providers/scraperapi/runtime.js +4 -4
- package/src/providers/scrapfly/executors.js +2 -2
- package/src/providers/scrapingant/executors.js +6 -7
- package/src/providers/scrapingbee/executors.js +3 -3
- package/src/providers/scrapingdog/executors.js +1 -1
- package/src/providers/screenshot_fyi/executors.js +3 -4
- package/src/providers/screenshotbase/runtime.js +3 -3
- package/src/providers/search_api/runtime.js +2 -2
- package/src/providers/securitytrails/executors.js +2 -2
- package/src/providers/semantic_scholar/executors.js +2 -2
- package/src/providers/sendbird/executors.js +2 -2
- package/src/providers/sendfox/executors.js +3 -3
- package/src/providers/sendgrid/executors.js +5 -5
- package/src/providers/sendmator/runtime.js +3 -4
- package/src/providers/seqera/runtime.js +3 -4
- package/src/providers/serveravatar/executors.js +3 -3
- package/src/providers/sheetdb/runtime.js +2 -2
- package/src/providers/short_menu/runtime.js +3 -3
- package/src/providers/shortcut/runtime.js +3 -3
- package/src/providers/shortpixel/runtime.js +2 -2
- package/src/providers/shotstack/runtime.js +4 -4
- package/src/providers/signpath/runtime.js +2 -2
- package/src/providers/signwell/runtime.js +5 -6
- package/src/providers/similarweb_digitalrank_api/runtime.js +3 -3
- package/src/providers/simla/runtime.js +5 -5
- package/src/providers/simplybook_me/executors.js +6 -6
- package/src/providers/sitespeakai/runtime.js +3 -3
- package/src/providers/slickdeals/runtime.js +2 -3
- package/src/providers/smartsuite/runtime.js +3 -3
- package/src/providers/sonarcloud/runtime.js +5 -5
- package/src/providers/sorftime/runtime.js +8 -8
- package/src/providers/spider/runtime.js +2 -2
- package/src/providers/splunk_http_event_collector/runtime.js +7 -8
- package/src/providers/sportsdata/runtime.js +4 -4
- package/src/providers/spyfu/runtime.js +4 -5
- package/src/providers/square/runtime.js +4 -4
- package/src/providers/stannp/runtime.js +2 -2
- package/src/providers/stripe/executors.js +2 -2
- package/src/providers/supermemory/runtime.js +3 -3
- package/src/providers/survey_monkey/runtime.js +3 -3
- package/src/providers/taiga/runtime.js +4 -4
- package/src/providers/talenox/executors.js +4 -4
- package/src/providers/tally/runtime.js +3 -3
- package/src/providers/tavily/runtime.js +3 -4
- package/src/providers/teamcamp/executors.js +2 -2
- package/src/providers/teamtailor/executors.js +2 -2
- package/src/providers/telegram/executors.js +6 -7
- package/src/providers/teltel/executors.js +2 -2
- package/src/providers/templated/executors.js +3 -3
- package/src/providers/tencent_docs/runtime.js +4 -4
- package/src/providers/tencent_maps/runtime.js +3 -3
- package/src/providers/textcortex/runtime.js +3 -3
- package/src/providers/the_cat_api/runtime.js +3 -3
- package/src/providers/the_colony/runtime.js +3 -3
- package/src/providers/the_odds_api/runtime.js +3 -4
- package/src/providers/the_official_board/runtime.js +4 -4
- package/src/providers/thehive/runtime.js +1 -1
- package/src/providers/tikhub/endpoint-catalog.js +2 -3
- package/src/providers/tiktok_business/runtime.js +2 -2
- package/src/providers/timecamp/runtime.js +2 -2
- package/src/providers/timelink/runtime.js +2 -2
- package/src/providers/totp/runtime.js +4 -5
- package/src/providers/trawlingweb/runtime.js +2 -2
- package/src/providers/trilium/runtime.js +2 -2
- package/src/providers/triple_whale/runtime.js +3 -3
- package/src/providers/truvera/runtime.js +2 -2
- package/src/providers/tuskr/runtime.js +2 -2
- package/src/providers/typebot/runtime.js +2 -2
- package/src/providers/typeform/runtime.js +2 -2
- package/src/providers/uptimerobot/executors.js +3 -4
- package/src/providers/v2ex/runtime.js +8 -9
- package/src/providers/valyu/runtime.js +3 -3
- package/src/providers/vapi/runtime.js +4 -4
- package/src/providers/vectorshift/runtime.js +3 -3
- package/src/providers/venafitlsprotectcloud/runtime.js +2 -3
- package/src/providers/venafitlsprotectdatacenter/runtime.js +2 -3
- package/src/providers/vida/runtime.js +4 -4
- package/src/providers/vonage/runtime.js +3 -3
- package/src/providers/walmart_marketplace/runtime.js +5 -5
- package/src/providers/weatherapi/executors.js +3 -4
- package/src/providers/web_of_science/runtime.js +4 -4
- package/src/providers/web_of_science_expanded/runtime.js +9 -9
- package/src/providers/webex/runtime.js +3 -3
- package/src/providers/webinarjam/runtime.js +4 -4
- package/src/providers/webscraping_ai/runtime.js +3 -3
- package/src/providers/webvizio/runtime.js +3 -4
- package/src/providers/wecom_bot/smart-runtime.js +4 -5
- package/src/providers/wecom_mcp/runtime.js +3 -4
- package/src/providers/wejam_ai/runtime.js +3 -3
- package/src/providers/wolfram_alpha_api/runtime.js +3 -3
- package/src/providers/woocommerce/runtime.js +1 -1
- package/src/providers/woodpecker_co/executors.js +3 -4
- package/src/providers/woot/runtime.js +6 -6
- package/src/providers/workable/runtime.js +3 -3
- package/src/providers/workday/runtime.js +4 -4
- package/src/providers/workiom/runtime.js +2 -2
- package/src/providers/workiz/runtime.js +2 -2
- package/src/providers/workpath/executors.js +3 -4
- package/src/providers/worksnaps/executors.js +2 -2
- package/src/providers/y_gy/runtime.js +2 -2
- package/src/providers/zenscrape/runtime.js +3 -3
- package/src/providers/zep/runtime.js +4 -4
- package/src/providers/zeplin/runtime.js +2 -2
- package/src/providers/zhihu/executors.js +6 -6
- package/src/providers/zylvie/runtime.js +4 -4
- package/src/saas/saas-cleanup-service.d.ts +2 -0
- package/src/saas/saas-cleanup-service.js +2 -1
- package/src/saas/saas-execution-service.d.ts +1 -1
- package/src/server/actions/action-runner.js +1 -1
- package/src/server/api/auth.js +3 -0
- package/src/server/api/connection-routes.js +1 -1
- package/src/server/api/console-catalog-routes.js +1 -1
- package/src/server/api/console-oauth-routes.d.ts +3 -1
- package/src/server/api/console-oauth-routes.js +22 -9
- package/src/server/api/oauth-completion-page.d.ts +57 -0
- package/src/server/api/oauth-completion-page.js +135 -10
- package/src/server/api/openapi.d.ts +5 -0
- package/src/server/api/openapi.js +62 -2
- package/src/server/api/runtime-api.d.ts +2 -1
- package/src/server/api/runtime-app-routes.js +1 -1
- package/src/server/api/runtime-execution-routes.js +2 -1
- package/src/server/connect-app.d.ts +4 -0
- package/src/server/connect-app.js +14 -1
- package/src/server/connect-server.d.ts +6 -0
- package/src/server/connect-server.js +114 -4
- package/src/server/connector-runtime.d.ts +6 -8
- package/src/server/connector-runtime.js +8 -28
- package/src/server/proxy/proxy-runner.js +1 -1
- package/src/server/slack-event-verification.d.ts +37 -0
- package/src/server/slack-event-verification.js +91 -0
- package/src/server/storage/connection-request-store.d.ts +1 -1
- package/src/server/storage/connection-store.d.ts +1 -1
- package/src/server/storage/postgres/runtime-store.d.ts +1 -1
- package/src/server/storage/runtime-database.d.ts +1 -1
- package/src/server/storage/saas-project-store.d.ts +1 -1
- package/src/triggers/maintenance.d.ts +2 -0
- package/src/triggers/maintenance.js +2 -1
- package/src/triggers/sources/slack-signature.d.ts +10 -0
- package/src/triggers/sources/slack-signature.js +13 -0
- package/src/triggers/sources/slack.js +9 -11
- package/src/triggers/trigger-runner.js +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject, optionalBoolean, optionalInteger, optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
|
-
import { ProviderRequestError, providerUserAgent, requiredInputString, requiredResponseRecord, } from "../provider-runtime.js";
|
|
2
|
+
import { ProviderRequestError, providerUserAgent, requiredInputString, requiredResponseRecord, providerInputError, } from "../provider-runtime.js";
|
|
3
3
|
export const contentfulApiBaseUrl = "https://api.contentful.com";
|
|
4
4
|
export const contentfulJsonContentType = "application/vnd.contentful.management.v1+json";
|
|
5
5
|
export const contentfulActionHandlers = {
|
|
@@ -263,7 +263,7 @@ function buildContentfulHeaders(apiKey, extraHeaders, includeJsonContentType = f
|
|
|
263
263
|
function createContentfulError(response, payload, notFoundMessage, invalidInputMessage) {
|
|
264
264
|
const message = optionalString(optionalRecord(payload)?.message);
|
|
265
265
|
if (response.status === 404 && notFoundMessage) {
|
|
266
|
-
return
|
|
266
|
+
return providerInputError(notFoundMessage);
|
|
267
267
|
}
|
|
268
268
|
if (response.status === 400) {
|
|
269
269
|
return new ProviderRequestError(400, message ?? "invalid Contentful request");
|
|
@@ -272,7 +272,7 @@ async function readContentstackPayload(response) {
|
|
|
272
272
|
function createContentstackError(status, payload, phase) {
|
|
273
273
|
const message = extractContentstackErrorMessage(payload) ?? `Contentstack Content Delivery request failed with status ${status}`;
|
|
274
274
|
if (phase === "validate" && status >= 400 && status < 500) {
|
|
275
|
-
return
|
|
275
|
+
return providerInputError(message);
|
|
276
276
|
}
|
|
277
277
|
if (status >= 400 && status < 500) {
|
|
278
278
|
return new ProviderRequestError(status, message);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject, optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
|
-
import { ProviderRequestError, providerUserAgent, runProviderRequest } from "../provider-runtime.js";
|
|
2
|
+
import { ProviderRequestError, providerUserAgent, runProviderRequest, providerInputError, } from "../provider-runtime.js";
|
|
3
3
|
export const cronlyApiBaseUrl = "https://cronly.app/api";
|
|
4
4
|
export const cronlyActionHandlers = {
|
|
5
5
|
async list_projects(_input, context) {
|
|
@@ -109,7 +109,7 @@ function createCronlyError(status, payload, phase) {
|
|
|
109
109
|
if (status === 429)
|
|
110
110
|
return new ProviderRequestError(429, message);
|
|
111
111
|
if (phase === "validate" && (status === 200 || (400 <= status && status < 500)))
|
|
112
|
-
return
|
|
112
|
+
return providerInputError(message);
|
|
113
113
|
if (400 <= status && status < 500)
|
|
114
114
|
return new ProviderRequestError(status, message);
|
|
115
115
|
return new ProviderRequestError(status === 200 ? 502 : status || 500, message);
|
|
@@ -411,7 +411,7 @@ function createCrossrefError(status, payload, phase, hasApiKey) {
|
|
|
411
411
|
return new ProviderRequestError(403, `${message}. Crossref has blocked this request pool; contact Crossref support if the block persists.`);
|
|
412
412
|
}
|
|
413
413
|
if (status === 401 && phase === "validate") {
|
|
414
|
-
return
|
|
414
|
+
return providerInputError(message);
|
|
415
415
|
}
|
|
416
416
|
if (status === 401 && hasApiKey) {
|
|
417
417
|
return new ProviderRequestError(401, message);
|
|
@@ -592,7 +592,7 @@ function normalizeDoi(value) {
|
|
|
592
592
|
function readMessageObject(payload, message) {
|
|
593
593
|
const record = optionalRecord(payload.message);
|
|
594
594
|
if (!record) {
|
|
595
|
-
throw
|
|
595
|
+
throw providerResponseError(message);
|
|
596
596
|
}
|
|
597
597
|
return record;
|
|
598
598
|
}
|
|
@@ -761,4 +761,4 @@ function numberToString(value) {
|
|
|
761
761
|
import { Buffer } from "node:buffer";
|
|
762
762
|
import { createHash, createHmac, timingSafeEqual } from "node:crypto";
|
|
763
763
|
import { compactObject, optionalInteger, optionalNumber, optionalRecord, optionalString, requiredString, } from "../../core/cast.js";
|
|
764
|
-
import { providerInputError, providerUserAgent, ProviderRequestError, runProviderRequest, } from "../provider-runtime.js";
|
|
764
|
+
import { providerInputError, providerUserAgent, ProviderRequestError, runProviderRequest, providerResponseError, } from "../provider-runtime.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject, optionalBoolean, optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
|
-
import { providerUserAgent, ProviderRequestError } from "../provider-runtime.js";
|
|
2
|
+
import { providerUserAgent, ProviderRequestError, providerInputError, providerResponseError, } from "../provider-runtime.js";
|
|
3
3
|
export const cuttlyApiBaseUrl = "https://cutt.ly";
|
|
4
4
|
const cuttlyApiPath = "/api/api.php";
|
|
5
5
|
const cuttlyValidationProbeUrl = "not-a-valid-url";
|
|
@@ -237,9 +237,9 @@ function mapCuttlyMessageToError(message, mode) {
|
|
|
237
237
|
normalized.includes("not a link") ||
|
|
238
238
|
normalized.includes("url does not exist") ||
|
|
239
239
|
normalized.includes("do not own")) {
|
|
240
|
-
return
|
|
240
|
+
return providerInputError(message);
|
|
241
241
|
}
|
|
242
|
-
return
|
|
242
|
+
return providerResponseError(message);
|
|
243
243
|
}
|
|
244
244
|
function createCuttlyAuthError(mode, message) {
|
|
245
245
|
return new ProviderRequestError(mode === "validate" ? 400 : 401, message);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { compactObject, optionalBoolean, optionalInteger, optionalRecord, optionalString, recordOrEmpty, } from "../../core/cast.js";
|
|
2
2
|
import { encodePathSegment } from "../../core/request.js";
|
|
3
|
-
import { ProviderRequestError, providerUserAgent } from "../provider-runtime.js";
|
|
3
|
+
import { ProviderRequestError, providerUserAgent, providerInputError } from "../provider-runtime.js";
|
|
4
4
|
export const cyberimpactApiBaseUrl = "https://api.cyberimpact.com";
|
|
5
5
|
export const cyberimpactActionHandlers = {
|
|
6
6
|
list_members(input, context) {
|
|
@@ -211,7 +211,7 @@ function normalizePaginatedPayload(payload, fieldName) {
|
|
|
211
211
|
function createCyberimpactError(status, payload, phase) {
|
|
212
212
|
const message = readErrorMessage(payload) ?? `Cyberimpact request failed with status ${status}`;
|
|
213
213
|
if (phase === "validate" && (status === 401 || status === 403))
|
|
214
|
-
return
|
|
214
|
+
return providerInputError(message);
|
|
215
215
|
return new ProviderRequestError(status || 502, message);
|
|
216
216
|
}
|
|
217
217
|
function readErrorMessage(payload) {
|
|
@@ -222,5 +222,5 @@ function readErrorMessage(payload) {
|
|
|
222
222
|
}
|
|
223
223
|
function assertAtLeastOne(input, keys, message) {
|
|
224
224
|
if (keys.every((key) => input[key] === undefined))
|
|
225
|
-
throw
|
|
225
|
+
throw providerInputError(message);
|
|
226
226
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject, optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
|
-
import { defineProviderExecutors, defineProviderProxy, providerUserAgent, ProviderRequestError, requireApiKeyCredential, } from "../provider-runtime.js";
|
|
2
|
+
import { defineProviderExecutors, defineProviderProxy, providerUserAgent, ProviderRequestError, requireApiKeyCredential, defaultProviderRequestTimeoutMs, } from "../provider-runtime.js";
|
|
3
3
|
const service = "dachser";
|
|
4
4
|
const apiBaseUrl = "https://api-gateway.dachser.com";
|
|
5
5
|
const validationTrackingNumber = "OPEN-CONNECTOR-CREDENTIAL-CHECK";
|
|
@@ -100,7 +100,7 @@ async function requestDachser(context, request) {
|
|
|
100
100
|
if (value !== undefined)
|
|
101
101
|
url.searchParams.set(name, String(value));
|
|
102
102
|
}
|
|
103
|
-
const timeoutSignal = AbortSignal.timeout(
|
|
103
|
+
const timeoutSignal = AbortSignal.timeout(defaultProviderRequestTimeoutMs);
|
|
104
104
|
const signal = context.signal ? AbortSignal.any([context.signal, timeoutSignal]) : timeoutSignal;
|
|
105
105
|
const headers = new Headers({
|
|
106
106
|
accept: "application/json",
|
|
@@ -182,7 +182,7 @@ async function readJsonPayload(response) {
|
|
|
182
182
|
function createDailybotError(status, payload, phase) {
|
|
183
183
|
const message = extractDailybotMessage(payload) ?? `Dailybot request failed with ${status || 500}`;
|
|
184
184
|
if (phase === "validate" && (status === 401 || status === 403))
|
|
185
|
-
return
|
|
185
|
+
return providerInputError(message);
|
|
186
186
|
return new ProviderRequestError(status || 500, message);
|
|
187
187
|
}
|
|
188
188
|
function extractDailybotMessage(payload) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { compactObject, optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
2
|
import { encodePathSegment } from "../../core/request.js";
|
|
3
|
-
import { ProviderRequestError, providerUserAgent, runProviderRequest } from "../provider-runtime.js";
|
|
3
|
+
import { ProviderRequestError, providerUserAgent, runProviderRequest, providerInputError, } from "../provider-runtime.js";
|
|
4
4
|
const databoxApiBaseUrl = "https://api.databox.com";
|
|
5
5
|
const validateKeyPath = "/v1/auth/validate-key";
|
|
6
6
|
export const databoxActionHandlers = {
|
|
@@ -121,7 +121,7 @@ async function readDataboxPayload(response) {
|
|
|
121
121
|
function createDataboxError(status, payload, phase) {
|
|
122
122
|
const message = extractDataboxErrorMessage(payload) ?? `Databox request failed with status ${status}`;
|
|
123
123
|
if (phase === "validate" && status >= 400 && status < 500)
|
|
124
|
-
return
|
|
124
|
+
return providerInputError(message);
|
|
125
125
|
return new ProviderRequestError(status || 500, message);
|
|
126
126
|
}
|
|
127
127
|
function extractDataboxErrorMessage(payload) {
|
|
@@ -143,7 +143,7 @@ export function normalizeDatabricksHost(value) {
|
|
|
143
143
|
const candidate = raw.includes("://") ? raw : `https://${raw}`;
|
|
144
144
|
const url = assertPublicHttpUrl(candidate, {
|
|
145
145
|
fieldName: "host",
|
|
146
|
-
createError:
|
|
146
|
+
createError: providerInputError,
|
|
147
147
|
});
|
|
148
148
|
if (url.protocol !== "https:")
|
|
149
149
|
throw new ProviderRequestError(400, "host must use HTTPS");
|
|
@@ -597,7 +597,7 @@ function parsePayload(text, contentType) {
|
|
|
597
597
|
function createDatabricksError(response, payload, phase) {
|
|
598
598
|
const message = extractErrorMessage(payload) ?? response.statusText ?? "Databricks request failed";
|
|
599
599
|
if (phase === "validate" && (response.status === 401 || response.status === 403))
|
|
600
|
-
return
|
|
600
|
+
return providerInputError(message);
|
|
601
601
|
return new ProviderRequestError(response.status || 500, message, payload);
|
|
602
602
|
}
|
|
603
603
|
function extractErrorMessage(payload) {
|
|
@@ -129,7 +129,7 @@ function createDataciteError(status, payload, phase) {
|
|
|
129
129
|
return new ProviderRequestError(429, message);
|
|
130
130
|
}
|
|
131
131
|
if (phase === "validate" && (status === 401 || status === 403)) {
|
|
132
|
-
return
|
|
132
|
+
return providerInputError(message);
|
|
133
133
|
}
|
|
134
134
|
if (status === 401 || status === 403) {
|
|
135
135
|
return new ProviderRequestError(400, message, status);
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { compactObject, optionalBoolean, optionalNumber, optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
|
-
import { createProviderProxyUrl, defineProviderExecutors, isAbortLikeError, normalizeProviderProxyHeaders, providerFetch, ProviderRequestError, providerUserAgent, readProviderProxyErrorMessage, readProviderProxyResponse, toProviderProxyError, } from "../provider-runtime.js";
|
|
2
|
+
import { createProviderProxyUrl, defineProviderExecutors, isAbortLikeError, normalizeProviderProxyHeaders, providerFetch, ProviderRequestError, providerUserAgent, readProviderProxyErrorMessage, readProviderProxyResponse, toProviderProxyError, defaultProviderRequestTimeoutMs, } from "../provider-runtime.js";
|
|
3
3
|
import { datadogApiKeySites, datadogOAuthSites } from "./sites.js";
|
|
4
4
|
const service = "datadog";
|
|
5
|
-
const datadogDefaultRequestTimeoutMs = 30_000;
|
|
6
5
|
const datadogCredentialHelpUrl = "https://docs.datadoghq.com/account_management/api-app-keys/";
|
|
7
6
|
export const datadogActionHandlers = {
|
|
8
7
|
validate_api_key(_input, context) {
|
|
@@ -257,8 +256,8 @@ async function datadogRequestJson(path, request, context) {
|
|
|
257
256
|
}
|
|
258
257
|
}
|
|
259
258
|
const signal = context.signal
|
|
260
|
-
? AbortSignal.any([context.signal, AbortSignal.timeout(
|
|
261
|
-
: AbortSignal.timeout(
|
|
259
|
+
? AbortSignal.any([context.signal, AbortSignal.timeout(defaultProviderRequestTimeoutMs)])
|
|
260
|
+
: AbortSignal.timeout(defaultProviderRequestTimeoutMs);
|
|
262
261
|
let response;
|
|
263
262
|
let payload;
|
|
264
263
|
try {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { optionalNumber, optionalRecord, optionalString, compactObject, optionalInteger, optionalBoolean, } from "../../core/cast.js";
|
|
2
|
-
import { createProviderTimeout, providerUserAgent, ProviderRequestError } from "../provider-runtime.js";
|
|
2
|
+
import { createProviderTimeout, providerUserAgent, ProviderRequestError, providerInputError, } from "../provider-runtime.js";
|
|
3
3
|
export const datascopeApiBaseUrl = "https://www.mydatascope.com/api/external/";
|
|
4
4
|
const answerReservedKeys = new Set([
|
|
5
5
|
"form_id",
|
|
@@ -238,7 +238,7 @@ function createDatascopeHttpError(status, payload, phase) {
|
|
|
238
238
|
return new ProviderRequestError(phase === "validate" ? 400 : 401, message);
|
|
239
239
|
}
|
|
240
240
|
if (status === 400 || status === 422) {
|
|
241
|
-
return
|
|
241
|
+
return providerInputError(message);
|
|
242
242
|
}
|
|
243
243
|
if (status === 429) {
|
|
244
244
|
return new ProviderRequestError(429, message);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
|
-
import { createProviderTimeout, defineApiKeyProviderExecutors, defineProviderProxy, ProviderRequestError, providerUserAgent, } from "../provider-runtime.js";
|
|
2
|
+
import { createProviderTimeout, defineApiKeyProviderExecutors, defineProviderProxy, ProviderRequestError, providerUserAgent, providerInputError, } from "../provider-runtime.js";
|
|
3
3
|
const service = "daytona";
|
|
4
4
|
const daytonaApiBaseUrl = "https://app.daytona.io/api";
|
|
5
5
|
export const executors = defineApiKeyProviderExecutors(service, {
|
|
@@ -150,10 +150,10 @@ function mapError(response, payload, phase) {
|
|
|
150
150
|
if (response.status === 429)
|
|
151
151
|
return new ProviderRequestError(429, message);
|
|
152
152
|
if (phase === "validate" && response.status >= 400 && response.status < 500)
|
|
153
|
-
return
|
|
153
|
+
return providerInputError(message);
|
|
154
154
|
if (response.status === 401 || response.status === 403)
|
|
155
155
|
return new ProviderRequestError(401, message);
|
|
156
156
|
if (response.status >= 400 && response.status < 500)
|
|
157
|
-
return
|
|
157
|
+
return providerInputError(message);
|
|
158
158
|
return new ProviderRequestError(response.status || 500, message);
|
|
159
159
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { optionalNumber, nullableString, optionalRecord, optionalString, compactObject, optionalBoolean, recordOrEmpty, } from "../../core/cast.js";
|
|
2
2
|
import { encodePathSegment } from "../../core/request.js";
|
|
3
|
-
import { providerUserAgent, ProviderRequestError, runProviderRequest } from "../provider-runtime.js";
|
|
3
|
+
import { providerUserAgent, ProviderRequestError, runProviderRequest, providerInputError, } from "../provider-runtime.js";
|
|
4
4
|
export const deepgramApiBaseUrl = "https://api.deepgram.com/v1";
|
|
5
5
|
export const deepgramActionHandlers = {
|
|
6
6
|
async list_projects(_input, fetcher, apiKey) {
|
|
@@ -168,7 +168,7 @@ function createDeepgramError(status, payload, phase) {
|
|
|
168
168
|
return new ProviderRequestError(429, message);
|
|
169
169
|
}
|
|
170
170
|
if (phase === "validate" && status >= 400 && status < 500) {
|
|
171
|
-
return
|
|
171
|
+
return providerInputError(message);
|
|
172
172
|
}
|
|
173
173
|
if (phase === "execute" && (status === 401 || status === 403)) {
|
|
174
174
|
return new ProviderRequestError(401, message);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject, optionalBoolean, optionalNumber, optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
|
-
import { createProviderTimeout, providerUserAgent, ProviderRequestError } from "../provider-runtime.js";
|
|
2
|
+
import { createProviderTimeout, providerUserAgent, ProviderRequestError, providerInputError, providerResponseError, } from "../provider-runtime.js";
|
|
3
3
|
export const deeplApiBaseUrl = "https://api.deepl.com";
|
|
4
4
|
export const deeplApiFreeBaseUrl = "https://api-free.deepl.com";
|
|
5
5
|
export const deeplTranslatePath = "/v2/translate";
|
|
@@ -130,13 +130,13 @@ async function readDeeplPayload(response) {
|
|
|
130
130
|
function createDeeplHttpError(status, payload, mode) {
|
|
131
131
|
const message = extractDeeplErrorMessage(payload) ?? `DeepL request failed with status ${status}`;
|
|
132
132
|
if (status === 400) {
|
|
133
|
-
return
|
|
133
|
+
return providerInputError(message);
|
|
134
134
|
}
|
|
135
135
|
if (status === 401 || status === 403) {
|
|
136
|
-
return
|
|
136
|
+
return providerInputError(message);
|
|
137
137
|
}
|
|
138
138
|
if (status === 404) {
|
|
139
|
-
return
|
|
139
|
+
return providerResponseError(message);
|
|
140
140
|
}
|
|
141
141
|
if (status === 429 || status === 456) {
|
|
142
142
|
return new ProviderRequestError(429, message);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject, optionalBoolean, optionalNumber, optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
|
-
import { createProviderTimeout, defineProviderExecutors, defineProviderProxy, providerUserAgent, ProviderRequestError, readProviderTextBody, requireApiKeyCredential, } from "../provider-runtime.js";
|
|
2
|
+
import { createProviderTimeout, defineProviderExecutors, defineProviderProxy, providerUserAgent, ProviderRequestError, readProviderTextBody, requireApiKeyCredential, providerResponseError, } from "../provider-runtime.js";
|
|
3
3
|
const detrackApiBaseUrl = "https://app.detrack.com/api/v2";
|
|
4
4
|
const detrackMaxResponseBytes = 10 * 1024 * 1024;
|
|
5
5
|
export const detrackActionHandlers = {
|
|
@@ -383,7 +383,7 @@ function createDetrackError(response, payload, phase) {
|
|
|
383
383
|
return new ProviderRequestError(429, message);
|
|
384
384
|
}
|
|
385
385
|
if (response.status >= 500) {
|
|
386
|
-
return
|
|
386
|
+
return providerResponseError(message);
|
|
387
387
|
}
|
|
388
388
|
if (phase === "validate") {
|
|
389
389
|
return new ProviderRequestError(response.status || 400, message);
|
|
@@ -426,19 +426,19 @@ function requireDetrackEnvelope(value) {
|
|
|
426
426
|
function requireObject(value, message) {
|
|
427
427
|
const object = optionalRecord(value);
|
|
428
428
|
if (!object) {
|
|
429
|
-
throw
|
|
429
|
+
throw providerResponseError(message);
|
|
430
430
|
}
|
|
431
431
|
return object;
|
|
432
432
|
}
|
|
433
433
|
function requireArray(value, message) {
|
|
434
434
|
if (!Array.isArray(value)) {
|
|
435
|
-
throw
|
|
435
|
+
throw providerResponseError(message);
|
|
436
436
|
}
|
|
437
437
|
return value;
|
|
438
438
|
}
|
|
439
439
|
function requireNumber(value, message) {
|
|
440
440
|
if (typeof value !== "number") {
|
|
441
|
-
throw
|
|
441
|
+
throw providerResponseError(message);
|
|
442
442
|
}
|
|
443
443
|
return value;
|
|
444
444
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject } from "../../core/cast.js";
|
|
2
|
-
import { ProviderRequestError } from "../provider-runtime.js";
|
|
2
|
+
import { ProviderRequestError, providerInputError } from "../provider-runtime.js";
|
|
3
3
|
export const deutschlandgptApiBaseUrl = "https://api.deutschlandgpt.de/v2";
|
|
4
4
|
export const deutschlandgptActionHandlers = {
|
|
5
5
|
list_models(_input, context) {
|
|
@@ -93,6 +93,6 @@ function mapError(status, payload, validating) {
|
|
|
93
93
|
? record.message
|
|
94
94
|
: `DeutschlandGPT request failed with HTTP ${status}`;
|
|
95
95
|
if ((status === 401 || status === 403) && validating)
|
|
96
|
-
return
|
|
96
|
+
return providerInputError(message);
|
|
97
97
|
return new ProviderRequestError(status, message);
|
|
98
98
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject, optionalRawString, optionalRecord, optionalString, requiredString } from "../../core/cast.js";
|
|
2
|
-
import { ProviderRequestError, providerUserAgent, requiredResponseRecord, runProviderRequest, } from "../provider-runtime.js";
|
|
2
|
+
import { ProviderRequestError, providerUserAgent, requiredResponseRecord, runProviderRequest, providerInputError, } from "../provider-runtime.js";
|
|
3
3
|
export const dialMyCallsApiBaseUrl = "https://api.dialmycalls.com/2.0";
|
|
4
4
|
export const dialMyCallsActionHandlers = {
|
|
5
5
|
async get_account(_input, fetcher, apiKey) {
|
|
@@ -114,7 +114,7 @@ export const dialMyCallsActionHandlers = {
|
|
|
114
114
|
};
|
|
115
115
|
export async function validateDialMyCallsCredential(input, fetcher) {
|
|
116
116
|
const payload = await requestDialMyCallsJson({
|
|
117
|
-
apiKey: requiredString(input.apiKey, "apiKey",
|
|
117
|
+
apiKey: requiredString(input.apiKey, "apiKey", providerInputError),
|
|
118
118
|
path: "/account",
|
|
119
119
|
fetcher,
|
|
120
120
|
phase: "validate",
|
|
@@ -140,7 +140,7 @@ export async function executeDialMyCallsAction(input, fetcher) {
|
|
|
140
140
|
if (!handler) {
|
|
141
141
|
throw new ProviderRequestError(500, `dialmycalls action is not implemented yet: ${input.actionName}`);
|
|
142
142
|
}
|
|
143
|
-
return handler(input.input, fetcher, requiredString(input.apiKey, "apiKey",
|
|
143
|
+
return handler(input.input, fetcher, requiredString(input.apiKey, "apiKey", providerInputError));
|
|
144
144
|
}
|
|
145
145
|
async function requestDialMyCallsJson(input) {
|
|
146
146
|
return runProviderRequest({ label: "DialMyCalls" }, async (signal) => {
|
|
@@ -194,7 +194,7 @@ function createDialMyCallsError(status, payload, phase) {
|
|
|
194
194
|
return new ProviderRequestError(429, message);
|
|
195
195
|
}
|
|
196
196
|
if (phase === "validate" && upstreamStatus >= 400 && upstreamStatus < 500) {
|
|
197
|
-
return
|
|
197
|
+
return providerInputError(message);
|
|
198
198
|
}
|
|
199
199
|
if (phase === "execute" && (upstreamStatus === 401 || upstreamStatus === 403)) {
|
|
200
200
|
return new ProviderRequestError(upstreamStatus, message);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { compactObject, optionalNumber, optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
2
|
import { assertPublicHttpUrl } from "../../core/request.js";
|
|
3
|
-
import { defineApiKeyProviderExecutors, defineProviderProxy, providerUserAgent, ProviderRequestError, } from "../provider-runtime.js";
|
|
3
|
+
import { defineApiKeyProviderExecutors, defineProviderProxy, providerUserAgent, ProviderRequestError, providerInputError, } from "../provider-runtime.js";
|
|
4
4
|
const service = "diffbot";
|
|
5
5
|
const diffbotApiOrigin = "https://api.diffbot.com";
|
|
6
6
|
const diffbotArticleRequestPath = "/v3/article";
|
|
@@ -65,7 +65,7 @@ function buildDiffbotArticleUrl(input, apiKey) {
|
|
|
65
65
|
}
|
|
66
66
|
const publicUrl = assertPublicHttpUrl(target, {
|
|
67
67
|
fieldName: "url",
|
|
68
|
-
createError:
|
|
68
|
+
createError: providerInputError,
|
|
69
69
|
});
|
|
70
70
|
if (publicUrl.protocol !== "https:" || publicUrl.username || publicUrl.password) {
|
|
71
71
|
throw new ProviderRequestError(400, "url must use https and must not include credentials");
|
|
@@ -129,10 +129,10 @@ function createDiffbotHttpError(status, raw, json, phase) {
|
|
|
129
129
|
return new ProviderRequestError(429, message);
|
|
130
130
|
}
|
|
131
131
|
if ((status === 401 || status === 403) && phase === "validate") {
|
|
132
|
-
return
|
|
132
|
+
return providerInputError(message);
|
|
133
133
|
}
|
|
134
134
|
if (status === 400) {
|
|
135
|
-
return
|
|
135
|
+
return providerInputError(message);
|
|
136
136
|
}
|
|
137
137
|
return new ProviderRequestError(status, message);
|
|
138
138
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject, optionalBoolean, optionalInteger, optionalNumber, optionalRecord, optionalString, } from "../../core/cast.js";
|
|
2
|
-
import { createProviderTimeout, defineProviderExecutors, defineProviderProxy, providerUserAgent, ProviderRequestError, readProviderTextBody, requireApiKeyCredential, } from "../provider-runtime.js";
|
|
2
|
+
import { createProviderTimeout, defineProviderExecutors, defineProviderProxy, providerUserAgent, ProviderRequestError, readProviderTextBody, requireApiKeyCredential, providerInputError, } from "../provider-runtime.js";
|
|
3
3
|
const digistore24ApiBaseUrl = "https://www.digistore24.com/api/call";
|
|
4
4
|
const digistore24MaxResponseBytes = 10 * 1024 * 1024;
|
|
5
5
|
export const digistore24ActionHandlers = {
|
|
@@ -245,13 +245,13 @@ function createDigistore24Error(status, statusText, payload, phase) {
|
|
|
245
245
|
return new ProviderRequestError(429, message);
|
|
246
246
|
}
|
|
247
247
|
else if (phase === "validate" && (status === 400 || status === 401 || status === 403)) {
|
|
248
|
-
return
|
|
248
|
+
return providerInputError(message);
|
|
249
249
|
}
|
|
250
250
|
else if (phase === "execute" && (status === 401 || status === 403)) {
|
|
251
251
|
return new ProviderRequestError(401, message);
|
|
252
252
|
}
|
|
253
253
|
else if (phase === "execute" && (status === 400 || status === 404 || status === 422)) {
|
|
254
|
-
return
|
|
254
|
+
return providerInputError(message);
|
|
255
255
|
}
|
|
256
256
|
else {
|
|
257
257
|
return new ProviderRequestError(status >= 500 ? 502 : status || 502, message);
|
|
@@ -234,7 +234,7 @@ function normalizeDingtalkBotError(result, phase) {
|
|
|
234
234
|
return new ProviderRequestError(phase === "validate" ? 400 : 401, message);
|
|
235
235
|
}
|
|
236
236
|
if (errcode === 310000 || errcode === 40035 || errcode === 400105) {
|
|
237
|
-
return
|
|
237
|
+
return providerInputError(message);
|
|
238
238
|
}
|
|
239
239
|
return new ProviderRequestError(result.status >= 400 ? result.status : 500, message);
|
|
240
240
|
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import type { CredentialValidators, ProviderExecutors, ProviderProxyExecutor } from "../../core/types.ts";
|
|
2
2
|
import type { ProviderActionHandlers } from "../provider-runtime.ts";
|
|
3
|
-
export declare const discourseDefaultRequestTimeoutMs = 30000;
|
|
4
3
|
interface DiscourseCredential {
|
|
5
4
|
baseUrl: string;
|
|
6
5
|
apiKey: string;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { createHash } from "node:crypto";
|
|
2
2
|
import { compactObject, optionalBoolean, optionalBooleanOrNull, optionalInteger, optionalString, rawStringOrNull, } from "../../core/cast.js";
|
|
3
3
|
import { assertPublicHttpUrl, isPrivateNetworkAccessAllowed } from "../../core/request.js";
|
|
4
|
-
import { createProviderFetch, createProviderTimeout, defineProviderExecutors, defineProviderProxy, ProviderRequestError, providerUserAgent, requireApiKeyCredential, } from "../provider-runtime.js";
|
|
5
|
-
export const discourseDefaultRequestTimeoutMs = 30_000;
|
|
4
|
+
import { createProviderFetch, createProviderTimeout, defineProviderExecutors, defineProviderProxy, ProviderRequestError, providerUserAgent, requireApiKeyCredential, providerInputError, defaultProviderRequestTimeoutMs, } from "../provider-runtime.js";
|
|
6
5
|
export const discourseActionHandlers = {
|
|
7
6
|
async list_latest_topics(input, context) {
|
|
8
7
|
const payload = await requestDiscourseJson({
|
|
@@ -227,7 +226,7 @@ export function normalizeDiscourseBaseUrl(value, allowPrivateNetwork = isPrivate
|
|
|
227
226
|
try {
|
|
228
227
|
url = assertPublicHttpUrl(value.trim(), {
|
|
229
228
|
fieldName: "baseUrl",
|
|
230
|
-
createError:
|
|
229
|
+
createError: providerInputError,
|
|
231
230
|
allowPrivateNetwork,
|
|
232
231
|
});
|
|
233
232
|
}
|
|
@@ -253,7 +252,7 @@ function resolveCredentialInput(input) {
|
|
|
253
252
|
};
|
|
254
253
|
}
|
|
255
254
|
async function requestDiscourseJson(input) {
|
|
256
|
-
const timeout = createProviderTimeout(input.signal
|
|
255
|
+
const timeout = createProviderTimeout(input.signal);
|
|
257
256
|
try {
|
|
258
257
|
const response = await input.fetcher(buildDiscourseUrl(input.credential.baseUrl, input.path, input.query), {
|
|
259
258
|
method: input.method,
|
|
@@ -277,7 +276,7 @@ async function requestDiscourseJson(input) {
|
|
|
277
276
|
throw error;
|
|
278
277
|
}
|
|
279
278
|
if (timeout.didTimeout()) {
|
|
280
|
-
throw new ProviderRequestError(504, `Discourse ${input.path} request timed out after ${Math.ceil(
|
|
279
|
+
throw new ProviderRequestError(504, `Discourse ${input.path} request timed out after ${Math.ceil(defaultProviderRequestTimeoutMs / 1000)} seconds`);
|
|
281
280
|
}
|
|
282
281
|
const message = error instanceof Error && error.message.trim() ? error.message : "request failed";
|
|
283
282
|
throw new ProviderRequestError(502, `Discourse ${input.path} request failed: ${message}`);
|
|
@@ -328,10 +327,10 @@ function mapDiscourseHttpError(input) {
|
|
|
328
327
|
return new ProviderRequestError(input.phase === "validate" ? 400 : 401, message);
|
|
329
328
|
}
|
|
330
329
|
if (input.status === 404 && input.notFoundAsInvalidInput) {
|
|
331
|
-
return
|
|
330
|
+
return providerInputError(message);
|
|
332
331
|
}
|
|
333
332
|
if (input.status === 400 || input.status === 422) {
|
|
334
|
-
return
|
|
333
|
+
return providerInputError(message);
|
|
335
334
|
}
|
|
336
335
|
return new ProviderRequestError(input.status >= 500 ? 502 : input.status || 502, message);
|
|
337
336
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject, optionalBoolean, optionalNumber, optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
|
-
import { providerUserAgent, ProviderRequestError, requiredInputString } from "../provider-runtime.js";
|
|
2
|
+
import { providerUserAgent, ProviderRequestError, requiredInputString, providerInputError, } from "../provider-runtime.js";
|
|
3
3
|
export const docugenerateValidationPath = "/template";
|
|
4
4
|
const docugenerateApiBaseUrlByRegion = {
|
|
5
5
|
us: "https://api.docugenerate.com/v1",
|
|
@@ -210,13 +210,13 @@ function createDocugenerateError(response, payload, phase) {
|
|
|
210
210
|
return new ProviderRequestError(429, message);
|
|
211
211
|
}
|
|
212
212
|
if (phase === "validate" && (response.status === 401 || response.status === 403)) {
|
|
213
|
-
return
|
|
213
|
+
return providerInputError(message);
|
|
214
214
|
}
|
|
215
215
|
if (phase === "execute" && (response.status === 401 || response.status === 403)) {
|
|
216
216
|
return new ProviderRequestError(response.status, message);
|
|
217
217
|
}
|
|
218
218
|
if (phase === "execute" && [400, 404, 422].includes(response.status)) {
|
|
219
|
-
return
|
|
219
|
+
return providerInputError(message);
|
|
220
220
|
}
|
|
221
221
|
return new ProviderRequestError(response.status >= 500 ? 502 : response.status, message);
|
|
222
222
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { optionalRecord, optionalString } from "../../core/cast.js";
|
|
2
|
-
import { ProviderRequestError } from "../provider-runtime.js";
|
|
2
|
+
import { ProviderRequestError, providerInputError } from "../provider-runtime.js";
|
|
3
3
|
export const dopplerApiBaseUrl = "https://api.doppler.com";
|
|
4
4
|
export async function dopplerRequest(accessToken, input, fetcher, phase) {
|
|
5
5
|
return (await dopplerRequestWithResponse(accessToken, input, fetcher, phase)).payload;
|
|
@@ -65,13 +65,13 @@ export function createDopplerError(response, payload, phase) {
|
|
|
65
65
|
return new ProviderRequestError(429, message);
|
|
66
66
|
}
|
|
67
67
|
if (phase === "validate" && (response.status === 401 || response.status === 403)) {
|
|
68
|
-
return
|
|
68
|
+
return providerInputError(message);
|
|
69
69
|
}
|
|
70
70
|
if (phase === "execute" && response.status === 401) {
|
|
71
71
|
return new ProviderRequestError(401, message);
|
|
72
72
|
}
|
|
73
73
|
if (response.status === 400 || response.status === 404) {
|
|
74
|
-
return
|
|
74
|
+
return providerInputError(message);
|
|
75
75
|
}
|
|
76
76
|
if (phase === "execute" && response.status === 403) {
|
|
77
77
|
return new ProviderRequestError(403, message);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { optionalBooleanOrNull, optionalRecord, optionalString, rawStringOrNull, requiredString, } from "../../core/cast.js";
|
|
2
|
-
import { createProviderTimeout, isAbortLikeError, ProviderRequestError, providerUserAgent, requiredResponseRecord, } from "../provider-runtime.js";
|
|
2
|
+
import { createProviderTimeout, isAbortLikeError, ProviderRequestError, providerUserAgent, requiredResponseRecord, providerInputError, } from "../provider-runtime.js";
|
|
3
3
|
export const dopplerMarketingAutomationApiBaseUrl = "https://restapi.fromdoppler.com";
|
|
4
4
|
export const dopplerMarketingAutomationActionHandlers = {
|
|
5
5
|
async list_lists(input, fetcher) {
|
|
@@ -146,7 +146,7 @@ function normalizeDopplerFields(value) {
|
|
|
146
146
|
});
|
|
147
147
|
}
|
|
148
148
|
export async function validateDopplerMarketingAutomationCredential(input, fetcher) {
|
|
149
|
-
const apiKey = requiredString(input.apiKey, "apiKey",
|
|
149
|
+
const apiKey = requiredString(input.apiKey, "apiKey", providerInputError);
|
|
150
150
|
const accountEmail = requireAccountEmail(input.accountEmail);
|
|
151
151
|
const validationPath = accountPath(accountEmail);
|
|
152
152
|
await requestDopplerMarketingJson({
|
|
@@ -238,7 +238,7 @@ function createDopplerMarketingError(status, statusText, payload, phase) {
|
|
|
238
238
|
return new ProviderRequestError(429, message);
|
|
239
239
|
}
|
|
240
240
|
if (phase === "validate" && (status === 401 || status === 403)) {
|
|
241
|
-
return
|
|
241
|
+
return providerInputError(message);
|
|
242
242
|
}
|
|
243
243
|
if (phase === "execute" && (status === 401 || status === 403)) {
|
|
244
244
|
return new ProviderRequestError(401, message);
|
|
@@ -332,7 +332,7 @@ function normalizeMessageResult(payload) {
|
|
|
332
332
|
}
|
|
333
333
|
function credentialContext(input) {
|
|
334
334
|
return {
|
|
335
|
-
apiKey: requiredString(input.apiKey, "apiKey",
|
|
335
|
+
apiKey: requiredString(input.apiKey, "apiKey", providerInputError),
|
|
336
336
|
accountEmail: requireAccountEmail(input.values?.accountEmail ?? optionalString(input.providerMetadata?.accountEmail)),
|
|
337
337
|
};
|
|
338
338
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compactObject } from "../../core/cast.js";
|
|
2
|
-
import { providerUserAgent, ProviderRequestError } from "../provider-runtime.js";
|
|
2
|
+
import { providerUserAgent, ProviderRequestError, providerInputError } from "../provider-runtime.js";
|
|
3
3
|
export const dovetailApiBaseUrl = "https://dovetail.com/api";
|
|
4
4
|
export const dovetailActionHandlers = {
|
|
5
5
|
get_token_info(input, context) {
|
|
@@ -211,7 +211,7 @@ function buildDovetailError(status, payload, phase) {
|
|
|
211
211
|
const message = extractDovetailErrorMessage(payload) ??
|
|
212
212
|
(phase === "validate" ? "invalid Dovetail personal API key" : `Dovetail request failed with ${status}`);
|
|
213
213
|
if (status === 400) {
|
|
214
|
-
return
|
|
214
|
+
return providerInputError(message);
|
|
215
215
|
}
|
|
216
216
|
if (status === 401) {
|
|
217
217
|
return new ProviderRequestError(phase === "validate" ? 400 : 401, message);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { optionalBoolean, optionalInteger, optionalRecord, optionalString, requiredString } from "../../core/cast.js";
|
|
2
|
-
import { createProviderTimeout, providerUserAgent, ProviderRequestError } from "../provider-runtime.js";
|
|
2
|
+
import { createProviderTimeout, providerUserAgent, ProviderRequestError, providerInputError, } from "../provider-runtime.js";
|
|
3
3
|
export const dropcontactApiBaseUrl = "https://api.dropcontact.com";
|
|
4
4
|
const textContactFields = [
|
|
5
5
|
"email",
|
|
@@ -30,7 +30,7 @@ export const dropcontactActionHandlers = {
|
|
|
30
30
|
return normalizeSubmission(payload);
|
|
31
31
|
},
|
|
32
32
|
async get_enrichment_result(input, context) {
|
|
33
|
-
const requestId = requiredString(input.request_id, "request_id",
|
|
33
|
+
const requestId = requiredString(input.request_id, "request_id", providerInputError);
|
|
34
34
|
const payload = await requestDropcontactJson({
|
|
35
35
|
method: "GET",
|
|
36
36
|
path: `/v1/enrich/all/${encodeURIComponent(requestId)}`,
|
|
@@ -123,7 +123,7 @@ function mapDropcontactError(status, payload, mode) {
|
|
|
123
123
|
return new ProviderRequestError(mode === "validate" ? 400 : 401, message);
|
|
124
124
|
}
|
|
125
125
|
if (status >= 400 && status < 500) {
|
|
126
|
-
return
|
|
126
|
+
return providerInputError(message);
|
|
127
127
|
}
|
|
128
128
|
return new ProviderRequestError(status >= 500 ? 502 : status, message);
|
|
129
129
|
}
|