@strapi/data-transfer 4.14.0-beta.0 → 4.14.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 (92) hide show
  1. package/dist/commands/commander.d.ts +35 -0
  2. package/dist/commands/commander.js +138 -0
  3. package/dist/commands/commander.js.map +1 -0
  4. package/dist/commands/data-transfer.d.ts +135 -0
  5. package/dist/commands/data-transfer.js +359 -0
  6. package/dist/commands/data-transfer.js.map +1 -0
  7. package/dist/commands/export/action.d.ts +20 -0
  8. package/dist/commands/export/action.js +156 -0
  9. package/dist/commands/export/action.js.map +1 -0
  10. package/dist/commands/export/command.d.ts +8 -0
  11. package/dist/commands/export/command.js +30 -0
  12. package/dist/commands/export/command.js.map +1 -0
  13. package/dist/commands/helpers.d.ts +30 -0
  14. package/dist/commands/helpers.js +87 -0
  15. package/dist/commands/helpers.js.map +1 -0
  16. package/dist/commands/import/action.d.ts +19 -0
  17. package/dist/commands/import/action.js +139 -0
  18. package/dist/commands/import/action.js.map +1 -0
  19. package/dist/commands/import/command.d.ts +8 -0
  20. package/dist/commands/import/command.js +75 -0
  21. package/dist/commands/import/command.js.map +1 -0
  22. package/dist/commands/index.d.ts +3 -0
  23. package/dist/commands/index.js +13 -0
  24. package/dist/commands/index.js.map +1 -0
  25. package/dist/commands/transfer/action.d.ts +18 -0
  26. package/dist/commands/transfer/action.js +161 -0
  27. package/dist/commands/transfer/action.js.map +1 -0
  28. package/dist/commands/transfer/command.d.ts +8 -0
  29. package/dist/commands/transfer/command.js +69 -0
  30. package/dist/commands/transfer/command.js.map +1 -0
  31. package/dist/engine/index.d.ts +2 -1
  32. package/dist/engine/index.js +330 -297
  33. package/dist/engine/index.js.map +1 -1
  34. package/dist/engine/validation/schemas/index.js.map +1 -1
  35. package/dist/errors/base.js +3 -0
  36. package/dist/errors/base.js.map +1 -1
  37. package/dist/file/providers/destination/index.js +51 -55
  38. package/dist/file/providers/destination/index.js.map +1 -1
  39. package/dist/file/providers/source/index.d.ts +1 -1
  40. package/dist/file/providers/source/index.js +111 -119
  41. package/dist/file/providers/source/index.js.map +1 -1
  42. package/dist/index.d.ts +1 -0
  43. package/dist/index.js +2 -1
  44. package/dist/index.js.map +1 -1
  45. package/dist/strapi/providers/local-destination/index.d.ts +4 -3
  46. package/dist/strapi/providers/local-destination/index.js +120 -125
  47. package/dist/strapi/providers/local-destination/index.js.map +1 -1
  48. package/dist/strapi/providers/local-destination/strategies/restore/configuration.d.ts +3 -2
  49. package/dist/strapi/providers/local-destination/strategies/restore/configuration.js.map +1 -1
  50. package/dist/strapi/providers/local-destination/strategies/restore/entities.d.ts +2 -2
  51. package/dist/strapi/providers/local-destination/strategies/restore/entities.js +5 -2
  52. package/dist/strapi/providers/local-destination/strategies/restore/entities.js.map +1 -1
  53. package/dist/strapi/providers/local-destination/strategies/restore/index.d.ts +2 -2
  54. package/dist/strapi/providers/local-destination/strategies/restore/index.js.map +1 -1
  55. package/dist/strapi/providers/local-destination/strategies/restore/links.d.ts +2 -1
  56. package/dist/strapi/providers/local-destination/strategies/restore/links.js.map +1 -1
  57. package/dist/strapi/providers/local-source/assets.d.ts +2 -1
  58. package/dist/strapi/providers/local-source/assets.js +1 -1
  59. package/dist/strapi/providers/local-source/assets.js.map +1 -1
  60. package/dist/strapi/providers/local-source/configuration.d.ts +2 -1
  61. package/dist/strapi/providers/local-source/configuration.js.map +1 -1
  62. package/dist/strapi/providers/local-source/entities.d.ts +2 -1
  63. package/dist/strapi/providers/local-source/entities.js.map +1 -1
  64. package/dist/strapi/providers/local-source/index.d.ts +4 -3
  65. package/dist/strapi/providers/local-source/index.js +5 -3
  66. package/dist/strapi/providers/local-source/index.js.map +1 -1
  67. package/dist/strapi/providers/local-source/links.d.ts +2 -1
  68. package/dist/strapi/providers/local-source/links.js.map +1 -1
  69. package/dist/strapi/providers/remote-destination/index.d.ts +1 -1
  70. package/dist/strapi/providers/remote-destination/index.js +95 -94
  71. package/dist/strapi/providers/remote-destination/index.js.map +1 -1
  72. package/dist/strapi/providers/remote-source/index.d.ts +1 -1
  73. package/dist/strapi/providers/remote-source/index.js +93 -93
  74. package/dist/strapi/providers/remote-source/index.js.map +1 -1
  75. package/dist/strapi/providers/utils.d.ts +2 -2
  76. package/dist/strapi/queries/entity.d.ts +2 -1
  77. package/dist/strapi/queries/entity.js +4 -4
  78. package/dist/strapi/queries/entity.js.map +1 -1
  79. package/dist/strapi/queries/link.d.ts +2 -1
  80. package/dist/strapi/queries/link.js +13 -4
  81. package/dist/strapi/queries/link.js.map +1 -1
  82. package/dist/strapi/remote/handlers/pull.js.map +1 -1
  83. package/dist/strapi/remote/handlers/push.js.map +1 -1
  84. package/dist/utils/components.d.ts +22 -0
  85. package/dist/utils/components.js +381 -0
  86. package/dist/utils/components.js.map +1 -0
  87. package/dist/utils/providers.d.ts +2 -1
  88. package/dist/utils/providers.js.map +1 -1
  89. package/dist/utils/schema.d.ts +1 -1
  90. package/dist/utils/transaction.d.ts +2 -2
  91. package/dist/utils/transaction.js.map +1 -1
  92. package/package.json +16 -9
