@tangle-network/agent-integrations 0.72.0 → 0.74.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.
Files changed (35) hide show
  1. package/data/bundled-adapter-manifests.json +1 -1
  2. package/dist/{adapters-BU09k8Cr.js → adapters-CngYgl1W.js} +568 -648
  3. package/dist/{adapters-BU09k8Cr.js.map → adapters-CngYgl1W.js.map} +1 -1
  4. package/dist/{bundled-manifest-data-NtJ0vFHc.js → bundled-manifest-data-DituXLws.js} +276 -9
  5. package/dist/{bundled-manifest-data-NtJ0vFHc.js.map → bundled-manifest-data-DituXLws.js.map} +1 -1
  6. package/dist/cloudbeds-BL5EF3xl.js +1195 -0
  7. package/dist/cloudbeds-BL5EF3xl.js.map +1 -0
  8. package/dist/connect/index.js +1 -1
  9. package/dist/connectors/adapters/index.js +3 -2
  10. package/dist/connectors/index.js +5 -4
  11. package/dist/consumer.js +1 -1
  12. package/dist/index-udV3gGjx.d.ts.map +1 -1
  13. package/dist/index.js +7 -6
  14. package/dist/internal/bundled-manifest-runtime.js +1 -1
  15. package/dist/mcp.js +1 -1
  16. package/dist/middleware/index.js +1 -1
  17. package/dist/registry.js +1 -1
  18. package/dist/{specs-D5F9nOWX.js → specs-BeC45S22.js} +2 -2
  19. package/dist/{specs-D5F9nOWX.js.map → specs-BeC45S22.js.map} +1 -1
  20. package/dist/specs.js +1 -1
  21. package/dist/{src-CzkzOHaa.js → src-B4-qkoxS.js} +4 -4
  22. package/dist/{src-CzkzOHaa.js.map → src-B4-qkoxS.js.map} +1 -1
  23. package/dist/{tangle-id-D2kPF0rX.js → tangle-id-81ShqJ7k.js} +3 -262
  24. package/dist/tangle-id-81ShqJ7k.js.map +1 -0
  25. package/dist/types-BSDXGSi5.js +263 -0
  26. package/dist/types-BSDXGSi5.js.map +1 -0
  27. package/dist/webhooks/index.d.ts +5 -0
  28. package/dist/webhooks/index.d.ts.map +1 -1
  29. package/dist/webhooks/index.js +92 -2
  30. package/dist/webhooks/index.js.map +1 -1
  31. package/docs/hospitality-connectors.md +91 -11
  32. package/package.json +1 -1
  33. package/dist/tangle-id-D2kPF0rX.js.map +0 -1
  34. package/dist/webhooks-FsjqRN_0.js +0 -117
  35. package/dist/webhooks-FsjqRN_0.js.map +0 -1
@@ -1,7 +1,8 @@
1
1
  import { t as IntegrationRuntimeError } from "./errors-CvO_y8JO.js";
2
- import { a as TangleIdentityUnreachableError, c as CredentialsExpired, d as ProviderRateLimited, f as ProviderRequestError, i as TANGLE_SERVICE_TOKEN_PREFIX, l as InvalidCapabilityArgument, n as TANGLE_API_KEY_PREFIX, o as createTangleIdentityClient, p as ResourceContention, s as tangleIdentity, t as DEFAULT_TANGLE_PLATFORM_URL, u as ProviderConfigError } from "./tangle-id-D2kPF0rX.js";
2
+ import { a as ProviderRequestError, i as ProviderRateLimited, n as InvalidCapabilityArgument, o as ResourceContention, r as ProviderConfigError, t as CredentialsExpired } from "./types-BSDXGSi5.js";
3
+ import { a as TangleIdentityUnreachableError, i as TANGLE_SERVICE_TOKEN_PREFIX, n as TANGLE_API_KEY_PREFIX, o as createTangleIdentityClient, s as tangleIdentity, t as DEFAULT_TANGLE_PLATFORM_URL } from "./tangle-id-81ShqJ7k.js";
3
4
  import { createOAuthBasicAuthorizationHeader, exchangeAuthorizationCode, oauthClientCredentialRedactionValues, redactOAuthSensitiveText, refreshAccessToken } from "./connectors/oauth.js";
4
- import { n as firstHeader, o as verifySlackSignature, s as verifyStripeSignature } from "./webhooks-FsjqRN_0.js";
5
+ import { c as verifySlackSignature, i as firstHeader, l as verifyStripeSignature, n as cloudbedsConnector } from "./cloudbeds-BL5EF3xl.js";
5
6
  import { i as retryAfterMs$6, n as record$3, r as requestJson, t as ProviderProtocolError } from "./response-json-BnUINkTL.js";
6
7
  import { t as linqWhatsappAttachmentUrl } from "./linq-whatsapp-attachment-url-C9jHVGw5.js";
7
8
  import { createHash, createHmac, createSign, randomBytes, timingSafeEqual } from "node:crypto";
@@ -8056,7 +8057,7 @@ const message = {
8056
8057
  minLength: 1,
8057
8058
  maxLength: 18e3
8058
8059
  };
