@wix/auto_sdk_site-import_imports 1.0.2 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -679,6 +679,31 @@ interface GetImportSourceFileRequest {
679
679
  * @maxLength 500
680
680
  */
681
681
  filePath: string;
682
+ /**
683
+ * QUERY OPTIONS (spec 0027) — at most one of `tail`, `head`, `lines`, `grep`.
684
+ * Served from the S3 snapshot only (never a clone): a checkpoint with no
685
+ * snapshot answers FAILED_PRECONDITION, an account outside the rollout
686
+ * UNIMPLEMENTED. When none is set the call is the plain bounded preview.
687
+ *
688
+ * Return only the last N lines of the file (N ≤ 200).
689
+ */
690
+ tail?: number;
691
+ /** Return only the first N lines of the file (N ≤ 200). */
692
+ head?: number;
693
+ /**
694
+ * Return a line range such as "10-60" (at most 200 lines).
695
+ * @maxLength 20
696
+ */
697
+ lines?: string;
698
+ /**
699
+ * Return the lines matching this pattern (with `context` lines around each).
700
+ * @maxLength 200
701
+ */
702
+ grep?: string;
703
+ /** Lines of context around each `grep` match, 0-10. */
704
+ context?: number;
705
+ /** Treat `grep` as a literal string instead of a regular expression. */
706
+ fixed?: boolean;
682
707
  }
683
708
  interface GetImportSourceFileResponse {
684
709
  /**
@@ -707,6 +732,36 @@ interface GetImportSourceFileResponse {
707
732
  * clipped, not the complete file.
708
733
  */
709
734
  truncated?: boolean;
735
+ /**
736
+ * First line number of `content` for `head`/`lines`; absent for `tail`
737
+ * (the line number of a file's end is not known without reading all of it).
738
+ */
739
+ firstLine?: number;
740
+ /**
741
+ * `grep` results (with context lines), in file order. `content` is empty.
742
+ * @maxSize 5000
743
+ */
744
+ matches?: SourceMatch[];
745
+ /**
746
+ * Why a query result is incomplete — MAX_LINES, MAX_MATCHES, RESPONSE_SIZE,
747
+ * TIME, LINE_CLIPPED (a line over 64 KiB was cut, so text past it was not
748
+ * seen) or STORED_PREFIX_ONLY (the file is over 25 MB and only its start is
749
+ * stored). Set whenever `truncated` is true for a query.
750
+ * @maxLength 32
751
+ */
752
+ truncatedReason?: string;
753
+ }
754
+ /** One matching (or context) line of a `grep` query on a single file. */
755
+ interface SourceMatch {
756
+ /** 1-based line number within the file. */
757
+ line?: number;
758
+ /**
759
+ * The line's text (clipped to 2000 characters).
760
+ * @maxLength 2000
761
+ */
762
+ text?: string;
763
+ /** True for a context line around a match, false for the match itself. */
764
+ contextLine?: boolean;
710
765
  }
711
766
  interface GetImportSourceForSiteRequest {
712
767
  /**
@@ -822,6 +877,31 @@ interface GetImportSourceFileForSiteRequest {
822
877
  * @format GUID
823
878
  */
824
879
  importId: string;
880
+ /**
881
+ * QUERY OPTIONS (spec 0027) — at most one of `tail`, `head`, `lines`, `grep`.
882
+ * Served from the S3 snapshot only (never a clone): a checkpoint with no
883
+ * snapshot answers FAILED_PRECONDITION, an account outside the rollout
884
+ * UNIMPLEMENTED. When none is set the call is the plain bounded preview.
885
+ *
886
+ * Return only the last N lines of the file (N ≤ 200).
887
+ */
888
+ tail?: number;
889
+ /** Return only the first N lines of the file (N ≤ 200). */
890
+ head?: number;
891
+ /**
892
+ * Return a line range such as "10-60" (at most 200 lines).
893
+ * @maxLength 20
894
+ */
895
+ lines?: string;
896
+ /**
897
+ * Return the lines matching this pattern (with `context` lines around each).
898
+ * @maxLength 200
899
+ */
900
+ grep?: string;
901
+ /** Lines of context around each `grep` match, 0-10. */
902
+ context?: number;
903
+ /** Treat `grep` as a literal string instead of a regular expression. */
904
+ fixed?: boolean;
825
905
  }
