import_upload
Upload a CSV, XLSX, XML, or ZIP file to start a Storno import job for clients, suppliers, products, invoices, receipts, or payments.
Instructions
Upload a file (CSV, XLSX, XML, or ZIP) to start a new import job. Requires importType (clients, suppliers, products, invoices_issued, invoices_received, recurring_invoices, platform_sales, receipts, payments) and source (smartbill, saga, oblio, fgo, facturis_online, easybill, ciel, factureaza, facturare_pro, icefact, bolt, facturis, emag, uber, glovo, tazz, woocommerce, prestashop, cash_register, efactura, generic). Platform statements (uber, bolt, glovo, tazz) use importType platform_sales and become one sales invoice to the platform plus the commission purchase invoice per group; shop exports (woocommerce, prestashop) use invoices_issued; the A4200 XML or a ZIP of a month exported by a fiscal cash register uses source cash_register with importType receipts. The invoice report of another invoicing or accounting program (or any spreadsheet, source generic) uses importType invoices_issued or invoices_received: one row per invoice or one row per invoice line, the mapping is suggested from the usual column names, collection status is read from the file and missing clients are created; the invoice XML those programs export for the accountant (, .xml with source smartbill, saga, oblio, fgo or generic) is read as well. A supplier list exported by another program (or any spreadsheet, source generic) uses importType suppliers: suppliers already known by fiscal code are not duplicated, only completed with the fields they miss. The facturis sales journal also reads columns added to it by their usual names (due date, amount left to pay, paid amount, state, reversed invoice). The invoice target field stornoOf holds the number of the invoice a storno reverses: the storno is linked to it and gets status refund. e-Factura XML (UBL Invoice or CreditNote, one .xml file or a .zip of up to 5000 of them) uses source efactura with importType invoices_issued or invoices_received: the invoices are kept as history with status synced and are never sent to ANAF, a credit note becomes a negative invoice linked to the invoice it names, an invoice of another company is refused with a row error, and numbers already present are skipped. Collections of issued invoices use importType payments (every source that imports invoices, including facturis and generic): one row per payment with invoiceNumber and amount (required), series, paymentDate, paymentMethod, reference, notes. The invoice is found by number, several rows for one invoice are its partial payments, a payment larger than what is left to pay is a row error, and importing the same file again adds nothing. Returns the created import job with preview data.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"filePath": "<filePath>",
"importType": "<importType>",
"source": "<source>"
},
"name": "import_upload"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| source | Yes | Source application the file was exported from; efactura for e-Factura XML files | |
| filePath | Yes | Absolute path to the file to upload (CSV, XLSX, XML, or a ZIP of A4200 or e-Factura XML files) | |
| companyId | No | Company UUID override (uses active company if not set) | |
| importType | Yes | Type of data being imported |