@@ -1,19 +1,7 @@
1
1
  "use strict";
2
- var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
3
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
4
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
5
- return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
6
- };
7
- var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
8
- if (kind === "m") throw new TypeError("Private method is not writable");
9
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
10
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
11
- return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
12
- };
13
2
  var __importDefault = (this && this.__importDefault) || function (mod) {
14
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
15
4
  };
16
- var _LocalFileSourceProvider_instances, _LocalFileSourceProvider_metadata, _LocalFileSourceProvider_loadMetadata, _LocalFileSourceProvider_loadAssetMetadata, _LocalFileSourceProvider_getBackupStream, _LocalFileSourceProvider_streamJsonlDirectory, _LocalFileSourceProvider_parseJSONFile;
17
5
  Object.defineProperty(exports, "__esModule", { value: true });
18
6
  exports.createLocalFileSourceProvider = void 0;
19
7
  const zlib_1 = __importDefault(require("zlib"));
@@ -37,11 +25,11 @@ const createLocalFileSourceProvider = (options) => {
37
25
  };
38
26
  exports.createLocalFileSourceProvider = createLocalFileSourceProvider;
39
27
  class LocalFileSourceProvider {
28
+ type = 'source';
29
+ name = 'source::local-file';
30
+ options;
31
+ #metadata;
40
32
  constructor(options) {
41
- _LocalFileSourceProvider_instances.add(this);
42
- this.type = 'source';
43
- this.name = 'source::local-file';
44
- _LocalFileSourceProvider_metadata.set(this, void 0);
45
33
  this.options = options;
46
34
  const { encryption } = this.options;
47
35
  if (encryption.enabled && encryption.key === undefined) {
@@ -55,7 +43,7 @@ class LocalFileSourceProvider {
55
43
  const { path: filePath } = this.options.file;
56
44
  try {
57
45
  // Read the metadata to ensure the file can be parsed
58
- await __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_loadMetadata).call(this);
46
+ await this.#loadMetadata();
59
47
  // TODO: we might also need to read the schema.jsonl files & implements a custom stream-check
60
48
  }
61
49
  catch (e) {
@@ -64,15 +52,23 @@ class LocalFileSourceProvider {
64
52
  }
65
53
  throw new providers_1.ProviderInitializationError(`File '${filePath}' is not a valid Strapi data file.`);
66
54
  }
67
- if (!__classPrivateFieldGet(this, _LocalFileSourceProvider_metadata, "f")) {
55
+ if (!this.#metadata) {
68
56
  throw new providers_1.ProviderInitializationError('Could not load metadata from Strapi data file.');
69
57
  }
70
58
  }
59
+ async #loadMetadata() {
60
+ const backupStream = this.#getBackupStream();
61
+ this.#metadata = await this.#parseJSONFile(backupStream, METADATA_FILE_PATH);
62
+ }
63
+ async #loadAssetMetadata(path) {
64
+ const backupStream = this.#getBackupStream();
65
+ return this.#parseJSONFile(backupStream, path);
66
+ }
71
67
  async getMetadata() {
72
- if (!__classPrivateFieldGet(this, _LocalFileSourceProvider_metadata, "f")) {
73
- await __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_loadMetadata).call(this);
68
+ if (!this.#metadata) {
69
+ await this.#loadMetadata();
74
70
  }
75
- return __classPrivateFieldGet(this, _LocalFileSourceProvider_metadata, "f") ?? null;
71
+ return this.#metadata ?? null;
76
72
  }
77
73
  async getSchemas() {
78
74
  const schemas = await (0, stream_2.collect)(this.createSchemasReadStream());
@@ -82,22 +78,22 @@ class LocalFileSourceProvider {
82
78
  return (0, fp_1.keyBy)('uid', schemas);
83
79
  }
84
80
  createEntitiesReadStream() {
85
- return __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_streamJsonlDirectory).call(this, 'entities');
81
+ return this.#streamJsonlDirectory('entities');
86
82
  }
87
83
  createSchemasReadStream() {
88
- return __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_streamJsonlDirectory).call(this, 'schemas');
84
+ return this.#streamJsonlDirectory('schemas');
89
85
  }
