# Files

Files can be used for a multitude of different use cases including but not limited to, individual identity verification and business underwriting. You may need to provide documentation to enable capabilities or to keep capabilities enabled for an account. The maximum file size is 20 MB. Each account is allowed a maximum of 50 files. Acceptable file types include CSV, JPG, PDF, and PNG.

[API reference](/api/moov-accounts/files/post/)

## Upload file

Uploads a file related to a specific account.

To upload files, you'll need to specify the `/accounts/{accountID}/files.write` scope when generating a token.

#### Parameters

| Name          | Type                                                                                                                                                  |
|---------------|-------------------------------------------------------------------------------------------------------------------------------------------------------|
| `accountID`   | string                                                                                                                                                |
| `file`        | binary                                                                                                                                                |
| `filePurpose` | `identity_verification` `individual_verification` `representative_verification` `business_verification` `merchant_underwriting` `account_requirement` |
| `metadata`    | JSON string `keys :` `representative_id` `requirement_id` `error_code` `comment`                                                                      |

```javascript
moov.accounts.files.upload({accountID, file, filePurpose});
```

## List files for account

Retrieve all the files associated with an account.

To list files, you'll need to specify the `/accounts/{accountID}/files.read` scope when generating a token.

#### Parameters

| Name Type   |        |
|-------------|--------|
| `accountID` | string |

```javascript
moov.accounts.files.list({accountID});
```

## Get details about a file

Retrieve file details associated with a specific Moov account.

To retrieve file details, you'll need to specify the `/accounts/{accountID}/files.read` scope when generating a token.

#### Parameters

| Name        | Type   |
|-------------|--------|
| `accountID` | string |
| `fileID`    | string |

```javascript
moov.accounts.files.get({accountID, fileID});
```