826
906
  /**
827
907
  * Identical shape to GetImportSourceFileResponse — a distinct message only
@@ -854,6 +934,158 @@ interface GetImportSourceFileForSiteResponse {
854
934
  * clipped, not the complete file.
855
935
  */
856
936
  truncated?: boolean;
937
+ /**
938
+ * First line number of `content` for `head`/`lines`; absent for `tail`
939
+ * (the line number of a file's end is not known without reading all of it).
940
+ */
941
+ firstLine?: number;
942
+ /**
943
+ * `grep` results (with context lines), in file order. `content` is empty.
944
+ * @maxSize 5000
945
+ */
946
+ matches?: SourceMatch[];
947
+ /**
948
+ * Why a query result is incomplete — MAX_LINES, MAX_MATCHES, RESPONSE_SIZE,
949
+ * TIME, LINE_CLIPPED (a line over 64 KiB was cut, so text past it was not
950
+ * seen) or STORED_PREFIX_ONLY (the file is over 25 MB and only its start is
951
+ * stored). Set whenever `truncated` is true for a query.
952
+ * @maxLength 32
953
+ */
954
+ truncatedReason?: string;
955
+ }
956
+ interface SearchImportSourceRequest {
957
+ /**
958
+ * Id of the import whose source to search.
959
+ * @format GUID
960
+ */
961
+ importId: string;
962
+ /**
963
+ * Checkpoint to search AS OF — a prior GetImportSource response's
964
+ * `checkpoint`. Absent = the latest checkpoint.
965
+ * @maxLength 40
966
+ */
967
+ checkpoint?: string;
968
+ /**
969
+ * The pattern to look for (a regular expression unless `fixed`).
970
+ * @maxLength 200
971
+ */
972
+ pattern: string;
973
+ /** Treat `pattern` as a literal string. */
974
+ fixed?: boolean;
975
+ /** Lines of context around each match, 0-10. */
976
+ context?: number;
977
+ /**
978
+ * Only search files whose path starts with this prefix.
979
+ * @maxLength 500
980
+ */
981
+ pathPrefix?: string;
982
+ }
983
+ interface SearchImportSourceResponse {
984
+ /**
985
+ * Id of this import (echoes the request).
986
+ * @format GUID
987
+ */
988
+ importId?: string;
989
+ /**
990
+ * The checkpoint that was searched.
991
+ * @maxLength 40
992
+ */
993
+ checkpoint?: string;
994
+ /**
995
+ * Matching lines (and their context), in path order.
996
+ * @maxSize 5000
997
+ */
998
+ matches?: SearchMatch[];
999
+ /** True if the scan stopped before covering every file. */
1000
+ truncated?: boolean;
1001
+ /**
1002
+ * Why: MAX_FILES, MAX_BYTES, MAX_MATCHES, RESPONSE_SIZE, TIME, LINE_CLIPPED (a
1003
+ * line over 64 KiB was cut) or STORED_PREFIX_ONLY (a file over 25 MB is stored
1004
+ * only in part). Unknown values should be treated as "partial result".
1005
+ * @maxLength 32
1006
+ */
1007
+ truncatedReason?: string;
1008
+ /**
1009
+ * The last path fully scanned, so a capped search can continue with a
1010
+ * narrower `path_prefix`.
1011
+ * @maxLength 500
1012
+ */
1013
+ lastPathScanned?: string;
1014
+ }
1015
+ /** One matching (or context) line found by SearchImportSource. */
1016
+ interface SearchMatch {
1017
+ /**
1018
+ * File the line is in, relative to the repository root.
1019
+ * @maxLength 500
1020
+ */
1021
+ path?: string;
1022
+ /** 1-based line number within the file. */
1023
+ line?: number;
1024
+ /**
1025
+ * The line's text (clipped to 2000 characters).
1026
+ * @maxLength 2000
1027
+ */
1028
+ text?: string;
1029
+ /** True for a context line around a match, false for the match itself. */
1030
+ contextLine?: boolean;
1031
+ }
1032
+ interface SearchImportSourceForSiteRequest {
1033
+ /**
1034
+ * OPTIONAL. Pins the search to the import a prior GetImportSourceForSite
1035
+ * response resolved; the server re-verifies it belongs to the caller's site.
1036
+ * @format GUID
1037
+ */
1038
+ importId?: string;
1039
+ /**
1040
+ * Checkpoint to search AS OF. Absent = the latest checkpoint.
1041
+ * @maxLength 40
1042
+ */
1043
+ checkpoint?: string;
1044
+ /**
1045
+ * The pattern to look for (a regular expression unless `fixed`).
1046
+ * @maxLength 200
1047
+ */
1048
+ pattern: string;
1049
+ /** Treat `pattern` as a literal string. */
1050
+ fixed?: boolean;
1051
+ /** Lines of context around each match, 0-10. */
1052
+ context?: number;
1053
+ /**
1054
+ * Only search files whose path starts with this prefix.
1055
+ * @maxLength 500
1056
+ */
1057
+ pathPrefix?: string;
1058
+ }
1059
+ interface SearchImportSourceForSiteResponse {
1060
+ /**
1061
+ * Id of the import resolved for the caller's site.
1062
+ * @format GUID
1063
+ */
1064
+ importId?: string;
1065
+ /**
1066
+ * The checkpoint that was searched.
1067
+ * @maxLength 40
1068
+ */
1069
+ checkpoint?: string;
1070
+ /**
1071
+ * Matching lines (and their context), in path order.
1072
+ * @maxSize 5000
1073
+ */
1074
+ matches?: SearchMatch[];
1075
+ /** True if the scan stopped before covering every file. */
1076
+ truncated?: boolean;
1077
+ /**
1078
+ * Why: MAX_FILES, MAX_BYTES, MAX_MATCHES, RESPONSE_SIZE, TIME, LINE_CLIPPED (a
1079
+ * line over 64 KiB was cut) or STORED_PREFIX_ONLY (a file over 25 MB is stored
1080
+ * only in part). Unknown values should be treated as "partial result".
1081
+ * @maxLength 32
1082
+ */
1083
+ truncatedReason?: string;
1084
+ /**
1085
+ * The last path fully scanned, so a capped search can continue.
1086
+ * @maxLength 500
1087
+ */
1088
+ lastPathScanned?: string;
857
1089
  }