8059
- const base$11 = declarativeRestConnector({
8060
+ const base$12 = declarativeRestConnector({
8060
8061
  kind: "contiguity",
8061
8062
  displayName: "Contiguity",
8062
8063
  category: "crm",
@@ -8316,14 +8317,14 @@ const base$11 = declarativeRestConnector({
8316
8317
  ]
8317
8318
  });
8318
8319
  const contiguityConnector = {
8319
- ...base$11,
8320
+ ...base$12,
8320
8321
  async executeMutation(inv) {
8321
- if (inv.capabilityName !== "email.send") return base$11.executeMutation(inv);
8322
+ if (inv.capabilityName !== "email.send") return base$12.executeMutation(inv);
8322
8323
  const { body, contentType, ...args } = inv.args;
8323
8324
  if (typeof body !== "string" || !body.length || contentType !== void 0 && contentType !== "text/plain" && contentType !== "text/html") throw new Error("Contiguity email requires a body and supported contentType");
8324
8325
  delete args.text;
8325
8326
  delete args.html;
8326
- return base$11.executeMutation({
8327
+ return base$12.executeMutation({
8327
8328
  ...inv,
8328
8329
  args: {
8329
8330
  ...args,
@@ -8835,7 +8836,7 @@ function transcriptResponse(value) {
8835
8836
  language: "multi"
8836
8837
  };
8837
8838
  }
8838
- const base$10 = declarativeRestConnector({
8839
+ const base$11 = declarativeRestConnector({
8839
8840
  kind: "deepgram",
8840
8841
  displayName: "Deepgram",
8841
8842
  description: "Transcribe audio to text, synthesize text to speech, and analyze audio content with AI-powered speech recognition.",
@@ -9079,10 +9080,10 @@ const base$10 = declarativeRestConnector({
9079
9080
  ]
9080
9081
  });
9081
9082
  const deepgramConnector = {
9082
- ...base$10,
9083
+ ...base$11,
9083
9084
  manifest: {
9084
- ...base$10.manifest,
9085
- capabilities: [...base$10.manifest.capabilities, {
9085
+ ...base$11.manifest,
9086
+ capabilities: [...base$11.manifest.capabilities, {
9086
9087
  name: "transcription.bytes",
9087
9088
  class: "mutation",
9088
9089
  cas: "none",
@@ -9109,7 +9110,7 @@ const deepgramConnector = {
9109
9110
  }]
9110
9111
  },
9111
9112
  async executeMutation(inv) {
9112
- if (inv.capabilityName !== "transcription.bytes") return base$10.executeMutation(inv);
9113
+ if (inv.capabilityName !== "transcription.bytes") return base$11.executeMutation(inv);
9113
9114
  const { bytes, contentType } = privateAudio(inv.args);
9114
9115
  if (inv.source.credentials.kind !== "api-key" || !inv.source.credentials.apiKey || /[\u0000-\u0020\u007f]/.test(inv.source.credentials.apiKey)) throw new IntegrationRuntimeError({
9115
9116
  code: "provider_auth_failed",
@@ -10211,7 +10212,7 @@ const echowinConnector = declarativeRestConnector({
10211
10212
  */
10212
10213
  const ELEVENLABS_BASE_URL = "https://api.elevenlabs.io";
10213
10214
  const MAX_SAMPLE_BYTES = 11e6;
10214
- const base$9 = declarativeRestConnector({
10215
+ const base$10 = declarativeRestConnector({
10215
10216
  kind: "elevenlabs",
10216
10217
  displayName: "ElevenLabs",
10217
10218
  description: "Your own ElevenLabs account: text to speech, voices, instant voice clones of your own voice, speech to text, and conversational voice agents.",
@@ -10328,11 +10329,11 @@ const base$9 = declarativeRestConnector({
10328
10329
  ]
10329
10330
  });
10330
10331
  const elevenlabsConnector = {
10331
- ...base$9,
10332
+ ...base$10,
10332
10333
  manifest: {
10333
- ...base$9.manifest,
10334
+ ...base$10.manifest,
10334
10335
  capabilities: [
10335
- ...base$9.manifest.capabilities,
10336
+ ...base$10.manifest.capabilities,
10336
10337
  {
10337
10338
  name: "voices.clone_instant",
10338
10339
  class: "mutation",
@@ -10443,7 +10444,7 @@ const elevenlabsConnector = {
10443
10444
  ]
10444
10445
  },
10445
10446
  async executeRead(inv) {
10446
- if (inv.capabilityName !== "speech_to_text") return base$9.executeRead(inv);
10447
+ if (inv.capabilityName !== "speech_to_text") return base$10.executeRead(inv);
10447
10448
  const audioUrl = httpsUrl(inv.args.audioUrl, "audioUrl");
10448
10449
  const form = new FormData();
10449
10450
  form.append("model_id", "scribe_v1");
@@ -10511,7 +10512,7 @@ const elevenlabsConnector = {
10511
10512
  idempotentReplay: false
10512
10513
  };
10513
10514
  }
10514
- return base$9.executeMutation(inv);
10515
+ return base$10.executeMutation(inv);
10515
10516
  }
10516
10517
  };
10517
10518
  function invalid(message) {
@@ -27056,7 +27057,7 @@ function arbitraryBodyParameters() {
27056
27057
  }
27057
27058
  //#endregion
27058
27059
  //#region src/connectors/adapters/amplitude.ts
27059
- const date$4 = {
27060
+ const date$3 = {
27060
27061
  type: "string",
27061
27062
  pattern: "^[0-9]{8}$",
27062
27063
  description: "Inclusive date in YYYYMMDD format."
@@ -27173,8 +27174,8 @@ const amplitudeConnector = declarativeRestConnector({
27173
27174
  type: "string",
27174
27175
  enum: ["any", "active"]
27175
27176
  },
27176
- start: date$4,
27177
- end: date$4,
27177
+ start: date$3,
27178
+ end: date$3,
27178
27179
  interval: {
27179
27180
  type: "integer",
27180
27181
  enum: [
@@ -27240,8 +27241,8 @@ const amplitudeConnector = declarativeRestConnector({
27240
27241
  parameters: {
27241
27242
  type: "object",
27242
27243
  properties: {
27243
- start: date$4,
27244
- end: date$4,
27244
+ start: date$3,
27245
+ end: date$3,
27245
27246
  mode: {
27246
27247
  type: "string",
27247
27248
  enum: ["active", "new"]
@@ -27282,8 +27283,8 @@ const amplitudeConnector = declarativeRestConnector({
27282
27283
  parameters: {
27283
27284
  type: "object",
27284
27285
  properties: {
27285
- start: date$4,
27286
- end: date$4
27286
+ start: date$3,
27287
+ end: date$3
27287
27288
  },
27288
27289
  required: ["start", "end"]
27289
27290
  },
@@ -48775,7 +48776,7 @@ const SCOPE_SEND$1 = "https://www.googleapis.com/auth/gmail.send";
48775
48776
  const SCOPE_MODIFY = "https://www.googleapis.com/auth/gmail.modify";
48776
48777
  const AUTH_URL$17 = "https://accounts.google.com/o/oauth2/v2/auth";
48777
48778
  const TOKEN_URL$20 = "https://oauth2.googleapis.com/token";
48778
- const API$13 = "https://gmail.googleapis.com/gmail/v1/users/me";
48779
+ const API$12 = "https://gmail.googleapis.com/gmail/v1/users/me";
48779
48780
  function gmail(opts) {
48780
48781
  const { clientId, clientSecret } = opts;
48781
48782
  const timeoutMs = opts.timeoutMs ?? 3e4;
@@ -49003,7 +49004,7 @@ function gmail(opts) {
49003
49004
  async test(source) {
49004
49005
  try {
49005
49006
  const accessToken = await ensureFreshAccessToken$14(source.credentials, clientId, clientSecret);
49006
- const res = await fetch(`${API$13}/profile`, {
49007
+ const res = await fetch(`${API$12}/profile`, {
49007
49008
  headers: { authorization: `Bearer ${accessToken}` },
49008
49009
  signal: AbortSignal.timeout(8e3)
49009
49010
  });
@@ -49030,7 +49031,7 @@ async function listMessages$1(inv, accessToken, timeoutMs) {
49030
49031
  for (const id of args.labelIds ?? ["INBOX"]) params.append("labelIds", id);
49031
49032
  if (args.query) params.set("q", args.query);
49032
49033
  if (args.pageToken) params.set("pageToken", args.pageToken);
49033
- const listRes = await fetch(`${API$13}/messages?${params.toString()}`, {
49034
+ const listRes = await fetch(`${API$12}/messages?${params.toString()}`, {
49034
49035
  headers: { authorization: `Bearer ${accessToken}` },
49035
49036
  signal: AbortSignal.timeout(timeoutMs)
49036
49037
  });
@@ -49040,7 +49041,7 @@ async function listMessages$1(inv, accessToken, timeoutMs) {
49040
49041
  return {
49041
49042
  data: {
49042
49043
  messages: (await Promise.all(ids.map(async ({ id }) => {
49043
- const res = await fetch(`${API$13}/messages/${encodeURIComponent(id)}?format=metadata&metadataHeaders=From&metadataHeaders=To&metadataHeaders=Subject&metadataHeaders=Date`, {
49044
+ const res = await fetch(`${API$12}/messages/${encodeURIComponent(id)}?format=metadata&metadataHeaders=From&metadataHeaders=To&metadataHeaders=Subject&metadataHeaders=Date`, {
49044
49045
  headers: { authorization: `Bearer ${accessToken}` },
49045
49046
  signal: AbortSignal.timeout(timeoutMs)
49046
49047
  });
@@ -49068,7 +49069,7 @@ function toMessageSummary$1(meta) {
49068
49069
  }
49069
49070
  async function readMessage$1(inv, accessToken, timeoutMs) {
49070
49071
  const { id } = inv.args;
49071
- const res = await fetch(`${API$13}/messages/${encodeURIComponent(id)}?format=full`, {
49072
+ const res = await fetch(`${API$12}/messages/${encodeURIComponent(id)}?format=full`, {
49072
49073
  headers: { authorization: `Bearer ${accessToken}` },
49073
49074
  signal: AbortSignal.timeout(timeoutMs)
49074
49075
  });
@@ -49129,7 +49130,7 @@ async function send$1(inv, accessToken, timeoutMs) {
49129
49130
  rfcHeaders.push(`Content-Type: ${contentType}`);
49130
49131
  rfcHeaders.push("MIME-Version: 1.0");
49131
49132
  const raw = `${rfcHeaders.join("\r\n")}\r\n\r\n${args.body}`;
49132
- const sendRes = await fetch(`${API$13}/messages/send`, {
49133
+ const sendRes = await fetch(`${API$12}/messages/send`, {
49133
49134
  method: "POST",
49134
49135
  headers: {
49135
49136
  authorization: `Bearer ${accessToken}`,
@@ -49153,7 +49154,7 @@ async function send$1(inv, accessToken, timeoutMs) {
49153
49154
  }
49154
49155
  async function sendReply$1(inv, accessToken, timeoutMs) {
49155
49156
  const { threadId, body, replyAll, cc } = inv.args;
49156
- const threadRes = await fetch(`${API$13}/threads/${encodeURIComponent(threadId)}?format=metadata&metadataHeaders=From&metadataHeaders=To&metadataHeaders=Cc&metadataHeaders=Subject&metadataHeaders=Message-ID&metadataHeaders=References`, {
49157
+ const threadRes = await fetch(`${API$12}/threads/${encodeURIComponent(threadId)}?format=metadata&metadataHeaders=From&metadataHeaders=To&metadataHeaders=Cc&metadataHeaders=Subject&metadataHeaders=Message-ID&metadataHeaders=References`, {
49157
49158
  headers: { authorization: `Bearer ${accessToken}` },
49158
49159
  signal: AbortSignal.timeout(timeoutMs)
49159
49160
  });
@@ -49190,7 +49191,7 @@ async function sendReply$1(inv, accessToken, timeoutMs) {
49190
49191
  threadId,
49191
49192
  raw: encodeBase64Url(`${rfcHeaders.join("\r\n")}\r\n\r\n${body}`)
49192
49193
  };
49193
- const sendRes = await fetch(`${API$13}/messages/send`, {
49194
+ const sendRes = await fetch(`${API$12}/messages/send`, {
49194
49195
  method: "POST",
49195
49196
  headers: {
49196
49197
  authorization: `Bearer ${accessToken}`,
@@ -49219,7 +49220,7 @@ async function watchLabel(inv, accessToken, timeoutMs) {
49219
49220
  labelIds: labelIds ?? ["INBOX"],
49220
49221
  labelFilterAction: labelFilterAction ?? "include"
49221
49222
  };
49222
- const res = await fetch(`${API$13}/watch`, {
49223
+ const res = await fetch(`${API$12}/watch`, {
49223
49224
  method: "POST",
49224
49225
  headers: {
49225
49226
  authorization: `Bearer ${accessToken}`,
@@ -51302,7 +51303,7 @@ const text$9 = {
51302
51303
  type: "string",
51303
51304
  minLength: 1
51304
51305
  };
51305
- const money$4 = {
51306
+ const money$3 = {
51306
51307
  type: "integer",
51307
51308
  minimum: 1,
51308
51309
  description: "Positive amount in the ad account currency minor units, e.g. 10000 = USD 100. Confirm account currency first."
@@ -51316,7 +51317,7 @@ const url$1 = {
51316
51317
  format: "uri",
51317
51318
  pattern: "^https://"
51318
51319
  };
51319
- const page$7 = {
51320
+ const page$6 = {
51320
51321
  limit: {
51321
51322
  type: "integer",
51322
51323
  minimum: 1,
@@ -51353,7 +51354,7 @@ function mutation$2(name, description, properties, required, path, body) {
51353
51354
  }
51354
51355
  };
51355
51356
  }
51356
- const base$8 = declarativeRestConnector({
51357
+ const base$9 = declarativeRestConnector({
51357
51358
  kind: "meta-ads",
51358
51359
  displayName: "Meta Ads",
51359
51360
  description: "Manage Facebook and Instagram paid traffic campaigns, bounded budgets, ad sets, link creatives, delivery status and insights.",
@@ -51389,7 +51390,7 @@ const base$8 = declarativeRestConnector({
51389
51390
  class: "read",
51390
51391
  description: "Discover permitted ad accounts, currencies, timezones and readiness. Follow paging.cursors.after.",
51391
51392
  requiredScopes: ["ads_read"],
51392
- parameters: parameters$8(page$7),
51393
+ parameters: parameters$8(page$6),
51393
51394
  request: {
51394
51395
  method: "GET",
51395
51396
  path: "/me/adaccounts",
@@ -51404,7 +51405,7 @@ const base$8 = declarativeRestConnector({
51404
51405
  class: "read",
51405
51406
  description: "Discover Pages and their linked Instagram business identities for ad creatives. Page access tokens are deliberately not requested.",
51406
51407
  requiredScopes: ["pages_show_list"],
51407
- parameters: parameters$8(page$7),
51408
+ parameters: parameters$8(page$6),
51408
51409
  request: {
51409
51410
  method: "GET",
51410
51411
  path: "/me/accounts",
@@ -51426,7 +51427,7 @@ const base$8 = declarativeRestConnector({
51426
51427
  description: `Read ${edge} in an ad account, including native IDs and readiness. Follow paging.cursors.after.`,
51427
51428
  parameters: parameters$8({
51428
51429
  accountId: id$13,
51429
- ...page$7
51430
+ ...page$6
51430
51431
  }, ["accountId"]),
51431
51432
  request: {
51432
51433
  method: "GET",
@@ -51440,7 +51441,7 @@ const base$8 = declarativeRestConnector({
51440
51441
  mutation$2("campaigns.createTraffic", "Create a PAUSED auction traffic campaign with an explicit campaign spend cap across all its ad sets. The cap is not a daily budget; configure bounded ad sets before enabling.", {
51441
51442
  accountId: id$13,
51442
51443
  name: text$9,
51443
- spendCap: money$4,
51444
+ spendCap: money$3,
51444
51445
  specialAdCategories: {
51445
51446
  type: "array",
51446
51447
  items: {
@@ -51472,7 +51473,7 @@ const base$8 = declarativeRestConnector({
51472
51473
  accountId: id$13,
51473
51474
  campaignId: id$13,
51474
51475
  name: text$9,
51475
- lifetimeBudget: money$4,
51476
+ lifetimeBudget: money$3,
51476
51477
  startTime: dateTime,
51477
51478
  endTime: dateTime,
51478
51479
  countries: {
@@ -51597,7 +51598,7 @@ const base$8 = declarativeRestConnector({
51597
51598
  "ad"
51598
51599
  ]
51599
51600
  },
51600
- ...page$7
51601
+ ...page$6
51601
51602
  }, [
51602
51603
  "accountId",
51603
51604
  "since",
@@ -51657,9 +51658,9 @@ function prepare$2(inv) {
51657
51658
  };
51658
51659
  }
51659
51660
  const metaAdsConnector = {
51660
- ...base$8,
51661
+ ...base$9,
51661
51662
  async executeRead(inv) {
51662
- const result = await base$8.executeRead(prepare$2(inv));
51663
+ const result = await base$9.executeRead(prepare$2(inv));
51663
51664
  if (isPlainRecord(result.data) && isPlainRecord(result.data.paging)) {
51664
51665
  const { next: _next, previous: _previous, ...paging } = result.data.paging;
51665
51666
  return {
@@ -51673,7 +51674,7 @@ const metaAdsConnector = {
51673
51674
  return result;
51674
51675
  },
51675
51676
  async executeMutation(inv) {
51676
- const result = await base$8.executeMutation(prepare$2(inv));
51677
+ const result = await base$9.executeMutation(prepare$2(inv));
51677
51678
  if (result.status !== "committed") return result;
51678
51679
  const data = result.data;
51679
51680
  if (!(isPlainRecord(data) && !("error" in data) && (inv.capabilityName.includes(".create") ? typeof data.id === "string" && data.id.trim().length > 0 : data.success === true))) throw new Error("meta-ads: missing native mutation receipt; reconcile provider state before retrying");
@@ -51700,7 +51701,7 @@ const time$4 = {
51700
51701
  type: "string",
51701
51702
  format: "date-time"
51702
51703
  };
51703
- const page$6 = {
51704
+ const page$5 = {
51704
51705
  cursor: { type: "string" },
51705
51706
  count: {
51706
51707
  type: "integer",
@@ -51736,7 +51737,7 @@ function write$5(name, description, path, properties, required, body, method = "
51736
51737
  }
51737
51738
  };
51738
51739
  }
51739
- const base$7 = declarativeRestConnector({
51740
+ const base$8 = declarativeRestConnector({
51740
51741
  kind: "x-ads",
51741
51742
  displayName: "X Ads",
51742
51743
  description: "Manage X paid campaigns with total budgets, scheduled line items, targeting, promoted posts, and spend reports.",
@@ -51759,7 +51760,7 @@ const base$7 = declarativeRestConnector({
51759
51760
  name: "accounts.list",
51760
51761
  class: "read",
51761
51762
  description: "Discover accessible advertising accounts, approval status and timezone. Follow next_cursor.",
51762
- parameters: parameters$7(page$6),
51763
+ parameters: parameters$7(page$5),
51763
51764
  request: {
51764
51765
  method: "GET",
51765
51766
  path: "/accounts",
@@ -51789,7 +51790,7 @@ const base$7 = declarativeRestConnector({
51789
51790
  description: `Read ${resource} with native IDs, status, budget and pagination. Funding instruments include currency and funding readiness.`,
51790
51791
  parameters: parameters$7({
51791
51792
  accountId: id$12,
51792
- ...page$6
51793
+ ...page$5
51793
51794
  }, ["accountId"]),
51794
51795
  request: {
51795
51796
  method: "GET",
@@ -52014,7 +52015,7 @@ const base$7 = declarativeRestConnector({
52014
52015
  ]
52015
52016
  });
52016
52017
  const xAdsConnector = {
52017
- ...base$7,
52018
+ ...base$8,
52018
52019
  async executeMutation(inv) {
52019
52020
  for (const key of [
52020
52021
  "totalBudgetMicros",
@@ -52023,7 +52024,7 @@ const xAdsConnector = {
52023
52024
  ]) if (inv.args[key] !== void 0 && (typeof inv.args[key] !== "string" || !/^[1-9][0-9]*$/.test(inv.args[key]))) throw new Error(`x-ads: ${key} must be positive integer microcurrency`);
52024
52025
  if (typeof inv.args.dailyBudgetMicros === "string" && typeof inv.args.totalBudgetMicros === "string" && BigInt(inv.args.dailyBudgetMicros) > BigInt(inv.args.totalBudgetMicros)) throw new Error("x-ads: daily budget exceeds total budget");
52025
52026
  if (inv.capabilityName === "lineItems.createTraffic" && !(typeof inv.args.startTime === "string" && typeof inv.args.endTime === "string" && Date.parse(inv.args.endTime) > Date.parse(inv.args.startTime))) throw new Error("x-ads: endTime must be after startTime");
52026
- const result = await base$7.executeMutation(inv);
52027
+ const result = await base$8.executeMutation(inv);
52027
52028
  if (result.status === "committed") {
52028
52029
  const envelope = result.data;
52029
52030
  const records = isPlainRecord(envelope) ? Array.isArray(envelope.data) ? envelope.data : [envelope.data] : [];
@@ -52098,7 +52099,7 @@ function mutation$1(name, description, properties, required, path, body) {
52098
52099
  }
52099
52100
  };
52100
52101
  }
52101
- const base$6 = declarativeRestConnector({
52102
+ const base$7 = declarativeRestConnector({
52102
52103
  kind: "tiktok-ads",
52103
52104
  displayName: "TikTok Ads",
52104
52105
  description: "Operate TikTok Marketing API traffic campaigns, lifetime budgets, targeted ad groups, video ads and paid performance reports.",
@@ -52537,18 +52538,18 @@ async function uploadVideo(inv) {
52537
52538
  };
52538
52539
  }
52539
52540
  const tiktokAdsConnector = {
52540
- ...base$6,
52541
+ ...base$7,
52541
52542
  async executeRead(inv) {
52542
52543
  if (inv.capabilityName === "advertisers.list") return discover(inv);
52543
52544
  credentials(inv.source.credentials);
52544
- const result = await base$6.executeRead(prepare$1(inv));
52545
+ const result = await base$7.executeRead(prepare$1(inv));
52545
52546
  assertEnvelope$1(result.data);
52546
52547
  return result;
52547
52548
  },
52548
52549
  async executeMutation(inv) {
52549
52550
  if (inv.capabilityName === "videos.uploadFromUrl") return uploadVideo(inv);
52550
52551
  credentials(inv.source.credentials);
52551
- const result = await base$6.executeMutation(prepare$1(inv));
52552
+ const result = await base$7.executeMutation(prepare$1(inv));
52552
52553
  if (result.status === "committed") assertMutationReceipt$1(result.data, inv.capabilityName);
52553
52554
  return result;
52554
52555
  },
@@ -52580,7 +52581,7 @@ const text$6 = {
52580
52581
  minLength: 1,
52581
52582
  maxLength: 255
52582
52583
  };
52583
- const money$3 = {
52584
+ const money$2 = {
52584
52585
  type: "string",
52585
52586
  pattern: "^(?:[1-9][0-9]*(?:\\.[0-9]{1,2})?|0\\.(?:0[1-9]|[1-9][0-9]?))$",
52586
52587
  description: "Positive decimal amount in account currency, not micros."
@@ -52670,7 +52671,7 @@ function nativeTargeting(value) {
52670
52671
  };
52671
52672
  }
52672
52673
  const account$1 = "/adAccounts/{accountId}";
52673
- const page$5 = {
52674
+ const page$4 = {
52674
52675
  pageSize: {
52675
52676
  type: "integer",
52676
52677
  minimum: 1,
@@ -52709,7 +52710,7 @@ function write$4(name, description, path, properties, required, body, create = f
52709
52710
  }
52710
52711
  };
52711
52712
  }
52712
- const base$5 = declarativeRestConnector({
52713
+ const base$6 = declarativeRestConnector({
52713
52714
  kind: "linkedin-ads",
52714
52715
  displayName: "LinkedIn Ads",
52715
52716
  description: "Discover advertiser accounts, prepare lifetime-budget sponsored campaigns, target professional audiences, sponsor existing posts, and measure results.",
@@ -52743,7 +52744,7 @@ const base$5 = declarativeRestConnector({
52743
52744
  class: "read",
52744
52745
  requiredScopes: ["rw_ads"],
52745
52746
  description: "List accessible advertiser accounts, currency, account status and native nextPageToken. Includes test accounts.",
52746
- parameters: parameters$5(page$5),
52747
+ parameters: parameters$5(page$4),
52747
52748
  request: {
52748
52749
  method: "GET",
52749
52750
  path: "/adAccounts",
@@ -52763,7 +52764,7 @@ const base$5 = declarativeRestConnector({
52763
52764
  description: "Read campaigns or groups with native budgets, serving holds and nextPageToken.",
52764
52765
  parameters: parameters$5({
52765
52766
  accountId: id$10,
52766
- ...page$5
52767
+ ...page$4
52767
52768
  }, ["accountId"]),
52768
52769
  request: {
52769
52770
  method: "GET",
@@ -52792,7 +52793,7 @@ const base$5 = declarativeRestConnector({
52792
52793
  }),
52793
52794
  write$4("campaignGroups.create", "Create a DRAFT campaign group with a cumulative total budget and fixed schedule. New groups only accept DRAFT or ACTIVE at creation.", "/adCampaignGroups", {
52794
52795
  name: text$6,
52795
- totalBudget: money$3,
52796
+ totalBudget: money$2,
52796
52797
  currencyCode: currency,
52797
52798
  startTime: time$2,
52798
52799
  endTime: time$2
@@ -52824,9 +52825,9 @@ const base$5 = declarativeRestConnector({
52824
52825
  pattern: "^urn:li:(organization:[0-9]+|person:[A-Za-z0-9_-]+)$",
52825
52826
  description: "Beneficiary organization or member URN with sponsorship rights for this campaign."
52826
52827
  },
52827
- totalBudget: money$3,
52828
+ totalBudget: money$2,
52828
52829
  currencyCode: currency,
52829
- bidAmount: money$3,
52830
+ bidAmount: money$2,
52830
52831
  startTime: time$2,
52831
52832
  endTime: time$2,
52832
52833
  targetingCriteria: targeting,
@@ -53045,9 +53046,9 @@ const base$5 = declarativeRestConnector({
53045
53046
  ]
53046
53047
  });
53047
53048
  const linkedinAdsConnector = {
53048
- ...base$5,
53049
+ ...base$6,
53049
53050
  async executeMutation(inv) {
53050
- for (const key of ["totalBudget", "bidAmount"]) if (inv.args[key] !== void 0 && (typeof inv.args[key] !== "string" || !new RegExp(money$3.pattern).test(inv.args[key]))) throw new Error(`linkedin-ads: ${key} must be positive decimal currency`);
53051
+ for (const key of ["totalBudget", "bidAmount"]) if (inv.args[key] !== void 0 && (typeof inv.args[key] !== "string" || !new RegExp(money$2.pattern).test(inv.args[key]))) throw new Error(`linkedin-ads: ${key} must be positive decimal currency`);
53051
53052
  if (inv.capabilityName === "campaignGroups.create" || inv.capabilityName === "campaigns.createSponsored") {
53052
53053
  if (!(typeof inv.args.startTime === "number" && typeof inv.args.endTime === "number" && Number.isSafeInteger(inv.args.startTime) && Number.isSafeInteger(inv.args.endTime) && Number(inv.args.startTime) > 0 && Number(inv.args.endTime) > Number(inv.args.startTime))) throw new Error("linkedin-ads: endTime must be after startTime in epoch milliseconds");
53053
53054
  }
@@ -53058,7 +53059,7 @@ const linkedinAdsConnector = {
53058
53059
  targetingCriteria: nativeTargeting(inv.args.targetingCriteria)
53059
53060
  }
53060
53061
  };
53061
- const result = await base$5.executeMutation(inv);
53062
+ const result = await base$6.executeMutation(inv);
53062
53063
  if (result.status === "committed") {
53063
53064
  if ([
53064
53065
  "campaignGroups.create",
@@ -53095,7 +53096,7 @@ const micros$2 = {
53095
53096
  maximum: Number.MAX_SAFE_INTEGER,
53096
53097
  description: "Positive integer microcurrency in the advertiser account currency; 1000000 = one currency unit."
53097
53098
  };
53098
- const page$4 = {
53099
+ const page$3 = {
53099
53100
  pageToken: { type: "string" },
53100
53101
  pageSize: {
53101
53102
  type: "integer",
@@ -53143,7 +53144,7 @@ function write$3(name, description, path, properties, required, data, method = "
53143
53144
  }
53144
53145
  };
53145
53146
  }
53146
- const base$4 = declarativeRestConnector({
53147
+ const base$5 = declarativeRestConnector({
53147
53148
  kind: "reddit-ads",
53148
53149
  displayName: "Reddit Ads",
53149
53150
  description: "Prepare lifetime-budget Reddit traffic campaigns, target communities and geographies, create ad creatives, launch or pause, and measure spend and conversions.",
@@ -53175,7 +53176,7 @@ const base$4 = declarativeRestConnector({
53175
53176
  class: "read",
53176
53177
  requiredScopes: ["adsread"],
53177
53178
  description: "Discover advertiser businesses available to the connected user. Follow pagination tokens.",
53178
- parameters: parameters$4(page$4),
53179
+ parameters: parameters$4(page$3),
53179
53180
  request: {
53180
53181
  method: "GET",
53181
53182
  path: "/me/businesses",
@@ -53189,7 +53190,7 @@ const base$4 = declarativeRestConnector({
53189
53190
  description: "List advertiser accounts in one accessible business. Use account currency and billing readiness before budgeting.",
53190
53191
  parameters: parameters$4({
53191
53192
  businessId: id$9,
53192
- ...page$4
53193
+ ...page$3
53193
53194
  }, ["businessId"]),
53194
53195
  request: {
53195
53196
  method: "GET",
@@ -53221,7 +53222,7 @@ const base$4 = declarativeRestConnector({
53221
53222
  description: `List ${resource} under this advertiser account. Retain provider IDs and pagination.`,
53222
53223
  parameters: parameters$4({
53223
53224
  accountId: id$9,
53224
- ...page$4
53225
+ ...page$3
53225
53226
  }, ["accountId"]),
53226
53227
  request: {
53227
53228
  method: "GET",
@@ -53318,7 +53319,7 @@ const base$4 = declarativeRestConnector({
53318
53319
  description: "Search targetable communities by name or topic. Use returned community names in ad-group targeting.",
53319
53320
  parameters: parameters$4({
53320
53321
  query: text$5,
53321
- ...page$4
53322
+ ...page$3
53322
53323
  }, ["query"]),
53323
53324
  request: {
53324
53325
  method: "GET",
@@ -53498,13 +53499,13 @@ const base$4 = declarativeRestConnector({
53498
53499
  ]
53499
53500
  });
53500
53501
  const redditAdsConnector = {
53501
- ...base$4,
53502
+ ...base$5,
53502
53503
  async executeMutation(inv) {
53503
53504
  if (inv.args.totalBudgetMicros !== void 0 && !(typeof inv.args.totalBudgetMicros === "number" && Number.isSafeInteger(inv.args.totalBudgetMicros) && Number(inv.args.totalBudgetMicros) > 0)) throw new Error("reddit-ads: totalBudgetMicros must be positive safe integer microcurrency");
53504
53505
  if (inv.capabilityName === "campaigns.createTraffic" || inv.capabilityName === "adGroups.createTraffic") {
53505
53506
  if (!(typeof inv.args.startTime === "string" && typeof inv.args.endTime === "string" && Date.parse(inv.args.endTime) > Date.parse(inv.args.startTime))) throw new Error("reddit-ads: endTime must be after startTime");
53506
53507
  }
53507
- const result = await base$4.executeMutation(inv);
53508
+ const result = await base$5.executeMutation(inv);
53508
53509
  if (result.status === "committed") {
53509
53510
  const envelope = result.data;
53510
53511
  if (!isPlainRecord(envelope) || envelope.error || envelope.errors || !isPlainRecord(envelope.data) || typeof envelope.data.id !== "string" || !envelope.data.id) throw new Error("reddit-ads: missing native mutation receipt or provider error; reconcile state before retrying");
@@ -53572,7 +53573,7 @@ function mutation(name, description, properties, required, path, body) {
53572
53573
  }
53573
53574
  };
53574
53575
  }
53575
- const base$3 = declarativeRestConnector({
53576
+ const base$4 = declarativeRestConnector({
53576
53577
  kind: "snapchat-ads",
53577
53578
  displayName: "Snapchat Ads",
53578
53579
  description: "Create bounded Snapchat campaigns, targeted ad squads, uploaded media and website creatives; control delivery and read spend and conversions.",
@@ -53943,21 +53944,21 @@ async function upload(inv) {
53943
53944
  };
53944
53945
  }
53945
53946
  const snapchatAdsConnector = {
53946
- ...base$3,
53947
+ ...base$4,
53947
53948
  async executeRead(inv) {
53948
- const result = await base$3.executeRead(prepare(inv));
53949
+ const result = await base$4.executeRead(prepare(inv));
53949
53950
  assertEnvelope(result.data);
53950
53951
  return result;
53951
53952
  },
53952
53953
  async executeMutation(inv) {
53953
53954
  if (inv.capabilityName === "media.upload") return upload(inv);
53954
- const result = await base$3.executeMutation(prepare(inv));
53955
+ const result = await base$4.executeMutation(prepare(inv));
53955
53956
  if (result.status === "committed") assertMutationReceipt(result.data, inv.capabilityName);
53956
53957
  return result;
53957
53958
  },
53958
53959
  async test(source) {
53959
53960
  try {
53960
- assertEnvelope((await base$3.executeRead({
53961
+ assertEnvelope((await base$4.executeRead({
53961
53962
  source,
53962
53963
  capabilityName: "accounts.list",
53963
53964
  args: {},
@@ -54224,12 +54225,12 @@ const id$6 = {
54224
54225
  ...text$2,
54225
54226
  pattern: "^[0-9]+$"
54226
54227
  };
54227
- const money$2 = {
54228
+ const money$1 = {
54228
54229
  type: "number",
54229
54230
  exclusiveMinimum: 0,
54230
54231
  description: "Amount in the advertising account currency, not micros or cents."
54231
54232
  };
54232
- const date$3 = {
54233
+ const date$2 = {
54233
54234
  type: "object",
54234
54235
  properties: {
54235
54236
  Year: {
@@ -54398,8 +54399,8 @@ function createMicrosoftAdsConnector(options) {
54398
54399
  },
54399
54400
  write$1("campaigns.createSearch", "Create a PAUSED Search campaign with a DAILY budget in account currency and MaxClicks bidding capped by maximum CPC. This is not a lifetime spend cap. Configure dated ad groups, location targeting and ads before enabling.", "/Campaigns", {
54400
54401
  name: text$2,
54401
- dailyBudget: money$2,
54402
- maxCpc: money$2,
54402
+ dailyBudget: money$1,
54403
+ maxCpc: money$1,
54403
54404
  languages: {
54404
54405
  type: "array",
54405
54406
  minItems: 1,
@@ -54431,9 +54432,9 @@ function createMicrosoftAdsConnector(options) {
54431
54432
  write$1("adGroups.create", "Create a PAUSED Search ad group with explicit start/end dates and currency CPC bid. Serving is limited to Microsoft owned and operated networks; the parent daily budget is not a total cap.", "/AdGroups", {
54432
54433
  campaignId: id$6,
54433
54434
  name: text$2,
54434
- cpcBid: money$2,
54435
- startDate: date$3,
54436
- endDate: date$3
54435
+ cpcBid: money$1,
54436
+ startDate: date$2,
54437
+ endDate: date$2
54437
54438
  }, [
54438
54439
  "campaignId",
54439
54440
  "name",
@@ -54462,7 +54463,7 @@ function createMicrosoftAdsConnector(options) {
54462
54463
  "Broad"
54463
54464
  ]
54464
54465
  },
54465
- bid: money$2
54466
+ bid: money$1
54466
54467
  }, [
54467
54468
  "adGroupId",
54468
54469
  "text",
@@ -54574,8 +54575,8 @@ function createMicrosoftAdsConnector(options) {
54574
54575
  requiredScopes: [scope$1],
54575
54576
  description: "Submit a daily campaign performance CSV report for a closed date range. Returns ReportRequestId; poll reports.get. Spend is in account currency and attribution can lag.",
54576
54577
  parameters: parameters$1({
54577
- startDate: date$3,
54578
- endDate: date$3
54578
+ startDate: date$2,
54579
+ endDate: date$2
54579
54580
  }, ["startDate", "endDate"]),
54580
54581
  request: {
54581
54582
  method: "POST",
@@ -54692,12 +54693,12 @@ const id$5 = {
54692
54693
  ...text$1,
54693
54694
  pattern: "^[0-9]+$"
54694
54695
  };
54695
- const money$1 = {
54696
+ const money = {
54696
54697
  type: "number",
54697
54698
  exclusiveMinimum: 0,
54698
54699
  description: "Amount in the profile currency, not micros or cents. Provider marketplace minimums apply."
54699
54700
  };
54700
- const date$2 = {
54701
+ const date$1 = {
54701
54702
  type: "string",
54702
54703
  format: "date",
54703
54704
  description: "YYYY-MM-DD in the advertiser marketplace timezone."
@@ -54816,9 +54817,9 @@ function createAmazonAdsConnector(options) {
54816
54817
  }),
54817
54818
  write("campaigns.createSponsoredProducts", "Create a PAUSED manual Sponsored Products campaign. DAILY budget is in profile currency and is an average daily budget, not a hard daily or lifetime spend cap. Required end date bounds the schedule; only eligible products may advertise.", "campaigns", {
54818
54819
  name: text$1,
54819
- dailyBudget: money$1,
54820
- startDate: date$2,
54821
- endDate: date$2
54820
+ dailyBudget: money,
54821
+ startDate: date$1,
54822
+ endDate: date$1
54822
54823
  }, [
54823
54824
  "name",
54824
54825
  "dailyBudget",
@@ -54839,7 +54840,7 @@ function createAmazonAdsConnector(options) {
54839
54840
  write("adGroups.create", "Create a PAUSED Sponsored Products ad group with a default bid in profile currency.", "adGroups", {
54840
54841
  campaignId: id$5,
54841
54842
  name: text$1,
54842
- defaultBid: money$1
54843
+ defaultBid: money
54843
54844
  }, [
54844
54845
  "campaignId",
54845
54846
  "name",
@@ -54862,7 +54863,7 @@ function createAmazonAdsConnector(options) {
54862
54863
  "BROAD"
54863
54864
  ]
54864
54865
  },
54865
- bid: money$1
54866
+ bid: money
54866
54867
  }, [
54867
54868
  "campaignId",
54868
54869
  "adGroupId",
@@ -54901,8 +54902,8 @@ function createAmazonAdsConnector(options) {
54901
54902
  requiredScopes: [scope],
54902
54903
  description: "Request a daily Sponsored Products campaign report. Returns reportId; poll reports.get until COMPLETED. Costs are profile currency; attribution and reporting lag apply.",
54903
54904
  parameters: parameters({
54904
- startDate: date$2,
54905
- endDate: date$2
54905
+ startDate: date$1,
54906
+ endDate: date$1
54906
54907
  }, ["startDate", "endDate"]),
54907
54908
  request: {
54908
54909
  method: "POST",
@@ -56561,7 +56562,7 @@ const googleContactsConnector = declarativeRestConnector({
56561
56562
  const SCOPES$12 = ["https://www.googleapis.com/auth/documents", "https://www.googleapis.com/auth/drive.file"];
56562
56563
  const AUTH_URL$15 = "https://accounts.google.com/o/oauth2/v2/auth";
56563
56564
  const TOKEN_URL$17 = "https://oauth2.googleapis.com/token";
56564
- const API$12 = "https://docs.googleapis.com/v1";
56565
+ const API$11 = "https://docs.googleapis.com/v1";
56565
56566
  const DRIVE_API = "https://www.googleapis.com/drive/v3";
56566
56567
  const EXPORT_MIME = {
56567
56568
  pdf: "application/pdf",
@@ -56803,7 +56804,7 @@ function findAppendIndex(doc) {
56803
56804
  }
56804
56805
  async function getDocument$1(inv, accessToken, timeoutMs) {
56805
56806
  const { documentId } = inv.args ?? {};
56806
- const res = await fetch(`${API$12}/documents/${encodeURIComponent(documentId)}`, {
56807
+ const res = await fetch(`${API$11}/documents/${encodeURIComponent(documentId)}`, {
56807
56808
  headers: { authorization: `Bearer ${accessToken}` },
56808
56809
  signal: AbortSignal.timeout(timeoutMs)
56809
56810
  });
@@ -56827,7 +56828,7 @@ async function getDocument$1(inv, accessToken, timeoutMs) {
56827
56828
  async function createDocument$1(inv, accessToken, timeoutMs) {
56828
56829
  const { title, body } = inv.args ?? {};
56829
56830
  if (!title || typeof title !== "string") throw new Error("google-docs create_document: title is required");
56830
- const createRes = await fetch(`${API$12}/documents`, {
56831
+ const createRes = await fetch(`${API$11}/documents`, {
56831
56832
  method: "POST",
56832
56833
  headers: {
56833
56834
  authorization: `Bearer ${accessToken}`,
@@ -56840,7 +56841,7 @@ async function createDocument$1(inv, accessToken, timeoutMs) {
56840
56841
  const created = await createRes.json();
56841
56842
  let revisionId = created.revisionId;
56842
56843
  if (typeof body === "string" && body.length > 0) {
56843
- const insertRes = await fetch(`${API$12}/documents/${encodeURIComponent(created.documentId)}:batchUpdate`, {
56844
+ const insertRes = await fetch(`${API$11}/documents/${encodeURIComponent(created.documentId)}:batchUpdate`, {
56844
56845
  method: "POST",
56845
56846
  headers: {
56846
56847
  authorization: `Bearer ${accessToken}`,
@@ -56870,7 +56871,7 @@ async function createDocument$1(inv, accessToken, timeoutMs) {
56870
56871
  async function appendText(inv, accessToken, timeoutMs) {
56871
56872
  const { documentId, text, requiredRevisionId } = inv.args ?? {};
56872
56873
  if (!text) throw new Error("google-docs append_text: text is required");
56873
- const docRes = await fetch(`${API$12}/documents/${encodeURIComponent(documentId)}?fields=documentId,revisionId,body(content(endIndex))`, {
56874
+ const docRes = await fetch(`${API$11}/documents/${encodeURIComponent(documentId)}?fields=documentId,revisionId,body(content(endIndex))`, {
56874
56875
  headers: { authorization: `Bearer ${accessToken}` },
56875
56876
  signal: AbortSignal.timeout(timeoutMs)
56876
56877
  });
@@ -56881,7 +56882,7 @@ async function appendText(inv, accessToken, timeoutMs) {
56881
56882
  text
56882
56883
  } }] };
56883
56884
  if (requiredRevisionId) body.writeControl = { requiredRevisionId };
56884
- const res = await fetch(`${API$12}/documents/${encodeURIComponent(documentId)}:batchUpdate`, {
56885
+ const res = await fetch(`${API$11}/documents/${encodeURIComponent(documentId)}:batchUpdate`, {
56885
56886
  method: "POST",
56886
56887
  headers: {
56887
56888
  authorization: `Bearer ${accessToken}`,
@@ -57021,7 +57022,7 @@ const SCOPE_WATCH = "https://www.googleapis.com/auth/drive";
57021
57022
  const SCOPE_WRITE$2 = "https://www.googleapis.com/auth/drive.file";
57022
57023
  const AUTH_URL$14 = "https://accounts.google.com/o/oauth2/v2/auth";
57023
57024
  const TOKEN_URL$16 = "https://oauth2.googleapis.com/token";
57024
- const API$11 = "https://www.googleapis.com/drive/v3";
57025
+ const API$10 = "https://www.googleapis.com/drive/v3";
57025
57026
  const UPLOAD_API = "https://www.googleapis.com/upload/drive/v3";
57026
57027
  function googleDrive(opts) {
57027
57028
  const { clientId, clientSecret } = opts;
@@ -57277,7 +57278,7 @@ function googleDrive(opts) {
57277
57278
  async test(source) {
57278
57279
  try {
57279
57280
  const accessToken = await ensureFreshAccessToken$11(source.credentials, clientId, clientSecret);
57280
- const res = await fetch(`${API$11}/about?fields=user`, {
57281
+ const res = await fetch(`${API$10}/about?fields=user`, {
57281
57282
  headers: { authorization: `Bearer ${accessToken}` },
57282
57283
  signal: AbortSignal.timeout(8e3)
57283
57284
  });
@@ -57310,7 +57311,7 @@ async function listFiles$1(inv, accessToken, timeoutMs) {
57310
57311
  fields: "nextPageToken, files(id,name,mimeType,modifiedTime,size,md5Checksum,parents)"
57311
57312
  });
57312
57313
  if (args.pageToken) params.set("pageToken", args.pageToken);
57313
- const res = await fetch(`${API$11}/files?${params.toString()}`, {
57314
+ const res = await fetch(`${API$10}/files?${params.toString()}`, {
57314
57315
  headers: { authorization: `Bearer ${accessToken}` },
57315
57316
  signal: AbortSignal.timeout(timeoutMs)
57316
57317
  });
@@ -57331,7 +57332,7 @@ const GOOGLE_NATIVE_DEFAULTS = {
57331
57332
  };
57332
57333
  async function readFile$1(inv, accessToken, timeoutMs) {
57333
57334
  const { fileId, exportMime } = inv.args ?? {};
57334
- const metaRes = await fetch(`${API$11}/files/${encodeURIComponent(fileId)}?fields=id,name,mimeType,modifiedTime`, {
57335
+ const metaRes = await fetch(`${API$10}/files/${encodeURIComponent(fileId)}?fields=id,name,mimeType,modifiedTime`, {
57335
57336
  headers: { authorization: `Bearer ${accessToken}` },
57336
57337
  signal: AbortSignal.timeout(timeoutMs)
57337
57338
  });
@@ -57342,7 +57343,7 @@ async function readFile$1(inv, accessToken, timeoutMs) {
57342
57343
  const fetchedAt = Date.now();
57343
57344
  if (isNative) {
57344
57345
  const targetMime = exportMime ?? GOOGLE_NATIVE_DEFAULTS[meta.mimeType] ?? "text/plain";
57345
- const res = await fetch(`${API$11}/files/${encodeURIComponent(fileId)}/export?mimeType=${encodeURIComponent(targetMime)}`, {
57346
+ const res = await fetch(`${API$10}/files/${encodeURIComponent(fileId)}/export?mimeType=${encodeURIComponent(targetMime)}`, {
57346
57347
  headers: { authorization: `Bearer ${accessToken}` },
57347
57348
  signal: AbortSignal.timeout(timeoutMs)
57348
57349
  });
@@ -57372,7 +57373,7 @@ async function readFile$1(inv, accessToken, timeoutMs) {
57372
57373
  fetchedAt
57373
57374
  };
57374
57375
  }
57375
- const res = await fetch(`${API$11}/files/${encodeURIComponent(fileId)}?alt=media`, {
57376
+ const res = await fetch(`${API$10}/files/${encodeURIComponent(fileId)}?alt=media`, {
57376
57377
  headers: { authorization: `Bearer ${accessToken}` },
57377
57378
  signal: AbortSignal.timeout(timeoutMs)
57378
57379
  });
@@ -57410,7 +57411,7 @@ async function watchFolder$1(inv, accessToken, timeoutMs) {
57410
57411
  address
57411
57412
  };
57412
57413
  if (ttlMs && ttlMs > 0) body.expiration = String(Date.now() + ttlMs);
57413
- const res = await fetch(`${API$11}/files/${encodeURIComponent(folderId)}/watch`, {
57414
+ const res = await fetch(`${API$10}/files/${encodeURIComponent(folderId)}/watch`, {
57414
57415
  method: "POST",
57415
57416
  headers: {
57416
57417
  authorization: `Bearer ${accessToken}`,
@@ -57498,7 +57499,7 @@ async function createFolder$1(inv, accessToken, timeoutMs) {
57498
57499
  mimeType: "application/vnd.google-apps.folder"
57499
57500
  };
57500
57501
  if (args.parents?.length) body.parents = args.parents;
57501
- const res = await fetch(`${API$11}/files?fields=id,name,mimeType,parents,modifiedTime`, {
57502
+ const res = await fetch(`${API$10}/files?fields=id,name,mimeType,parents,modifiedTime`, {
57502
57503
  method: "POST",
57503
57504
  headers: {
57504
57505
  authorization: `Bearer ${accessToken}`,
@@ -57525,7 +57526,7 @@ async function createFolder$1(inv, accessToken, timeoutMs) {
57525
57526
  async function deleteFile(inv, accessToken, timeoutMs) {
57526
57527
  const args = inv.args ?? {};
57527
57528
  if (!args.fileId) throw new Error("google-drive delete_file: `fileId` is required");
57528
- const res = await fetch(`${API$11}/files/${encodeURIComponent(args.fileId)}`, {
57529
+ const res = await fetch(`${API$10}/files/${encodeURIComponent(args.fileId)}`, {
57529
57530
  method: "DELETE",
57530
57531
  headers: { authorization: `Bearer ${accessToken}` },
57531
57532
  signal: AbortSignal.timeout(timeoutMs)
@@ -57548,7 +57549,7 @@ async function moveFile(inv, accessToken, timeoutMs) {
57548
57549
  const params = new URLSearchParams({ fields: "id,name,parents,modifiedTime" });
57549
57550
  if (args.addParents?.length) params.set("addParents", args.addParents.join(","));
57550
57551
  if (args.removeParents?.length) params.set("removeParents", args.removeParents.join(","));
57551
- const res = await fetch(`${API$11}/files/${encodeURIComponent(args.fileId)}?${params.toString()}`, {
57552
+ const res = await fetch(`${API$10}/files/${encodeURIComponent(args.fileId)}?${params.toString()}`, {
57552
57553
  method: "PATCH",
57553
57554
  headers: {
57554
57555
  authorization: `Bearer ${accessToken}`,
@@ -57653,7 +57654,7 @@ const SCOPES$11 = [
57653
57654
  ];
57654
57655
  const AUTH_URL$13 = "https://accounts.google.com/o/oauth2/v2/auth";
57655
57656
  const TOKEN_URL$15 = "https://oauth2.googleapis.com/token";
57656
- const API$10 = "https://forms.googleapis.com/v1";
57657
+ const API$9 = "https://forms.googleapis.com/v1";
57657
57658
  function googleForms(opts) {
57658
57659
  const { clientId, clientSecret } = opts;
57659
57660
  const timeoutMs = opts.timeoutMs ?? 3e4;
@@ -57880,7 +57881,7 @@ function flattenAnswers(answers) {
57880
57881
  async function getForm(inv, accessToken, timeoutMs) {
57881
57882
  const { formId } = inv.args ?? {};
57882
57883
  if (!formId) throw new Error("google-forms get_form: formId is required");
57883
- const res = await fetch(`${API$10}/forms/${encodeURIComponent(formId)}`, {
57884
+ const res = await fetch(`${API$9}/forms/${encodeURIComponent(formId)}`, {
57884
57885
  headers: { authorization: `Bearer ${accessToken}` },
57885
57886
  signal: AbortSignal.timeout(timeoutMs)
57886
57887
  });
@@ -57907,7 +57908,7 @@ async function listResponses(inv, accessToken, timeoutMs) {
57907
57908
  if (pageToken) params.set("pageToken", pageToken);
57908
57909
  if (filter) params.set("filter", filter);
57909
57910
  const qs = params.toString();
57910
- const url = `${API$10}/forms/${encodeURIComponent(formId)}/responses${qs ? `?${qs}` : ""}`;
57911
+ const url = `${API$9}/forms/${encodeURIComponent(formId)}/responses${qs ? `?${qs}` : ""}`;
57911
57912
  const res = await fetch(url, {
57912
57913
  headers: { authorization: `Bearer ${accessToken}` },
57913
57914
  signal: AbortSignal.timeout(timeoutMs)
@@ -57934,7 +57935,7 @@ async function getResponse(inv, accessToken, timeoutMs) {
57934
57935
  const { formId, responseId } = inv.args ?? {};
57935
57936
  if (!formId) throw new Error("google-forms get_response: formId is required");
57936
57937
  if (!responseId) throw new Error("google-forms get_response: responseId is required");
57937
- const res = await fetch(`${API$10}/forms/${encodeURIComponent(formId)}/responses/${encodeURIComponent(responseId)}`, {
57938
+ const res = await fetch(`${API$9}/forms/${encodeURIComponent(formId)}/responses/${encodeURIComponent(responseId)}`, {
57938
57939
  headers: { authorization: `Bearer ${accessToken}` },
57939
57940
  signal: AbortSignal.timeout(timeoutMs)
57940
57941
  });
@@ -57958,7 +57959,7 @@ async function createForm(inv, accessToken, timeoutMs) {
57958
57959
  if (!title) throw new Error("google-forms create_form: title is required");
57959
57960
  const info = { title };
57960
57961
  if (documentTitle) info.documentTitle = documentTitle;
57961
- const res = await fetch(`${API$10}/forms`, {
57962
+ const res = await fetch(`${API$9}/forms`, {
57962
57963
  method: "POST",
57963
57964
  headers: {
57964
57965
  authorization: `Bearer ${accessToken}`,
@@ -57989,7 +57990,7 @@ async function batchUpdate(inv, accessToken, timeoutMs) {
57989
57990
  const body = { requests };
57990
57991
  if (typeof includeFormInResponse === "boolean") body.includeFormInResponse = includeFormInResponse;
57991
57992
  if (writeControl) body.writeControl = writeControl;
57992
- const res = await fetch(`${API$10}/forms/${encodeURIComponent(formId)}:batchUpdate`, {
57993
+ const res = await fetch(`${API$9}/forms/${encodeURIComponent(formId)}:batchUpdate`, {
57993
57994
  method: "POST",
57994
57995
  headers: {
57995
57996
  authorization: `Bearer ${accessToken}`,
@@ -61555,16 +61556,18 @@ const helpscoutConnector = declarativeRestConnector({
61555
61556
  */
61556
61557
  const SCOPE_CONTACTS_READ = "crm.objects.contacts.read";
61557
61558
  const SCOPE_CONTACTS_WRITE = "crm.objects.contacts.write";
61559
+ const SCOPE_DEALS_READ = "crm.objects.deals.read";
61558
61560
  const SCOPE_DEALS_WRITE = "crm.objects.deals.write";
61559
61561
  const SCOPE_TICKETS_WRITE = "tickets";
61560
61562
  const SCOPES_BASE = [
61561
61563
  "oauth",
61562
61564
  SCOPE_CONTACTS_READ,
61563
- SCOPE_CONTACTS_WRITE
61565
+ SCOPE_CONTACTS_WRITE,
61566
+ SCOPE_DEALS_READ
61564
61567
  ];
61565
61568
  const AUTH_URL$10 = "https://app.hubspot.com/oauth/authorize";
61566
61569
  const TOKEN_URL$12 = "https://api.hubapi.com/oauth/v1/token";
61567
- const API$9 = "https://api.hubapi.com";
61570
+ const API$8 = "https://api.hubapi.com";
61568
61571
  function hubspot(opts) {
61569
61572
  const { clientId, clientSecret } = opts;
61570
61573
  const scopes = opts.includeWriteScope ? [
@@ -61822,7 +61825,7 @@ function hubspot(opts) {
61822
61825
  if (inv.capabilityName !== "find_contact") throw new Error(`hubspot: unknown read capability ${inv.capabilityName}`);
61823
61826
  const { email } = inv.args;
61824
61827
  const accessToken = await ensureFreshAccessToken$7(inv.source.credentials, clientId, clientSecret);
61825
- const res = await fetch(`${API$9}/crm/v3/objects/contacts/search`, {
61828
+ const res = await fetch(`${API$8}/crm/v3/objects/contacts/search`, {
61826
61829
  method: "POST",
61827
61830
  headers: {
61828
61831
  authorization: `Bearer ${accessToken}`,
@@ -61911,7 +61914,7 @@ function hubspot(opts) {
61911
61914
  async test(source) {
61912
61915
  try {
61913
61916
  const accessToken = await ensureFreshAccessToken$7(source.credentials, clientId, clientSecret);
61914
- const res = await fetch(`${API$9}/oauth/v1/access-tokens/${encodeURIComponent(accessToken)}`, { signal: AbortSignal.timeout(8e3) });
61917
+ const res = await fetch(`${API$8}/oauth/v1/access-tokens/${encodeURIComponent(accessToken)}`, { signal: AbortSignal.timeout(8e3) });
61915
61918
  if (res.status === 401 || res.status === 403 || res.status === 404) return {
61916
61919
  ok: false,
61917
61920
  reason: `HubSpot rejected token (${res.status}) — reconnect required`
@@ -61933,7 +61936,7 @@ function hubspot(opts) {
61933
61936
  async function upsertContact(inv, accessToken) {
61934
61937
  const { email, properties } = inv.args;
61935
61938
  const idemKey = sanitizeIdempotencyKey(inv.idempotencyKey);
61936
- const url = `${API$9}/crm/v3/objects/contacts/batch/upsert?idempotencyKey=${encodeURIComponent(idemKey)}`;
61939
+ const url = `${API$8}/crm/v3/objects/contacts/batch/upsert?idempotencyKey=${encodeURIComponent(idemKey)}`;
61937
61940
  const body = { inputs: [{
61938
61941
  idProperty: "email",
61939
61942
  id: email.toLowerCase(),
@@ -61976,7 +61979,7 @@ async function upsertContact(inv, accessToken) {
61976
61979
  async function createNote(inv, accessToken) {
61977
61980
  const { contactId, body } = inv.args;
61978
61981
  const idemKey = sanitizeIdempotencyKey(inv.idempotencyKey);
61979
- const url = `${API$9}/crm/v3/objects/notes/batch/create?idempotencyKey=${encodeURIComponent(idemKey)}`;
61982
+ const url = `${API$8}/crm/v3/objects/notes/batch/create?idempotencyKey=${encodeURIComponent(idemKey)}`;
61980
61983
  const payload = { inputs: [{
61981
61984
  properties: {
61982
61985
  hs_note_body: body,
@@ -62035,7 +62038,7 @@ async function createDeal(inv, accessToken, timeoutMs) {
62035
62038
  associationTypeId: 3
62036
62039
  }]
62037
62040
  }));
62038
- const res = await fetch(`${API$9}/crm/v3/objects/deals`, {
62041
+ const res = await fetch(`${API$8}/crm/v3/objects/deals`, {
62039
62042
  method: "POST",
62040
62043
  headers: {
62041
62044
  authorization: `Bearer ${accessToken}`,
@@ -62070,7 +62073,7 @@ async function updateDealStage(inv, accessToken, timeoutMs) {
62070
62073
  const args = inv.args ?? {};
62071
62074
  if (!args.dealId) throw new Error("hubspot update_deal_stage: `dealId` is required");
62072
62075
  if (!args.dealstage) throw new Error("hubspot update_deal_stage: `dealstage` is required");
62073
- const res = await fetch(`${API$9}/crm/v3/objects/deals/${encodeURIComponent(args.dealId)}`, {
62076
+ const res = await fetch(`${API$8}/crm/v3/objects/deals/${encodeURIComponent(args.dealId)}`, {
62074
62077
  method: "PATCH",
62075
62078
  headers: {
62076
62079
  authorization: `Bearer ${accessToken}`,
@@ -62109,7 +62112,7 @@ async function createTicket(inv, accessToken, timeoutMs) {
62109
62112
  if (args.properties.content !== void 0) ticketProperties.content = args.properties.content;
62110
62113
  if (args.properties.hs_pipeline_stage !== void 0) ticketProperties.hs_pipeline_stage = args.properties.hs_pipeline_stage;
62111
62114
  if (args.properties.hs_ticket_priority !== void 0) ticketProperties.hs_ticket_priority = args.properties.hs_ticket_priority;
62112
- const res = await fetch(`${API$9}/crm/v3/objects/tickets`, {
62115
+ const res = await fetch(`${API$8}/crm/v3/objects/tickets`, {
62113
62116
  method: "POST",
62114
62117
  headers: {
62115
62118
  authorization: `Bearer ${accessToken}`,
@@ -62172,7 +62175,7 @@ async function searchCreatedSince(inv, accessToken, object, properties, label) {
62172
62175
  const { createdAfter, limit, after } = inv.args;
62173
62176
  const since = Date.parse(createdAfter);
62174
62177
  if (!Number.isFinite(since)) throw new Error(`hubspot ${label}: createdAfter must be an ISO-8601 time`);
62175
- const res = await fetch(`${API$9}/crm/v3/objects/${object}/search`, {
62178
+ const res = await fetch(`${API$8}/crm/v3/objects/${object}/search`, {
62176
62179
  method: "POST",
62177
62180
  headers: {
62178
62181
  authorization: `Bearer ${accessToken}`,
@@ -62259,7 +62262,7 @@ async function listNewContacts(inv, accessToken) {
62259
62262
  };
62260
62263
  }
62261
62264
  async function hubspotJson(inv, accessToken, path, init = {}) {
62262
- const res = await fetch(`${API$9}${path}`, {
62265
+ const res = await fetch(`${API$8}${path}`, {
62263
62266
  ...init,
62264
62267
  headers: {
62265
62268
  authorization: `Bearer ${accessToken}`,
@@ -76323,7 +76326,7 @@ const SCOPE_WRITE = "https://graph.microsoft.com/Files.ReadWrite";
76323
76326
  const SCOPE_OFFLINE$1 = "offline_access";
76324
76327
  const AUTH_URL$6 = "https://login.microsoftonline.com/common/oauth2/v2.0/authorize";
76325
76328
  const TOKEN_URL$7 = "https://login.microsoftonline.com/common/oauth2/v2.0/token";
76326
- const API$8 = "https://graph.microsoft.com/v1.0";
76329
+ const API$7 = "https://graph.microsoft.com/v1.0";
76327
76330
  function oneDrive(opts) {
76328
76331
  const { clientId, clientSecret } = opts;
76329
76332
  const timeoutMs = opts.timeoutMs ?? 3e4;
@@ -76640,7 +76643,7 @@ function oneDrive(opts) {
76640
76643
  async test(source) {
76641
76644
  try {
76642
76645
  const accessToken = await ensureFreshAccessToken$3(source.credentials, clientId, clientSecret);
76643
- const res = await fetch(`${API$8}/me/drive?$select=id`, {
76646
+ const res = await fetch(`${API$7}/me/drive?$select=id`, {
76644
76647
  headers: { authorization: `Bearer ${accessToken}` },
76645
76648
  signal: AbortSignal.timeout(8e3)
76646
76649
  });
@@ -76674,7 +76677,7 @@ async function listFiles(inv, accessToken, timeoutMs) {
76674
76677
  const headers = { authorization: `Bearer ${accessToken}` };
76675
76678
  if (args.query) headers["ConsistencyLevel"] = "eventual";
76676
76679
  const path = args.folderId ? `/me/drive/items/${encodeURIComponent(args.folderId)}/children` : "/me/drive/root/children";
76677
- const url = !!args.query && !args.folderId ? `${API$8}/me/drive/root/search(q=${encodeURIComponent(`'${args.query.replace(/'/g, "''")}'`)})?${stripSearch(params).toString()}` : `${API$8}${path}?${params.toString()}`;
76680
+ const url = !!args.query && !args.folderId ? `${API$7}/me/drive/root/search(q=${encodeURIComponent(`'${args.query.replace(/'/g, "''")}'`)})?${stripSearch(params).toString()}` : `${API$7}${path}?${params.toString()}`;
76678
76681
  const res = await fetch(url, {
76679
76682
  headers,
76680
76683
  signal: AbortSignal.timeout(timeoutMs)
@@ -76703,7 +76706,7 @@ function stripSearch(params) {
76703
76706
  async function readFile(inv, accessToken, timeoutMs) {
76704
76707
  const { fileId } = inv.args ?? {};
76705
76708
  if (!fileId) throw new Error("onedrive read_file: fileId is required");
76706
- const metaUrl = `${API$8}/me/drive/items/${encodeURIComponent(fileId)}?$select=id,name,eTag,lastModifiedDateTime,size,file,folder`;
76709
+ const metaUrl = `${API$7}/me/drive/items/${encodeURIComponent(fileId)}?$select=id,name,eTag,lastModifiedDateTime,size,file,folder`;
76707
76710
  const metaRes = await fetch(metaUrl, {
76708
76711
  headers: { authorization: `Bearer ${accessToken}` },
76709
76712
  signal: AbortSignal.timeout(timeoutMs)
@@ -76718,7 +76721,7 @@ async function readFile(inv, accessToken, timeoutMs) {
76718
76721
  if (meta.folder) throw new Error(`onedrive read_file: item ${fileId} is a folder, not a file`);
76719
76722
  const mimeType = meta.file?.mimeType ?? "application/octet-stream";
76720
76723
  const fetchedAt = Date.now();
76721
- const contentRes = await fetch(`${API$8}/me/drive/items/${encodeURIComponent(fileId)}/content`, {
76724
+ const contentRes = await fetch(`${API$7}/me/drive/items/${encodeURIComponent(fileId)}/content`, {
76722
76725
  headers: { authorization: `Bearer ${accessToken}` },
76723
76726
  signal: AbortSignal.timeout(timeoutMs)
76724
76727
  });
@@ -76767,7 +76770,7 @@ async function watchFolder(inv, accessToken, timeoutMs) {
76767
76770
  expirationDateTime,
76768
76771
  clientState: clientState ?? inv.idempotencyKey
76769
76772
  };
76770
- const res = await fetch(`${API$8}/subscriptions`, {
76773
+ const res = await fetch(`${API$7}/subscriptions`, {
76771
76774
  method: "POST",
76772
76775
  headers: {
76773
76776
  authorization: `Bearer ${accessToken}`,
@@ -76803,7 +76806,7 @@ async function uploadFile$1(inv, accessToken, timeoutMs) {
76803
76806
  if (fileContent === void 0 || fileContent === null) throw new Error("onedrive files.upload: fileContent is required");
76804
76807
  const body = encoding === "base64" ? Buffer.from(fileContent, "base64") : Buffer.from(fileContent, "utf-8");
76805
76808
  const parentSegment = folderId === "root" ? "/me/drive/root" : `/me/drive/items/${encodeURIComponent(folderId)}`;
76806
- const url = `${API$8}${parentSegment}:/${encodeURIComponent(fileName)}:/content`;
76809
+ const url = `${API$7}${parentSegment}:/${encodeURIComponent(fileName)}:/content`;
76807
76810
  const res = await fetch(url, {
76808
76811
  method: "PUT",
76809
76812
  headers: {
@@ -76837,7 +76840,7 @@ async function uploadFile$1(inv, accessToken, timeoutMs) {
76837
76840
  async function deleteItem(inv, accessToken, timeoutMs) {
76838
76841
  const { itemId } = inv.args ?? {};
76839
76842
  if (!itemId) throw new Error("onedrive files.delete: itemId is required");
76840
- const res = await fetch(`${API$8}${itemPath(itemId)}`, {
76843
+ const res = await fetch(`${API$7}${itemPath(itemId)}`, {
76841
76844
  method: "DELETE",
76842
76845
  headers: { authorization: `Bearer ${accessToken}` },
76843
76846
  signal: AbortSignal.timeout(timeoutMs)
@@ -76873,7 +76876,7 @@ async function moveItem(inv, accessToken, timeoutMs) {
76873
76876
  const body = {};
76874
76877
  if (newParentId) body.parentReference = newParentId === "root" ? { path: "/drive/root" } : { id: newParentId };
76875
76878
  if (newName) body.name = newName;
76876
- const res = await fetch(`${API$8}${itemPath(itemId)}`, {
76879
+ const res = await fetch(`${API$7}${itemPath(itemId)}`, {
76877
76880
  method: "PATCH",
76878
76881
  headers: {
76879
76882
  authorization: `Bearer ${accessToken}`,
@@ -76911,7 +76914,7 @@ async function shareItem(inv, accessToken, timeoutMs) {
76911
76914
  };
76912
76915
  if (password) body.password = password;
76913
76916
  if (expirationDateTime) body.expirationDateTime = expirationDateTime;
76914
- const res = await fetch(`${API$8}${itemPath(itemId)}/createLink`, {
76917
+ const res = await fetch(`${API$7}${itemPath(itemId)}/createLink`, {
76915
76918
  method: "POST",
76916
76919
  headers: {
76917
76920
  authorization: `Bearer ${accessToken}`,
@@ -76948,7 +76951,7 @@ async function createFolder(inv, accessToken, timeoutMs) {
76948
76951
  folder: {},
76949
76952
  "@microsoft.graph.conflictBehavior": conflictBehavior ?? "fail"
76950
76953
  };
76951
- const res = await fetch(`${API$8}${parentSegment}`, {
76954
+ const res = await fetch(`${API$7}${parentSegment}`, {
76952
76955
  method: "POST",
76953
76956
  headers: {
76954
76957
  authorization: `Bearer ${accessToken}`,
@@ -77225,7 +77228,7 @@ const SCOPE_RW = "https://graph.microsoft.com/Mail.ReadWrite";
77225
77228
  const SCOPE_OFFLINE = "offline_access";
77226
77229
  const AUTH_URL$5 = "https://login.microsoftonline.com/common/oauth2/v2.0/authorize";
77227
77230
  const TOKEN_URL$6 = "https://login.microsoftonline.com/common/oauth2/v2.0/token";
77228
- const API$7 = "https://graph.microsoft.com/v1.0";
77231
+ const API$6 = "https://graph.microsoft.com/v1.0";
77229
77232
  function outlookMail(opts) {
77230
77233
  const { clientId, clientSecret } = opts;
77231
77234
  const timeoutMs = opts.timeoutMs ?? 3e4;
@@ -77651,7 +77654,7 @@ function outlookMail(opts) {
77651
77654
  async test(source) {
77652
77655
  try {
77653
77656
  const accessToken = await ensureFreshAccessToken$2(source.credentials, clientId, clientSecret);
77654
- const res = await fetch(`${API$7}/me?$select=id,userPrincipalName`, {
77657
+ const res = await fetch(`${API$6}/me?$select=id,userPrincipalName`, {
77655
77658
  headers: { authorization: `Bearer ${accessToken}` },
77656
77659
  signal: AbortSignal.timeout(8e3)
77657
77660
  });
@@ -77685,7 +77688,7 @@ async function listMessages(inv, accessToken, timeoutMs) {
77685
77688
  if (args.skipToken) params.set("$skiptoken", args.skipToken);
77686
77689
  const headers = { authorization: `Bearer ${accessToken}` };
77687
77690
  if (args.query) headers["ConsistencyLevel"] = "eventual";
77688
- const res = await fetch(`${API$7}/me/mailFolders/${folder}/messages?${params.toString()}`, {
77691
+ const res = await fetch(`${API$6}/me/mailFolders/${folder}/messages?${params.toString()}`, {
77689
77692
  headers,
77690
77693
  signal: AbortSignal.timeout(timeoutMs)
77691
77694
  });
@@ -77719,7 +77722,7 @@ function toMessageSummary(m) {
77719
77722
  }
77720
77723
  async function readMessage(inv, accessToken, timeoutMs) {
77721
77724
  const { id } = inv.args;
77722
- const url = `${API$7}/me/messages/${encodeURIComponent(id)}?$expand=attachments($select=id,name,contentType,size,isInline)`;
77725
+ const url = `${API$6}/me/messages/${encodeURIComponent(id)}?$expand=attachments($select=id,name,contentType,size,isInline)`;
77723
77726
  const res = await fetch(url, {
77724
77727
  headers: { authorization: `Bearer ${accessToken}` },
77725
77728
  signal: AbortSignal.timeout(timeoutMs)
@@ -77758,7 +77761,7 @@ async function readMessage(inv, accessToken, timeoutMs) {
77758
77761
  async function sendReply(inv, accessToken, timeoutMs) {
77759
77762
  const { messageId, body, bodyType, replyAll, comment } = inv.args;
77760
77763
  const action = replyAll ? "createReplyAll" : "createReply";
77761
- const draftRes = await fetch(`${API$7}/me/messages/${encodeURIComponent(messageId)}/${action}`, {
77764
+ const draftRes = await fetch(`${API$6}/me/messages/${encodeURIComponent(messageId)}/${action}`, {
77762
77765
  method: "POST",
77763
77766
  headers: {
77764
77767
  authorization: `Bearer ${accessToken}`,
@@ -77783,7 +77786,7 @@ async function sendReply(inv, accessToken, timeoutMs) {
77783
77786
  value: inv.idempotencyKey
77784
77787
  }]
77785
77788
  };
77786
- const patchRes = await fetch(`${API$7}/me/messages/${encodeURIComponent(draft.id)}`, {
77789
+ const patchRes = await fetch(`${API$6}/me/messages/${encodeURIComponent(draft.id)}`, {
77787
77790
  method: "PATCH",
77788
77791
  headers: {
77789
77792
  authorization: `Bearer ${accessToken}`,
@@ -77797,7 +77800,7 @@ async function sendReply(inv, accessToken, timeoutMs) {
77797
77800
  const text = await patchRes.text().catch(() => "");
77798
77801
  throw new Error(`outlook-mail send_reply patch ${patchRes.status}: ${text.slice(0, 200)}`);
77799
77802
  }
77800
- const sendRes = await fetch(`${API$7}/me/messages/${encodeURIComponent(draft.id)}/send`, {
77803
+ const sendRes = await fetch(`${API$6}/me/messages/${encodeURIComponent(draft.id)}/send`, {
77801
77804
  method: "POST",
77802
77805
  headers: { authorization: `Bearer ${accessToken}` },
77803
77806
  signal: AbortSignal.timeout(timeoutMs)
@@ -77853,7 +77856,7 @@ function buildMessagePayload(args, idempotencyKey, cap) {
77853
77856
  async function sendMessage(inv, accessToken, timeoutMs) {
77854
77857
  const args = inv.args ?? {};
77855
77858
  const message = buildMessagePayload(args, inv.idempotencyKey, "send_message");
77856
- const res = await fetch(`${API$7}/me/sendMail`, {
77859
+ const res = await fetch(`${API$6}/me/sendMail`, {
77857
77860
  method: "POST",
77858
77861
  headers: {
77859
77862
  authorization: `Bearer ${accessToken}`,
@@ -77883,7 +77886,7 @@ async function sendMessage(inv, accessToken, timeoutMs) {
77883
77886
  }
77884
77887
  async function createDraft(inv, accessToken, timeoutMs) {
77885
77888
  const message = buildMessagePayload(inv.args ?? {}, inv.idempotencyKey, "create_draft");
77886
- const res = await fetch(`${API$7}/me/messages`, {
77889
+ const res = await fetch(`${API$6}/me/messages`, {
77887
77890
  method: "POST",
77888
77891
  headers: {
77889
77892
  authorization: `Bearer ${accessToken}`,
@@ -77922,7 +77925,7 @@ async function subscribeFolder(inv, accessToken, timeoutMs) {
77922
77925
  expirationDateTime,
77923
77926
  clientState: clientState ?? inv.idempotencyKey
77924
77927
  };
77925
- const res = await fetch(`${API$7}/subscriptions`, {
77928
+ const res = await fetch(`${API$6}/subscriptions`, {
77926
77929
  method: "POST",
77927
77930
  headers: {
77928
77931
  authorization: `Bearer ${accessToken}`,
@@ -77956,7 +77959,7 @@ async function forwardMessage(inv, accessToken, timeoutMs) {
77956
77959
  const toList = Array.isArray(to) ? to : [to];
77957
77960
  const fwdBody = { toRecipients: toList.map((address) => ({ emailAddress: { address } })) };
77958
77961
  if (comment !== void 0) fwdBody.comment = comment;
77959
- const res = await fetch(`${API$7}/me/messages/${encodeURIComponent(messageId)}/forward`, {
77962
+ const res = await fetch(`${API$6}/me/messages/${encodeURIComponent(messageId)}/forward`, {
77960
77963
  method: "POST",
77961
77964
  headers: {
77962
77965
  authorization: `Bearer ${accessToken}`,
@@ -77985,7 +77988,7 @@ async function moveMessage(inv, accessToken, timeoutMs) {
77985
77988
  const { messageId, destinationId } = inv.args;
77986
77989
  if (!messageId) throw new Error("outlook-mail move_message: `messageId` is required");
77987
77990
  if (!destinationId) throw new Error("outlook-mail move_message: `destinationId` is required");
77988
- const res = await fetch(`${API$7}/me/messages/${encodeURIComponent(messageId)}/move`, {
77991
+ const res = await fetch(`${API$6}/me/messages/${encodeURIComponent(messageId)}/move`, {
77989
77992
  method: "POST",
77990
77993
  headers: {
77991
77994
  authorization: `Bearer ${accessToken}`,
@@ -78016,7 +78019,7 @@ async function setLabels(inv, accessToken, timeoutMs) {
78016
78019
  const { messageId, categories } = inv.args;
78017
78020
  if (!messageId) throw new Error("outlook-mail set_labels: `messageId` is required");
78018
78021
  if (!Array.isArray(categories)) throw new Error("outlook-mail set_labels: `categories` must be an array (the full desired set)");
78019
- const res = await fetch(`${API$7}/me/messages/${encodeURIComponent(messageId)}`, {
78022
+ const res = await fetch(`${API$6}/me/messages/${encodeURIComponent(messageId)}`, {
78020
78023
  method: "PATCH",
78021
78024
  headers: {
78022
78025
  authorization: `Bearer ${accessToken}`,
@@ -78044,7 +78047,7 @@ async function setLabels(inv, accessToken, timeoutMs) {
78044
78047
  async function sendDraft(inv, accessToken, timeoutMs) {
78045
78048
  const { messageId } = inv.args;
78046
78049
  if (!messageId) throw new Error("outlook-mail send_draft: `messageId` is required");
78047
- const res = await fetch(`${API$7}/me/messages/${encodeURIComponent(messageId)}/send`, {
78050
+ const res = await fetch(`${API$6}/me/messages/${encodeURIComponent(messageId)}/send`, {
78048
78051
  method: "POST",
78049
78052
  headers: { authorization: `Bearer ${accessToken}` },
78050
78053
  signal: AbortSignal.timeout(timeoutMs)
@@ -78066,7 +78069,7 @@ async function sendDraft(inv, accessToken, timeoutMs) {
78066
78069
  }
78067
78070
  async function downloadAttachment$1(inv, accessToken, timeoutMs) {
78068
78071
  const { messageId, attachmentId } = inv.args;
78069
- const url = `${API$7}/me/messages/${encodeURIComponent(messageId)}/attachments/${encodeURIComponent(attachmentId)}`;
78072
+ const url = `${API$6}/me/messages/${encodeURIComponent(messageId)}/attachments/${encodeURIComponent(attachmentId)}`;
78070
78073
  const res = await fetch(url, {
78071
78074
  headers: { authorization: `Bearer ${accessToken}` },
78072
78075
  signal: AbortSignal.timeout(timeoutMs)
@@ -78170,10 +78173,10 @@ async function ensureFreshAccessToken$2(creds, clientId, clientSecret, onCredent
78170
78173
  const SCOPES$5 = ["read", "read+write"];
78171
78174
  const AUTH_URL$4 = "https://app.pandadoc.com/oauth2/authorize";
78172
78175
  const TOKEN_URL$5 = "https://api.pandadoc.com/oauth2/access_token";
78173
- const API$6 = "https://api.pandadoc.com/public/v1";
78176
+ const API$5 = "https://api.pandadoc.com/public/v1";
78174
78177
  function pandadoc(opts) {
78175
78178
  const { clientId, clientSecret } = opts;
78176
- const baseUrl = (opts.baseUrl ?? API$6).replace(/\/$/, "");
78179
+ const baseUrl = (opts.baseUrl ?? API$5).replace(/\/$/, "");
78177
78180
  const timeoutMs = opts.timeoutMs ?? 3e4;
78178
78181
  return {
78179
78182
  manifest: {
@@ -85486,7 +85489,7 @@ const SCOPES$3 = [
85486
85489
  ];
85487
85490
  const AUTH_URL$2 = "https://slack.com/oauth/v2/authorize";
85488
85491
  const TOKEN_URL$3 = "https://slack.com/api/oauth.v2.access";
85489
- const API$5 = "https://slack.com/api";
85492
+ const API$4 = "https://slack.com/api";
85490
85493
  function slack(opts) {
85491
85494
  const { clientId, clientSecret } = opts;
85492
85495
  return {
@@ -85709,7 +85712,7 @@ function slack(opts) {
85709
85712
  const accessToken = readBotToken(inv.source.credentials);
85710
85713
  if (inv.capabilityName === "lookup_user") {
85711
85714
  const { email } = inv.args;
85712
- const json = await slackGet(`${API$5}/users.lookupByEmail?email=${encodeURIComponent(email)}`, accessToken, inv.source.id);
85715
+ const json = await slackGet(`${API$4}/users.lookupByEmail?email=${encodeURIComponent(email)}`, accessToken, inv.source.id);
85713
85716
  if (!json.ok) {
85714
85717
  if (json.error === "users_not_found") return {
85715
85718
  data: { found: false },
@@ -85736,7 +85739,7 @@ function slack(opts) {
85736
85739
  limit: String(Math.min(Math.max(1, limit ?? 200), 1e3)),
85737
85740
  types: types ?? "public_channel,private_channel"
85738
85741
  });
85739
- const json = await slackGet(`${API$5}/conversations.list?${params.toString()}`, accessToken, inv.source.id);
85742
+ const json = await slackGet(`${API$4}/conversations.list?${params.toString()}`, accessToken, inv.source.id);
85740
85743
  if (!json.ok) throw new Error(`slack list_channels: ${json.error ?? "unknown"}`);
85741
85744
  return {
85742
85745
  data: { channels: (json.channels ?? []).map((c) => ({
@@ -85799,7 +85802,7 @@ function slack(opts) {
85799
85802
  async test(source) {
85800
85803
  try {
85801
85804
  const accessToken = readBotToken(source.credentials);
85802
- const res = await fetch(`${API$5}/auth.test`, {
85805
+ const res = await fetch(`${API$4}/auth.test`, {
85803
85806
  method: "POST",
85804
85807
  headers: { authorization: `Bearer ${accessToken}` },
85805
85808
  signal: AbortSignal.timeout(8e3)
@@ -85843,7 +85846,7 @@ async function downloadFile(inv, accessToken) {
85843
85846
  const { file_id: rawFileId } = inv.args;
85844
85847
  const fileId = typeof rawFileId === "string" ? rawFileId.trim() : "";
85845
85848
  if (!fileId || fileId.length > 300) throw new Error("slack download_file: a bounded `file_id` is required");
85846
- const info = await slackGet(`${API$5}/files.info?file=${encodeURIComponent(fileId)}`, accessToken, inv.source.id);
85849
+ const info = await slackGet(`${API$4}/files.info?file=${encodeURIComponent(fileId)}`, accessToken, inv.source.id);
85847
85850
  if (!info.ok) {
85848
85851
  if (isAuthError(info.error)) throw new CredentialsExpired(`Slack rejected token: ${info.error}`, inv.source.id);
85849
85852
  throw new Error(`slack download_file: ${info.error ?? "unknown"}`);
@@ -85943,7 +85946,7 @@ async function slackPostJson(url, accessToken, body, timeoutMs, dataSourceId, ca
85943
85946
  async function postMessage(inv, accessToken, timeoutMs) {
85944
85947
  const { channel, text, blocks } = inv.args;
85945
85948
  if (!channel) throw new Error("slack post_message: `channel` is required");
85946
- const json = await slackPostJson(`${API$5}/chat.postMessage`, accessToken, {
85949
+ const json = await slackPostJson(`${API$4}/chat.postMessage`, accessToken, {
85947
85950
  channel,
85948
85951
  text,
85949
85952
  blocks
@@ -85962,7 +85965,7 @@ async function postInThread(inv, accessToken, timeoutMs) {
85962
85965
  const { channel, thread_ts, text, blocks } = inv.args;
85963
85966
  if (!channel) throw new Error("slack post_in_thread: `channel` is required");
85964
85967
  if (!thread_ts) throw new Error("slack post_in_thread: `thread_ts` is required");
85965
- const json = await slackPostJson(`${API$5}/chat.postMessage`, accessToken, {
85968
+ const json = await slackPostJson(`${API$4}/chat.postMessage`, accessToken, {
85966
85969
  channel,
85967
85970
  thread_ts,
85968
85971
  text,
@@ -85984,7 +85987,7 @@ async function updateMessage(inv, accessToken, timeoutMs) {
85984
85987
  if (!channel) throw new Error("slack update_message: `channel` is required");
85985
85988
  if (!ts) throw new Error("slack update_message: `ts` is required");
85986
85989
  if (text === void 0 && blocks === void 0) throw new Error("slack update_message: `text` or `blocks` is required");
85987
- const json = await slackPostJson(`${API$5}/chat.update`, accessToken, {
85990
+ const json = await slackPostJson(`${API$4}/chat.update`, accessToken, {
85988
85991
  channel,
85989
85992
  ts,
85990
85993
  text,
@@ -86005,7 +86008,7 @@ async function deleteMessage(inv, accessToken, timeoutMs) {
86005
86008
  const { channel, ts } = inv.args;
86006
86009
  if (!channel) throw new Error("slack delete_message: `channel` is required");
86007
86010
  if (!ts) throw new Error("slack delete_message: `ts` is required");
86008
- const json = await slackPostJson(`${API$5}/chat.delete`, accessToken, {
86011
+ const json = await slackPostJson(`${API$4}/chat.delete`, accessToken, {
86009
86012
  channel,
86010
86013
  ts
86011
86014
  }, timeoutMs, inv.source.id, "delete_message");
@@ -86024,7 +86027,7 @@ async function addReaction(inv, accessToken, timeoutMs) {
86024
86027
  if (!channel) throw new Error("slack add_reaction: `channel` is required");
86025
86028
  if (!timestamp) throw new Error("slack add_reaction: `timestamp` is required");
86026
86029
  if (!name) throw new Error("slack add_reaction: `name` is required");
86027
- const res = await fetch(`${API$5}/reactions.add`, {
86030
+ const res = await fetch(`${API$4}/reactions.add`, {
86028
86031
  method: "POST",
86029
86032
  headers: {
86030
86033
  authorization: `Bearer ${accessToken}`,
@@ -86074,7 +86077,7 @@ async function uploadFile(inv, accessToken, timeoutMs) {
86074
86077
  if (!args.filename) throw new Error("slack upload_file: `filename` is required");
86075
86078
  if (!args.content) throw new Error("slack upload_file: `content` is required");
86076
86079
  const bytes = Buffer.from(args.content, "base64");
86077
- const stepOne = await fetch(`${API$5}/files.getUploadURLExternal`, {
86080
+ const stepOne = await fetch(`${API$4}/files.getUploadURLExternal`, {
86078
86081
  method: "POST",
86079
86082
  headers: {
86080
86083
  authorization: `Bearer ${accessToken}`,
@@ -86114,7 +86117,7 @@ async function uploadFile(inv, accessToken, timeoutMs) {
86114
86117
  channel_id: args.channels.join(",")
86115
86118
  };
86116
86119
  if (args.initial_comment) completePayload.initial_comment = args.initial_comment;
86117
- const files = (await slackPostJson(`${API$5}/files.completeUploadExternal`, accessToken, completePayload, timeoutMs, inv.source.id, "upload_file")).files ?? [];
86120
+ const files = (await slackPostJson(`${API$4}/files.completeUploadExternal`, accessToken, completePayload, timeoutMs, inv.source.id, "upload_file")).files ?? [];
86118
86121
  return {
86119
86122
  status: "committed",
86120
86123
  data: {
@@ -87274,7 +87277,7 @@ const squareConnector = declarativeRestConnector({
87274
87277
  * directly. MutationGuard short-circuits before us on retry; Stripe's
87275
87278
  * own dedup is the second line of defense.
87276
87279
  */
87277
- const API$4 = "https://api.stripe.com/v1";
87280
+ const API$3 = "https://api.stripe.com/v1";
87278
87281
  /** Stripe events that mean a new customer: an account, a purchase, or a subscription or trial. */
87279
87282
  const SIGNUP_EVENT_TYPES = [
87280
87283
  "customer.created",
@@ -87596,7 +87599,7 @@ const stripePackConnector = {
87596
87599
  if (inv.capabilityName === "list_signup_events") return listSignupEvents(inv, apiKey);
87597
87600
  if (inv.capabilityName !== "find_customer") throw new Error(`stripe-pack: unknown read capability ${inv.capabilityName}`);
87598
87601
  const { email } = inv.args;
87599
- const url = `${API$4}/customers/search?query=${encodeURIComponent(`email:'${email.toLowerCase()}'`)}&limit=1`;
87602
+ const url = `${API$3}/customers/search?query=${encodeURIComponent(`email:'${email.toLowerCase()}'`)}&limit=1`;
87600
87603
  const res = await fetch(url, {
87601
87604
  headers: { authorization: `Bearer ${apiKey}` },
87602
87605
  signal: AbortSignal.timeout(1e4)
@@ -87634,7 +87637,7 @@ const stripePackConnector = {
87634
87637
  async test(source) {
87635
87638
  try {
87636
87639
  const apiKey = readApiKey(source.credentials);
87637
- const res = await fetch(`${API$4}/account`, {
87640
+ const res = await fetch(`${API$3}/account`, {
87638
87641
  headers: { authorization: `Bearer ${apiKey}` },
87639
87642
  signal: AbortSignal.timeout(8e3)
87640
87643
  });
@@ -87667,7 +87670,7 @@ async function createInvoice(inv, apiKey) {
87667
87670
  quantity: String(it.quantity ?? 1)
87668
87671
  });
87669
87672
  if (it.description) body.set("description", it.description);
87670
- const res = await fetch(`${API$4}/invoiceitems`, {
87673
+ const res = await fetch(`${API$3}/invoiceitems`, {
87671
87674
  method: "POST",
87672
87675
  headers: {
87673
87676
  authorization: `Bearer ${apiKey}`,
@@ -87690,7 +87693,7 @@ async function createInvoice(inv, apiKey) {
87690
87693
  collection_method: "send_invoice",
87691
87694
  days_until_due: "14"
87692
87695
  });
87693
- const invRes = await fetch(`${API$4}/invoices`, {
87696
+ const invRes = await fetch(`${API$3}/invoices`, {
87694
87697
  method: "POST",
87695
87698
  headers: {
87696
87699
  authorization: `Bearer ${apiKey}`,
@@ -87730,7 +87733,7 @@ async function createCheckoutSession(inv, apiKey) {
87730
87733
  body.set(`line_items[${i}][price]`, it.price);
87731
87734
  body.set(`line_items[${i}][quantity]`, String(it.quantity ?? 1));
87732
87735
  });
87733
- const res = await fetch(`${API$4}/checkout/sessions`, {
87736
+ const res = await fetch(`${API$3}/checkout/sessions`, {
87734
87737
  method: "POST",
87735
87738
  headers: {
87736
87739
  authorization: `Bearer ${apiKey}`,
@@ -87759,7 +87762,7 @@ async function createCheckoutSession(inv, apiKey) {
87759
87762
  };
87760
87763
  }
87761
87764
  async function stripeGet(inv, apiKey, path, label) {
87762
- const res = await fetch(`${API$4}${path}`, {
87765
+ const res = await fetch(`${API$3}${path}`, {
87763
87766
  headers: { authorization: `Bearer ${apiKey}` },
87764
87767
  signal: AbortSignal.timeout(1e4)
87765
87768
  });
@@ -87838,7 +87841,7 @@ async function listSubscriptions(inv, apiKey) {
87838
87841
  });
87839
87842
  if (status && status !== "all") params.set("status", status);
87840
87843
  else params.set("status", "all");
87841
- const res = await fetch(`${API$4}/subscriptions?${params.toString()}`, {
87844
+ const res = await fetch(`${API$3}/subscriptions?${params.toString()}`, {
87842
87845
  headers: { authorization: `Bearer ${apiKey}` },
87843
87846
  signal: AbortSignal.timeout(1e4)
87844
87847
  });
@@ -87869,7 +87872,7 @@ async function cancelSubscription(inv, apiKey) {
87869
87872
  let res;
87870
87873
  if (atPeriodEnd) {
87871
87874
  const body = new URLSearchParams({ cancel_at_period_end: "true" });
87872
- res = await fetch(`${API$4}/subscriptions/${encodeURIComponent(subscriptionId)}`, {
87875
+ res = await fetch(`${API$3}/subscriptions/${encodeURIComponent(subscriptionId)}`, {
87873
87876
  method: "POST",
87874
87877
  headers: {
87875
87878
  authorization: `Bearer ${apiKey}`,
@@ -87879,7 +87882,7 @@ async function cancelSubscription(inv, apiKey) {
87879
87882
  body,
87880
87883
  signal: AbortSignal.timeout(15e3)
87881
87884
  });
87882
- } else res = await fetch(`${API$4}/subscriptions/${encodeURIComponent(subscriptionId)}`, {
87885
+ } else res = await fetch(`${API$3}/subscriptions/${encodeURIComponent(subscriptionId)}`, {
87883
87886
  method: "DELETE",
87884
87887
  headers: {
87885
87888
  authorization: `Bearer ${apiKey}`,
@@ -87914,7 +87917,7 @@ async function createBillingPortalSession(inv, apiKey) {
87914
87917
  customer: customerId,
87915
87918
  return_url: returnUrl
87916
87919
  });
87917
- const res = await fetch(`${API$4}/billing_portal/sessions`, {
87920
+ const res = await fetch(`${API$3}/billing_portal/sessions`, {
87918
87921
  method: "POST",
87919
87922
  headers: {
87920
87923
  authorization: `Bearer ${apiKey}`,
@@ -87954,7 +87957,7 @@ async function createPaymentIntent(inv, apiKey) {
87954
87957
  if (args.description) body.set("description", args.description);
87955
87958
  if (args.automatic_payment_methods && typeof args.automatic_payment_methods.enabled === "boolean") body.set("automatic_payment_methods[enabled]", args.automatic_payment_methods.enabled ? "true" : "false");
87956
87959
  if (args.metadata) for (const [k, v] of Object.entries(args.metadata)) body.set(`metadata[${k}]`, String(v));
87957
- const res = await fetch(`${API$4}/payment_intents`, {
87960
+ const res = await fetch(`${API$3}/payment_intents`, {
87958
87961
  method: "POST",
87959
87962
  headers: {
87960
87963
  authorization: `Bearer ${apiKey}`,
@@ -87994,7 +87997,7 @@ async function createRefund(inv, apiKey) {
87994
87997
  if (args.charge) body.set("charge", args.charge);
87995
87998
  if (typeof args.amount === "number") body.set("amount", String(args.amount));
87996
87999
  if (args.reason) body.set("reason", args.reason);
87997
- const res = await fetch(`${API$4}/refunds`, {
88000
+ const res = await fetch(`${API$3}/refunds`, {
87998
88001
  method: "POST",
87999
88002
  headers: {
88000
88003
  authorization: `Bearer ${apiKey}`,
@@ -88034,7 +88037,7 @@ async function createCustomer(inv, apiKey) {
88034
88037
  if (args.phone) body.set("phone", args.phone);
88035
88038
  if (args.description) body.set("description", args.description);
88036
88039
  if (args.metadata) for (const [k, v] of Object.entries(args.metadata)) body.set(`metadata[${k}]`, String(v));
88037
- const res = await fetch(`${API$4}/customers`, {
88040
+ const res = await fetch(`${API$3}/customers`, {
88038
88041
  method: "POST",
88039
88042
  headers: {
88040
88043
  authorization: `Bearer ${apiKey}`,
@@ -91885,7 +91888,7 @@ function safeProviderValue(value) {
91885
91888
  * filtered by To/From. Useful for "did the confirmation actually
91886
91889
  * send?" introspection inside an agent run.
91887
91890
  */
91888
- const API$3 = "https://api.twilio.com/2010-04-01";
91891
+ const API$2 = "https://api.twilio.com/2010-04-01";
91889
91892
  const LOOKUP_API = "https://lookups.twilio.com/v1";
91890
91893
  const twilioSmsConnector = {
91891
91894
  manifest: {
@@ -92119,7 +92122,7 @@ const twilioSmsConnector = {
92119
92122
  params.set("PageSize", String(Math.min(Math.max(1, limit ?? 20), 100)));
92120
92123
  if (to) params.set("To", to);
92121
92124
  if (from) params.set("From", from);
92122
- const url = `${API$3}/Accounts/${encodeURIComponent(auth.accountSid)}/Messages.json?${params.toString()}`;
92125
+ const url = `${API$2}/Accounts/${encodeURIComponent(auth.accountSid)}/Messages.json?${params.toString()}`;
92123
92126
  const res = await fetch(url, {
92124
92127
  headers: { authorization: basicAuth(auth) },
92125
92128
  signal: AbortSignal.timeout(1e4)
@@ -92140,7 +92143,7 @@ const twilioSmsConnector = {
92140
92143
  const params = new URLSearchParams();
92141
92144
  params.set("PageSize", String(Math.min(Math.max(1, limit ?? 50), 100)));
92142
92145
  if (phoneNumber) params.set("PhoneNumber", phoneNumber);
92143
- const baseUrl = `${API$3}/Accounts/${encodeURIComponent(auth.accountSid)}/IncomingPhoneNumbers`;
92146
+ const baseUrl = `${API$2}/Accounts/${encodeURIComponent(auth.accountSid)}/IncomingPhoneNumbers`;
92144
92147
  const url = numberSid ? `${baseUrl}/${numberSid}.json` : `${baseUrl}.json?${params.toString()}`;
92145
92148
  const res = await fetch(url, {
92146
92149
  headers: { authorization: basicAuth(auth) },
@@ -92180,7 +92183,7 @@ const twilioSmsConnector = {
92180
92183
  if (inv.capabilityName === "get_media") {
92181
92184
  const { messageSid, mediaSid } = inv.args;
92182
92185
  if (!/^(SM|MM)[a-f\d]{32}$/i.test(messageSid) || !/^ME[a-f\d]{32}$/i.test(mediaSid)) throw new Error("twilio-sms get_media requires exact message and media SIDs");
92183
- const url = `${API$3}/Accounts/${encodeURIComponent(auth.accountSid)}/Messages/${messageSid}/Media/${mediaSid}`;
92186
+ const url = `${API$2}/Accounts/${encodeURIComponent(auth.accountSid)}/Messages/${messageSid}/Media/${mediaSid}`;
92184
92187
  const signal = AbortSignal.timeout(2e4);
92185
92188
  let res = await fetch(url, {
92186
92189
  headers: { authorization: basicAuth(auth) },
@@ -92265,7 +92268,7 @@ const twilioSmsConnector = {
92265
92268
  }
92266
92269
  if (inv.capabilityName === "redact_message") {
92267
92270
  const { messageSid } = inv.args;
92268
- const url = `${API$3}/Accounts/${encodeURIComponent(auth.accountSid)}/Messages/${encodeURIComponent(messageSid)}.json`;
92271
+ const url = `${API$2}/Accounts/${encodeURIComponent(auth.accountSid)}/Messages/${encodeURIComponent(messageSid)}.json`;
92269
92272
  const formBody = new URLSearchParams({ Body: "" });
92270
92273
  const res = await fetch(url, {
92271
92274
  method: "POST",
@@ -92298,7 +92301,7 @@ const twilioSmsConnector = {
92298
92301
  async test(source) {
92299
92302
  try {
92300
92303
  const auth = parseAuth(source.credentials);
92301
- const res = await fetch(`${API$3}/Accounts/${encodeURIComponent(auth.accountSid)}.json`, {
92304
+ const res = await fetch(`${API$2}/Accounts/${encodeURIComponent(auth.accountSid)}.json`, {
92302
92305
  headers: { authorization: basicAuth(auth) },
92303
92306
  signal: AbortSignal.timeout(8e3)
92304
92307
  });
@@ -92355,7 +92358,7 @@ function readMetaStringOptional(meta, key) {
92355
92358
  return typeof v === "string" && v.length > 0 ? v : void 0;
92356
92359
  }
92357
92360
  async function postMessages(inv, auth, formBody, label) {
92358
- const url = `${API$3}/Accounts/${encodeURIComponent(auth.accountSid)}/Messages.json`;
92361
+ const url = `${API$2}/Accounts/${encodeURIComponent(auth.accountSid)}/Messages.json`;
92359
92362
  const res = await fetch(url, {
92360
92363
  method: "POST",
92361
92364
  headers: {
@@ -92592,7 +92595,7 @@ const SCOPES = [
92592
92595
  ];
92593
92596
  const AUTH_URL = "https://www.facebook.com/v21.0/dialog/oauth";
92594
92597
  const TOKEN_URL = "https://graph.facebook.com/v21.0/oauth/access_token";
92595
- const API$2 = "https://graph.facebook.com/v21.0";
92598
+ const API$1 = "https://graph.facebook.com/v21.0";
92596
92599
  function whatsappBusiness(opts) {
92597
92600
  const { clientId, clientSecret } = opts;
92598
92601
  return {
@@ -92842,7 +92845,7 @@ function whatsappBusiness(opts) {
92842
92845
  params.set("limit", String(Math.min(Math.max(1, limit ?? 50), 200)));
92843
92846
  if (status) params.set("status", status);
92844
92847
  return {
92845
- data: { templates: ((await graphGet(`${API$2}/${encodeURIComponent(wabaId)}/message_templates?${params.toString()}`, accessToken, inv.source.id)).data ?? []).map((t) => ({
92848
+ data: { templates: ((await graphGet(`${API$1}/${encodeURIComponent(wabaId)}/message_templates?${params.toString()}`, accessToken, inv.source.id)).data ?? []).map((t) => ({
92846
92849
  id: t.id,
92847
92850
  name: t.name,
92848
92851
  status: t.status,
@@ -92855,7 +92858,7 @@ function whatsappBusiness(opts) {
92855
92858
  if (inv.capabilityName === "get_business_phone_number") {
92856
92859
  const phoneNumberId = readMetaString$1(inv.source.metadata, "phoneNumberId");
92857
92860
  const params = new URLSearchParams({ fields: "display_phone_number,verified_name,quality_rating,code_verification_status,platform_type" });
92858
- const json = await graphGet(`${API$2}/${encodeURIComponent(phoneNumberId)}?${params.toString()}`, accessToken, inv.source.id);
92861
+ const json = await graphGet(`${API$1}/${encodeURIComponent(phoneNumberId)}?${params.toString()}`, accessToken, inv.source.id);
92859
92862
  return {
92860
92863
  data: {
92861
92864
  phoneNumber: json.display_phone_number,
@@ -92875,7 +92878,7 @@ function whatsappBusiness(opts) {
92875
92878
  if (inv.capabilityName === "templates.create") return createTemplate(inv, accessToken);
92876
92879
  if (inv.capabilityName === "templates.delete") return deleteTemplate(inv, accessToken);
92877
92880
  const phoneNumberId = readMetaString$1(inv.source.metadata, "phoneNumberId");
92878
- const url = `${API$2}/${encodeURIComponent(phoneNumberId)}/messages`;
92881
+ const url = `${API$1}/${encodeURIComponent(phoneNumberId)}/messages`;
92879
92882
  let body;
92880
92883
  if (inv.capabilityName === "messages.reply") {
92881
92884
  const { to, text, replyToMessageId } = inv.args;
@@ -92981,7 +92984,7 @@ function whatsappBusiness(opts) {
92981
92984
  try {
92982
92985
  const accessToken = readAccessToken(source.credentials);
92983
92986
  const phoneNumberId = typeof source.metadata.phoneNumberId === "string" ? source.metadata.phoneNumberId : void 0;
92984
- const probeUrl = phoneNumberId ? `${API$2}/${encodeURIComponent(phoneNumberId)}?fields=display_phone_number` : `${API$2}/me?fields=id`;
92987
+ const probeUrl = phoneNumberId ? `${API$1}/${encodeURIComponent(phoneNumberId)}?fields=display_phone_number` : `${API$1}/me?fields=id`;
92985
92988
  const res = await fetch(probeUrl, {
92986
92989
  headers: { authorization: `Bearer ${accessToken}` },
92987
92990
  signal: AbortSignal.timeout(8e3)
@@ -93048,7 +93051,7 @@ async function uploadMedia(inv, accessToken) {
93048
93051
  form.set("messaging_product", "whatsapp");
93049
93052
  form.set("type", mimeType);
93050
93053
  form.set("file", new Blob([bytes], { type: mimeType }), filename ?? "upload");
93051
- const url = `${API$2}/${encodeURIComponent(phoneNumberId)}/media`;
93054
+ const url = `${API$1}/${encodeURIComponent(phoneNumberId)}/media`;
93052
93055
  const res = await fetch(url, {
93053
93056
  method: "POST",
93054
93057
  headers: { authorization: `Bearer ${accessToken}` },
@@ -93074,7 +93077,7 @@ async function createTemplate(inv, accessToken) {
93074
93077
  if (typeof language !== "string" || language.length === 0) throw new Error("whatsapp-business templates.create: language is required");
93075
93078
  if (typeof category !== "string" || category.length === 0) throw new Error("whatsapp-business templates.create: category is required");
93076
93079
  if (!Array.isArray(components)) throw new Error("whatsapp-business templates.create: components must be an array");
93077
- const url = `${API$2}/${encodeURIComponent(wabaId)}/message_templates`;
93080
+ const url = `${API$1}/${encodeURIComponent(wabaId)}/message_templates`;
93078
93081
  const res = await fetch(url, {
93079
93082
  method: "POST",
93080
93083
  headers: {
@@ -93113,7 +93116,7 @@ async function deleteTemplate(inv, accessToken) {
93113
93116
  const params = new URLSearchParams();
93114
93117
  params.set("name", name);
93115
93118
  if (typeof hsmId === "string" && hsmId.length > 0) params.set("hsm_id", hsmId);
93116
- const url = `${API$2}/${encodeURIComponent(wabaId)}/message_templates?${params.toString()}`;
93119
+ const url = `${API$1}/${encodeURIComponent(wabaId)}/message_templates?${params.toString()}`;
93117
93120
  const res = await fetch(url, {
93118
93121
  method: "DELETE",
93119
93122
  headers: { authorization: `Bearer ${accessToken}` },
@@ -96873,446 +96876,6 @@ function retryAfterMs(value) {
96873
96876
  return Number.isFinite(seconds) && seconds >= 0 ? Math.max(1e3, seconds * 1e3) : 6e4;
96874
96877
  }
96875
96878
  //#endregion
96876
- //#region src/connectors/adapters/cloudbeds.ts
96877
- const API$1 = "https://api.cloudbeds.com/api/v1.3";
96878
- const DATE$1 = /^\d{4}-\d{2}-\d{2}$/;
96879
- const PROPERTY_ID = /^[1-9]\d{0,19}$/;
96880
- const OPERATION_ID = /^[A-Za-z0-9:._-]{1,128}$/;
96881
- const STATUSES = /* @__PURE__ */ new Set([
96882
- "not_confirmed",
96883
- "confirmed",
96884
- "canceled",
96885
- "checked_in",
96886
- "checked_out",
96887
- "no_show"
96888
- ]);
96889
- function boundedString(value, name, max = 256) {
96890
- if (typeof value !== "string" || !value.trim() || value.length > max || /[\u0000-\u001f\u007f]/.test(value)) throw new Error(`cloudbeds: invalid ${name}`);
96891
- return value;
96892
- }
96893
- function providerText$1(value) {
96894
- return typeof value === "string" && value.length <= 256 && !/[\u0000-\u001f\u007f]/.test(value) ? value : null;
96895
- }
96896
- function propertyId(source) {
96897
- const value = source.metadata.propertyId;
96898
- if (typeof value !== "string" || !PROPERTY_ID.test(value)) throw new Error("cloudbeds: connection requires one numeric propertyId");
96899
- return value;
96900
- }
96901
- function apiKey$1(source) {
96902
- const value = source.credentials;
96903
- if (value.kind !== "api-key" || !value.apiKey || /[\u0000-\u0020\u007f]/.test(value.apiKey)) throw new Error("cloudbeds: connection requires an API key");
96904
- return value.apiKey;
96905
- }
96906
- async function call$1(source, path, init) {
96907
- const headers = {
96908
- "x-api-key": apiKey$1(source),
96909
- accept: "application/json",
96910
- ...init.headers
96911
- };
96912
- let result;
96913
- try {
96914
- result = await requestJson(`${API$1}/${path}`, {
96915
- ...init,
96916
- headers
96917
- }, { maxResponseBytes: 2e6 });
96918
- } catch (error) {
96919
- if (error instanceof ProviderProtocolError && error.status === 401) throw new CredentialsExpired("Cloudbeds rejected the API key", source.id);
96920
- if (error instanceof ProviderProtocolError && error.status === 429) throw new ProviderRateLimited("Cloudbeds rate limit (429)", source.id, {
96921
- status: 429,
96922
- retryAfterMs: error.retryAfterMs
96923
- });
96924
- throw error;
96925
- }
96926
- if (record$3(result) && result.success === false) throw new ProviderProtocolError("Cloudbeds rejected the request", "provider_rejected", 422, true);
96927
- if (!record$3(result) || result.success !== true) throw new ProviderProtocolError("Cloudbeds returned an unsuccessful or malformed response", "invalid_response");
96928
- return result;
96929
- }
96930
- function date$1(value, label) {
96931
- if (typeof value !== "string" || !DATE$1.test(value) || Number.isNaN(Date.parse(`${value}T00:00:00Z`)) || (/* @__PURE__ */ new Date(`${value}T00:00:00Z`)).toISOString().slice(0, 10) !== value) throw new Error(`cloudbeds: invalid ${label}`);
96932
- return value;
96933
- }
96934
- function page$3(value, label, fallback, max) {
96935
- const selected = value ?? fallback;
96936
- if (!Number.isSafeInteger(selected) || selected < 1 || selected > max) throw new Error(`cloudbeds: invalid ${label}`);
96937
- return selected;
96938
- }
96939
- function money(value, label, allowZero = false) {
96940
- if (typeof value !== "number" || !Number.isFinite(value) || value < (allowZero ? 0 : .01) || value > 1e6 || Math.abs(value * 100 - Math.round(value * 100)) > 1e-7) throw new Error(`cloudbeds: invalid ${label}`);
96941
- return value;
96942
- }
96943
- function reservationQuery(args, property) {
96944
- const query = new URLSearchParams({ propertyID: property });
96945
- const pairs = [["checkInFrom", "checkInTo"], ["checkOutFrom", "checkOutTo"]];
96946
- let found = false;
96947
- for (const [fromKey, toKey] of pairs) {
96948
- if (args[fromKey] === void 0 && args[toKey] === void 0) continue;
96949
- const from = date$1(args[fromKey], fromKey);
96950
- const to = date$1(args[toKey], toKey);
96951
- const days = (Date.parse(`${to}T00:00:00Z`) - Date.parse(`${from}T00:00:00Z`)) / 864e5;
96952
- if (days < 0 || days > 31) throw new Error("cloudbeds: reservation date range must be at most 31 days");
96953
- query.set(fromKey, from);
96954
- query.set(toKey, to);
96955
- found = true;
96956
- }
96957
- if (!found) throw new Error("cloudbeds: an arrival or departure date range is required");
96958
- if (args.status !== void 0) {
96959
- if (typeof args.status !== "string" || !STATUSES.has(args.status)) throw new Error("cloudbeds: invalid status");
96960
- query.set("status", args.status);
96961
- }
96962
- query.set("pageNumber", String(page$3(args.pageNumber, "pageNumber", 1, 1e5)));
96963
- query.set("pageSize", String(page$3(args.pageSize, "pageSize", 100, 100)));
96964
- return query;
96965
- }
96966
- function reservations(result, property, query) {
96967
- if (!Array.isArray(result.data) || !Number.isSafeInteger(result.count) || !Number.isSafeInteger(result.total) || result.count < 0 || result.total < 0 || result.count !== result.data.length || result.total < result.count || result.count > Number(query.get("pageSize"))) throw new ProviderProtocolError("Cloudbeds returned malformed reservation pagination", "invalid_response");
96968
- const items = result.data.map((raw) => {
96969
- if (!record$3(raw) || raw.propertyID !== property || typeof raw.reservationID !== "string" || !raw.reservationID || typeof raw.startDate !== "string" || typeof raw.endDate !== "string" || typeof raw.status !== "string" || !STATUSES.has(raw.status)) throw new ProviderProtocolError("Cloudbeds returned a reservation outside the connected property or with invalid fields", "invalid_response");
96970
- try {
96971
- date$1(raw.startDate, "provider startDate");
96972
- date$1(raw.endDate, "provider endDate");
96973
- } catch {
96974
- throw new ProviderProtocolError("Cloudbeds returned an invalid reservation date", "invalid_response");
96975
- }
96976
- return {
96977
- propertyId: property,
96978
- reservationId: raw.reservationID,
96979
- status: raw.status,
96980
- arrivalDate: raw.startDate,
96981
- departureDate: raw.endDate,
96982
- guestName: providerText$1(raw.guestName),
96983
- balance: typeof raw.balance === "number" && Number.isFinite(raw.balance) ? raw.balance : null
96984
- };
96985
- });
96986
- const pageNumber = Number(query.get("pageNumber"));
96987
- const pageSize = Number(query.get("pageSize"));
96988
- return {
96989
- reservations: items,
96990
- pageNumber,
96991
- pageSize,
96992
- total: result.total,
96993
- hasMore: pageNumber * pageSize < result.total
96994
- };
96995
- }
96996
- function roomAvailabilityQuery(args, property) {
96997
- const startDate = date$1(args.startDate, "startDate");
96998
- const endDate = date$1(args.endDate, "endDate");
96999
- const days = (Date.parse(`${endDate}T00:00:00Z`) - Date.parse(`${startDate}T00:00:00Z`)) / 864e5;
97000
- if (days < 1 || days > 31) throw new Error("cloudbeds: stay must be between 1 and 31 nights");
97001
- const children = args.children ?? 0;
97002
- if (!Number.isSafeInteger(children) || children < 0 || children > 20) throw new Error("cloudbeds: invalid children");
97003
- return new URLSearchParams({
97004
- propertyIDs: property,
97005
- startDate,
97006
- endDate,
97007
- rooms: String(page$3(args.rooms, "rooms", 1, 10)),
97008
- adults: String(page$3(args.adults, "adults", 1, 20)),
97009
- children: String(children),
97010
- pageNumber: String(page$3(args.pageNumber, "pageNumber", 1, 1e5)),
97011
- pageSize: String(page$3(args.pageSize, "pageSize", 100, 100)),
97012
- detailedRates: "false",
97013
- includeSharedRooms: "false"
97014
- });
97015
- }
97016
- function roomAvailability(result, property, query) {
97017
- if (!Array.isArray(result.data) || !Number.isSafeInteger(result.count) || !Number.isSafeInteger(result.total) || !Number.isSafeInteger(result.roomCount) || result.count < 0 || result.count > 1 || result.total < result.count || result.count !== result.data.length || result.roomCount < 0 || result.count > Number(query.get("pageSize"))) throw new ProviderProtocolError("Cloudbeds returned malformed room availability pagination", "invalid_response");
97018
- const roomTypes = result.data.flatMap((raw) => {
97019
- if (!record$3(raw) || raw.propertyID !== property || !Array.isArray(raw.propertyRooms)) throw new ProviderProtocolError("Cloudbeds returned availability outside the connected property", "invalid_response");
97020
- return raw.propertyRooms.map((room) => {
97021
- if (!record$3(room) || typeof room.roomTypeID !== "string" || !room.roomTypeID || !Number.isSafeInteger(room.roomsAvailable) || room.roomsAvailable < 0 || room.roomRate !== void 0 && (typeof room.roomRate !== "number" || !Number.isFinite(room.roomRate) || room.roomRate < 0)) throw new ProviderProtocolError("Cloudbeds returned malformed room-type availability", "invalid_response");
97022
- return {
97023
- roomTypeId: room.roomTypeID,
97024
- roomTypeName: providerText$1(room.roomTypeName),
97025
- roomsAvailable: room.roomsAvailable,
97026
- roomRate: typeof room.roomRate === "number" ? room.roomRate : null
97027
- };
97028
- });
97029
- });
97030
- if (roomTypes.length !== result.roomCount) throw new ProviderProtocolError("Cloudbeds returned mismatched room-type count", "invalid_response");
97031
- return {
97032
- propertyId: property,
97033
- startDate: query.get("startDate"),
97034
- endDate: query.get("endDate"),
97035
- rooms: Number(query.get("rooms")),
97036
- adults: Number(query.get("adults")),
97037
- children: Number(query.get("children")),
97038
- roomTypes,
97039
- pageNumber: Number(query.get("pageNumber")),
97040
- pageSize: Number(query.get("pageSize")),
97041
- mayHaveMore: Number(query.get("pageNumber")) * Number(query.get("pageSize")) < result.total
97042
- };
97043
- }
97044
- function formForItem(inv, property) {
97045
- const args = inv.args;
97046
- const reservationId = boundedString(args.reservationId, "reservationId");
97047
- const appItemId = boundedString(args.appItemId, "appItemId");
97048
- const itemName = boundedString(args.itemName, "itemName");
97049
- const itemCategoryName = boundedString(args.itemCategoryName, "itemCategoryName");
97050
- const itemPrice = money(args.itemPrice, "itemPrice");
97051
- const itemQuantity = page$3(args.itemQuantity, "itemQuantity", 1, 1e3);
97052
- if (!OPERATION_ID.test(inv.idempotencyKey)) throw new Error("cloudbeds: stable bounded idempotencyKey is required");
97053
- if (!Array.isArray(args.taxes) || args.taxes.length > 10) throw new Error("cloudbeds: explicit taxes array is required");
97054
- const form = new URLSearchParams({
97055
- propertyID: property,
97056
- reservationID: reservationId,
97057
- referenceID: inv.idempotencyKey,
97058
- "items[0][appItemID]": appItemId,
97059
- "items[0][itemName]": itemName,
97060
- "items[0][itemCategoryName]": itemCategoryName,
97061
- "items[0][itemPrice]": itemPrice.toFixed(2),
97062
- "items[0][itemQuantity]": String(itemQuantity),
97063
- itemPaid: "false"
97064
- });
97065
- args.taxes.forEach((tax, index) => {
97066
- if (!record$3(tax)) throw new Error("cloudbeds: invalid tax");
97067
- form.set(`items[0][itemTaxes][${index}][taxName]`, boundedString(tax.taxName, "taxName"));
97068
- form.set(`items[0][itemTaxes][${index}][taxValue]`, money(tax.taxValue, "taxValue", true).toFixed(2));
97069
- });
97070
- return form;
97071
- }
97072
- const cloudbedsConnector = {
97073
- manifest: {
97074
- kind: "cloudbeds",
97075
- displayName: "Cloudbeds",
97076
- description: "Read reservations and room availability for one connected property, then post an approved custom item to a guest folio.",
97077
- auth: {
97078
- kind: "api-key",
97079
- hint: "Property-scoped Cloudbeds API key with read:reservation, read:room and write:item scopes. Set the connection propertyId."
97080
- },
97081
- category: "other",
97082
- defaultConsistencyModel: "authoritative",
97083
- capabilities: [
97084
- {
97085
- name: "reservations.list",
97086
- class: "read",
97087
- requiredScopes: ["read:reservation"],
97088
- description: "List one page of arrivals or departures for the connected property. Guest requirements are never requested.",
97089
- parameters: {
97090
- type: "object",
97091
- properties: {
97092
- checkInFrom: {
97093
- type: "string",
97094
- format: "date"
97095
- },
97096
- checkInTo: {
97097
- type: "string",
97098
- format: "date"
97099
- },
97100
- checkOutFrom: {
97101
- type: "string",
97102
- format: "date"
97103
- },
97104
- checkOutTo: {
97105
- type: "string",
97106
- format: "date"
97107
- },
97108
- status: {
97109
- type: "string",
97110
- enum: [...STATUSES]
97111
- },
97112
- pageNumber: {
97113
- type: "integer",
97114
- minimum: 1,
97115
- maximum: 1e5
97116
- },
97117
- pageSize: {
97118
- type: "integer",
97119
- minimum: 1,
97120
- maximum: 100
97121
- }
97122
- }
97123
- }
97124
- },
97125
- {
97126
- name: "room-types.available",
97127
- class: "read",
97128
- requiredScopes: ["read:room"],
97129
- description: "Read provider-reported room-type availability for a stay at the connected property. This does not hold or confirm a booking.",
97130
- parameters: {
97131
- type: "object",
97132
- properties: {
97133
- startDate: {
97134
- type: "string",
97135
- format: "date"
97136
- },
97137
- endDate: {
97138
- type: "string",
97139
- format: "date"
97140
- },
97141
- rooms: {
97142
- type: "integer",
97143
- minimum: 1,
97144
- maximum: 10
97145
- },
97146
- adults: {
97147
- type: "integer",
97148
- minimum: 1,
97149
- maximum: 20
97150
- },
97151
- children: {
97152
- type: "integer",
97153
- minimum: 0,
97154
- maximum: 20
97155
- },
97156
- pageNumber: {
97157
- type: "integer",
97158
- minimum: 1,
97159
- maximum: 1e5
97160
- },
97161
- pageSize: {
97162
- type: "integer",
97163
- minimum: 1,
97164
- maximum: 100
97165
- }
97166
- },
97167
- required: ["startDate", "endDate"]
97168
- }
97169
- },
97170
- {
97171
- name: "folio-items.post",
97172
- class: "mutation",
97173
- cas: "native-idempotency",
97174
- externalEffect: true,
97175
- requiredScopes: ["read:reservation", "write:item"],
97176
- description: "Verify reservation ownership, then post one unpaid custom item to the connected property guest folio. The Hub operation key becomes Cloudbeds referenceID.",
97177
- parameters: {
97178
- type: "object",
97179
- properties: {
97180
- reservationId: {
97181
- type: "string",
97182
- minLength: 1,
97183
- maxLength: 256
97184
- },
97185
- appItemId: {
97186
- type: "string",
97187
- minLength: 1,
97188
- maxLength: 256
97189
- },
97190
- itemName: {
97191
- type: "string",
97192
- minLength: 1,
97193
- maxLength: 256
97194
- },
97195
- itemCategoryName: {
97196
- type: "string",
97197
- minLength: 1,
97198
- maxLength: 256
97199
- },
97200
- itemPrice: {
97201
- type: "number",
97202
- minimum: .01,
97203
- maximum: 1e6,
97204
- multipleOf: .01
97205
- },
97206
- itemQuantity: {
97207
- type: "integer",
97208
- minimum: 1,
97209
- maximum: 1e3
97210
- },
97211
- taxes: {
97212
- type: "array",
97213
- description: "Explicit tax amounts in the property currency. Use [] only when no tax applies.",
97214
- maxItems: 10,
97215
- items: {
97216
- type: "object",
97217
- properties: {
97218
- taxName: {
97219
- type: "string",
97220
- minLength: 1,
97221
- maxLength: 256
97222
- },
97223
- taxValue: {
97224
- type: "number",
97225
- minimum: 0,
97226
- maximum: 1e6,
97227
- multipleOf: .01
97228
- }
97229
- },
97230
- required: ["taxName", "taxValue"]
97231
- }
97232
- }
97233
- },
97234
- required: [
97235
- "reservationId",
97236
- "appItemId",
97237
- "itemName",
97238
- "itemCategoryName",
97239
- "itemPrice",
97240
- "taxes"
97241
- ]
97242
- }
97243
- }
97244
- ]
97245
- },
97246
- async executeRead(inv) {
97247
- const property = propertyId(inv.source);
97248
- if (inv.capabilityName === "room-types.available") {
97249
- const query = roomAvailabilityQuery(inv.args, property);
97250
- return {
97251
- data: roomAvailability(await call$1(inv.source, `getAvailableRoomTypes?${query}`, { method: "GET" }), property, query),
97252
- fetchedAt: Date.now()
97253
- };
97254
- }
97255
- if (inv.capabilityName !== "reservations.list") throw new Error(`cloudbeds: unknown read ${inv.capabilityName}`);
97256
- const query = reservationQuery(inv.args, property);
97257
- return {
97258
- data: reservations(await call$1(inv.source, `getReservations?${query}`, { method: "GET" }), property, query),
97259
- fetchedAt: Date.now()
97260
- };
97261
- },
97262
- async executeMutation(inv) {
97263
- if (inv.capabilityName !== "folio-items.post") throw new Error(`cloudbeds: unknown mutation ${inv.capabilityName}`);
97264
- const property = propertyId(inv.source);
97265
- const form = formForItem(inv, property);
97266
- const reservationId = form.get("reservationID");
97267
- const query = new URLSearchParams({
97268
- propertyID: property,
97269
- reservationID: reservationId
97270
- });
97271
- const reservation = await call$1(inv.source, `getReservation?${query}`, { method: "GET" });
97272
- if (!record$3(reservation.data) || reservation.data.propertyID !== property || reservation.data.reservationID !== reservationId) throw new ProviderProtocolError("Cloudbeds could not verify the reservation belongs to the connected property", "invalid_response");
97273
- const result = await call$1(inv.source, "postCustomItem", {
97274
- method: "POST",
97275
- headers: { "content-type": "application/x-www-form-urlencoded" },
97276
- body: form.toString()
97277
- });
97278
- if (!record$3(result.data)) throw new ProviderProtocolError("Cloudbeds returned a malformed folio item receipt", "invalid_response");
97279
- const soldProductId = typeof result.data.soldProductID === "string" && result.data.soldProductID ? result.data.soldProductID : null;
97280
- const notice = providerText$1(result.data.notice);
97281
- const duplicate = soldProductId === null && notice !== null && /referenceid/i.test(notice) && /nothing was created/i.test(notice);
97282
- if (!soldProductId && !duplicate) throw new ProviderProtocolError("Cloudbeds returned an indeterminate folio item receipt", "capability_outcome_indeterminate");
97283
- return {
97284
- status: "committed",
97285
- data: {
97286
- referenceId: inv.idempotencyKey,
97287
- soldProductId,
97288
- transactionId: typeof result.data.transactionID === "string" ? result.data.transactionID : null,
97289
- duplicate,
97290
- notice
97291
- },
97292
- committedAt: Date.now(),
97293
- idempotentReplay: duplicate
97294
- };
97295
- },
97296
- async test(source) {
97297
- try {
97298
- const property = propertyId(source);
97299
- const result = await call$1(source, `getReservations?${new URLSearchParams({
97300
- propertyID: property,
97301
- status: "checked_in",
97302
- pageNumber: "1",
97303
- pageSize: "1"
97304
- })}`, { method: "GET" });
97305
- if (!Array.isArray(result.data)) throw new ProviderProtocolError("Cloudbeds returned malformed reservations", "invalid_response");
97306
- return { ok: true };
97307
- } catch (error) {
97308
- return {
97309
- ok: false,
97310
- reason: error instanceof Error ? error.message : "Cloudbeds connection failed"
97311
- };
97312
- }
97313
- }
97314
- };
97315
- //#endregion
97316
96879
  //#region src/connectors/adapters/pricelabs.ts
97317
96880
  const API = "https://api.pricelabs.co/v1";
97318
96881
  const DATE = /^\d{4}-\d{2}-\d{2}$/;
@@ -110482,6 +110045,9 @@ const slackEventsConnector = {
110482
110045
  //#endregion
110483
110046
  //#region src/connectors/adapters/github.ts
110484
110047
  const GIT_SHA = "(?:[0-9a-fA-F]{40}|[0-9a-fA-F]{64})";
110048
+ /** The most files one pulls.propose call may write or delete. */
110049
+ const PROPOSE_MAX_FILES = 50;
110050
+ const PLAIN_BRANCH = "^(?!/)(?!.*//)(?!.*\\.\\.)(?!.*@\\{)(?!.*\\.lock$)[A-Za-z0-9._/-]+(?<![/.])$";
110485
110051
  const repoParams = {
110486
110052
  type: "object",
110487
110053
  properties: {
@@ -110490,7 +110056,7 @@ const repoParams = {
110490
110056
  },
110491
110057
  required: ["owner", "repo"]
110492
110058
  };
110493
- const githubConnector = declarativeRestConnector({
110059
+ const githubSpec = {
110494
110060
  kind: "github",
110495
110061
  displayName: "GitHub",
110496
110062
  description: "Search repositories/issues and create or update GitHub issues through a user-scoped token.",
@@ -111256,7 +110822,7 @@ const githubConnector = declarativeRestConnector({
111256
110822
  {
111257
110823
  name: "git.createTree",
111258
110824
  class: "mutation",
111259
- description: "Step 2 of a draft pull request. Write a tree: `base_tree` plus the changed entries. Each entry is `{ path, mode: \"100644\", type: \"blob\", content }` (use `sha: null` to delete a file). Creates an unreferenced object; nothing is visible until a branch points at a commit using it.",
110825
+ description: "Prefer pulls.propose, which proposes a whole change under one owner approval; each of these low-level steps needs its own. Step 2 of a draft pull request. Write a tree: `base_tree` plus the changed entries. Each entry is `{ path, mode: \"100644\", type: \"blob\", content }` (use `sha: null` to delete a file). Creates an unreferenced object; nothing is visible until a branch points at a commit using it.",
111260
110826
  parameters: {
111261
110827
  type: "object",
111262
110828
  properties: {
@@ -111322,7 +110888,7 @@ const githubConnector = declarativeRestConnector({
111322
110888
  {
111323
110889
  name: "git.createCommit",
111324
110890
  class: "mutation",
111325
- description: "Step 3 of a draft pull request. Write a commit object for a tree with explicit parents (normally the base branch head). Creates an unreferenced object; it moves no branch. Its `sha` is what git.createRef needs.",
110891
+ description: "Prefer pulls.propose for a pull request (one owner approval for the whole change). Step 3 of a draft pull request. Write a commit object for a tree with explicit parents (normally the base branch head). Creates an unreferenced object; it moves no branch. Its `sha` is what git.createRef needs.",
111326
110892
  parameters: {
111327
110893
  type: "object",
111328
110894
  properties: {
@@ -111365,7 +110931,7 @@ const githubConnector = declarativeRestConnector({
111365
110931
  {
111366
110932
  name: "git.createRef",
111367
110933
  class: "mutation",
111368
- description: "Step 4 of a draft pull request. Create a NEW branch at a commit: `ref` must be `refs/heads/<new-branch>` and `sha` the commit from git.createCommit. Never moves an existing branch; GitHub returns 422 when the ref already exists. Then pulls.create with `head: \"<new-branch>\"` (no `refs/heads/`) and `draft: true`.",
110934
+ description: "Prefer pulls.propose for a pull request (one owner approval for the whole change). Step 4 of a draft pull request. Create a NEW branch at a commit: `ref` must be `refs/heads/<new-branch>` and `sha` the commit from git.createCommit. Never moves an existing branch; GitHub returns 422 when the ref already exists. Then pulls.create with `head: \"<new-branch>\"` (no `refs/heads/`) and `draft: true`.",
111369
110935
  parameters: {
111370
110936
  type: "object",
111371
110937
  properties: {
@@ -111462,7 +111028,7 @@ const githubConnector = declarativeRestConnector({
111462
111028
  {
111463
111029
  name: "pulls.create",
111464
111030
  class: "mutation",
111465
- description: "Open a pull request from `head` into `base` on the target repository. Step 5 of a draft pull request: `head` is the branch git.createRef created and `draft: true`.",
111031
+ description: "Open a pull request from `head` into `base` on the target repository. To propose file changes, prefer pulls.propose, which writes the files and opens the draft under one owner approval. Step 5 of a draft pull request: `head` is the branch git.createRef created and `draft: true`.",
111466
111032
  parameters: {
111467
111033
  type: "object",
111468
111034
  properties: {
@@ -111502,6 +111068,84 @@ const githubConnector = declarativeRestConnector({
111502
111068
  cas: "native-idempotency",
111503
111069
  externalEffect: true
111504
111070
  },
111071
+ {
111072
+ name: "pulls.propose",
111073
+ class: "mutation",
111074
+ description: "Propose a change as a draft pull request in ONE call, under one owner approval: write `files` on a NEW branch cut from the head of `base`, commit them, and open a draft pull request from `branch` into `base`. Prefer it over git.createTree, git.createCommit, git.createRef and pulls.create, which each need their own approval. It never moves an existing branch and never merges. Returns the pull request, the commit and each changed file with its line counts.",
111075
+ parameters: {
111076
+ type: "object",
111077
+ additionalProperties: false,
111078
+ properties: {
111079
+ owner: { type: "string" },
111080
+ repo: { type: "string" },
111081
+ base: {
111082
+ type: "string",
111083
+ description: "Branch the pull request merges into, usually the default branch (`main`). A plain branch name."
111084
+ },
111085
+ branch: {
111086
+ type: "string",
111087
+ description: "The NEW branch to create, e.g. `gtm-agent/hero-copy`. It must not exist yet and must differ from `base`."
111088
+ },
111089
+ title: {
111090
+ type: "string",
111091
+ minLength: 1,
111092
+ maxLength: 256
111093
+ },
111094
+ body: {
111095
+ type: "string",
111096
+ description: "Pull request description (markdown)."
111097
+ },
111098
+ commit_message: {
111099
+ type: "string",
111100
+ description: "Commit message; defaults to the title."
111101
+ },
111102
+ files: {
111103
+ type: "array",
111104
+ minItems: 1,
111105
+ maxItems: PROPOSE_MAX_FILES,
111106
+ description: "Every file the change writes or deletes. `{ path, content }` writes the whole new file; `{ path, delete: true }` removes it.",
111107
+ items: {
111108
+ type: "object",
111109
+ additionalProperties: false,
111110
+ properties: {
111111
+ path: {
111112
+ type: "string",
111113
+ description: "Repository-relative path, e.g. `src/routes/_index.tsx`."
111114
+ },
111115
+ content: {
111116
+ type: "string",
111117
+ description: "The complete new file content (UTF-8 text)."
111118
+ },
111119
+ mode: {
111120
+ type: "string",
111121
+ enum: ["100644", "100755"],
111122
+ description: "File mode; `100755` for an executable. Defaults to `100644`."
111123
+ },
111124
+ delete: {
111125
+ type: "boolean",
111126
+ description: "True deletes the file; false or absent writes `content`."
111127
+ }
111128
+ },
111129
+ required: ["path"]
111130
+ }
111131
+ }
111132
+ },
111133
+ required: [
111134
+ "owner",
111135
+ "repo",
111136
+ "base",
111137
+ "branch",
111138
+ "title",
111139
+ "files"
111140
+ ]
111141
+ },
111142
+ request: {
111143
+ method: "POST",
111144
+ path: "/repos/{owner}/{repo}/pulls"
111145
+ },
111146
+ cas: "optimistic-read-verify",
111147
+ externalEffect: true
111148
+ },
111505
111149
  {
111506
111150
  name: "pulls.merge",
111507
111151
  class: "mutation",
@@ -111610,7 +111254,283 @@ const githubConnector = declarativeRestConnector({
111610
111254
  externalEffect: true
111611
111255
  }
111612
111256
  ]
111613
- });
111257
+ };
111258
+ const base$3 = declarativeRestConnector(githubSpec);
111259
+ const baseMutation$1 = base$3.executeMutation;
111260
+ const githubConnector = {
111261
+ ...base$3,
111262
+ async executeMutation(inv) {
111263
+ if (inv.capabilityName === "pulls.propose") return proposePullRequest(inv);
111264
+ return baseMutation$1(inv);
111265
+ }
111266
+ };
111267
+ const PROPOSE_MAX_FILE_BYTES = 1e6;
111268
+ const PROPOSE_MAX_TOTAL_BYTES = 4e6;
111269
+ /** Branches a repository serves by default; a proposal never creates one. */
111270
+ const DEFAULT_BRANCH_NAMES = /* @__PURE__ */ new Set([
111271
+ "main",
111272
+ "master",
111273
+ "trunk",
111274
+ "default",
111275
+ "head",
111276
+ "develop"
111277
+ ]);
111278
+ const PROPOSE_ARGUMENTS = /* @__PURE__ */ new Set([
111279
+ "owner",
111280
+ "repo",
111281
+ "base",
111282
+ "branch",
111283
+ "title",
111284
+ "body",
111285
+ "commit_message",
111286
+ "files"
111287
+ ]);
111288
+ const PROPOSE_FILE_FIELDS = /* @__PURE__ */ new Set([
111289
+ "path",
111290
+ "content",
111291
+ "mode",
111292
+ "delete"
111293
+ ]);
111294
+ function refuse(field, message) {
111295
+ throw new InvalidCapabilityArgument(`github pulls.propose: invalid argument "${field}": ${message}`, field);
111296
+ }
111297
+ function requiredText(args, field, max = 256) {
111298
+ const value = args[field];
111299
+ if (typeof value !== "string" || !value.trim()) refuse(field, "is required");
111300
+ if (value.length > max) refuse(field, `is longer than ${max} characters`);
111301
+ return value.trim();
111302
+ }
111303
+ function branchName(args, field) {
111304
+ const value = requiredText(args, field, 200);
111305
+ if (new RegExp(`^${GIT_SHA}$`).test(value)) refuse(field, "is a commit sha, not a branch name");
111306
+ if (value.startsWith("refs/")) refuse(field, "pass the bare branch name, not a `refs/` path");
111307
+ if (!new RegExp(PLAIN_BRANCH).test(value) || value.split("/").some((part) => part.startsWith(".") || part.endsWith(".lock"))) refuse(field, "is not a plain git branch name");
111308
+ return value;
111309
+ }
111310
+ function repoPath(value, index) {
111311
+ const field = `files[${index}].path`;
111312
+ if (typeof value !== "string" || !value.trim()) refuse(field, "is required");
111313
+ const path = value.trim();
111314
+ if (path.startsWith("/") || /[\\\0]/.test(path) || path.split("/").some((part) => !part || part === "." || part === "..")) refuse(field, `${JSON.stringify(path.slice(0, 80))} is not a repository-relative path`);
111315
+ if (path === ".git" || path.startsWith(".git/")) refuse(field, "cannot write inside .git");
111316
+ return path;
111317
+ }
111318
+ /** Validate every argument before the first request, so a refusal writes nothing. */
111319
+ function proposeArgs(raw) {
111320
+ for (const key of Object.keys(raw)) if (!PROPOSE_ARGUMENTS.has(key)) refuse(key, "is not an argument of pulls.propose");
111321
+ const base = branchName(raw, "base");
111322
+ const branch = branchName(raw, "branch");
111323
+ if (branch === base) refuse("branch", "must be a new branch, not the base");
111324
+ if (DEFAULT_BRANCH_NAMES.has(branch.toLowerCase())) refuse("branch", `${branch} is a default branch name; name a new branch`);
111325
+ const title = requiredText(raw, "title");
111326
+ const body = raw.body === void 0 ? void 0 : typeof raw.body === "string" ? raw.body : refuse("body", "must be a string");
111327
+ const commitMessage = raw.commit_message === void 0 ? title : requiredText(raw, "commit_message", 4e3);
111328
+ if (!Array.isArray(raw.files) || raw.files.length === 0) refuse("files", "name at least one file");
111329
+ if (raw.files.length > PROPOSE_MAX_FILES) refuse("files", `a proposal changes at most ${PROPOSE_MAX_FILES} files`);
111330
+ const seen = /* @__PURE__ */ new Set();
111331
+ let total = 0;
111332
+ const files = raw.files.map((entry, index) => {
111333
+ if (!entry || typeof entry !== "object" || Array.isArray(entry)) refuse(`files[${index}]`, "must be an object");
111334
+ const file = entry;
111335
+ for (const key of Object.keys(file)) if (!PROPOSE_FILE_FIELDS.has(key)) refuse(`files[${index}].${key}`, "is not a file field");
111336
+ const path = repoPath(file.path, index);
111337
+ if (seen.has(path)) refuse(`files[${index}].path`, `${path} is listed twice`);
111338
+ seen.add(path);
111339
+ const mode = file.mode === void 0 ? "100644" : file.mode;
111340
+ if (mode !== "100644" && mode !== "100755") refuse(`files[${index}].mode`, "must be 100644 or 100755");
111341
+ if (file.delete !== void 0 && typeof file.delete !== "boolean") refuse(`files[${index}].delete`, "must be true or false");
111342
+ if (file.delete === true) {
111343
+ if (file.content !== void 0) refuse(`files[${index}]`, "a deleted file carries no content");
111344
+ return {
111345
+ path,
111346
+ mode,
111347
+ delete: true
111348
+ };
111349
+ }
111350
+ if (typeof file.content !== "string") refuse(`files[${index}].content`, "is required unless delete is true");
111351
+ const bytes = new TextEncoder().encode(file.content).length;
111352
+ if (bytes > PROPOSE_MAX_FILE_BYTES) refuse(`files[${index}].content`, `is larger than ${PROPOSE_MAX_FILE_BYTES} bytes`);
111353
+ total += bytes;
111354
+ return {
111355
+ path,
111356
+ content: file.content,
111357
+ mode,
111358
+ delete: false
111359
+ };
111360
+ });
111361
+ if (total > PROPOSE_MAX_TOTAL_BYTES) refuse("files", `the change is larger than ${PROPOSE_MAX_TOTAL_BYTES} bytes`);
111362
+ return {
111363
+ owner: requiredText(raw, "owner", 100),
111364
+ repo: requiredText(raw, "repo", 100),
111365
+ base,
111366
+ branch,
111367
+ title,
111368
+ ...body !== void 0 ? { body } : {},
111369
+ commitMessage,
111370
+ files
111371
+ };
111372
+ }
111373
+ function field(value, ...path) {
111374
+ let current = value;
111375
+ for (const key of path) {
111376
+ if (!current || typeof current !== "object") return void 0;
111377
+ current = current[key];
111378
+ }
111379
+ return current;
111380
+ }
111381
+ function shaOf(value, what, ...path) {
111382
+ const sha = field(value, ...path);
111383
+ if (typeof sha !== "string" || !new RegExp(`^${GIT_SHA}$`).test(sha)) throw new Error(`github pulls.propose: GitHub returned no ${what}`);
111384
+ return sha;
111385
+ }
111386
+ /**
111387
+ * Write the files on a new branch and open a draft pull request, as one call:
111388
+ * read the base head, write a tree, commit it on that head, create the branch,
111389
+ * open the draft, and read its file list. The branch is new (GitHub refuses
111390
+ * an existing ref), so the call never moves an existing branch.
111391
+ */
111392
+ async function proposePullRequest(inv) {
111393
+ const args = proposeArgs(inv.args);
111394
+ const at = (request, values) => executeRestRequest(githubSpec, request, {
111395
+ ...inv,
111396
+ args: {
111397
+ owner: args.owner,
111398
+ repo: args.repo,
111399
+ ...values
111400
+ }
111401
+ });
111402
+ const head = await at({
111403
+ method: "GET",
111404
+ path: "/repos/{owner}/{repo}/branches/{branch}"
111405
+ }, { branch: args.base });
111406
+ if (head.outcome) return mutationResultFromTransport(githubSpec.displayName, head);
111407
+ const parent = shaOf(head.data, "base head commit", "commit", "sha");
111408
+ const tree = await at({
111409
+ method: "POST",
111410
+ path: "/repos/{owner}/{repo}/git/trees",
111411
+ body: {
111412
+ base_tree: "{base_tree}",
111413
+ tree: "{tree}"
111414
+ }
111415
+ }, {
111416
+ base_tree: shaOf(head.data, "base tree", "commit", "commit", "tree", "sha"),
111417
+ tree: args.files.map((file) => file.delete ? {
111418
+ path: file.path,
111419
+ mode: file.mode,
111420
+ type: "blob",
111421
+ sha: null
111422
+ } : {
111423
+ path: file.path,
111424
+ mode: file.mode,
111425
+ type: "blob",
111426
+ content: file.content
111427
+ })
111428
+ });
111429
+ if (tree.outcome) return mutationResultFromTransport(githubSpec.displayName, tree);
111430
+ const commit = await at({
111431
+ method: "POST",
111432
+ path: "/repos/{owner}/{repo}/git/commits",
111433
+ body: {
111434
+ message: "{message}",
111435
+ tree: "{tree}",
111436
+ parents: "{parents}"
111437
+ }
111438
+ }, {
111439
+ message: args.commitMessage,
111440
+ tree: shaOf(tree.data, "tree", "sha"),
111441
+ parents: [parent]
111442
+ });
111443
+ if (commit.outcome) return mutationResultFromTransport(githubSpec.displayName, commit);
111444
+ const commitSha = shaOf(commit.data, "commit", "sha");
111445
+ let ref;
111446
+ try {
111447
+ ref = await at({
111448
+ method: "POST",
111449
+ path: "/repos/{owner}/{repo}/git/refs",
111450
+ body: {
111451
+ ref: "{ref}",
111452
+ sha: "{sha}"
111453
+ }
111454
+ }, {
111455
+ ref: `refs/heads/${args.branch}`,
111456
+ sha: commitSha
111457
+ });
111458
+ } catch (error) {
111459
+ if (error instanceof Error && / HTTP 422: /.test(error.message) && /already exists/i.test(error.message)) refuse("branch", `${args.branch} already exists in ${args.owner}/${args.repo}; name a new branch`);
111460
+ throw error;
111461
+ }
111462
+ if (ref.outcome) return mutationResultFromTransport(githubSpec.displayName, ref);
111463
+ const created = `branch ${args.branch} at commit ${commitSha} exists in ${args.owner}/${args.repo}`;
111464
+ let pull;
111465
+ try {
111466
+ pull = await at({
111467
+ method: "POST",
111468
+ path: "/repos/{owner}/{repo}/pulls",
111469
+ body: {
111470
+ title: "{title}",
111471
+ head: "{head}",
111472
+ base: "{base}",
111473
+ body: "{body}",
111474
+ draft: true
111475
+ }
111476
+ }, {
111477
+ title: args.title,
111478
+ head: args.branch,
111479
+ base: args.base,
111480
+ ...args.body !== void 0 ? { body: args.body } : {}
111481
+ });
111482
+ } catch (error) {
111483
+ throw new Error(`github pulls.propose: ${created}, but opening the pull request failed; call pulls.create with head ${args.branch}. ${error instanceof Error ? error.message : String(error)}`);
111484
+ }
111485
+ if (pull.outcome) throw new Error(`github pulls.propose: ${created}, but GitHub ${pull.outcome === "rate-limited" ? "throttled" : "refused"} opening the pull request; call pulls.create with head ${args.branch}. ${(pull.message ?? "").slice(0, 300)}`.trim());
111486
+ const number = field(pull.data, "number");
111487
+ if (typeof number !== "number") throw new Error(`github pulls.propose: ${created}, but GitHub returned no pull request number`);
111488
+ let files = args.files.map((file) => ({
111489
+ path: file.path,
111490
+ status: file.delete ? "removed" : "modified",
111491
+ additions: 0,
111492
+ deletions: 0
111493
+ }));
111494
+ try {
111495
+ const listed = await at({
111496
+ method: "GET",
111497
+ path: "/repos/{owner}/{repo}/pulls/{pull_number}/files",
111498
+ query: { per_page: "100" }
111499
+ }, { pull_number: number });
111500
+ if (!listed.outcome && Array.isArray(listed.data)) files = listed.data.flatMap((entry) => {
111501
+ const path = field(entry, "filename");
111502
+ return typeof path === "string" ? [{
111503
+ path,
111504
+ status: String(field(entry, "status") ?? "modified"),
111505
+ additions: Number(field(entry, "additions") ?? 0),
111506
+ deletions: Number(field(entry, "deletions") ?? 0)
111507
+ }] : [];
111508
+ });
111509
+ } catch {}
111510
+ return {
111511
+ status: "committed",
111512
+ data: {
111513
+ pullRequest: {
111514
+ number,
111515
+ url: String(field(pull.data, "html_url") ?? `https://github.com/${args.owner}/${args.repo}/pull/${number}`),
111516
+ title: String(field(pull.data, "title") ?? args.title),
111517
+ state: String(field(pull.data, "state") ?? "open"),
111518
+ draft: field(pull.data, "draft") !== false
111519
+ },
111520
+ repository: `${args.owner}/${args.repo}`,
111521
+ base: args.base,
111522
+ branch: args.branch,
111523
+ commit: {
111524
+ sha: commitSha,
111525
+ url: `https://github.com/${args.owner}/${args.repo}/commit/${commitSha}`
111526
+ },
111527
+ files
111528
+ },
111529
+ etagAfter: pull.etag,
111530
+ committedAt: Date.now(),
111531
+ idempotentReplay: false
111532
+ };
111533
+ }
111614
111534
  //#endregion
111615
111535
  //#region src/connectors/adapters/gitlab.ts
111616
111536
  const gitlabConnector = declarativeRestConnector({
@@ -195700,6 +195620,6 @@ var adapters_exports = /* @__PURE__ */ __exportAll({
195700
195620
  zuoraConnector: () => zuoraConnector
195701
195621
  });
195702
195622
  //#endregion
195703
- export { vboutConnector as $, googleGeminiConnector as $a, hubspot as $c, codyConnector as $d, captainDataConnector as $i, docuseal as $l, mauticConnector as $n, zohoInvoiceConnector as $o, fragmentConnector as $r, rabbitMqConnector as $s, predictLeadsConnector as $t, tenzoConnector as $u, contactoutConnector as A, amazonSesConnector as Aa, microsoftDynamicsCrmConnector as Ac, adobeCreativeCloudConnector as Ad, cryptolensConnector as Ai, gongConnector as Al, knockConnector as An, firebaseConnector as Ao, kapsoConnector as Ar, squareConnector as As, serpstatConnector as At, azureAdConnector as Au, workableConnector as B, afforaiConnector as Ba, leadConnectorConnector as Bc, excelFilesConnector as Bd, clearoutConnector as Bi, folkConnector as Bl, griptapeConnector as Bn, matrixConnector as Bo, housecallProConnector as Br, sftpConnector as Bs, robollyConnector as Bt, amazonLambdaConnector as Bu, warmlyConnector as C, similarwebConnector as Ca, mastodonConnector as Cc, cloudconvertConnector as Cd, oneloginConnector as Cf, dittofeedConnector as Ci, tiktokAdsConnector as Cl, odooConnector as Cn, supabaseConnector as Co, leapAiConnector as Cr, twentyConnector as Cs, smartsheetConnector as Ct, boxConnector as Cu, wizaConnector as D, ampecoConnector as Da, microsoftTeams as Dc, bigcommerceConnector as Dd, createPhonyConnector as Df, denserAiConnector as Di, googleAnalyticsConnector as Dl, medullarConnector as Dn, metabaseConnector as Do, klentyConnector as Dr, ticktickConnector as Ds, signrequestConnector as Dt, azureServiceBusConnector as Du, commonRoomConnector as E, appfollowConnector as Ea, microsoftOnenoteConnector as Ec, canvaConnector as Ed, declarativeRestConnector as Ef, devinConnector as Ei, googleAdsConnector as El, mindStudioConnector as En, mysqlConnector as Eo, knackConnector as Er, tlDvConnector as Es, shortIoConnector as Et, basecampConnector as Eu, amplemarketConnector as F, amazonSecretsManagerConnector as Fa, makeConnector as Fc, gammaConnector as Fd, crispConnector as Fi, googleErrorReason as Fl, ibmCognoseConnector as Fn, baserowConnector as Fo, jinaAiConnector as Fr, shippoConnector as Fs, scrapelessConnector as Ft, attioConnector as Fu, whatsappConnector as G, smooveConnector as Ga, jotformConnector as Gc, duckdbConnector as Gd, chatDataConnector as Gi, firefliesAiConnector as Gl, googleVertexaiConnector as Gn, marketoConnector as Go, guideliteConnector as Gr, recallAiConnector as Gs, reachinboxConnector as Gt, aircallConnector as Gu, woodpeckerConnector as H, airOpsConnector as Ha, kafkaConnector as Hc, echowinConnector as Hd, clockifyConnector as Hi, filloutFormsConnector as Hl, gptzeroDetectAiConnector as Hn, smartleadConnector as Ho, hashiCorpVaultConnector as Hr, rssConnector as Hs, retableConnector as Ht, amazonEventBridgeConnector as Hu, zeplinConnector as I, amazonBedrockConnector as Ia, createLinkedinConnector as Ic, flowParserConnector as Id, comfyicuConnector as Ii, googleTestFailureReason as Il, hystructConnector as In, airtableConnector as Io, imageRouterConnector as Ir, sharepoint as Is, scrapegraphaiConnector as It, asanaConnector as Iu, wafeqConnector as J, qdrantConnector as Ja, invoiceninjaConnector as Jc, deepgramConnector as Jd, chatlingConnector as Ji, etsyConnector as Jl, mixpanelConnector as Jn, klaviyoConnector as Jo, googleSearchConnector as Jr, createRedshiftConnector as Js, quadernoConnector as Jt, zoominfoConnector as Ju, webscrapingAiConnector as K, greenhouseConnector as Ka, jiraCloudConnector as Kc, digitalPilotConnector as Kd, chartlyConnector as Ki, fireberryConnector as Kl, exaConnector as Kn, mailchimpConnector as Ko, greipConnector as Kr, createPostgresConnector as Ks, rapidtextAiConnector as Kt, adobeSignConnector as Ku, youcanbookmeConnector as L, aipriseConnector as La, linkedinConnector as Lc, fellowConnector as Ld, cometapiConnector as Li, frontConnector as Ll, humeAiConnector as Ln, TELEGRAM_FILE_DOWNLOAD_ROOT as Lo, instantlyAiConnector as Lr, savvycalConnector as Ls, sardisConnector as Lt, amazonSqsConnector as Lu, saleshandyConnector as M, altTextAiConnector as Ma, microsoftCalendar as Mc, giftbitConnector as Md, copyAiConnector as Mi, classifyGoogleError as Ml, instasentConnector as Mn, digitalOceanConnector as Mo, joggAiConnector as Mr, sageIntacctConnector as Ms, sendinblueConnector as Mt, avomaConnector as Mu, lagrowthmachineConnector as N, alaiConnector as Na, microsoft365PlannerConnector as Nc, generatebannersConnector as Nd, dashworksConnector as Ni, classifyGoogleReason as Nl, insightoAiConnector as Nn, discourseConnector as No, justInvoiceConnector as Nr, slack as Ns, skyprepConnector as Nt, acuitySchedulingConnector as Nu, snovIoConnector as O, apitemplateIoConnector as Oa, microsoftGraph as Oc, bexioConnector as Od, phonyConnector as Of, deepseekConnector as Oi, googleCalendar as Ol, mailchainConnector as On, hightouchConnector as Oo, kissflowConnector as Or, tallyConnector as Os, serviceNowConnector as Ot, azureEventGridConnector as Ou, heyreachConnector as P, airtopConnector as Pa, microsoft365PeopleConnector as Pc, genderApiConnector as Pd, convertkitConnector as Pi, googleApiError as Pl, imapConnector as Pn, datadogConnector as Po, jiraDataCenterConnector as Pr, signNowConnector as Ps, seekTableConnector as Pt, auth0Connector as Pu, vidlab7Connector as Q, geminiConnector as Qa, httpConnector as Qc, contextualAiConnector as Qd, certopusConnector as Qi, docusignConnector as Ql, memConnector as Qn, zohoMailConnector as Qo, gameballConnector as Qr, createRabbitMqConnector as Qs, productboardConnector as Qt, vercelConnector as Qu, wufooConnector as R, acumbamailConnector as Ra, linearConnector as Rc, featheryConnector as Rd, cohereConnector as Ri, freshsalesConnector as Rl, hedyConnector as Rn, telegramConnector as Ro, huggingFaceConnector as Rr, saleorConnector as Rs, saasticConnector as Rt, amazonSnsConnector as Ru, autoboundConnector as S, semrushConnector as Sa, meetgeekAiConnector as Sc, constantContactConnector as Sd, pingIdentityConnector as Sf, documergeConnector as Si, linkedinAdsConnector as Sl, omniCoConnector as Sn, builtwithConnector as So, kommoConnector as Sr, typeformConnector as Ss, smartsuiteConnector as St, baremetricsConnector as Su, leadfeederConnector as T, apitableConnector as Ta, microsoftPowerBiConnector as Tc, clicdataConnector as Td, oktaConnector as Tf, descriptConnector as Ti, metaAdsConnector as Tl, nocodbConnector as Tn, createMySqlConnector as To, koFiConnector as Tr, todoistConnector as Ts, simplirouteConnector as Tt, backblazeConnector as Tu, wonderchatConnector as U, kustomerConnector as Ua, publicKafkaSocketFactory as Uc, dripConnector as Ud, clockodoConnector as Ui, figmaConnector as Ul, gotifyConnector as Un, salesloftConnector as Uo, heygenConnector as Ur, ringcentralConnector as Us, replyIoConnector as Ut, amplitudeConnector as Uu, woocommerceConnector as V, agentxConnector as Va, createKafkaConnector as Vc, elevenlabsConnector as Vd, cloutlyConnector as Vi, flowluConnector as Vl, gristConnector as Vn, chatwootConnector as Vo, heymarketSmsConnector as Vr, salesforceConnector as Vs, retellAiConnector as Vt, amazonCloudWatchConnector as Vu, whatsscaleConnector as W, activecampaignConnector as Wa, justcallConnector as Wc, docsbotConnector as Wd, chatnodeConnector as Wi, figjamConnector as Wl, glideConnector as Wn, outreachConnector as Wo, hastewireConnector as Wr, rampConnector as Ws, reoonVerifierConnector as Wt, affinityConnector as Wu, vtexConnector as X, weaviateConnector as Xa, instagramBusinessConnector as Xc, couchbaseConnector as Xd, cannyConnector as Xi, dropboxConnector as Xl, mindeeConnector as Xn, brazeConnector as Xo, ghostcmsConnector as Xr, createRedisConnector as Xs, pushoverConnector as Xt, wootricConnector as Xu, vtigerConnector as Y, pineconeConnector as Ya, insightlyConnector as Yc, dappierConnector as Yd, chargekeepConnector as Yi, ebayConnector as Yl, mixmaxConnector as Yn, customerIoConnector as Yo, gistlyConnector as Yr, redshiftConnector as Ys, qawafelConnector as Yt, workdayConnector as Yu, vlmRunConnector as Z, huggingfaceConnector as Za, intercomConnector as Zc, contiguityConnector as Zd, chainalysisApiConnector as Zi, dialpadConnector as Zl, millionverifierConnector as Zn, apolloConnector as Zo, freshserviceConnector as Zr, redisConnector as Zs, proxycurlConnector as Zt, videoaskConnector as Zu, zenrowsConnector as _, avianConnector as _a, createMongoDbConnector as _c, giteaConnector as _d, anyhookWebsocketConnector as _f, elasticEmailConnector as _i, createAmazonAdsConnector as _l, opnformConnector as _n, zerobounceConnector as _o, linkaConnector as _r, twilioSmsConnector as _s, stripeConnector as _t, calCom as _u, linqWhatsappConnector as a, bolnaConnector as aa, paddleConnector as ac, reddit as ad, chaindeskConnector as af, flipandoConnector as ai, googleTasksConnector as al, placidConnector as an, zendeskSellConnector as ao, lucidyaConnector as ar, cloudbedsConnector as as, twilioConnector as at, recurlyConnector as au, leadmagicConnector as b, clayConnector as ba, miroConnector as bc, discordConnector as bd, actualbudgetConnector as bf, dumplingAiConnector as bi, snapchatAdsConnector as bl, openRouterConnector as bn, hunterConnector as bo, lettaConnector as br, twitter as bs, socialkitConnector as bt, billComConnector as bu, getresponseConnector as c, bitlyConnector as ca, oneSpanSignConnector as cc, paychexConnector as cd, cartloomConnector as cf, enrichlayerConnector as ci, googleSearchConsoleConnector as cl, peekshotConnector as cn, facebookPagesConnector as co, lushaConnector as cr, zendeskConnector as cs, totalcmsConnector as ct, contentfulConnector as cu, nooksConnector as d, beamerConnector as da, ninjapipeConnector as dc, niftyConnector as dd, bikaConnector as df, esignaturesConnector as di, googleForms as dl, paywhirlConnector as dn, slackEventsConnector as do, logrocketConnector as dr, wrikeConnector as ds, timeOpsConnector as dt, cloudinaryConnector as du, braveSearchConnector as ea, quickbooksConnector as ec, teableConnector as ed, clickfunnelsConnector as ef, frameConnector as ei, helpscoutConnector as el, posthogConnector as en, anthropicConnector as eo, messagebirdConnector as er, zohoCampaignsConnector as es, uscreenConnector as et, chessComConnector as eu, signwellConnector as f, azureOpenaiConnector as fa, netsuiteConnector as fc, netlifyConnector as fd, beehiivConnector as ff, emailitConnector as fi, googleDrive as fl, pinchPaymentsConnector as fn, stripeWebhookReceiverConnector as fo, lokaliseConnector as fr, wordpressConnector as fs, textcortexAiConnector as ft, cloudflareConnector as fu, oceanIoConnector as g, asknewsConnector as ga, mycaseConnector as gc, gustoConnector as gd, apifyConnector as gf, edenAiConnector as gi, googleCloudStorageConnector as gl, orimonConnector as gn, resolveConnectorAdapterFactoryOptions as go, localaiConnector as gr, voucheryIoConnector as gs, systemeIoConnector as gt, calendlyConnector as gu, seamlessAiConnector as h, azureCommunicationServicesConnector as ha, notionConnector as hc, instaChartsConnector as hd, askHandleConnector as hf, easyPeasyAiConnector as hi, googlePubSubConnector as hl, oracleDatabaseConnector as hn, CONNECTOR_ADAPTER_FACTORIES as ho, lobstermailConnector as hr, whatsappBusiness as hs, tableauConnector as ht, capsuleCrmConnector as hu, resendConnector as i, bookedinConnector as ia, plaidConnector as ic, ripplingConnector as id, chatAidConnector as if, formbricksConnector as ii, googlechatConnector as il, plausibleConnector as in, sendgridConnector as io, matomoConnector as ir, pricelabsConnector as is, upgradechatConnector as it, taxjarConnector as iu, bettercontactConnector as j, alttextifyConnector as ja, microsoftDynamics365BusinessCentralConnector as jc, modelslabConnector as jd, datafuelConnector as ji, gmail as jl, kallabotAiConnector as jn, clicksendConnector as jo, kizeoFormsConnector as jr, shopifyConnector as js, senjaConnector as jt, avalaraConnector as ju, findymailConnector as k, amazonTextractConnector as ka, microsoftExcel365Connector as kc, adpConnector as kd, customgptConnector as ki, gorgiasConnector as kl, loopsConnector as kn, googleBigqueryConnector as ko, kimaiConnector as kr, stripePackConnector as ks, tregConnector as kt, azureBlobStorageConnector as ku, factorsAiConnector as l, blandAiConnector as la, oneDrive as lc, pagerdutyConnector as ld, cambAiConnector as lf, fathomAnalyticsConnector as li, googleMyBusinessConnector as ll, pdfmonkeyConnector as ln, gitlabConnector as lo, loftyConnector as lr, zapierConnector as ls, togglTrackConnector as lt, confluenceConnector as lu, usergemsConnector as m, autocallsConnector as ma, notion as mc, leverConnector as md, bannerbearConnector as mf, dustConnector as mi, googleContactsConnector as ml, paperformConnector as mn, webhookConnector as mo, llmrailsConnector as mr, xeroConnector as ms, talkableConnector as mt, closeConnector as mu, sendblueConnector as n, brilliantDirectoriesConnector as na, pipedriveConnector as nc, sendpulseConnector as nd, claudeConnector as nf, fountainConnector as ni, hellosign as nl, pollybotAiConnector as nn, sentryConnector as no, mailgunConnector as nr, zohoCrmConnector as ns, validatedmailsConnector as nt, circleConnector as nu, linqConnector as o, blueskyConnector as oa, pandadoc as oc, redditConnector as od, chainAwareConnector as of, flowiseConnector as oi, googleSlidesConnector as ol, personalAiConnector as on, zagomailConnector as oo, luxuryPresenceConnector as or, zohoBookingsConnector as os, twinLabsConnector as ot, chargebeeConnector as ou, polytomicConnector as p, barcodeLookupConnector as pa, n8nConnector as pc, lightfunnelsConnector as pd, base44Connector as pf, emailoctopusConnector as pi, googleDocs as pl, pastefyConnector as pn, gtmAgentConnector as po, magicalApiConnector as pr, webflowConnector as ps, telnyxConnector as pt, clickupConnector as pu, whatConvertsConnector as q, bamboohrConnector as qa, ironcladConnector as qc, detectingAiConnector as qd, chatbaseConnector as qi, fathomConnector as ql, missiveConnector as qn, lemlistConnector as qo, greenptConnector as qr, postgresConnector as qs, raiaAiConnector as qt, zuoraConnector as qu, clerkConnector as r, browseAiConnector as ra, pipedreamConnector as rc, sanityConnector as rd, chatsistantConnector as rf, foreplayCoConnector as ri, granolaConnector as rl, pocketbaseConnector as rn, postmarkConnector as ro, manychatConnector as rr, zohoDeskConnector as rs, vapiConnector as rt, cashfreePaymentsConnector as ru, inkboxConnector as s, bonjoroConnector as sa, outlookMail as sc, pushbulletConnector as sd, csvFilesConnector as sf, facebookLeadsConnector as si, googleSheets as sl, perplexityAiConnector as sn, quickzuConnector as so, mailerLiteConnector as sr, zoomConnector as ss, typefullyConnector as st, copperConnector as su, adapters_exports as t, campaignMonitorConnector as ta, parquetFilesConnector as tc, snowflakeConnector as td, clearoutphoneConnector as tf, mailercheckConnector as ti, harvestConnector as tl, postizConnector as tn, openaiConnector as to, mailerooConnector as tr, zohoBooksConnector as ts, umamiConnector as tt, checkoutConnector as tu, modjoConnector as u, bettermodeConnector as ua, openPhoneConnector as uc, opsgenieConnector as ud, buttondownConnector as uf, firecrawlConnector as ui, googleMeetConnector as ul, parseurConnector as un, githubConnector as uo, logsnagConnector as ur, youtubeDataConnector as us, timelinesAiConnector as ut, codaConnector as uu, phantombusterConnector as v, assemblyaiConnector as va, mongodbConnector as vc, freeAgentConnector as vd, airparserConnector as vf, documentproConnector as vi, createMicrosoftAdsConnector as vl, openmicAiConnector as vn, theirstackConnector as vo, letsCalendarConnector as vr, tiktok as vs, swarmnodeConnector as vt, calComConnector as vu, serperConnector as w, aminosConnector as wa, microsoftTodoConnector as wc, clioConnector as wd, clientCredentialsRestConnector as wf, datocmsConnector as wi, xAdsConnector as wl, ntfyConnector as wn, segmentConnector as wo, kudosityConnector as wr, trelloConnector as ws, simplybookmeConnector as wt, biginByZohoConnector as wu, crustdataConnector as x, cognismConnector as xa, mollieConnector as xc, demandbaseConnector as xd, scimConnector as xf, doctlyConnector as xi, redditAdsConnector as xl, omnihrConnector as xn, fullenrichConnector as xo, leexiConnector as xr, twitterConnector as xs, smsmodeConnector as xt, brexConnector as xu, brightdataConnector as y, ashbyConnector as ya, mondayConnector as yc, formstackConnector as yd, aianswerConnector as yf, dubConnector as yi, pinterestAdsConnector as yl, opportifyConnector as yn, neverbounceConnector as yo, linkupConnector as yr, tiktokConnector as ys, supadataConnector as yt, billplzConnector as yu, writesonicBulkConnector as z, aidbaseConnector as za, lemonSqueezyConnector as zc, everhourConnector as zd, cognitoFormsConnector as zi, freshdeskConnector as zl, heartbeatConnector as zn, mattermostConnector as zo, influencersClubConnector as zr, createSftpConnector as zs, runwareConnector as zt, amazonS3Connector as zu };
195623
+ export { vboutConnector as $, googleGeminiConnector as $a, helpscoutConnector as $c, clickfunnelsConnector as $d, captainDataConnector as $i, chessComConnector as $l, mauticConnector as $n, zohoInvoiceConnector as $o, fragmentConnector as $r, quickbooksConnector as $s, predictLeadsConnector as $t, teableConnector as $u, contactoutConnector as A, amazonSesConnector as Aa, microsoftDynamics365BusinessCentralConnector as Ac, modelslabConnector as Ad, cryptolensConnector as Ai, gmail as Al, knockConnector as An, firebaseConnector as Ao, kapsoConnector as Ar, shopifyConnector as As, serpstatConnector as At, avalaraConnector as Au, workableConnector as B, afforaiConnector as Ba, createKafkaConnector as Bc, elevenlabsConnector as Bd, clearoutConnector as Bi, flowluConnector as Bl, griptapeConnector as Bn, matrixConnector as Bo, housecallProConnector as Br, salesforceConnector as Bs, robollyConnector as Bt, amazonCloudWatchConnector as Bu, warmlyConnector as C, similarwebConnector as Ca, microsoftTodoConnector as Cc, clioConnector as Cd, clientCredentialsRestConnector as Cf, dittofeedConnector as Ci, xAdsConnector as Cl, odooConnector as Cn, supabaseConnector as Co, leapAiConnector as Cr, trelloConnector as Cs, smartsheetConnector as Ct, biginByZohoConnector as Cu, wizaConnector as D, ampecoConnector as Da, microsoftGraph as Dc, bexioConnector as Dd, phonyConnector as Df, denserAiConnector as Di, googleCalendar as Dl, medullarConnector as Dn, metabaseConnector as Do, klentyConnector as Dr, tallyConnector as Ds, signrequestConnector as Dt, azureEventGridConnector as Du, commonRoomConnector as E, appfollowConnector as Ea, microsoftTeams as Ec, bigcommerceConnector as Ed, createPhonyConnector as Ef, devinConnector as Ei, googleAnalyticsConnector as El, mindStudioConnector as En, mysqlConnector as Eo, knackConnector as Er, ticktickConnector as Es, shortIoConnector as Et, azureServiceBusConnector as Eu, amplemarketConnector as F, amazonSecretsManagerConnector as Fa, createLinkedinConnector as Fc, flowParserConnector as Fd, crispConnector as Fi, googleTestFailureReason as Fl, ibmCognoseConnector as Fn, baserowConnector as Fo, jinaAiConnector as Fr, sharepoint as Fs, scrapelessConnector as Ft, asanaConnector as Fu, whatsappConnector as G, smooveConnector as Ga, jiraCloudConnector as Gc, digitalPilotConnector as Gd, chatDataConnector as Gi, fireberryConnector as Gl, googleVertexaiConnector as Gn, marketoConnector as Go, guideliteConnector as Gr, createPostgresConnector as Gs, reachinboxConnector as Gt, adobeSignConnector as Gu, woodpeckerConnector as H, airOpsConnector as Ha, publicKafkaSocketFactory as Hc, dripConnector as Hd, clockifyConnector as Hi, figmaConnector as Hl, gptzeroDetectAiConnector as Hn, smartleadConnector as Ho, hashiCorpVaultConnector as Hr, ringcentralConnector as Hs, retableConnector as Ht, amplitudeConnector as Hu, zeplinConnector as I, amazonBedrockConnector as Ia, linkedinConnector as Ic, fellowConnector as Id, comfyicuConnector as Ii, frontConnector as Il, hystructConnector as In, airtableConnector as Io, imageRouterConnector as Ir, savvycalConnector as Is, scrapegraphaiConnector as It, amazonSqsConnector as Iu, wafeqConnector as J, qdrantConnector as Ja, insightlyConnector as Jc, dappierConnector as Jd, chatlingConnector as Ji, ebayConnector as Jl, mixpanelConnector as Jn, klaviyoConnector as Jo, googleSearchConnector as Jr, redshiftConnector as Js, quadernoConnector as Jt, workdayConnector as Ju, webscrapingAiConnector as K, greenhouseConnector as Ka, ironcladConnector as Kc, detectingAiConnector as Kd, chartlyConnector as Ki, fathomConnector as Kl, exaConnector as Kn, mailchimpConnector as Ko, greipConnector as Kr, postgresConnector as Ks, rapidtextAiConnector as Kt, zuoraConnector as Ku, youcanbookmeConnector as L, aipriseConnector as La, linearConnector as Lc, featheryConnector as Ld, cometapiConnector as Li, freshsalesConnector as Ll, humeAiConnector as Ln, TELEGRAM_FILE_DOWNLOAD_ROOT as Lo, instantlyAiConnector as Lr, saleorConnector as Ls, sardisConnector as Lt, amazonSnsConnector as Lu, saleshandyConnector as M, altTextAiConnector as Ma, microsoft365PlannerConnector as Mc, generatebannersConnector as Md, copyAiConnector as Mi, classifyGoogleReason as Ml, instasentConnector as Mn, digitalOceanConnector as Mo, joggAiConnector as Mr, slack as Ms, sendinblueConnector as Mt, acuitySchedulingConnector as Mu, lagrowthmachineConnector as N, alaiConnector as Na, microsoft365PeopleConnector as Nc, genderApiConnector as Nd, dashworksConnector as Ni, googleApiError as Nl, insightoAiConnector as Nn, discourseConnector as No, justInvoiceConnector as Nr, signNowConnector as Ns, skyprepConnector as Nt, auth0Connector as Nu, snovIoConnector as O, apitemplateIoConnector as Oa, microsoftExcel365Connector as Oc, adpConnector as Od, deepseekConnector as Oi, gorgiasConnector as Ol, mailchainConnector as On, hightouchConnector as Oo, kissflowConnector as Or, stripePackConnector as Os, serviceNowConnector as Ot, azureBlobStorageConnector as Ou, heyreachConnector as P, airtopConnector as Pa, makeConnector as Pc, gammaConnector as Pd, convertkitConnector as Pi, googleErrorReason as Pl, imapConnector as Pn, datadogConnector as Po, jiraDataCenterConnector as Pr, shippoConnector as Ps, seekTableConnector as Pt, attioConnector as Pu, vidlab7Connector as Q, geminiConnector as Qa, hubspot as Qc, codyConnector as Qd, certopusConnector as Qi, docuseal as Ql, memConnector as Qn, zohoMailConnector as Qo, gameballConnector as Qr, rabbitMqConnector as Qs, productboardConnector as Qt, tenzoConnector as Qu, wufooConnector as R, acumbamailConnector as Ra, lemonSqueezyConnector as Rc, everhourConnector as Rd, cohereConnector as Ri, freshdeskConnector as Rl, hedyConnector as Rn, telegramConnector as Ro, huggingFaceConnector as Rr, createSftpConnector as Rs, saasticConnector as Rt, amazonS3Connector as Ru, autoboundConnector as S, semrushConnector as Sa, mastodonConnector as Sc, cloudconvertConnector as Sd, oneloginConnector as Sf, documergeConnector as Si, tiktokAdsConnector as Sl, omniCoConnector as Sn, builtwithConnector as So, kommoConnector as Sr, twentyConnector as Ss, smartsuiteConnector as St, boxConnector as Su, leadfeederConnector as T, apitableConnector as Ta, microsoftOnenoteConnector as Tc, canvaConnector as Td, declarativeRestConnector as Tf, descriptConnector as Ti, googleAdsConnector as Tl, nocodbConnector as Tn, createMySqlConnector as To, koFiConnector as Tr, tlDvConnector as Ts, simplirouteConnector as Tt, basecampConnector as Tu, wonderchatConnector as U, kustomerConnector as Ua, justcallConnector as Uc, docsbotConnector as Ud, clockodoConnector as Ui, figjamConnector as Ul, gotifyConnector as Un, salesloftConnector as Uo, heygenConnector as Ur, rampConnector as Us, replyIoConnector as Ut, affinityConnector as Uu, woocommerceConnector as V, agentxConnector as Va, kafkaConnector as Vc, echowinConnector as Vd, cloutlyConnector as Vi, filloutFormsConnector as Vl, gristConnector as Vn, chatwootConnector as Vo, heymarketSmsConnector as Vr, rssConnector as Vs, retellAiConnector as Vt, amazonEventBridgeConnector as Vu, whatsscaleConnector as W, activecampaignConnector as Wa, jotformConnector as Wc, duckdbConnector as Wd, chatnodeConnector as Wi, firefliesAiConnector as Wl, glideConnector as Wn, outreachConnector as Wo, hastewireConnector as Wr, recallAiConnector as Ws, reoonVerifierConnector as Wt, aircallConnector as Wu, vtexConnector as X, weaviateConnector as Xa, intercomConnector as Xc, contiguityConnector as Xd, cannyConnector as Xi, dialpadConnector as Xl, mindeeConnector as Xn, brazeConnector as Xo, ghostcmsConnector as Xr, redisConnector as Xs, pushoverConnector as Xt, videoaskConnector as Xu, vtigerConnector as Y, pineconeConnector as Ya, instagramBusinessConnector as Yc, couchbaseConnector as Yd, chargekeepConnector as Yi, dropboxConnector as Yl, mixmaxConnector as Yn, customerIoConnector as Yo, gistlyConnector as Yr, createRedisConnector as Ys, qawafelConnector as Yt, wootricConnector as Yu, vlmRunConnector as Z, huggingfaceConnector as Za, httpConnector as Zc, contextualAiConnector as Zd, chainalysisApiConnector as Zi, docusignConnector as Zl, millionverifierConnector as Zn, apolloConnector as Zo, freshserviceConnector as Zr, createRabbitMqConnector as Zs, proxycurlConnector as Zt, vercelConnector as Zu, zenrowsConnector as _, avianConnector as _a, mongodbConnector as _c, freeAgentConnector as _d, airparserConnector as _f, elasticEmailConnector as _i, createMicrosoftAdsConnector as _l, opnformConnector as _n, zerobounceConnector as _o, linkaConnector as _r, tiktok as _s, stripeConnector as _t, calComConnector as _u, linqWhatsappConnector as a, bolnaConnector as aa, pandadoc as ac, redditConnector as ad, chainAwareConnector as af, flipandoConnector as ai, googleSlidesConnector as al, placidConnector as an, zendeskSellConnector as ao, lucidyaConnector as ar, zohoBookingsConnector as as, twilioConnector as at, chargebeeConnector as au, leadmagicConnector as b, clayConnector as ba, mollieConnector as bc, demandbaseConnector as bd, scimConnector as bf, dumplingAiConnector as bi, redditAdsConnector as bl, openRouterConnector as bn, hunterConnector as bo, lettaConnector as br, twitterConnector as bs, socialkitConnector as bt, brexConnector as bu, getresponseConnector as c, bitlyConnector as ca, oneDrive as cc, pagerdutyConnector as cd, cambAiConnector as cf, enrichlayerConnector as ci, googleMyBusinessConnector as cl, peekshotConnector as cn, facebookPagesConnector as co, lushaConnector as cr, zapierConnector as cs, totalcmsConnector as ct, confluenceConnector as cu, nooksConnector as d, beamerConnector as da, netsuiteConnector as dc, netlifyConnector as dd, beehiivConnector as df, esignaturesConnector as di, googleDrive as dl, paywhirlConnector as dn, slackEventsConnector as do, logrocketConnector as dr, wordpressConnector as ds, timeOpsConnector as dt, cloudflareConnector as du, braveSearchConnector as ea, parquetFilesConnector as ec, snowflakeConnector as ed, clearoutphoneConnector as ef, frameConnector as ei, harvestConnector as el, posthogConnector as en, anthropicConnector as eo, messagebirdConnector as er, zohoCampaignsConnector as es, uscreenConnector as et, checkoutConnector as eu, signwellConnector as f, azureOpenaiConnector as fa, n8nConnector as fc, lightfunnelsConnector as fd, base44Connector as ff, emailitConnector as fi, googleDocs as fl, pinchPaymentsConnector as fn, stripeWebhookReceiverConnector as fo, lokaliseConnector as fr, webflowConnector as fs, textcortexAiConnector as ft, clickupConnector as fu, oceanIoConnector as g, asknewsConnector as ga, createMongoDbConnector as gc, giteaConnector as gd, anyhookWebsocketConnector as gf, edenAiConnector as gi, createAmazonAdsConnector as gl, orimonConnector as gn, resolveConnectorAdapterFactoryOptions as go, localaiConnector as gr, twilioSmsConnector as gs, systemeIoConnector as gt, calCom as gu, seamlessAiConnector as h, azureCommunicationServicesConnector as ha, mycaseConnector as hc, gustoConnector as hd, apifyConnector as hf, easyPeasyAiConnector as hi, googleCloudStorageConnector as hl, oracleDatabaseConnector as hn, CONNECTOR_ADAPTER_FACTORIES as ho, lobstermailConnector as hr, voucheryIoConnector as hs, tableauConnector as ht, calendlyConnector as hu, resendConnector as i, bookedinConnector as ia, paddleConnector as ic, reddit as id, chaindeskConnector as if, formbricksConnector as ii, googleTasksConnector as il, plausibleConnector as in, sendgridConnector as io, matomoConnector as ir, pricelabsConnector as is, upgradechatConnector as it, recurlyConnector as iu, bettercontactConnector as j, alttextifyConnector as ja, microsoftCalendar as jc, giftbitConnector as jd, datafuelConnector as ji, classifyGoogleError as jl, kallabotAiConnector as jn, clicksendConnector as jo, kizeoFormsConnector as jr, sageIntacctConnector as js, senjaConnector as jt, avomaConnector as ju, findymailConnector as k, amazonTextractConnector as ka, microsoftDynamicsCrmConnector as kc, adobeCreativeCloudConnector as kd, customgptConnector as ki, gongConnector as kl, loopsConnector as kn, googleBigqueryConnector as ko, kimaiConnector as kr, squareConnector as ks, tregConnector as kt, azureAdConnector as ku, factorsAiConnector as l, blandAiConnector as la, openPhoneConnector as lc, opsgenieConnector as ld, buttondownConnector as lf, fathomAnalyticsConnector as li, googleMeetConnector as ll, pdfmonkeyConnector as ln, gitlabConnector as lo, loftyConnector as lr, youtubeDataConnector as ls, togglTrackConnector as lt, codaConnector as lu, usergemsConnector as m, autocallsConnector as ma, notionConnector as mc, instaChartsConnector as md, askHandleConnector as mf, dustConnector as mi, googlePubSubConnector as ml, paperformConnector as mn, webhookConnector as mo, llmrailsConnector as mr, whatsappBusiness as ms, talkableConnector as mt, capsuleCrmConnector as mu, sendblueConnector as n, brilliantDirectoriesConnector as na, pipedreamConnector as nc, sanityConnector as nd, chatsistantConnector as nf, fountainConnector as ni, granolaConnector as nl, pollybotAiConnector as nn, sentryConnector as no, mailgunConnector as nr, zohoCrmConnector as ns, validatedmailsConnector as nt, cashfreePaymentsConnector as nu, linqConnector as o, blueskyConnector as oa, outlookMail as oc, pushbulletConnector as od, csvFilesConnector as of, flowiseConnector as oi, googleSheets as ol, personalAiConnector as on, zagomailConnector as oo, luxuryPresenceConnector as or, zoomConnector as os, twinLabsConnector as ot, copperConnector as ou, polytomicConnector as p, barcodeLookupConnector as pa, notion as pc, leverConnector as pd, bannerbearConnector as pf, emailoctopusConnector as pi, googleContactsConnector as pl, pastefyConnector as pn, gtmAgentConnector as po, magicalApiConnector as pr, xeroConnector as ps, telnyxConnector as pt, closeConnector as pu, whatConvertsConnector as q, bamboohrConnector as qa, invoiceninjaConnector as qc, deepgramConnector as qd, chatbaseConnector as qi, etsyConnector as ql, missiveConnector as qn, lemlistConnector as qo, greenptConnector as qr, createRedshiftConnector as qs, raiaAiConnector as qt, zoominfoConnector as qu, clerkConnector as r, browseAiConnector as ra, plaidConnector as rc, ripplingConnector as rd, chatAidConnector as rf, foreplayCoConnector as ri, googlechatConnector as rl, pocketbaseConnector as rn, postmarkConnector as ro, manychatConnector as rr, zohoDeskConnector as rs, vapiConnector as rt, taxjarConnector as ru, inkboxConnector as s, bonjoroConnector as sa, oneSpanSignConnector as sc, paychexConnector as sd, cartloomConnector as sf, facebookLeadsConnector as si, googleSearchConsoleConnector as sl, perplexityAiConnector as sn, quickzuConnector as so, mailerLiteConnector as sr, zendeskConnector as ss, typefullyConnector as st, contentfulConnector as su, adapters_exports as t, campaignMonitorConnector as ta, pipedriveConnector as tc, sendpulseConnector as td, claudeConnector as tf, mailercheckConnector as ti, hellosign as tl, postizConnector as tn, openaiConnector as to, mailerooConnector as tr, zohoBooksConnector as ts, umamiConnector as tt, circleConnector as tu, modjoConnector as u, bettermodeConnector as ua, ninjapipeConnector as uc, niftyConnector as ud, bikaConnector as uf, firecrawlConnector as ui, googleForms as ul, parseurConnector as un, githubConnector as uo, logsnagConnector as ur, wrikeConnector as us, timelinesAiConnector as ut, cloudinaryConnector as uu, phantombusterConnector as v, assemblyaiConnector as va, mondayConnector as vc, formstackConnector as vd, aianswerConnector as vf, documentproConnector as vi, pinterestAdsConnector as vl, openmicAiConnector as vn, theirstackConnector as vo, letsCalendarConnector as vr, tiktokConnector as vs, swarmnodeConnector as vt, billplzConnector as vu, serperConnector as w, aminosConnector as wa, microsoftPowerBiConnector as wc, clicdataConnector as wd, oktaConnector as wf, datocmsConnector as wi, metaAdsConnector as wl, ntfyConnector as wn, segmentConnector as wo, kudosityConnector as wr, todoistConnector as ws, simplybookmeConnector as wt, backblazeConnector as wu, crustdataConnector as x, cognismConnector as xa, meetgeekAiConnector as xc, constantContactConnector as xd, pingIdentityConnector as xf, doctlyConnector as xi, linkedinAdsConnector as xl, omnihrConnector as xn, fullenrichConnector as xo, leexiConnector as xr, typeformConnector as xs, smsmodeConnector as xt, baremetricsConnector as xu, brightdataConnector as y, ashbyConnector as ya, miroConnector as yc, discordConnector as yd, actualbudgetConnector as yf, dubConnector as yi, snapchatAdsConnector as yl, opportifyConnector as yn, neverbounceConnector as yo, linkupConnector as yr, twitter as ys, supadataConnector as yt, billComConnector as yu, writesonicBulkConnector as z, aidbaseConnector as za, leadConnectorConnector as zc, excelFilesConnector as zd, cognitoFormsConnector as zi, folkConnector as zl, heartbeatConnector as zn, mattermostConnector as zo, influencersClubConnector as zr, sftpConnector as zs, runwareConnector as zt, amazonLambdaConnector as zu };
195704
195624
 
195705
- //# sourceMappingURL=adapters-BU09k8Cr.js.map
195625
+ //# sourceMappingURL=adapters-CngYgl1W.js.map