90
86
  createLinksReadStream() {
91
- return __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_streamJsonlDirectory).call(this, 'links');
87
+ return this.#streamJsonlDirectory('links');
92
88
  }
93
89
  createConfigurationReadStream() {
94
90
  // NOTE: TBD
95
- return __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_streamJsonlDirectory).call(this, 'configuration');
91
+ return this.#streamJsonlDirectory('configuration');
96
92
  }
97
93
  createAssetsReadStream() {
98
- const inStream = __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_getBackupStream).call(this);
94
+ const inStream = this.#getBackupStream();
99
95
  const outStream = new stream_1.PassThrough({ objectMode: true });
100
- const loadAssetMetadata = __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_loadAssetMetadata).bind(this);
96
+ const loadAssetMetadata = this.#loadAssetMetadata.bind(this);
101
97
  (0, stream_1.pipeline)([
102
98
  inStream,
103
99
  new tar_1.default.Parse({
@@ -132,111 +128,107 @@ class LocalFileSourceProvider {
132
128
  ], () => outStream.end());
133
129
  return outStream;
134
130
  }
135
- }
136
- _LocalFileSourceProvider_metadata = new WeakMap(), _LocalFileSourceProvider_instances = new WeakSet(), _LocalFileSourceProvider_loadMetadata = async function _LocalFileSourceProvider_loadMetadata() {
137
- const backupStream = __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_getBackupStream).call(this);
138
- __classPrivateFieldSet(this, _LocalFileSourceProvider_metadata, await __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_parseJSONFile).call(this, backupStream, METADATA_FILE_PATH), "f");
139
- }, _LocalFileSourceProvider_loadAssetMetadata = async function _LocalFileSourceProvider_loadAssetMetadata(path) {
140
- const backupStream = __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_getBackupStream).call(this);
141
- return __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_parseJSONFile).call(this, backupStream, path);
142
- }, _LocalFileSourceProvider_getBackupStream = function _LocalFileSourceProvider_getBackupStream() {
143
- const { file, encryption, compression } = this.options;
144
- const streams = [];
145
- try {
146
- streams.push(fs_extra_1.default.createReadStream(file.path));
147
- }
148
- catch (e) {
149
- throw new Error(`Could not read backup file path provided at "${this.options.file.path}"`);
150
- }
151
- if (encryption.enabled && encryption.key) {
152
- streams.push((0, encryption_1.createDecryptionCipher)(encryption.key));
153
- }
154
- if (compression.enabled) {
155
- streams.push(zlib_1.default.createGunzip());
131
+ #getBackupStream() {
132
+ const { file, encryption, compression } = this.options;
133
+ const streams = [];
134
+ try {
135
+ streams.push(fs_extra_1.default.createReadStream(file.path));
136
+ }
137
+ catch (e) {
138
+ throw new Error(`Could not read backup file path provided at "${this.options.file.path}"`);
139
+ }
140
+ if (encryption.enabled && encryption.key) {
141
+ streams.push((0, encryption_1.createDecryptionCipher)(encryption.key));
142
+ }
143
+ if (compression.enabled) {
144
+ streams.push(zlib_1.default.createGunzip());
145
+ }
146
+ return (0, stream_chain_1.chain)(streams);
156
147
  }
157
- return (0, stream_chain_1.chain)(streams);
158
- }, _LocalFileSourceProvider_streamJsonlDirectory = function _LocalFileSourceProvider_streamJsonlDirectory(directory) {
159
- const inStream = __classPrivateFieldGet(this, _LocalFileSourceProvider_instances, "m", _LocalFileSourceProvider_getBackupStream).call(this);
160
- const outStream = new stream_1.PassThrough({ objectMode: true });
161
- (0, stream_1.pipeline)([
162
- inStream,
163
- new tar_1.default.Parse({
164
- filter(filePath, entry) {
165
- if (entry.type !== 'File') {
166
- return false;
167
- }
168
- return (0, utils_1.isFilePathInDirname)(directory, filePath);
169
- },
170
- async onentry(entry) {
171
- const transforms = [
172
- // JSONL parser to read the data chunks one by one (line by line)
173
- (0, Parser_1.parser)({
174
- checkErrors: true,
175
- }),
176
- // The JSONL parser returns each line as key/value
177
- (line) => line.value,
178
- ];
179
- const stream = entry.pipe((0, stream_chain_1.chain)(transforms));
180
- try {
181
- for await (const chunk of stream) {
182
- outStream.write(chunk);
183
- }
184
- }
185
- catch (e) {
186
- outStream.destroy(new providers_1.ProviderTransferError(`Error parsing backup files from backup file ${entry.path}: ${e.message}`, {
187
- details: {
188
- error: e,
189
- },
190
- }));
191
- }
192
- },
193
- }),
194
- ], async () => {
195
- // Manually send the 'end' event to the out stream
196
- // once every entry has finished streaming its content
197
- outStream.end();
198
- });
199
- return outStream;
200
- }, _LocalFileSourceProvider_parseJSONFile =
201
- // For collecting an entire JSON file then parsing it, not for streaming JSONL
202
- async function _LocalFileSourceProvider_parseJSONFile(fileStream, filePath) {
203
- return new Promise((resolve, reject) => {
148
+ // `directory` must be posix formatted path
149
+ #streamJsonlDirectory(directory) {
150
+ const inStream = this.#getBackupStream();
151
+ const outStream = new stream_1.PassThrough({ objectMode: true });
204
152
  (0, stream_1.pipeline)([
205
- fileStream,
206
- // Custom backup archive parsing
153
+ inStream,
207
154
  new tar_1.default.Parse({
208
- /**
209
- * Filter the parsed entries to only keep the one that matches the given filepath
210
- */
211
- filter(entryPath, entry) {
155
+ filter(filePath, entry) {
212
156
  if (entry.type !== 'File') {
213
157
  return false;
214
158
  }
215
- return (0, utils_1.isPathEquivalent)(entryPath, filePath);
159
+ return (0, utils_1.isFilePathInDirname)(directory, filePath);
216
160
  },
217
161
  async onentry(entry) {
218
- // Collect all the content of the entry file
219
- const content = await entry.collect();
162
+ const transforms = [
163
+ // JSONL parser to read the data chunks one by one (line by line)
164
+ (0, Parser_1.parser)({
165
+ checkErrors: true,
166
+ }),
167
+ // The JSONL parser returns each line as key/value
168
+ (line) => line.value,
169
+ ];
170
+ const stream = entry.pipe((0, stream_chain_1.chain)(transforms));
220
171
  try {
221
- // Parse from buffer array to string to JSON
222
- const parsedContent = JSON.parse(Buffer.concat(content).toString());
223
- // Resolve the Promise with the parsed content
224
- resolve(parsedContent);
172
+ for await (const chunk of stream) {
173
+ outStream.write(chunk);
174
+ }
225
175
  }
226
176
  catch (e) {
227
- reject(e);
228
- }
229
- finally {
230
- // Cleanup (close the stream associated to the entry)
231
- entry.destroy();
177
+ outStream.destroy(new providers_1.ProviderTransferError(`Error parsing backup files from backup file ${entry.path}: ${e.message}`, {
178
+ details: {
179
+ error: e,
180
+ },
181
+ }));
232
182
  }
233
183
  },
234
184
  }),
235
- ], () => {
236
- // If the promise hasn't been resolved and we've parsed all
237
- // the archive entries, then the file doesn't exist
238
- reject(new Error(`File "${filePath}" not found`));
185
+ ], async () => {
186
+ // Manually send the 'end' event to the out stream
187
+ // once every entry has finished streaming its content
188
+ outStream.end();
239
189
  });
240
- });
241
- };
190
+ return outStream;
191
+ }
192
+ // For collecting an entire JSON file then parsing it, not for streaming JSONL
193
+ async #parseJSONFile(fileStream, filePath) {
194
+ return new Promise((resolve, reject) => {
195
+ (0, stream_1.pipeline)([
196
+ fileStream,
197
+ // Custom backup archive parsing
198
+ new tar_1.default.Parse({
199
+ /**
200
+ * Filter the parsed entries to only keep the one that matches the given filepath
201
+ */
202
+ filter(entryPath, entry) {
203
+ if (entry.type !== 'File') {
204
+ return false;
205
+ }
206
+ return (0, utils_1.isPathEquivalent)(entryPath, filePath);
207
+ },
208
+ async onentry(entry) {
209
+ // Collect all the content of the entry file
210
+ const content = await entry.collect();
211
+ try {
212
+ // Parse from buffer array to string to JSON
213
+ const parsedContent = JSON.parse(Buffer.concat(content).toString());
214
+ // Resolve the Promise with the parsed content
215
+ resolve(parsedContent);
216
+ }
217
+ catch (e) {
218
+ reject(e);
219
+ }
220
+ finally {
221
+ // Cleanup (close the stream associated to the entry)
222
+ entry.destroy();
223
+ }
224
+ },
225
+ }),
226
+ ], () => {
227
+ // If the promise hasn't been resolved and we've parsed all
228
+ // the archive entries, then the file doesn't exist
229
+ reject(new Error(`File "${filePath}" not found`));
230
+ });
231
+ });
232
+ }
233
+ }
242
234
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/file/providers/source/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAEA,gDAAuB;AACvB,gDAAwB;AACxB,mCAA+C;AAC/C,wDAA0B;AAC1B,8CAAsB;AACtB,kCAA2C;AAC3C,+CAAqC;AACrC,qDAAkD;AAKlD,0DAAmE;AACnE,kDAAgD;AAChD,yDAA+F;AAC/F,mCAAoF;AAIpF;;GAEG;AACH,MAAM,kBAAkB,GAAG,eAAe,CAAC;AAoBpC,MAAM,6BAA6B,GAAG,CAAC,OAAwC,EAAE,EAAE;IACxF,OAAO,IAAI,uBAAuB,C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AC3D,mDAAmD;gBACnD,MAAM,CAAC,IAAI,KAAK,CAAC,SAAS,QAAQ,aAAa,CAAC,CAAC,CAAC;YACpD,CAAC,CACF,CAAC;QACJ,CAAC,CAAC,CAAC;IACL,CAAC;CACF"}
package/dist/index.d.ts CHANGED
@@ -2,3 +2,4 @@ export * as engine from './engine';
2
2
  export * as strapi from './strapi';
