How to download assets with cURL | AEM
cURL commands can be used in AEM to download single and multiple files and folders.
Description description
Environments
Adobe Experience Manager 6.5
Issue/Symptoms:
By using cURL, you can download multiple assets with a command at once. It is useful for the following use cases:
- Download assets automatically
- Download assets in several folders
- Download particular assets in a folder
Resolution resolution
Specify the asset or folder path to be downloaded in a cURL command.
Download a single asset
$ curl -u user:password -o <output file name> http://localhost:4502/<asset path>.assetdownload.zip
Example:
$ curl -u user:password -o download_asset.zip http://localhost:4502/content/dam/we-retail/en/features/tracking.png.assetdownload.zip
Download all assets in a single folder
$ curl -u user:password -o <output file name> http://localhost:4502/<asset path>.assetdownload.zip
Example:
$ curl -u user:password -o download_asset.zip http://localhost:4502/content/dam/we-retail/en/people.assetdownload.zip
Download multiple folders and assets at once
$ curl -u user:password -o <output file name> -F "path=<path A>" -F "path=<path B>" -F ... http://localhost:4502/<path A>.assetdownload.zip
Example:
$ curl -u admin:admin -o download_asset.zip -F "path=/content/dam/we-retail/en/people" -F "path=/content/dam/we-retail/en/experiences" -F "path=/content/dam/we-retail/en/features/tracking.png" http://localhost:4502/content/dam/we-retail/en/people.assetdownload.zip
Specify <
path A>
.assetdownload.zip for the path part of the URL.
Downloading a large number of assets at once may cause performance problems. Adjust the number of assets monitoring the server load.
recommendation-more-help
3d58f420-19b5-47a0-a122-5c9dab55ec7f