@spaceinvoices/js-sdk 18.22.0 → 18.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/generated/customers/customers.d.cts +1 -1
- package/dist/generated/customers/customers.d.ts +1 -1
- package/dist/generated/exports/exports.d.cts +1 -1
- package/dist/generated/exports/exports.d.ts +1 -1
- package/dist/generated/tax-reports/tax-reports.d.cts +4 -4
- package/dist/generated/tax-reports/tax-reports.d.ts +4 -4
- package/dist/generated-zod/customers/customers.d.cts +1 -1
- package/dist/generated-zod/customers/customers.d.ts +1 -1
- package/dist/generated-zod/exports/exports.d.cts +1 -1
- package/dist/generated-zod/exports/exports.d.ts +1 -1
- package/dist/generated-zod/tax-reports/tax-reports.d.cts +4 -4
- package/dist/generated-zod/tax-reports/tax-reports.d.ts +4 -4
- package/package.json +1 -1
|
@@ -209,7 +209,7 @@ export declare const getDeleteCustomerUrl: (id: string) => string;
|
|
|
209
209
|
export declare const deleteCustomer: (id: string, options?: RequestInit) => Promise<deleteCustomerResponse>;
|
|
210
210
|
/**
|
|
211
211
|
* Which items, in what quantity and for what net amount were sold to this customer in a date range.
|
|
212
|
-
Counts finalized invoices and advance invoices that are not applied to a live invoice; credit notes are subtracted. Drafts, deleted documents, voided credit notes and voided advance invoices are excluded. A voided invoice is counted together with
|
|
212
|
+
Counts finalized invoices and advance invoices that are not applied to a live invoice; credit notes are subtracted. Drafts, deleted documents, voided credit notes and voided advance invoices are excluded. A voided invoice that has a credit note issued for it is counted together with each such credit note, so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, neither it nor its credit notes count. A voided invoice without a credit note counts as if it never happened.
|
|
213
213
|
Items are grouped by catalog item ID when available, or by case-insensitive name. Amounts are in entity currency, rows are ordered by gross amount (total_with_tax, highest first); totals.quantity_net is null when the items use different units. The period may span up to 20 years.
|
|
214
214
|
Also available for soft-deleted customers. To download the same data as a spreadsheet use the sales-per-item export with customer_id.
|
|
215
215
|
* @summary Get items sold to a customer
|
|
@@ -209,7 +209,7 @@ export declare const getDeleteCustomerUrl: (id: string) => string;
|
|
|
209
209
|
export declare const deleteCustomer: (id: string, options?: RequestInit) => Promise<deleteCustomerResponse>;
|
|
210
210
|
/**
|
|
211
211
|
* Which items, in what quantity and for what net amount were sold to this customer in a date range.
|
|
212
|
-
Counts finalized invoices and advance invoices that are not applied to a live invoice; credit notes are subtracted. Drafts, deleted documents, voided credit notes and voided advance invoices are excluded. A voided invoice is counted together with
|
|
212
|
+
Counts finalized invoices and advance invoices that are not applied to a live invoice; credit notes are subtracted. Drafts, deleted documents, voided credit notes and voided advance invoices are excluded. A voided invoice that has a credit note issued for it is counted together with each such credit note, so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, neither it nor its credit notes count. A voided invoice without a credit note counts as if it never happened.
|
|
213
213
|
Items are grouped by catalog item ID when available, or by case-insensitive name. Amounts are in entity currency, rows are ordered by gross amount (total_with_tax, highest first); totals.quantity_net is null when the items use different units. The period may span up to 20 years.
|
|
214
214
|
Also available for soft-deleted customers. To download the same data as a spreadsheet use the sales-per-item export with customer_id.
|
|
215
215
|
* @summary Get items sold to a customer
|
|
@@ -53,7 +53,7 @@ export declare const exportDocuments: (params: ExportDocumentsParams, options?:
|
|
|
53
53
|
* Export aggregated sales data per item (product/service) for a given date range.
|
|
54
54
|
Includes quantities sold/returned, average price, and totals.
|
|
55
55
|
Aggregates across invoices, credit notes, and advance invoices.
|
|
56
|
-
A voided invoice is counted together with
|
|
56
|
+
A voided invoice that has a credit note issued for it is counted together with each such credit note (sold and returned), so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, neither it nor its credit notes count. Voided invoices without a credit note are excluded.
|
|
57
57
|
Items are grouped by catalog item ID when available, or by exact name match.
|
|
58
58
|
* @summary Export sales per item for a period
|
|
59
59
|
*/
|
|
@@ -53,7 +53,7 @@ export declare const exportDocuments: (params: ExportDocumentsParams, options?:
|
|
|
53
53
|
* Export aggregated sales data per item (product/service) for a given date range.
|
|
54
54
|
Includes quantities sold/returned, average price, and totals.
|
|
55
55
|
Aggregates across invoices, credit notes, and advance invoices.
|
|
56
|
-
A voided invoice is counted together with
|
|
56
|
+
A voided invoice that has a credit note issued for it is counted together with each such credit note (sold and returned), so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, neither it nor its credit notes count. Voided invoices without a credit note are excluded.
|
|
57
57
|
Items are grouped by catalog item ID when available, or by exact name match.
|
|
58
58
|
* @summary Export sales per item for a period
|
|
59
59
|
*/
|
|
@@ -283,7 +283,7 @@ when a period has no applicable records, as required for a joint eDavki submissi
|
|
|
283
283
|
|
|
284
284
|
**Important:**
|
|
285
285
|
- KIR/KPR is available only to entities whose country code is `SI`
|
|
286
|
-
- Draft and deleted documents and voided credit notes are excluded. A voided invoice is excluded together with
|
|
286
|
+
- Draft and deleted documents and voided credit notes are excluded. A voided invoice is excluded together with a credit note issued for it if both fall in the same period, unless the credit note is linked to more than one voided invoice, in which case each document is reported in its own period. If that credit note falls in another period, the invoice is reported in its own period and the credit note in its own. A voided invoice without a credit note is excluded
|
|
287
287
|
- Domestic outgoing advances are included as separate KIR rows and their allocated net/VAT amounts are subtracted from the linked final invoice. For intra-EU B2B supplies, goods prepayments are omitted and not deducted; only the classified service component is reported in P10 and deducted from the final invoice. A fully prepaid reportable service still emits the final reconciliation row with P10 empty/zero
|
|
288
288
|
- Third-country outgoing documents use the persisted item tax treatment: bases with an explicit 0% tax row map to P7, while no-tax net amounts (including unrated summary bases) map to P27. Mixed documents are split between both fields. Product/service classification and customer geography are not substitutes for tax treatment; the legacy `export` transaction type remains an explicit goods-export marker and maps to P7
|
|
289
289
|
- An explicit 0% base on a domestic or intra-EU B2C outgoing document is an exempt supply without the right to deduct; it is reported in P9 and excluded from P7
|
|
@@ -545,7 +545,7 @@ export type exportSloveniaVodXmlResponse = (exportSloveniaVodXmlResponseSuccess
|
|
|
545
545
|
export declare const getExportSloveniaVodXmlUrl: () => string;
|
|
546
546
|
export declare const exportSloveniaVodXml: (exportSloveniaVodXmlBody: ExportSloveniaVodXmlBody, options?: RequestInit) => Promise<exportSloveniaVodXmlResponse>;
|
|
547
547
|
/**
|
|
548
|
-
* Download miniMAX XML for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range. A voided invoice is included together with
|
|
548
|
+
* Download miniMAX XML for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range. A voided invoice that has a credit note issued for it is included together with each such credit note, each on its own date, so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, the voided invoice is left out and its credit notes are exported alone. Voided invoices without a credit note, voided credit notes and voided advance invoices are excluded. Advances carry VAT records; linked final invoices reconcile previously reported VAT and settle the configured advance account. Bank/cash payments are booked separately. Source data must contain product/service classifications and reconcilable tax and EUR amounts. Invalid or unsupported accounting data rejects the entire export with an actionable 422 error. Re-importing the same date range may duplicate entries in miniMAX; import each document once.
|
|
549
549
|
* @summary Export Slovenia miniMAX accounting XML
|
|
550
550
|
*/
|
|
551
551
|
export type exportSloveniaMinimaxXmlResponse200 = {
|
|
@@ -586,7 +586,7 @@ export type exportSloveniaMinimaxXmlResponse = (exportSloveniaMinimaxXmlResponse
|
|
|
586
586
|
export declare const getExportSloveniaMinimaxXmlUrl: () => string;
|
|
587
587
|
export declare const exportSloveniaMinimaxXml: (exportSloveniaMinimaxXmlBody: ExportSloveniaMinimaxXmlBody, options?: RequestInit) => Promise<exportSloveniaMinimaxXmlResponse>;
|
|
588
588
|
/**
|
|
589
|
-
* Download a single windows-1250 VASCO KN 2.1 XML file (Prenos Verzija 2.1) for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range (the same selection as the miniMAX export: a voided invoice
|
|
589
|
+
* Download a single windows-1250 VASCO KN 2.1 XML file (Prenos Verzija 2.1) for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range (the same selection as the miniMAX export: a voided invoice that has a credit note issued for it is included together with each such credit note, unless it had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, in which case its credit notes are exported alone). Amounts are in EUR. Advance invoices carry their VAT-book records on a zero-amount advance-account entry; linked final invoices settle the advance account. Payments are not exported. The 5% VAT rate, OSS destination-VAT documents and customs imports are not supported by VASCO KN 2.1 and reject the export. Source data must contain product/service classifications and reconcilable tax and EUR amounts. Invalid or unsupported accounting data rejects the entire export with an actionable 422 error, as does a range with no exportable entries (no finalized issued or received documents with postings). The first export of a partner without a Slovenian 8-digit tax number assigns it a permanent VASCO partner code (100000000 upwards) that later exports reuse. Re-importing the same date range duplicates entries in VASCO; import each document once.
|
|
590
590
|
* @summary Export Slovenia VASCO accounting XML
|
|
591
591
|
*/
|
|
592
592
|
export type exportSloveniaVascoXmlResponse200 = {
|
|
@@ -627,7 +627,7 @@ export type exportSloveniaVascoXmlResponse = (exportSloveniaVascoXmlResponseSucc
|
|
|
627
627
|
export declare const getExportSloveniaVascoXmlUrl: () => string;
|
|
628
628
|
export declare const exportSloveniaVascoXml: (exportSloveniaVascoXmlBody: ExportSloveniaVascoXmlBody, options?: RequestInit) => Promise<exportSloveniaVascoXmlResponse>;
|
|
629
629
|
/**
|
|
630
|
-
* Download a ZIP of CSV files for QuickBooks Online import: `invoices.csv` (invoice import layout), `credit-notes.csv` (same layout, for manual entry because QuickBooks cannot import credit memos) and `bills.csv` (bill import layout, built from expenses). Includes finalized invoices, credit notes and expenses whose document date falls in the inclusive range; expenses without a document date use their received date. A voided invoice is included together with
|
|
630
|
+
* Download a ZIP of CSV files for QuickBooks Online import: `invoices.csv` (invoice import layout), `credit-notes.csv` (same layout, for manual entry because QuickBooks cannot import credit memos) and `bills.csv` (bill import layout, built from expenses). Includes finalized invoices, credit notes and expenses whose document date falls in the inclusive range; expenses without a document date use their received date. A voided invoice that has a credit note issued for it is included together with each such credit note, each on its own date. If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, the voided invoice is left out and its credit notes are exported alone. Voided invoices without a credit note, voided credit notes and voided expenses are excluded. Advance invoices are excluded because final invoices carry the full amount. Each line keeps the document currency and a tax-exclusive amount with its tax amount; the tax code column holds the rate (for example `22%`, or `22% RC` for reverse charge) for mapping to QuickBooks tax codes during import. Dates use DD/MM/YYYY, or MM/DD/YYYY for US entities. Bill lines use the line's financial category as the account, otherwise `Uncategorized Expense`. Files are split at 100 documents or 1,000 rows (for example `invoices-01.csv`, `invoices-02.csv`) to fit QuickBooks import limits; a set with no documents still contains a header-only file. QuickBooks-specific validation failures return 422 with a `cause.code`: `quickbooks_export_too_many_documents` (more than 10,000 documents in range), `quickbooks_export_unsupported_expense_type` (the range includes supplier credit notes or advance invoices), `quickbooks_export_document_too_many_lines` (a single document renders more than 1,000 rows and cannot be split without breaking its grouping on import), or `quickbooks_export_missing_exchange_rate` (a crypto-denominated document has neither converted amounts nor a stored exchange rate, so it cannot be converted to the entity currency). If the selected period contains an issued invoice with early-payment terms, or the entity has any early-payment discount-adjustment history, the export is unsupported and returns a message-only 422 with no `cause.code`.
|
|
631
631
|
* @summary Export QuickBooks Online import files
|
|
632
632
|
*/
|
|
633
633
|
export type exportQuickbooksCsvResponse200 = {
|
|
@@ -283,7 +283,7 @@ when a period has no applicable records, as required for a joint eDavki submissi
|
|
|
283
283
|
|
|
284
284
|
**Important:**
|
|
285
285
|
- KIR/KPR is available only to entities whose country code is `SI`
|
|
286
|
-
- Draft and deleted documents and voided credit notes are excluded. A voided invoice is excluded together with
|
|
286
|
+
- Draft and deleted documents and voided credit notes are excluded. A voided invoice is excluded together with a credit note issued for it if both fall in the same period, unless the credit note is linked to more than one voided invoice, in which case each document is reported in its own period. If that credit note falls in another period, the invoice is reported in its own period and the credit note in its own. A voided invoice without a credit note is excluded
|
|
287
287
|
- Domestic outgoing advances are included as separate KIR rows and their allocated net/VAT amounts are subtracted from the linked final invoice. For intra-EU B2B supplies, goods prepayments are omitted and not deducted; only the classified service component is reported in P10 and deducted from the final invoice. A fully prepaid reportable service still emits the final reconciliation row with P10 empty/zero
|
|
288
288
|
- Third-country outgoing documents use the persisted item tax treatment: bases with an explicit 0% tax row map to P7, while no-tax net amounts (including unrated summary bases) map to P27. Mixed documents are split between both fields. Product/service classification and customer geography are not substitutes for tax treatment; the legacy `export` transaction type remains an explicit goods-export marker and maps to P7
|
|
289
289
|
- An explicit 0% base on a domestic or intra-EU B2C outgoing document is an exempt supply without the right to deduct; it is reported in P9 and excluded from P7
|
|
@@ -545,7 +545,7 @@ export type exportSloveniaVodXmlResponse = (exportSloveniaVodXmlResponseSuccess
|
|
|
545
545
|
export declare const getExportSloveniaVodXmlUrl: () => string;
|
|
546
546
|
export declare const exportSloveniaVodXml: (exportSloveniaVodXmlBody: ExportSloveniaVodXmlBody, options?: RequestInit) => Promise<exportSloveniaVodXmlResponse>;
|
|
547
547
|
/**
|
|
548
|
-
* Download miniMAX XML for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range. A voided invoice is included together with
|
|
548
|
+
* Download miniMAX XML for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range. A voided invoice that has a credit note issued for it is included together with each such credit note, each on its own date, so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, the voided invoice is left out and its credit notes are exported alone. Voided invoices without a credit note, voided credit notes and voided advance invoices are excluded. Advances carry VAT records; linked final invoices reconcile previously reported VAT and settle the configured advance account. Bank/cash payments are booked separately. Source data must contain product/service classifications and reconcilable tax and EUR amounts. Invalid or unsupported accounting data rejects the entire export with an actionable 422 error. Re-importing the same date range may duplicate entries in miniMAX; import each document once.
|
|
549
549
|
* @summary Export Slovenia miniMAX accounting XML
|
|
550
550
|
*/
|
|
551
551
|
export type exportSloveniaMinimaxXmlResponse200 = {
|
|
@@ -586,7 +586,7 @@ export type exportSloveniaMinimaxXmlResponse = (exportSloveniaMinimaxXmlResponse
|
|
|
586
586
|
export declare const getExportSloveniaMinimaxXmlUrl: () => string;
|
|
587
587
|
export declare const exportSloveniaMinimaxXml: (exportSloveniaMinimaxXmlBody: ExportSloveniaMinimaxXmlBody, options?: RequestInit) => Promise<exportSloveniaMinimaxXmlResponse>;
|
|
588
588
|
/**
|
|
589
|
-
* Download a single windows-1250 VASCO KN 2.1 XML file (Prenos Verzija 2.1) for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range (the same selection as the miniMAX export: a voided invoice
|
|
589
|
+
* Download a single windows-1250 VASCO KN 2.1 XML file (Prenos Verzija 2.1) for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range (the same selection as the miniMAX export: a voided invoice that has a credit note issued for it is included together with each such credit note, unless it had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, in which case its credit notes are exported alone). Amounts are in EUR. Advance invoices carry their VAT-book records on a zero-amount advance-account entry; linked final invoices settle the advance account. Payments are not exported. The 5% VAT rate, OSS destination-VAT documents and customs imports are not supported by VASCO KN 2.1 and reject the export. Source data must contain product/service classifications and reconcilable tax and EUR amounts. Invalid or unsupported accounting data rejects the entire export with an actionable 422 error, as does a range with no exportable entries (no finalized issued or received documents with postings). The first export of a partner without a Slovenian 8-digit tax number assigns it a permanent VASCO partner code (100000000 upwards) that later exports reuse. Re-importing the same date range duplicates entries in VASCO; import each document once.
|
|
590
590
|
* @summary Export Slovenia VASCO accounting XML
|
|
591
591
|
*/
|
|
592
592
|
export type exportSloveniaVascoXmlResponse200 = {
|
|
@@ -627,7 +627,7 @@ export type exportSloveniaVascoXmlResponse = (exportSloveniaVascoXmlResponseSucc
|
|
|
627
627
|
export declare const getExportSloveniaVascoXmlUrl: () => string;
|
|
628
628
|
export declare const exportSloveniaVascoXml: (exportSloveniaVascoXmlBody: ExportSloveniaVascoXmlBody, options?: RequestInit) => Promise<exportSloveniaVascoXmlResponse>;
|
|
629
629
|
/**
|
|
630
|
-
* Download a ZIP of CSV files for QuickBooks Online import: `invoices.csv` (invoice import layout), `credit-notes.csv` (same layout, for manual entry because QuickBooks cannot import credit memos) and `bills.csv` (bill import layout, built from expenses). Includes finalized invoices, credit notes and expenses whose document date falls in the inclusive range; expenses without a document date use their received date. A voided invoice is included together with
|
|
630
|
+
* Download a ZIP of CSV files for QuickBooks Online import: `invoices.csv` (invoice import layout), `credit-notes.csv` (same layout, for manual entry because QuickBooks cannot import credit memos) and `bills.csv` (bill import layout, built from expenses). Includes finalized invoices, credit notes and expenses whose document date falls in the inclusive range; expenses without a document date use their received date. A voided invoice that has a credit note issued for it is included together with each such credit note, each on its own date. If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, the voided invoice is left out and its credit notes are exported alone. Voided invoices without a credit note, voided credit notes and voided expenses are excluded. Advance invoices are excluded because final invoices carry the full amount. Each line keeps the document currency and a tax-exclusive amount with its tax amount; the tax code column holds the rate (for example `22%`, or `22% RC` for reverse charge) for mapping to QuickBooks tax codes during import. Dates use DD/MM/YYYY, or MM/DD/YYYY for US entities. Bill lines use the line's financial category as the account, otherwise `Uncategorized Expense`. Files are split at 100 documents or 1,000 rows (for example `invoices-01.csv`, `invoices-02.csv`) to fit QuickBooks import limits; a set with no documents still contains a header-only file. QuickBooks-specific validation failures return 422 with a `cause.code`: `quickbooks_export_too_many_documents` (more than 10,000 documents in range), `quickbooks_export_unsupported_expense_type` (the range includes supplier credit notes or advance invoices), `quickbooks_export_document_too_many_lines` (a single document renders more than 1,000 rows and cannot be split without breaking its grouping on import), or `quickbooks_export_missing_exchange_rate` (a crypto-denominated document has neither converted amounts nor a stored exchange rate, so it cannot be converted to the entity currency). If the selected period contains an issued invoice with early-payment terms, or the entity has any early-payment discount-adjustment history, the export is unsupported and returns a message-only 422 with no `cause.code`.
|
|
631
631
|
* @summary Export QuickBooks Online import files
|
|
632
632
|
*/
|
|
633
633
|
export type exportQuickbooksCsvResponse200 = {
|
|
@@ -462,7 +462,7 @@ export declare const DeleteCustomerHeader: zod.ZodObject<{
|
|
|
462
462
|
}, zod.z.core.$strip>;
|
|
463
463
|
/**
|
|
464
464
|
* Which items, in what quantity and for what net amount were sold to this customer in a date range.
|
|
465
|
-
Counts finalized invoices and advance invoices that are not applied to a live invoice; credit notes are subtracted. Drafts, deleted documents, voided credit notes and voided advance invoices are excluded. A voided invoice is counted together with
|
|
465
|
+
Counts finalized invoices and advance invoices that are not applied to a live invoice; credit notes are subtracted. Drafts, deleted documents, voided credit notes and voided advance invoices are excluded. A voided invoice that has a credit note issued for it is counted together with each such credit note, so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, neither it nor its credit notes count. A voided invoice without a credit note counts as if it never happened.
|
|
466
466
|
Items are grouped by catalog item ID when available, or by case-insensitive name. Amounts are in entity currency, rows are ordered by gross amount (total_with_tax, highest first); totals.quantity_net is null when the items use different units. The period may span up to 20 years.
|
|
467
467
|
Also available for soft-deleted customers. To download the same data as a spreadsheet use the sales-per-item export with customer_id.
|
|
468
468
|
* @summary Get items sold to a customer
|
|
@@ -462,7 +462,7 @@ export declare const DeleteCustomerHeader: zod.ZodObject<{
|
|
|
462
462
|
}, zod.z.core.$strip>;
|
|
463
463
|
/**
|
|
464
464
|
* Which items, in what quantity and for what net amount were sold to this customer in a date range.
|
|
465
|
-
Counts finalized invoices and advance invoices that are not applied to a live invoice; credit notes are subtracted. Drafts, deleted documents, voided credit notes and voided advance invoices are excluded. A voided invoice is counted together with
|
|
465
|
+
Counts finalized invoices and advance invoices that are not applied to a live invoice; credit notes are subtracted. Drafts, deleted documents, voided credit notes and voided advance invoices are excluded. A voided invoice that has a credit note issued for it is counted together with each such credit note, so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, neither it nor its credit notes count. A voided invoice without a credit note counts as if it never happened.
|
|
466
466
|
Items are grouped by catalog item ID when available, or by case-insensitive name. Amounts are in entity currency, rows are ordered by gross amount (total_with_tax, highest first); totals.quantity_net is null when the items use different units. The period may span up to 20 years.
|
|
467
467
|
Also available for soft-deleted customers. To download the same data as a spreadsheet use the sales-per-item export with customer_id.
|
|
468
468
|
* @summary Get items sold to a customer
|
|
@@ -39,7 +39,7 @@ export declare const ExportDocumentsHeader: zod.ZodObject<{
|
|
|
39
39
|
* Export aggregated sales data per item (product/service) for a given date range.
|
|
40
40
|
Includes quantities sold/returned, average price, and totals.
|
|
41
41
|
Aggregates across invoices, credit notes, and advance invoices.
|
|
42
|
-
A voided invoice is counted together with
|
|
42
|
+
A voided invoice that has a credit note issued for it is counted together with each such credit note (sold and returned), so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, neither it nor its credit notes count. Voided invoices without a credit note are excluded.
|
|
43
43
|
Items are grouped by catalog item ID when available, or by exact name match.
|
|
44
44
|
* @summary Export sales per item for a period
|
|
45
45
|
*/
|
|
@@ -39,7 +39,7 @@ export declare const ExportDocumentsHeader: zod.ZodObject<{
|
|
|
39
39
|
* Export aggregated sales data per item (product/service) for a given date range.
|
|
40
40
|
Includes quantities sold/returned, average price, and totals.
|
|
41
41
|
Aggregates across invoices, credit notes, and advance invoices.
|
|
42
|
-
A voided invoice is counted together with
|
|
42
|
+
A voided invoice that has a credit note issued for it is counted together with each such credit note (sold and returned), so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, neither it nor its credit notes count. Voided invoices without a credit note are excluded.
|
|
43
43
|
Items are grouped by catalog item ID when available, or by exact name match.
|
|
44
44
|
* @summary Export sales per item for a period
|
|
45
45
|
*/
|
|
@@ -335,7 +335,7 @@ when a period has no applicable records, as required for a joint eDavki submissi
|
|
|
335
335
|
|
|
336
336
|
**Important:**
|
|
337
337
|
- KIR/KPR is available only to entities whose country code is `SI`
|
|
338
|
-
- Draft and deleted documents and voided credit notes are excluded. A voided invoice is excluded together with
|
|
338
|
+
- Draft and deleted documents and voided credit notes are excluded. A voided invoice is excluded together with a credit note issued for it if both fall in the same period, unless the credit note is linked to more than one voided invoice, in which case each document is reported in its own period. If that credit note falls in another period, the invoice is reported in its own period and the credit note in its own. A voided invoice without a credit note is excluded
|
|
339
339
|
- Domestic outgoing advances are included as separate KIR rows and their allocated net/VAT amounts are subtracted from the linked final invoice. For intra-EU B2B supplies, goods prepayments are omitted and not deducted; only the classified service component is reported in P10 and deducted from the final invoice. A fully prepaid reportable service still emits the final reconciliation row with P10 empty/zero
|
|
340
340
|
- Third-country outgoing documents use the persisted item tax treatment: bases with an explicit 0% tax row map to P7, while no-tax net amounts (including unrated summary bases) map to P27. Mixed documents are split between both fields. Product/service classification and customer geography are not substitutes for tax treatment; the legacy `export` transaction type remains an explicit goods-export marker and maps to P7
|
|
341
341
|
- An explicit 0% base on a domestic or intra-EU B2C outgoing document is an exempt supply without the right to deduct; it is reported in P9 and excluded from P7
|
|
@@ -879,7 +879,7 @@ export declare const ExportSloveniaVodXmlBody: zod.ZodObject<{
|
|
|
879
879
|
date_to: zod.z.ZodISODate;
|
|
880
880
|
}, zod.z.core.$strip>;
|
|
881
881
|
/**
|
|
882
|
-
* Download miniMAX XML for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range. A voided invoice is included together with
|
|
882
|
+
* Download miniMAX XML for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range. A voided invoice that has a credit note issued for it is included together with each such credit note, each on its own date, so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, the voided invoice is left out and its credit notes are exported alone. Voided invoices without a credit note, voided credit notes and voided advance invoices are excluded. Advances carry VAT records; linked final invoices reconcile previously reported VAT and settle the configured advance account. Bank/cash payments are booked separately. Source data must contain product/service classifications and reconcilable tax and EUR amounts. Invalid or unsupported accounting data rejects the entire export with an actionable 422 error. Re-importing the same date range may duplicate entries in miniMAX; import each document once.
|
|
883
883
|
* @summary Export Slovenia miniMAX accounting XML
|
|
884
884
|
*/
|
|
885
885
|
export declare const ExportSloveniaMinimaxXmlHeader: zod.ZodObject<{
|
|
@@ -890,7 +890,7 @@ export declare const ExportSloveniaMinimaxXmlBody: zod.ZodObject<{
|
|
|
890
890
|
date_to: zod.z.ZodISODate;
|
|
891
891
|
}, zod.z.core.$strip>;
|
|
892
892
|
/**
|
|
893
|
-
* Download a single windows-1250 VASCO KN 2.1 XML file (Prenos Verzija 2.1) for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range (the same selection as the miniMAX export: a voided invoice
|
|
893
|
+
* Download a single windows-1250 VASCO KN 2.1 XML file (Prenos Verzija 2.1) for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range (the same selection as the miniMAX export: a voided invoice that has a credit note issued for it is included together with each such credit note, unless it had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, in which case its credit notes are exported alone). Amounts are in EUR. Advance invoices carry their VAT-book records on a zero-amount advance-account entry; linked final invoices settle the advance account. Payments are not exported. The 5% VAT rate, OSS destination-VAT documents and customs imports are not supported by VASCO KN 2.1 and reject the export. Source data must contain product/service classifications and reconcilable tax and EUR amounts. Invalid or unsupported accounting data rejects the entire export with an actionable 422 error, as does a range with no exportable entries (no finalized issued or received documents with postings). The first export of a partner without a Slovenian 8-digit tax number assigns it a permanent VASCO partner code (100000000 upwards) that later exports reuse. Re-importing the same date range duplicates entries in VASCO; import each document once.
|
|
894
894
|
* @summary Export Slovenia VASCO accounting XML
|
|
895
895
|
*/
|
|
896
896
|
export declare const ExportSloveniaVascoXmlHeader: zod.ZodObject<{
|
|
@@ -901,7 +901,7 @@ export declare const ExportSloveniaVascoXmlBody: zod.ZodObject<{
|
|
|
901
901
|
date_to: zod.z.ZodISODate;
|
|
902
902
|
}, zod.z.core.$strip>;
|
|
903
903
|
/**
|
|
904
|
-
* Download a ZIP of CSV files for QuickBooks Online import: `invoices.csv` (invoice import layout), `credit-notes.csv` (same layout, for manual entry because QuickBooks cannot import credit memos) and `bills.csv` (bill import layout, built from expenses). Includes finalized invoices, credit notes and expenses whose document date falls in the inclusive range; expenses without a document date use their received date. A voided invoice is included together with
|
|
904
|
+
* Download a ZIP of CSV files for QuickBooks Online import: `invoices.csv` (invoice import layout), `credit-notes.csv` (same layout, for manual entry because QuickBooks cannot import credit memos) and `bills.csv` (bill import layout, built from expenses). Includes finalized invoices, credit notes and expenses whose document date falls in the inclusive range; expenses without a document date use their received date. A voided invoice that has a credit note issued for it is included together with each such credit note, each on its own date. If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, the voided invoice is left out and its credit notes are exported alone. Voided invoices without a credit note, voided credit notes and voided expenses are excluded. Advance invoices are excluded because final invoices carry the full amount. Each line keeps the document currency and a tax-exclusive amount with its tax amount; the tax code column holds the rate (for example `22%`, or `22% RC` for reverse charge) for mapping to QuickBooks tax codes during import. Dates use DD/MM/YYYY, or MM/DD/YYYY for US entities. Bill lines use the line's financial category as the account, otherwise `Uncategorized Expense`. Files are split at 100 documents or 1,000 rows (for example `invoices-01.csv`, `invoices-02.csv`) to fit QuickBooks import limits; a set with no documents still contains a header-only file. QuickBooks-specific validation failures return 422 with a `cause.code`: `quickbooks_export_too_many_documents` (more than 10,000 documents in range), `quickbooks_export_unsupported_expense_type` (the range includes supplier credit notes or advance invoices), `quickbooks_export_document_too_many_lines` (a single document renders more than 1,000 rows and cannot be split without breaking its grouping on import), or `quickbooks_export_missing_exchange_rate` (a crypto-denominated document has neither converted amounts nor a stored exchange rate, so it cannot be converted to the entity currency). If the selected period contains an issued invoice with early-payment terms, or the entity has any early-payment discount-adjustment history, the export is unsupported and returns a message-only 422 with no `cause.code`.
|
|
905
905
|
* @summary Export QuickBooks Online import files
|
|
906
906
|
*/
|
|
907
907
|
export declare const ExportQuickbooksCsvQueryParams: zod.ZodObject<{
|
|
@@ -335,7 +335,7 @@ when a period has no applicable records, as required for a joint eDavki submissi
|
|
|
335
335
|
|
|
336
336
|
**Important:**
|
|
337
337
|
- KIR/KPR is available only to entities whose country code is `SI`
|
|
338
|
-
- Draft and deleted documents and voided credit notes are excluded. A voided invoice is excluded together with
|
|
338
|
+
- Draft and deleted documents and voided credit notes are excluded. A voided invoice is excluded together with a credit note issued for it if both fall in the same period, unless the credit note is linked to more than one voided invoice, in which case each document is reported in its own period. If that credit note falls in another period, the invoice is reported in its own period and the credit note in its own. A voided invoice without a credit note is excluded
|
|
339
339
|
- Domestic outgoing advances are included as separate KIR rows and their allocated net/VAT amounts are subtracted from the linked final invoice. For intra-EU B2B supplies, goods prepayments are omitted and not deducted; only the classified service component is reported in P10 and deducted from the final invoice. A fully prepaid reportable service still emits the final reconciliation row with P10 empty/zero
|
|
340
340
|
- Third-country outgoing documents use the persisted item tax treatment: bases with an explicit 0% tax row map to P7, while no-tax net amounts (including unrated summary bases) map to P27. Mixed documents are split between both fields. Product/service classification and customer geography are not substitutes for tax treatment; the legacy `export` transaction type remains an explicit goods-export marker and maps to P7
|
|
341
341
|
- An explicit 0% base on a domestic or intra-EU B2C outgoing document is an exempt supply without the right to deduct; it is reported in P9 and excluded from P7
|
|
@@ -879,7 +879,7 @@ export declare const ExportSloveniaVodXmlBody: zod.ZodObject<{
|
|
|
879
879
|
date_to: zod.z.ZodISODate;
|
|
880
880
|
}, zod.z.core.$strip>;
|
|
881
881
|
/**
|
|
882
|
-
* Download miniMAX XML for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range. A voided invoice is included together with
|
|
882
|
+
* Download miniMAX XML for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range. A voided invoice that has a credit note issued for it is included together with each such credit note, each on its own date, so a full reversal nets to zero in the document currency (amounts converted at each document's own exchange rate can differ). If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, the voided invoice is left out and its credit notes are exported alone. Voided invoices without a credit note, voided credit notes and voided advance invoices are excluded. Advances carry VAT records; linked final invoices reconcile previously reported VAT and settle the configured advance account. Bank/cash payments are booked separately. Source data must contain product/service classifications and reconcilable tax and EUR amounts. Invalid or unsupported accounting data rejects the entire export with an actionable 422 error. Re-importing the same date range may duplicate entries in miniMAX; import each document once.
|
|
883
883
|
* @summary Export Slovenia miniMAX accounting XML
|
|
884
884
|
*/
|
|
885
885
|
export declare const ExportSloveniaMinimaxXmlHeader: zod.ZodObject<{
|
|
@@ -890,7 +890,7 @@ export declare const ExportSloveniaMinimaxXmlBody: zod.ZodObject<{
|
|
|
890
890
|
date_to: zod.z.ZodISODate;
|
|
891
891
|
}, zod.z.core.$strip>;
|
|
892
892
|
/**
|
|
893
|
-
* Download a single windows-1250 VASCO KN 2.1 XML file (Prenos Verzija 2.1) for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range (the same selection as the miniMAX export: a voided invoice
|
|
893
|
+
* Download a single windows-1250 VASCO KN 2.1 XML file (Prenos Verzija 2.1) for finalized issued and received invoices, credit notes and advance invoices in an inclusive document-date range (the same selection as the miniMAX export: a voided invoice that has a credit note issued for it is included together with each such credit note, unless it had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, in which case its credit notes are exported alone). Amounts are in EUR. Advance invoices carry their VAT-book records on a zero-amount advance-account entry; linked final invoices settle the advance account. Payments are not exported. The 5% VAT rate, OSS destination-VAT documents and customs imports are not supported by VASCO KN 2.1 and reject the export. Source data must contain product/service classifications and reconcilable tax and EUR amounts. Invalid or unsupported accounting data rejects the entire export with an actionable 422 error, as does a range with no exportable entries (no finalized issued or received documents with postings). The first export of a partner without a Slovenian 8-digit tax number assigns it a permanent VASCO partner code (100000000 upwards) that later exports reuse. Re-importing the same date range duplicates entries in VASCO; import each document once.
|
|
894
894
|
* @summary Export Slovenia VASCO accounting XML
|
|
895
895
|
*/
|
|
896
896
|
export declare const ExportSloveniaVascoXmlHeader: zod.ZodObject<{
|
|
@@ -901,7 +901,7 @@ export declare const ExportSloveniaVascoXmlBody: zod.ZodObject<{
|
|
|
901
901
|
date_to: zod.z.ZodISODate;
|
|
902
902
|
}, zod.z.core.$strip>;
|
|
903
903
|
/**
|
|
904
|
-
* Download a ZIP of CSV files for QuickBooks Online import: `invoices.csv` (invoice import layout), `credit-notes.csv` (same layout, for manual entry because QuickBooks cannot import credit memos) and `bills.csv` (bill import layout, built from expenses). Includes finalized invoices, credit notes and expenses whose document date falls in the inclusive range; expenses without a document date use their received date. A voided invoice is included together with
|
|
904
|
+
* Download a ZIP of CSV files for QuickBooks Online import: `invoices.csv` (invoice import layout), `credit-notes.csv` (same layout, for manual entry because QuickBooks cannot import credit memos) and `bills.csv` (bill import layout, built from expenses). Includes finalized invoices, credit notes and expenses whose document date falls in the inclusive range; expenses without a document date use their received date. A voided invoice that has a credit note issued for it is included together with each such credit note, each on its own date. If the invoice had an advance payment or advance invoice application (including removed ones) or a link with an advance invoice, the voided invoice is left out and its credit notes are exported alone. Voided invoices without a credit note, voided credit notes and voided expenses are excluded. Advance invoices are excluded because final invoices carry the full amount. Each line keeps the document currency and a tax-exclusive amount with its tax amount; the tax code column holds the rate (for example `22%`, or `22% RC` for reverse charge) for mapping to QuickBooks tax codes during import. Dates use DD/MM/YYYY, or MM/DD/YYYY for US entities. Bill lines use the line's financial category as the account, otherwise `Uncategorized Expense`. Files are split at 100 documents or 1,000 rows (for example `invoices-01.csv`, `invoices-02.csv`) to fit QuickBooks import limits; a set with no documents still contains a header-only file. QuickBooks-specific validation failures return 422 with a `cause.code`: `quickbooks_export_too_many_documents` (more than 10,000 documents in range), `quickbooks_export_unsupported_expense_type` (the range includes supplier credit notes or advance invoices), `quickbooks_export_document_too_many_lines` (a single document renders more than 1,000 rows and cannot be split without breaking its grouping on import), or `quickbooks_export_missing_exchange_rate` (a crypto-denominated document has neither converted amounts nor a stored exchange rate, so it cannot be converted to the entity currency). If the selected period contains an issued invoice with early-payment terms, or the entity has any early-payment discount-adjustment history, the export is unsupported and returns a message-only 422 with no `cause.code`.
|
|
905
905
|
* @summary Export QuickBooks Online import files
|
|
906
906
|
*/
|
|
907
907
|
export declare const ExportQuickbooksCsvQueryParams: zod.ZodObject<{
|
package/package.json
CHANGED