3
3
  export * as file from './file';
4
4
  export * as utils from './utils';
5
+ export * as commands from './commands';
package/dist/index.js CHANGED
@@ -23,9 +23,10 @@ var __importStar = (this && this.__importStar) || function (mod) {
23
23
  return result;
24
24
  };
25
25
  Object.defineProperty(exports, "__esModule", { value: true });
26
- exports.utils = exports.file = exports.strapi = exports.engine = void 0;
26
+ exports.commands = exports.utils = exports.file = exports.strapi = exports.engine = void 0;
27
27
  exports.engine = __importStar(require("./engine"));
28
28
  exports.strapi = __importStar(require("./strapi"));
29
29
  exports.file = __importStar(require("./file"));
30
30
  exports.utils = __importStar(require("./utils"));
31
+ exports.commands = __importStar(require("./commands"));
31
32
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,mDAAmC;AACnC,mDAAmC;AACnC,+CAA+B;AAC/B,iDAAiC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,mDAAmC;AACnC,mDAAmC;AACnC,+CAA+B;AAC/B,iDAAiC;AACjC,uDAAuC"}
@@ -1,11 +1,12 @@
1
1
  /// <reference types="node" />
2
2
  import { Writable } from 'stream';
3
+ import type { LoadedStrapi } from '@strapi/types';
3
4
  import type { IDestinationProvider, IMetadata, ProviderType, Transaction } from '../../../../types';
