# Exports

A month's or a period's invoices in a ZIP (XML and PDF) or in Excel.

The guide, step by step: https://fiscalisto.com/en/docs/api/exportaciones.md

## Endpoints

- [Export a month's invoices](https://fiscalisto.com/en/docs/api/referencia/exportaciones/create-export.md): `POST /v1/exports`
- [List exports](https://fiscalisto.com/en/docs/api/referencia/exportaciones/list-exports.md): `GET /v1/exports`
- [Get an export](https://fiscalisto.com/en/docs/api/referencia/exportaciones/get-export.md): `GET /v1/exports/{id}`
- [Download an export](https://fiscalisto.com/en/docs/api/referencia/exportaciones/download-export.md): `GET /v1/exports/{id}/download`

## The Export object

An issuer's invoices in a period, in a ZIP or in Excel.

`status` lifecycle:

- `processing` → `completed`: The file is ready.
- `processing` → `failed`: It failed to generate: request it again.
- `completed` → `expired`: 30 days pass and the file is deleted.

| Field | Type | Always present | Description |
| --- | --- | --- | --- |
| `id` | string | yes | Object identifier, with its prefix (iss_, inv_, ret_, cus_, prd_, emp_, bat_, brn_, whs_, stm_, adj_, evt_, whe_). |
| `object` | `"export"` | yes | What kind of object it is («invoice», «customer»…). |
| `livemode` | boolean | yes | true in production (fk_live_ keys), false in test mode (fk_test_). Test objects aren't valid before the SAT. |
| `issuer` | string | yes | The issuer (iss_…). |
| `format` | `zip`, `xlsx` | yes | zip (each invoice's files) or xlsx (an Excel file with one row per invoice). |
| `files` | `xml`, `pdf`, `xml_and_pdf` or null | yes | Which files of each invoice the ZIP carries; null for an Excel file. |
| `direction` | `issued`, `received` | yes | EntradaSalidaMerc: Entrada or Salida. |
| `from` | string or null | yes | From which day (inclusive), by issue date. |
| `to` | string or null | yes | Up to which day (inclusive), by issue date. |
| `type` | `I`, `E`, `P`, `T`, `N` or null | yes | Receipt type (TipoDeComprobante): I income, E expense, P payment, T transfer, N payroll. |
| `status` | `processing`, `completed`, `failed`, `expired` | yes | processing: being generated. completed: ready to download. failed: it failed (see error); request it again. expired: 30 days passed and the file was deleted. |
| `invoice_count` | number | yes | How many invoices it carries. |
| `size_bytes` | number or null | yes | The file size in bytes, when it is ready. |
| `error` | string or null | yes | Why the export failed, in words; null if it didn't fail. |
| `created_at` | string or null | yes | When it was created, ISO 8601 with Mexico City time (-06:00). |
| `completed_at` | string or null | yes | When it finished. |
| `expires_at` | string or null | yes | Until when it can be downloaded (30 days after completed). |

Example:

```json
{
  "id": "xpt_OufpKqnrvx9p0Nfbydl9jG4UNGeTYcvdrg",
  "object": "export",
  "livemode": false,
  "issuer": "iss_OufpKqnrvx9p",
  "format": "zip",
  "files": "xml_and_pdf",
  "direction": "issued",
  "from": "2026-10-01",
  "to": "2026-10-31",
  "type": null,
  "status": "processing",
  "invoice_count": 184,
  "size_bytes": null,
  "error": null,
  "created_at": "2026-11-01T09:00:12-06:00",
  "completed_at": null,
  "expires_at": null
}
```
