Download Assets of an AOI
Overview
This endpoint allows user to create a download request for assets in an AOI. A successful request returns a list of download id and signed url to download the assets. Authentication via API key is mandatory, and errors like 404 or 500 return standard error messages with relevant codes and details.
-
Method:
POST -
URL:
/v0/aois/{aoi_id}/downloads -
Operation: Create a download request for assets in an AOI
-
Authentication Required: Yes
Authorization
All API requests require authentication using a Personal Access Token. Include your token in the request header with the Bearer scheme:
Authorization: Bearer <YOUR_PERSONAL_ACCESS_TOKEN>See the Authentication guide for how to generate a Personal Access Token.
Path Parameters
The aoi_id identifies the exact AOI whose assets are to be downloaded.
| Field | Type | Required | Description |
|---|---|---|---|
aoi_id | string | Yes | Unique identifier of the AOI |
Response
Successful Response – 200 OK
A 200 OK response from the Create a download request for assets in an AOI endpoint indicates that the request was successful. It returns a download id, signed url and status.
Refer to the table below for the detailed breakdown of each field in the API response:
AOI Object Fields
| Field | Type | Description |
|---|---|---|
download_id | string | Unique identifier for the Download request. |
signed_url | string | URL to download the requested asset |
status | string | Current status of the download request (e.g., "success"). |
Below is the complete JSON request for listing assets for an AOI using the List Assets for an AOI endpoint. Customize the values as needed for your search criteria:
{
"download_id": "<string>",
"signed_url": "https://storage.account/download",
"status": "SUCCESS"
}- If you recieve a Not Found error (404) or the Internal Server Error (500), you will get the following response:
{
"error": {
"code": "<string>",
"details": "<any>",
"message": "<string>"
}
}How to use endpoint
-
Construct your Request:
Add your API key to theAuthorizationheader and add the path parameter. -
Send the Request:
Include the json body with correct path parameter and send the request to: https://api.pixxel.space/v0/aois/{aoi_id}/downloads. -
Examine the Response:
A successful response (200 OK) returns asigned_urlwhich should be used to download the asset. In case of failure (404, 500), structured error messages withcode,message, anddetailswill be returned.