4
5
  import { restore } from './strategies';
5
6
  export declare const VALID_CONFLICT_STRATEGIES: string[];
6
7
  export declare const DEFAULT_CONFLICT_STRATEGY = "restore";
7
8
  export interface ILocalStrapiDestinationProviderOptions {
8
- getStrapi(): Strapi.Strapi | Promise<Strapi.Strapi>;
9
+ getStrapi(): LoadedStrapi | Promise<LoadedStrapi>;
9
10
  autoDestroy?: boolean;
10
11
  restore?: restore.IRestoreOptions;
11
12
  strategy: 'restore';
@@ -15,7 +16,7 @@ declare class LocalStrapiDestinationProvider implements IDestinationProvider {
15
16
  name: string;
16
17
  type: ProviderType;
17
18
  options: ILocalStrapiDestinationProviderOptions;
18
- strapi?: Strapi.Strapi;
19
+ strapi?: LoadedStrapi;
19
20
  transaction?: Transaction;
20
21
  uploadsBackupDirectoryName: string;
21
22
  constructor(options: ILocalStrapiDestinationProviderOptions);
@@ -24,7 +25,7 @@ declare class LocalStrapiDestinationProvider implements IDestinationProvider {
24
25
  rollback(): Promise<void>;
25
26
  beforeTransfer(): Promise<void>;
26
27
  getMetadata(): IMetadata;
27
- getSchemas(): import("@strapi/strapi/lib/types/utils/string").Dict<import("@strapi/strapi/lib/types/core/schemas").Schema>;
28
+ getSchemas(): import("@strapi/types/dist/types/utils/string").Dict<import("@strapi/types/dist/types/core/schemas").Schema>;
28
29
  createEntitiesWriteStream(): Writable;
29
30
  createAssetsWriteStream(): Promise<Writable>;
30
31
  createConfigurationWriteStream(): Promise<Writable>;