# Export Data from Chat

Export your data to CSV or PDF without leaving the chat. The assistant generates the file and delivers it as a direct download.

## Export Tools

| Tool | Format | Data Exported |
|-------------|---------|-------------------|
| `exportToCSV` | CSV (compatible with Excel, Sheets, Numbers) | Invoices, expenses, quotes, clients, products |
| `exportToPDF` | PDF | Financial summaries, listings, reports |

## Usage Examples

### Export Invoices to CSV

```
"Export my invoices from January to March to CSV"
```

The assistant generates a CSV file with all invoices for the period, including: number, client, date, amount, tax, total, and status.

### Export Expenses to PDF

```
"Export this quarter's expense summary to PDF"
```

Generates a PDF with the breakdown by category, totals, and period.

### Export Clients

```
"Export all my clients to CSV"
```

Includes: name, email, NIF/CIF, address, phone, and total invoiced.

### Export Products

```
"Export my product catalog to CSV"
```

Includes: name, description, unit price, unit, tax rate, and SKU.

<h2>Available Filters</h2>

You can apply filters in natural language:

- **By period**: "invoices from Q1", "expenses from March", "this year"
- **By status**: "paid invoices", "pending invoices", "drafts"
- **By client**: "invoices from Acme SL"
- **By category**: "Software expenses", "Travel expenses"
- **By amount**: "invoices over 1,000 euros"

## CSV Format

CSV files are generated with:

- Separator: semicolon (`;`) — compatible with Excel in Spanish
- Encoding: UTF-8 with BOM
- Decimals: comma (`,`) for amounts
- Dates: `DD/MM/YYYY` format

## Download Flow

1. Request the export in the chat
2. The assistant processes the data and generates the file
3. A download link appears in the conversation
4. Download the file (available for 24 hours)

---

**Next step:** [Taxes and Fiscal Management from Chat](./impuestos-ia)
