Skip to content

Commit 87c1b52

Browse files
authored
Merge pull request #1398 from contentful/chore/embargoed-assets-dx-63
chore: update README with embargoed asset info [DX-63]
2 parents 53e233b + b356f19 commit 87c1b52

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

README.md

+20
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,8 @@ Path to a JSON file with the configuration options. This file will be merged wit
215215

216216
## :rescue_worker_helmet: Troubleshooting
217217

218+
### Proxy
219+
218220
Unable to connect to Contentful through your Proxy? Try to set the `rawProxy` option to `true`.
219221

220222
```javascript
@@ -225,6 +227,24 @@ contentfulImport({
225227
})
226228
```
227229

230+
### Embargoed Assets
231+
232+
If a space is configured to use the [embargoed assets feature](https://www.contentful.com/help/media/embargoed-assets/), certain options will need to be set to use the export/import tooling. When exporting content ([using `contentful-export`](https://github.com/contentful/contentful-export)), the `downloadAssets` option must be set to `true`. This will download the asset files to your local machine. Then, when importing content, the `uploadAssets` option must be set to `true` and the `assetsDirectory` must be set to the directory that contains all of the exported asset folders.
233+
234+
```javascript
235+
const contentfulImport = require('contentful-import')
236+
237+
const options = {
238+
contentFile: '/path/to/result/of/contentful-export.json',
239+
spaceId: '<space_id>',
240+
managementToken: '<content_management_api_key>',
241+
uploadAssets: true,
242+
assetsDirectory: '/path/to/exported/assets.json'
243+
}
244+
245+
contentfulImport(options)
246+
```
247+
228248
## :card_file_box: Expected input data structure
229249

230250
The data to import should be structured like this:

0 commit comments

Comments
 (0)