---
title: "List Task Files"
method: GET
path: "/api/files/task/{task_id}"
tags: ["files"]
---

# List Task Files

`GET /api/files/task/{task_id}`

Get all files for a specific task.

More efficient than /api/files/list as it filters at database level.
Only returns files that are already registered in the database.

## Path parameters

- `task_id` integer, required

## Response `200`

Successful Response

- object

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/xorbitsai/apis/xagent.md) · [All operations](https://skmtc.net/xorbitsai/apis/xagent/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/xorbitsai/xagent/revisions/33e4ba4936ad/schema)
