---
title: "List app code files"
method: GET
path: "/api/apps/{app_id}/code/file-list"
---

# List app code files

`GET /api/apps/{app_id}/code/file-list`

## Request

- Base URL: `https://app.base44.com`
- URL: `https://app.base44.com/api/apps/{app_id}/code/file-list`
- Auth: HTTP bearer

<Info>This API is in beta. Endpoints, fields, and behavior may still change, so avoid depending on it in production.</Info>

Returns the path of every file in the app's source, the list the app editor shows in its file tree.

Files the app's `.gitignore` excludes, dependency and build folders, most dotfiles, and binary or media files are left out. Read a file's text with [Get an app code file](/api-reference/get-an-app-code-file).

Reads come from the app's live sandbox, the same files the app editor shows, including changes that haven't been published yet. If no sandbox is running, the call starts one, so the first call after a quiet period takes noticeably longer than later ones.

Set `branch_id` to read a [branch](/developers/references/app-management/get-started/concepts#branches)'s files instead of main's. Each branch has its own sandbox, so the first read of a branch also takes longer. A merged branch can't be read: the call returns a 409. On an app imported from GitHub, reading a merged branch can instead return the files as they were when the branch was created, so don't rely on it there.

This is limited to 60 requests a minute per app for each workspace's personal API keys, so every key in a workspace shares one allowance. Some workspaces have a different limit.

<Note>This endpoint accepts a personal API key, including a read-only one, from anyone with access to the app, viewers included. Workspace API keys are not authorized for it.</Note>

## Path parameters

- `app_id` string, required: ID of the app whose code to read.

## Query parameters

- `branch_id` string: ID of the branch to work on, as returned by [List branches](/api-reference/list-branches). Omit it to work on the app's main branch.

## Response `200`

The path of every file in the app's source.

- FileList: The paths of the app's source files.
  - `paths` string[], required: Path of each file, relative to the app root.

## Other responses

- `401`: Missing or invalid credentials.
- `403`: You don't have access to this app, or you used a workspace API key.
- `404`: App not found, or no branch you can see has this `branch_id`.
- `409`: The branch in `branch_id` was merged (`extra_data.reason` is `branch_not_active`).
- `429`: Too many requests for this app in the last minute from personal API keys in your workspace.

## Changes

> 58 revisions in range; 1 not diffed.

- **2026-10-21** `c23775445de2`: 1 breaking, 1 info
  - `query` request parameter `branch_id` list-of-types was narrowed by removing types `null`
  - for the `query` request parameter `branch_id`, the type was generalized from no type to `string`
- **2026-10-21** `4e0beb03385b`: 2 info
  - added the new optional `query` request parameter `branch_id`
  - added the non-success response with the status `409`
- **2026-10-12** `5e139db2e643`: 1 info
  - the endpoint scheme security `PersonalAccessTokenAuth` was added to the API
- **2026-09-29** `d2b7ac8beb0c`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/adexad/apis/base44-app-management-api/changes/api/apps/:app_id/code/file-list/get.md)

---

[API](https://skmtc.dev/adexad/apis/base44-app-management-api.md) · [All operations](https://skmtc.dev/adexad/apis/base44-app-management-api/llms.txt) · [OpenAPI document](https://skmtc.dev/adexad/apis/base44-app-management-api/revisions/fa29e915c226?raw)
