@wix/auto_sdk_site-import_imports 1.0.0 → 1.0.2

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.
@@ -9,7 +9,7 @@ interface StartImportSignature {
9
9
  * @param - Natural-language import request. Include the source site URL
10
10
  * (e.g. "import https://shop.example.com into Wix").
11
11
  */
12
- (request: string, options?: StartImportOptions): Promise<NonNullablePaths<StartImportResponse, `importId` | `sourcePlatform` | `sourceConfidence` | `destinationSiteId`, 0>>;
12
+ (request: string, options?: StartImportOptions): Promise<NonNullablePaths<StartImportResponse, `importId` | `sourcePlatform` | `sourceConfidence` | `destinationSiteId` | `existingImport`, 0>>;
13
13
  }
14
14
  declare function getImportStatus$1(httpClient: HttpClient): GetImportStatusSignature;
15
15
  interface GetImportStatusSignature {
@@ -183,8 +183,8 @@ interface GetImportBySiteSignature {
183
183
  * caller error (`SITE_UNIDENTIFIED`), same as `StartImport` — this rpc has no
184
184
  * request-text fallback, so a site or fileset must be named explicitly.
185
185
  * ACCOUNT tenancy (unlike the SITE-tenancy pair above): scoped to the
186
- * CALLING USER's own imports only, never another account member's — see
187
- * GetImportBySiteRequest's comment and spec 0025 for why.
186
+ * ACCOUNT's import for the source, whichever member started it — see
187
+ * GetImportBySiteRequest's comment.
188
188
  * Resolvable only within the import's 7-day resumability window (the same
189
189
  * window `SendImportMessage`'s `SESSION_EXPIRED` bounds) — a lookup outside
190
190
  * that window returns `IMPORT_NOT_FOUND`, indistinguishable from "never
@@ -73,6 +73,12 @@ function resolveWixEcomSiteImportV1SiteImportServiceUrl(opts) {
73
73
  srcPath: "/site-import",
74
74
  destPath: ""
75
75
  }
76
+ ],
77
+ "*.dev.wix-code.com": [
78
+ {
79
+ srcPath: "/_api/bix-site-import",
80
+ destPath: ""
81
+ }
76
82
  ]
77
83
  };
78
84
  return (0, import_rest_modules2.resolveUrl)(Object.assign(opts, { domainToMappings }));
@@ -352,7 +358,6 @@ var ImportStatus = /* @__PURE__ */ ((ImportStatus2) => {
352
358
  ImportStatus2["DEPLOYED"] = "DEPLOYED";
353
359
  ImportStatus2["FAILED"] = "FAILED";
354
360
  ImportStatus2["CANCELLED"] = "CANCELLED";
355
- ImportStatus2["AUTH_EXPIRED"] = "AUTH_EXPIRED";
356
361
  ImportStatus2["NEEDS_INPUT"] = "NEEDS_INPUT";
357
362
  return ImportStatus2;
358
363
  })(ImportStatus || {});
@@ -394,7 +399,8 @@ async function startImport2(request, options) {
394
399
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
395
400
  request,
396
401
  sourceUrl: options?.sourceUrl,
397
- fileUrls: options?.fileUrls
402
+ fileUrls: options?.fileUrls,
403
+ forceNew: options?.forceNew
398
404
  });
399
405
  const reqOpts = startImport(payload);
400
406
  sideEffects?.onSiteCall?.();
@@ -410,7 +416,8 @@ async function startImport2(request, options) {
410
416
  explicitPathsToArguments: {
411
417
  request: "$[0]",
412
418
  sourceUrl: "$[1].sourceUrl",
413
- fileUrls: "$[1].fileUrls"
419
+ fileUrls: "$[1].fileUrls",
420
+ forceNew: "$[1].forceNew"
414
421
  },
415
422
  singleArgumentUnchanged: false
416
423
  },