> ## Documentation Index
> Fetch the complete documentation index at: https://docs.alumio.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Filesystem: Read files

> Reads the contents of a file from a filesystem and adds it to the data.

Reads a file from a filesystem and adds its contents to the data so later steps can work with it. Use this to pull in a file that lives alongside your main data, for example reading a product feed, a configuration file, or a previously exported document. The file's content is decoded from its format (such as JSON, XML, or CSV) into structured data and placed in the data under a key that matches the file's path. If the file does not exist, the data passes through unchanged.

This documentation describes: [Schema](/schemas/transformer/read-files)

## Fields

**Filesystem connection**

Required

The filesystem connection that holds the file you want to read.

See the [filesystem](/references/filesystem) reference.

**File location**

Required

The path to the file, including the file name and extension, for example `imports/products.json`. You can use [placeholders](/references/placeholders) here to build the path from the data. This same path is also used as the key under which the file's content is added to the data.

**Parser**

Required

The format the file is written in, so its content can be decoded into usable data. Pick the format that matches your file, such as JSON, XML, or CSV.

See the [deserializer](/references/deserializer) reference.

## Sample data

This step reads a file from a real filesystem connection and adds its decoded contents to the data, so there is no fixed before/after to show. The configuration below reads `imports/products.json` with the JSON parser; the decoded content is added to the data under the key `imports/products.json`.

| Field | Value |
| - | - |
| Filesystem connection | The connection holding the file |
| File location | `imports/products.json` |
| Parser | JSON |

```json Configuration theme={null}
{
  "prototype": "read-files",
  "parameters": {
    "filesystem": "import-files",
    "filePath": "imports/products.json",
    "parser": {
      "prototype": "json"
    }
  }
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.