/

Data Delivery (API)

Download assets.


Introduction

After the order is successful, the datasets will be delivered on the Storage. In this guide, you will learn how to download assets.

Download Data

  1. Before downloading assets, you need to identify the asset ID for your previously placed orders. This can be done with the following command:
curl -L -s -X GET $order_url -H "Authorization: Bearer $PTOKEN" \
| jq -r '.data.orders[] | .id + " : " + .assets[]'
  1. Get the assets associated to your placed orders and check status:
curl -L -s -X GET $order_url -H "Authorization: Bearer $PTOKEN" \
| jq -r '.data.orders[] | select(.id=="6e06915e-bfe8-4e3f-a0f3-ded9ed7279f9") | .assets[] + " : " + .status'
  1. The endpoint for viewing an asset is defined as variable `asset_url:
asset_url=https://api.up42.com/workspaces/$workspace_id/assets

To find your workspace ID, please follow the instructions from the article Workspaces.

  1. View information of a single asset:
asset=eee39b83-a805-444e-89a7-ca25b5e4b8bd
curl -s -L GET https://api.up42.com/workspaces/$workspace_id/assets/$asset \
-H "Authorization: Bearer $PTOKEN" | jq '.' > asset_information.json
  1. Download a single asset as a ZIP archive:
asset_data_URL=$(curl -s -L GET https://api.up42.com/workspaces/$workspace_id/assets/$asset/downloadUrl \
-H "Authorization: Bearer $PTOKEN" | jq -j '.data.url')
curl -s -L $asset_data_URL -H "Authorization: Bearer $PTOKEN" -o my_archive_order.zip

By following this guide, you managed to view the list of available collections and data products, perform a search for your set of requirements (preferred area of interest, search interval and quality criteria), estimate the costs, place an order and download archive data.