---
title: "List datafiles for application"
method: GET
path: "/v1/applications/{applicationId}/datafiles"
tags: ["Datafiles"]
---

# List datafiles for application

`GET /v1/applications/{applicationId}/datafiles`

## Path parameters

- `applicationId` string, required

## Response `200`

Success

- object
  - `items` Datafile[], required
    - `_id` string, required
    - `_application` string, required — The application that this datafile belongs to.
    - `name` string, required — The filename of this datafile.
    - `content_type` 'application/json', required — The content type of the datafile.
    - `schema` string, required — The name of the schema for this datafile.
    - `status` 'pending' | 'processing' | 'completed' | 'failed', required — The status of a datafile: - `pending` The datafile record exists, but the file has not yet been fully uploaded. - `processing` Akahu Apply is extracting and enriching the data from this datafile. - `completed` This datafile has been successfully processed. - `failed` This datafile has not been successfully processed. See the `failure_reason` for more detail.
    - `failure_reason` object — If this datafile has failed to be processed, this field provides additional detail about what went wrong.
      - `code` 'internal_error' | 'invalid_input' | 'timeout' | 'malware_scan_failed' | 'malware_detected', required
      - `message` string
    - `created_at` string, date-time, required — The date that this datafile was created.
    - `updated_at` string, date-time, required — The date that this datafile was last updated at.
    - `expires_at` string, date-time — Expiry for the datafile, after which the record will be deleted. Expiry varies as the datafile progresses through its lifecycle: - While the datafile has a status of `pending`, expiry is short lived, ensuring that the record is cleaned up quickly if a file is never uploaded. - After the datafile upload has been received, a 1 year expiry is set, after which the datafile and all associated data will be permanently deleted.

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `403` — Forbidden
- `404` — Not Found
- `429` — Too Many Requests
- `500` — Internal Server Error

---

[API](https://skmtc.dev/akahu/apis/akahu-enduring-api.md) · [All operations](https://skmtc.dev/akahu/apis/akahu-enduring-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/akahu/akahu-enduring-api/revisions/b2de9915920d/schema)
