list_dataset_files

DatasetsApi.list_dataset_files(id, role_id, from_time=None, to_time=None, limit=None, offset=None, sortorder=None, sortby=None, status=None, storage=None, projection_expression=None, filter_expression=None, _request_timeout=None, _request_auth=None, _content_type=None, _headers=None, _host_index=0)

Get list of files for a dataset

Returns a paginated list of dataset file metadata for the dataset. Pagination contract (no nextToken): - limit: page size; default 100; max 500 (IPV-1050 if exceeded). - offset: 1-based item start index (not page number). The service subtracts 1 to get the 0-based start. Omit for the first page (starts at 0). For the next page use offset = previous_offset + limit (e.g. limit=100 → pages at offset 1, 101, 201, …). - Response count: number of items in this page’s files array. - Response total_count: total matching files (before page slice), except when storage is set — then count/total_count reflect the filtered current page only. - Response next_available: “yes” if more items remain after this page (offset + limit < total_count in 0-based terms), else “no”. Stop paging when next_available is “no” or count is 0. - from_time and to_time must be used together (LastModified range). - sortby only supports LastModified (GE-1047 otherwise); sortorder defaults to desc. - Invalid status → DS-1025. Read-only callers on TBAC datasets only see files matching their tags.

Parameters:
  • id (str) – Dataset ID to list files for. (required)

  • role_id (str) – Amorphic role ID used for authorization. (required)

  • from_time (str) – Start of LastModified time range. Must be paired with to_time; alone is ignored/invalid depending on validation path.

  • to_time (str) – End of LastModified time range. Must be paired with from_time.

  • limit (str) – Page size. Default 100; maximum 500 (IPV-1050 if exceeded).

  • offset (str) – 1-based item start index (not page number). Service uses int(offset)-1 as the 0-based start. Omit for first page. Next page: previous offset + limit (e.g. 1, then 101 for limit=100).

  • sortorder (str) – Sort direction applied to sortby (default desc).

  • sortby (str) – Sort field. Only LastModified is supported; any other value returns GE-1047.

  • status (str) – Filter files where LoadStatus equals this value (case-insensitive). Invalid values return DS-1025.

  • storage (str) – Post-filter by S3 StorageClass after the page is fetched. When set, response count/total_count reflect the filtered page only (not the full matching set), so prefer paging without storage or treat next_available carefully.

  • projection_expression (str) – Comma-separated DynamoDB projection attribute names to return on each file item (e.g. FileName,LoadStatus,LastModified).

  • filter_expression (str) – Extra metadata filter as comma-separated key:value pairs. Same key values are OR’d; different keys are AND’d. FileName supports * contains. LastModified keys are ignored. Max string length ~3.5KB.

  • _request_timeout (int, tuple(int, int), optional) – timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts.

  • _request_auth (dict, optional) – set to override the auth_settings for an a single request; this effectively ignores the authentication in the spec for a single request.

  • _content_type (str, Optional) – force content-type for the request.

  • _headers (dict, optional) – set to override the headers for a single request; this effectively ignores the headers in the spec for a single request.

  • _host_index (int, optional) – set to override the host_index for a single request; this effectively ignores the host_index in the spec for a single request.

Return type:

DatasetFiles

Returns:

Returns the result object.

Request and Response Examples

HTTP: GET /datasets/{id}/files

Success (HTTP 200)

Paginated files list. Continue while next_available is “yes” by advancing offset by limit; stop when next_available is “no”.

Request / response example

{
  "files": [
    {
      "FileName": "data/2024/sales.csv",
      "DatasetId": "49e02003-289e-41e9-a9f2-28a733349481",
      "LastModified": "2024-01-15T10:30:00Z"
    }
  ],
  "next_available": "yes",
  "count": 100,
  "total_count": 250
}

Errors

Documented error codes: IPV-1050, GE-1047, DS-1025.

HTTP 400

Validation failure. Codes include IPV-1050 (limit > 500), GE-1047 (invalid sortby), DS-1025 (invalid status).

Limit too large

{
  "Message": "IPV-1050 - Out of range for items per page, Limit is 500"
}

HTTP 500

Backend/generic failure.