Access and download files within a batch

To access specific details of a file, use a file identifier ({FILE_ID}) with the Data Access API, including its name, size in bytes, and a link to download.

The response contains a data array. Depending on whether the file pointed to by the ID is an individual file or a directory, the data array returned may contain a single entry or a list of files belonging to that directory. Each file element includes the details of the file.

API format

GET /files/{FILE_ID}
PropertyDescription
{FILE_ID}Equal to the "dataSetFileId", the ID of the file to be accessed.

Request

curl -X GET https://platform.adobe.io/data/foundation/export/files/{FILE_ID} \
  -H 'Authorization: Bearer {ACCESS_TOKEN}' \
  -H 'x-api-key: {API_KEY}' \
  -H 'x-gw-ims-org-id: {ORG_ID}' \
  -H 'x-sandbox-name: {SANDBOX_NAME}'

Single file response

{
  "data": [
    {
      "name": "{FILE_NAME}",
      "length": "{LENGTH}",
      "_links": {
        "self": {
          "href": "https://platform.adobe.io/data/foundation/export/files/{FILE_ID}?path={FILE_NAME}"
        }
      }
    }
  ],
  "_page": {
    "limit": 100,
    "count": 1
  }
}
PropertyDescription
data.nameThe name of the file (for example, profiles.parquet).
data.lengthThe size of the file (in bytes).
data._links.self.hrefThe URL to download the file.

Directory response

{
  "data": [
    {
      "dataSetFileId": "{FILE_ID_1}",
      "dataSetViewId": "string",
      "version": "1.0.0",
      "created": "string",
      "updated": "string",
      "isValid": true,
      "_links": {
        "self": {
          "href": "https://platform.adobe.io/data/foundation/export/files/{FILE_ID_1}"
        }
      }
    },
    {
      "dataSetFileId": "{FILE_ID_2}",
      "dataSetViewId": "string",
      "version": "1.0.0",
      "created": "string",
      "updated": "string",
      "isValid": true,
      "_links": {
        "self": {
          "href": "https://platform.adobe.io/data/foundation/export/files/{FILE_ID_2}"
        }
      }
    }
  ],
  "_page": {
    "limit": 100,
    "count": 2
  }
}

When a directory is returned, it contains an array of all files within the directory.

PropertyDescription
data.nameThe name of the file (for example, profiles.parquet).
data._links.self.hrefThe URL to download the file.