858
1090
  interface GetImportBySiteRequest {
859
1091
  /**
@@ -1113,12 +1345,11 @@ interface GetImportSourceOptions {
1113
1345
  * @documentationMaturity preview
1114
1346
  * @requiredField checkpoint
1115
1347
  * @requiredField importId
1116
- * @requiredField options
1117
1348
  * @requiredField options.filePath
1118
1349
  * @permissionId ecom:site_import:v1:import:get_import_source_file
1119
1350
  * @fqn wix.ecom.site_import.v1.SiteImportService.GetImportSourceFile
1120
1351
  */
1121
- declare function getImportSourceFile(importId: string, checkpoint: string, options: NonNullablePaths<GetImportSourceFileOptions, `filePath`, 0>): Promise<NonNullablePaths<GetImportSourceFileResponse, `importId` | `checkpoint` | `path` | `content` | `truncated`, 0>>;
1352
+ declare function getImportSourceFile(importId: string, checkpoint: string, options?: NonNullablePaths<GetImportSourceFileOptions, `filePath`, 0>): Promise<NonNullablePaths<GetImportSourceFileResponse, `importId` | `checkpoint` | `path` | `content` | `truncated` | `firstLine` | `matches` | `matches.${number}.line` | `matches.${number}.text` | `matches.${number}.contextLine` | `truncatedReason`, 2>>;
1122
1353
  interface GetImportSourceFileOptions {
1123
1354
  /**
1124
1355
  * Path relative to the migration root, as named in a `SourceFile`/
@@ -1126,6 +1357,31 @@ interface GetImportSourceFileOptions {
1126
1357
  * @maxLength 500
1127
1358
  */
1128
1359
  filePath: string;
1360
+ /**
1361
+ * QUERY OPTIONS (spec 0027) — at most one of `tail`, `head`, `lines`, `grep`.
1362
+ * Served from the S3 snapshot only (never a clone): a checkpoint with no
1363
+ * snapshot answers FAILED_PRECONDITION, an account outside the rollout
1364
+ * UNIMPLEMENTED. When none is set the call is the plain bounded preview.
1365
+ *
1366
+ * Return only the last N lines of the file (N ≤ 200).
1367
+ */
1368
+ tail?: number;
1369
+ /** Return only the first N lines of the file (N ≤ 200). */
1370
+ head?: number;
1371
+ /**
1372
+ * Return a line range such as "10-60" (at most 200 lines).
1373
+ * @maxLength 20
1374
+ */
1375
+ lines?: string;
1376
+ /**
1377
+ * Return the lines matching this pattern (with `context` lines around each).
1378
+ * @maxLength 200
1379
+ */
1380
+ grep?: string;
1381
+ /** Lines of context around each `grep` match, 0-10. */
1382
+ context?: number;
1383
+ /** Treat `grep` as a literal string instead of a regular expression. */
1384
+ fixed?: boolean;
1129
1385
  }
1130
1386
  /**
1131
1387
  * Same manifest/delta contract as GetImportSource, but scoped to the
@@ -1202,7 +1458,6 @@ interface GetImportSourceForSiteOptions {
1202
1458
  * @public
1203
1459
  * @documentationMaturity preview
1204
1460
  * @requiredField checkpoint
1205
- * @requiredField options
1206
1461
  * @requiredField options.filePath
1207
1462
  * @requiredField options.importId
1208
1463
  * @permissionId ecom:site_import:v1:import:get_import_source_file_for_site
@@ -1211,7 +1466,7 @@ interface GetImportSourceForSiteOptions {
1211
1466
  * one rpc name.
1212
1467
  * @fqn wix.ecom.site_import.v1.SiteImportService.GetImportSourceFileForSite
1213
1468
  */
1214
- declare function getImportSourceFileForSite(checkpoint: string, options: NonNullablePaths<GetImportSourceFileForSiteOptions, `filePath` | `importId`, 0>): Promise<NonNullablePaths<GetImportSourceFileForSiteResponse, `importId` | `checkpoint` | `path` | `content` | `truncated`, 0>>;
1469
+ declare function getImportSourceFileForSite(checkpoint: string, options?: NonNullablePaths<GetImportSourceFileForSiteOptions, `filePath` | `importId`, 0>): Promise<NonNullablePaths<GetImportSourceFileForSiteResponse, `importId` | `checkpoint` | `path` | `content` | `truncated` | `firstLine` | `matches` | `matches.${number}.line` | `matches.${number}.text` | `matches.${number}.contextLine` | `truncatedReason`, 2>>;
1215
1470
  interface GetImportSourceFileForSiteOptions {
1216
1471
  /**
1217
1472
  * Path relative to the migration root, as named in a `SourceFile`/
@@ -1232,6 +1487,109 @@ interface GetImportSourceFileForSiteOptions {
1232
1487
  * @format GUID
1233
1488
  */
1234
1489
  importId: string;
1490
+ /**
1491
+ * QUERY OPTIONS (spec 0027) — at most one of `tail`, `head`, `lines`, `grep`.
1492
+ * Served from the S3 snapshot only (never a clone): a checkpoint with no
1493
+ * snapshot answers FAILED_PRECONDITION, an account outside the rollout
1494
+ * UNIMPLEMENTED. When none is set the call is the plain bounded preview.
1495
+ *
1496
+ * Return only the last N lines of the file (N ≤ 200).
1497
+ */
1498
+ tail?: number;
1499
+ /** Return only the first N lines of the file (N ≤ 200). */
1500
+ head?: number;
1501
+ /**
1502
+ * Return a line range such as "10-60" (at most 200 lines).
1503
+ * @maxLength 20
1504
+ */
1505
+ lines?: string;
1506
+ /**
1507
+ * Return the lines matching this pattern (with `context` lines around each).
1508
+ * @maxLength 200
1509
+ */
1510
+ grep?: string;
1511
+ /** Lines of context around each `grep` match, 0-10. */
1512
+ context?: number;
1513
+ /** Treat `grep` as a literal string instead of a regular expression. */
1514
+ fixed?: boolean;
1515
+ }
1516
+ /**
1517
+ * Search the migration's source for a pattern WITHOUT downloading it (spec
1518
+ * 0027): the service streams each file from S3, matches, and returns only
1519
+ * the matching lines (with optional context). Works only on checkpoints
1520
+ * that have a snapshot and only for accounts the snapshot-read rollout
1521
+ * covers; otherwise FAILED_PRECONDITION / UNIMPLEMENTED. Bounded — a
1522
+ * `truncated_reason` says which cap (files, bytes, time, matches, response
1523
+ * size) ended the scan and `last_path_scanned` lets the caller continue with
1524
+ * a narrower `path_prefix`.
1525
+ * @param importId - Id of the import whose source to search.
1526
+ * @public
1527
+ * @documentationMaturity preview
1528
+ * @requiredField importId
1529
+ * @requiredField options.pattern
1530
+ * @permissionId ecom:site_import:v1:import:search_import_source
1531
+ * @fqn wix.ecom.site_import.v1.SiteImportService.SearchImportSource
1532
+ */
1533
+ declare function searchImportSource(importId: string, options?: NonNullablePaths<SearchImportSourceOptions, `pattern`, 0>): Promise<NonNullablePaths<SearchImportSourceResponse, `importId` | `checkpoint` | `matches` | `matches.${number}.path` | `matches.${number}.line` | `matches.${number}.text` | `matches.${number}.contextLine` | `truncated` | `truncatedReason` | `lastPathScanned`, 2>>;
1534
+ interface SearchImportSourceOptions {
1535
+ /**
1536
+ * Checkpoint to search AS OF — a prior GetImportSource response's
1537
+ * `checkpoint`. Absent = the latest checkpoint.
1538
+ * @maxLength 40
1539
+ */
1540
+ checkpoint?: string;
1541
+ /**
1542
+ * The pattern to look for (a regular expression unless `fixed`).
1543
+ * @maxLength 200
1544
+ */
1545
+ pattern: string;
1546
+ /** Treat `pattern` as a literal string. */
1547
+ fixed?: boolean;
1548
+ /** Lines of context around each match, 0-10. */
1549
+ context?: number;
1550
+ /**
1551
+ * Only search files whose path starts with this prefix.
1552
+ * @maxLength 500
1553
+ */
1554
+ pathPrefix?: string;
1555
+ }
1556
+ /**
1557
+ * SITE-tenancy counterpart to SearchImportSource: the import is resolved
1558
+ * from the caller's destination site (optionally pinned with `import_id`),
1559
+ * exactly like GetImportSourceForSite.
1560
+ * @public
1561
+ * @documentationMaturity preview
1562
+ * @requiredField options.pattern
1563
+ * @permissionId ecom:site_import:v1:import:search_import_source_for_site
1564
+ * @fqn wix.ecom.site_import.v1.SiteImportService.SearchImportSourceForSite
1565
+ */
1566
+ declare function searchImportSourceForSite(options?: NonNullablePaths<SearchImportSourceForSiteOptions, `pattern`, 0>): Promise<NonNullablePaths<SearchImportSourceForSiteResponse, `importId` | `checkpoint` | `matches` | `matches.${number}.path` | `matches.${number}.line` | `matches.${number}.text` | `matches.${number}.contextLine` | `truncated` | `truncatedReason` | `lastPathScanned`, 2>>;
1567
+ interface SearchImportSourceForSiteOptions {
1568
+ /**
1569
+ * OPTIONAL. Pins the search to the import a prior GetImportSourceForSite
1570
+ * response resolved; the server re-verifies it belongs to the caller's site.
1571
+ * @format GUID
1572
+ */
1573
+ importId?: string;
1574
+ /**
1575
+ * Checkpoint to search AS OF. Absent = the latest checkpoint.
1576
+ * @maxLength 40
1577
+ */
1578
+ checkpoint?: string;
1579
+ /**
1580
+ * The pattern to look for (a regular expression unless `fixed`).
1581
+ * @maxLength 200
1582
+ */
1583
+ pattern: string;
1584
+ /** Treat `pattern` as a literal string. */
1585
+ fixed?: boolean;
1586
+ /** Lines of context around each match, 0-10. */
1587
+ context?: number;
1588
+ /**
1589
+ * Only search files whose path starts with this prefix.
1590
+ * @maxLength 500
1591
+ */
1592
+ pathPrefix?: string;
1235
1593
  }
1236
1594
  /**
1237
1595
  * Recovers the `import_id` for the site/fileset this call is scoped to, when
@@ -1279,4 +1637,4 @@ interface GetImportBySiteOptions {
1279
1637
  fileUrls?: string[];
1280
1638
  }
1281
1639
 
1282
- export { type CancelImportRequest, type CancelImportResponse, type ClaudeResultSummary, type FailedTaskDetail, type GetImportBySiteOptions, type GetImportBySiteRequest, type GetImportBySiteResponse, type GetImportDebugRequest, type GetImportDebugResponse, type GetImportSourceFileForSiteOptions, type GetImportSourceFileForSiteRequest, type GetImportSourceFileForSiteResponse, type GetImportSourceFileOptions, type GetImportSourceFileRequest, type GetImportSourceFileResponse, type GetImportSourceForSiteOptions, type GetImportSourceForSiteRequest, type GetImportSourceForSiteResponse, type GetImportSourceOptions, type GetImportSourceRequest, type GetImportSourceResponse, type GetImportStatusOptions, type GetImportStatusRequest, type GetImportStatusResponse, type Import, type ImportActivity, ImportActivityKind, type ImportActivityKindWithLiterals, type ImportArtifact, ImportArtifactFormat, type ImportArtifactFormatWithLiterals, ImportStatus, type ImportStatusWithLiterals, type ImportTodo, ImportTodoStatus, type ImportTodoStatusWithLiterals, type SendImportMessageRequest, type SendImportMessageResponse, type SourceChange, SourceChangeStatus, type SourceChangeStatusWithLiterals, SourceConfidence, type SourceConfidenceWithLiterals, type SourceFile, SourcePlatform, type SourcePlatformWithLiterals, SourceSyncMode, type SourceSyncModeWithLiterals, type StartFrontendPreviewRequest, type StartFrontendPreviewResponse, type StartImportOptions, type StartImportRequest, type StartImportResponse, type TaskDebug, cancelImport, getImportBySite, getImportDebug, getImportSource, getImportSourceFile, getImportSourceFileForSite, getImportSourceForSite, getImportStatus, sendImportMessage, startFrontendPreview, startImport };
1640
+ export { type CancelImportRequest, type CancelImportResponse, type ClaudeResultSummary, type FailedTaskDetail, type GetImportBySiteOptions, type GetImportBySiteRequest, type GetImportBySiteResponse, type GetImportDebugRequest, type GetImportDebugResponse, type GetImportSourceFileForSiteOptions, type GetImportSourceFileForSiteRequest, type GetImportSourceFileForSiteResponse, type GetImportSourceFileOptions, type GetImportSourceFileRequest, type GetImportSourceFileResponse, type GetImportSourceForSiteOptions, type GetImportSourceForSiteRequest, type GetImportSourceForSiteResponse, type GetImportSourceOptions, type GetImportSourceRequest, type GetImportSourceResponse, type GetImportStatusOptions, type GetImportStatusRequest, type GetImportStatusResponse, type Import, type ImportActivity, ImportActivityKind, type ImportActivityKindWithLiterals, type ImportArtifact, ImportArtifactFormat, type ImportArtifactFormatWithLiterals, ImportStatus, type ImportStatusWithLiterals, type ImportTodo, ImportTodoStatus, type ImportTodoStatusWithLiterals, type SearchImportSourceForSiteOptions, type SearchImportSourceForSiteRequest, type SearchImportSourceForSiteResponse, type SearchImportSourceOptions, type SearchImportSourceRequest, type SearchImportSourceResponse, type SearchMatch, type SendImportMessageRequest, type SendImportMessageResponse, type SourceChange, SourceChangeStatus, type SourceChangeStatusWithLiterals, SourceConfidence, type SourceConfidenceWithLiterals, type SourceFile, type SourceMatch, SourcePlatform, type SourcePlatformWithLiterals, SourceSyncMode, type SourceSyncModeWithLiterals, type StartFrontendPreviewRequest, type StartFrontendPreviewResponse, type StartImportOptions, type StartImportRequest, type StartImportResponse, type TaskDebug, cancelImport, getImportBySite, getImportDebug, getImportSource, getImportSourceFile, getImportSourceFileForSite, getImportSourceForSite, getImportStatus, searchImportSource, searchImportSourceForSite, sendImportMessage, startFrontendPreview, startImport };
@@ -36,6 +36,8 @@ __export(index_typings_exports, {
36
36
  getImportSourceFileForSite: () => getImportSourceFileForSite2,
37
37
  getImportSourceForSite: () => getImportSourceForSite2,
38
38
  getImportStatus: () => getImportStatus2,
39
+ searchImportSource: () => searchImportSource2,
40
+ searchImportSourceForSite: () => searchImportSourceForSite2,
39
41
  sendImportMessage: () => sendImportMessage2,
40
42
  startFrontendPreview: () => startFrontendPreview2,
41
43
  startImport: () => startImport2
@@ -312,6 +314,48 @@ function getImportSourceFileForSite(payload) {
312
314
  }
313
315
  return __getImportSourceFileForSite;
314
316
  }
317
+ function searchImportSource(payload) {
318
+ function __searchImportSource({ host }) {
319
+ const metadata = {
320
+ entityFqdn: "wix.ecom.site_import.v1.import",
321
+ method: "GET",
322
+ methodFqn: "wix.ecom.site_import.v1.SiteImportService.SearchImportSource",
323
+ packageName: PACKAGE_NAME,
324
+ migrationOptions: {
325
+ optInTransformResponse: true
326
+ },
327
+ url: resolveWixEcomSiteImportV1SiteImportServiceUrl({
328
+ protoPath: "/v1/imports/{importId}/source/search",
329
+ data: payload,
330
+ host
331
+ }),
332
+ params: (0, import_rest_modules.toURLSearchParams)(payload)
333
+ };
334
+ return metadata;
335
+ }
336
+ return __searchImportSource;
337
+ }
338
+ function searchImportSourceForSite(payload) {
339
+ function __searchImportSourceForSite({ host }) {
340
+ const metadata = {
341
+ entityFqdn: "wix.ecom.site_import.v1.import",
342
+ method: "GET",
343
+ methodFqn: "wix.ecom.site_import.v1.SiteImportService.SearchImportSourceForSite",
344
+ packageName: PACKAGE_NAME,
345
+ migrationOptions: {
346
+ optInTransformResponse: true
347
+ },
348
+ url: resolveWixEcomSiteImportV1SiteImportServiceUrl({
349
+ protoPath: "/v1/site-imports/source/search",
350
+ data: payload,
351
+ host
352
+ }),
353
+ params: (0, import_rest_modules.toURLSearchParams)(payload)
354
+ };
355
+ return metadata;
356
+ }
357
+ return __searchImportSourceForSite;
358
+ }
315
359
  function getImportBySite(payload) {
316
360
  function __getImportBySite({ host }) {
317
361
  const metadata = {
@@ -589,7 +633,13 @@ async function getImportSourceFile2(importId, checkpoint, options) {
589
633
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
590
634
  importId,
591
635
  checkpoint,
592
- filePath: options?.filePath
636
+ filePath: options?.filePath,
637
+ tail: options?.tail,
638
+ head: options?.head,
639
+ lines: options?.lines,
640
+ grep: options?.grep,
641
+ context: options?.context,
642
+ fixed: options?.fixed
593
643
  });
594
644
  const reqOpts = getImportSourceFile(payload);
595
645
  sideEffects?.onSiteCall?.();
@@ -605,7 +655,13 @@ async function getImportSourceFile2(importId, checkpoint, options) {
605
655
  explicitPathsToArguments: {
606
656
  importId: "$[0]",
607
657
  checkpoint: "$[1]",
608
- filePath: "$[2].filePath"
658
+ filePath: "$[2].filePath",
659
+ tail: "$[2].tail",
660
+ head: "$[2].head",
661
+ lines: "$[2].lines",
662
+ grep: "$[2].grep",
663
+ context: "$[2].context",
664
+ fixed: "$[2].fixed"
609
665
  },
610
666
  singleArgumentUnchanged: false
611
667
  },
@@ -651,7 +707,13 @@ async function getImportSourceFileForSite2(checkpoint, options) {
651
707
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
652
708
  checkpoint,
653
709
  filePath: options?.filePath,
654
- importId: options?.importId
710
+ importId: options?.importId,
711
+ tail: options?.tail,
712
+ head: options?.head,
713
+ lines: options?.lines,
714
+ grep: options?.grep,
715
+ context: options?.context,
716
+ fixed: options?.fixed
655
717
  });
656
718
  const reqOpts = getImportSourceFileForSite(payload);
657
719
  sideEffects?.onSiteCall?.();
@@ -667,7 +729,13 @@ async function getImportSourceFileForSite2(checkpoint, options) {
667
729
  explicitPathsToArguments: {
668
730
  checkpoint: "$[0]",
669
731
  filePath: "$[1].filePath",
670
- importId: "$[1].importId"
732
+ importId: "$[1].importId",
733
+ tail: "$[1].tail",
734
+ head: "$[1].head",
735
+ lines: "$[1].lines",
736
+ grep: "$[1].grep",
737
+ context: "$[1].context",
738
+ fixed: "$[1].fixed"
671
739
  },
672
740
  singleArgumentUnchanged: false
673
741
  },
@@ -677,6 +745,80 @@ async function getImportSourceFileForSite2(checkpoint, options) {
677
745
  throw transformedError;
678
746
  }
679
747
  }
748
+ async function searchImportSource2(importId, options) {
749
+ const { httpClient, sideEffects } = arguments[2];
750
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
751
+ importId,
752
+ checkpoint: options?.checkpoint,
753
+ pattern: options?.pattern,
754
+ fixed: options?.fixed,
755
+ context: options?.context,
756
+ pathPrefix: options?.pathPrefix
757
+ });
758
+ const reqOpts = searchImportSource(payload);
759
+ sideEffects?.onSiteCall?.();
760
+ try {
761
+ const result = await httpClient.request(reqOpts);
762
+ sideEffects?.onSuccess?.(result);
763
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
764
+ } catch (err) {
765
+ const transformedError = (0, import_transform_error.transformError)(
766
+ err,
767
+ {
768
+ spreadPathsToArguments: {},
769
+ explicitPathsToArguments: {
770
+ importId: "$[0]",
771
+ checkpoint: "$[1].checkpoint",
772
+ pattern: "$[1].pattern",
773
+ fixed: "$[1].fixed",
774
+ context: "$[1].context",
775
+ pathPrefix: "$[1].pathPrefix"
776
+ },
777
+ singleArgumentUnchanged: false
778
+ },
779
+ ["importId", "options"]
780
+ );
781
+ sideEffects?.onError?.(err);
782
+ throw transformedError;
783
+ }
784
+ }
785
+ async function searchImportSourceForSite2(options) {
786
+ const { httpClient, sideEffects } = arguments[1];
787
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
788
+ importId: options?.importId,
789
+ checkpoint: options?.checkpoint,
790
+ pattern: options?.pattern,
791
+ fixed: options?.fixed,
792
+ context: options?.context,
793
+ pathPrefix: options?.pathPrefix
794
+ });
795
+ const reqOpts = searchImportSourceForSite(payload);
796
+ sideEffects?.onSiteCall?.();
797
+ try {
798
+ const result = await httpClient.request(reqOpts);
799
+ sideEffects?.onSuccess?.(result);
800
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
801
+ } catch (err) {
802
+ const transformedError = (0, import_transform_error.transformError)(
803
+ err,
804
+ {
805
+ spreadPathsToArguments: {},
806
+ explicitPathsToArguments: {
807
+ importId: "$[0].importId",
808
+ checkpoint: "$[0].checkpoint",
809
+ pattern: "$[0].pattern",
810
+ fixed: "$[0].fixed",
811
+ context: "$[0].context",
812
+ pathPrefix: "$[0].pathPrefix"
813
+ },
814
+ singleArgumentUnchanged: false
815
+ },
816
+ ["options"]
817
+ );
818
+ sideEffects?.onError?.(err);
819
+ throw transformedError;
820
+ }
821
+ }
680
822
  async function getImportBySite2(options) {
681
823
  const { httpClient, sideEffects } = arguments[1];
682
824
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
@@ -724,6 +866,8 @@ async function getImportBySite2(options) {
724
866
  getImportSourceFileForSite,
725
867
  getImportSourceForSite,
726
868
  getImportStatus,
869
+ searchImportSource,
870
+ searchImportSourceForSite,
727
871
  sendImportMessage,
728
872
  startFrontendPreview,
729
873
  startImport