# Invoice workflow (https://docs.getbeel.com/en/guide/invoice-management/invoice-workflow)

From the invoice the AI read to the export for your accountant: check, approve and export received invoices.

Every received invoice goes through the same statuses, from the AI reading to the export. In **Received invoices** you check and export it; you approve it with the AI assistant or the API.

## The statuses [#the-statuses]

| Status             | API value          | What it means                                        |
| ------------------ | ------------------ | ---------------------------------------------------- |
| **Processing**     | `processing`       | The AI is reading the document.                      |
| **Pending review** | `pending_review`   | Read, waiting for your check.                        |
| **Approved**       | `verified`         | You confirmed the data is correct.                   |
| **Rejected**       | `rejected`         | It is not a valid invoice for you.                   |
| **Exported**       | `exported`         | Already handed over to accounting.                   |
| **Missing PDF**    | `missing_document` | The email confirms a payment but the PDF is missing. |

You can approve an invoice from **Pending review** or **Rejected**, and reject it from **Pending review** or **Approved**. In **Taxes**, an invoice not yet approved still goes into the VAT registers, marked **Not reviewed yet**.

## Before you start [#before-you-start]

- **Invoices in Getbeel**, from email, forwarding, upload or SDI ([Invoice management](/en/guide/invoice-management)).
- **The right role**: **Owner** or **Member** manage invoices; **Accountant** is read-only and can export.
- **To approve**: a [connected AI assistant](/en/guide/connect-ai). The app has no approve button.

## Steps [#steps]

<Steps>
<Step>

### Find the invoice [#find-the-invoice]

In **Received invoices** search by supplier or number. Filter by **Category**, by period or by source: **SDI** or **Email and uploads**.

</Step>
<Step>

### Check the data [#check-the-data]

Open the invoice. **Invoice details** shows the supplier, number, dates, amounts and **Line items**, next to the document preview. Correct the category from the list's **Category** column.

</Step>
<Step>

### Complete the invoices without a PDF [#complete-the-invoices-without-a-pdf]

Open the **Missing PDF** tab. For each invoice, download the document from the supplier and upload it into the box ([When the PDF is missing](/en/guide/invoice-management/ai-extraction#when-the-pdf-is-missing)).

</Step>
<Step>

### Approve or reject [#approve-or-reject]

Ask the assistant, for example: _"Show me the received invoices pending review and approve the ones from Aruba."_ The assistant uses `list_received_invoices` and `approve_collected_document`, with `decision: "reject"` to reject. It asks you to confirm before each change.

</Step>
<Step>

### Export for your accountant [#export-for-your-accountant]

Select the invoices and press **Export**. In **Export invoices** choose **CSV**, **Excel** or **ZIP** (data and PDF attachments), then press **Download**.

</Step>
</Steps>

## What just happened [#what-just-happened]

- **You found the invoices** with search and filters, without opening them one by one.
- **The data is checked** against the original document.
- **No invoice is left without a document**: the **Missing PDF** tab is empty.
- **Approved invoices are Approved**, and in **Taxes** they lose the **Not reviewed yet** mark.
- **Your accountant has the file** with the data and, in the ZIP, the PDFs.

## If it fails [#if-it-fails]

| Message                                           | Cause                                                       | Fix                                    |
| ------------------------------------------------- | ----------------------------------------------------------- | -------------------------------------- |
| "Export failed"                                   | The file was not created                                    | Try again with fewer invoices          |
| "No PDF attachments found"                        | The chosen invoices have no PDF                             | Export as **CSV** or **Excel**         |
| "Failed to delete invoices"                       | The invoices were not deleted                               | Try again; check your role             |
| The assistant says the invoice cannot be approved | It is still **Processing**, **Missing PDF** or **Exported** | Wait for the reading or upload the PDF |

You cannot undo deleting an invoice.

## Next steps [#next-steps]

<Cards>
  <Card title="Bank reconciliation" href="/en/guide/bank-reconciliation">
    Match invoices to bank payments.
  </Card>
  <Card
    title="Reports and your accountant"
    href="/en/guide/report-e-commercialista"
  >
    Exports and read-only access for your accountant.
  </Card>
  <Card title="Example prompts" href="/en/guide/example-prompts">
    More questions to ask the assistant about invoices.
  </Card>
</Cards>
