@invoicetronic/ts-sdk 1.2.0 → 1.3.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/api.ts CHANGED
@@ -15,6 +15,7 @@
15
15
 
16
16
 
17
17
  export * from './src/api/company-api';
18
+ export * from './src/api/export-api';
18
19
  export * from './src/api/log-api';
19
20
  export * from './src/api/receive-api';
20
21
  export * from './src/api/send-api';
package/dist/api.d.ts CHANGED
@@ -10,6 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  export * from './src/api/company-api';
13
+ export * from './src/api/export-api';
13
14
  export * from './src/api/log-api';
14
15
  export * from './src/api/receive-api';
15
16
  export * from './src/api/send-api';
package/dist/api.js CHANGED
@@ -28,6 +28,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
28
28
  };
29
29
  Object.defineProperty(exports, "__esModule", { value: true });
30
30
  __exportStar(require("./src/api/company-api"), exports);
31
+ __exportStar(require("./src/api/export-api"), exports);
31
32
  __exportStar(require("./src/api/log-api"), exports);
32
33
  __exportStar(require("./src/api/receive-api"), exports);
33
34
  __exportStar(require("./src/api/send-api"), exports);
package/dist/esm/api.d.ts CHANGED
@@ -10,6 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  export * from './src/api/company-api';
13
+ export * from './src/api/export-api';
13
14
  export * from './src/api/log-api';
14
15
  export * from './src/api/receive-api';
15
16
  export * from './src/api/send-api';
package/dist/esm/api.js CHANGED
@@ -12,6 +12,7 @@
12
12
  * Do not edit the class manually.
13
13
  */
14
14
  export * from './src/api/company-api';
15
+ export * from './src/api/export-api';
15
16
  export * from './src/api/log-api';
16
17
  export * from './src/api/receive-api';
17
18
  export * from './src/api/send-api';
@@ -0,0 +1,115 @@
1
+ /**
2
+ * Invoicetronic API
3
+ * The [Invoicetronic API][2] is a RESTful service that allows you to send and receive invoices through the Italian [Servizio di Interscambio (SDI)][1], or Interchange Service. The API is designed to be simple and easy to use, abstracting away SDI complexity while providing complete control over the invoice send/receive process. It provides advanced features as encryption at rest, multi-language pre-flight invoice validation, multiple upload formats, webhooks, event logging, client SDKs, and CLI tools. For more information, see [Invoicetronic website][2] [1]: https://www.fatturapa.gov.it/it/sistemainterscambio/cose-il-sdi/ [2]: https://invoicetronic.com/
4
+ *
5
+ * The version of the OpenAPI document: 1
6
+ * Contact: info@invoicetronic.com
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { Configuration } from '../../configuration';
13
+ import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
14
+ import { type RequestArgs, BaseAPI } from '../../base';
15
+ /**
16
+ * ExportApi - axios parameter creator
17
+ */
18
+ export declare const ExportApiAxiosParamCreator: (configuration?: Configuration) => {
19
+ /**
20
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
21
+ * @summary Export invoices as a ZIP archive
22
+ * @param {ExportGetTypeEnum} [type]
23
+ * @param {number} [companyId] Company id
24
+ * @param {number} [year]
25
+ * @param {number} [month]
26
+ * @param {number} [quarter]
27
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
28
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
29
+ * @param {*} [options] Override http request option.
30
+ * @throws {RequiredError}
31
+ */
32
+ exportGet: (type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
33
+ };
34
+ /**
35
+ * ExportApi - functional programming interface
36
+ */
37
+ export declare const ExportApiFp: (configuration?: Configuration) => {
38
+ /**
39
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
40
+ * @summary Export invoices as a ZIP archive
41
+ * @param {ExportGetTypeEnum} [type]
42
+ * @param {number} [companyId] Company id
43
+ * @param {number} [year]
44
+ * @param {number} [month]
45
+ * @param {number} [quarter]
46
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
47
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
48
+ * @param {*} [options] Override http request option.
49
+ * @throws {RequiredError}
50
+ */
51
+ exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
52
+ };
53
+ /**
54
+ * ExportApi - factory interface
55
+ */
56
+ export declare const ExportApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
57
+ /**
58
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
59
+ * @summary Export invoices as a ZIP archive
60
+ * @param {ExportGetTypeEnum} [type]
61
+ * @param {number} [companyId] Company id
62
+ * @param {number} [year]
63
+ * @param {number} [month]
64
+ * @param {number} [quarter]
65
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
66
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
67
+ * @param {*} [options] Override http request option.
68
+ * @throws {RequiredError}
69
+ */
70
+ exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): AxiosPromise<void>;
71
+ };
72
+ /**
73
+ * ExportApi - interface
74
+ */
75
+ export interface ExportApiInterface {
76
+ /**
77
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
78
+ * @summary Export invoices as a ZIP archive
79
+ * @param {ExportGetTypeEnum} [type]
80
+ * @param {number} [companyId] Company id
81
+ * @param {number} [year]
82
+ * @param {number} [month]
83
+ * @param {number} [quarter]
84
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
85
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
86
+ * @param {*} [options] Override http request option.
87
+ * @throws {RequiredError}
88
+ */
89
+ exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): AxiosPromise<void>;
90
+ }
91
+ /**
92
+ * ExportApi - object-oriented interface
93
+ */
94
+ export declare class ExportApi extends BaseAPI implements ExportApiInterface {
95
+ /**
96
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
97
+ * @summary Export invoices as a ZIP archive
98
+ * @param {ExportGetTypeEnum} [type]
99
+ * @param {number} [companyId] Company id
100
+ * @param {number} [year]
101
+ * @param {number} [month]
102
+ * @param {number} [quarter]
103
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
104
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
105
+ * @param {*} [options] Override http request option.
106
+ * @throws {RequiredError}
107
+ */
108
+ exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
109
+ }
110
+ export declare const ExportGetTypeEnum: {
111
+ readonly Send: "Send";
112
+ readonly Receive: "Receive";
113
+ readonly Both: "Both";
114
+ };
115
+ export type ExportGetTypeEnum = typeof ExportGetTypeEnum[keyof typeof ExportGetTypeEnum];
@@ -0,0 +1,179 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Invoicetronic API
5
+ * The [Invoicetronic API][2] is a RESTful service that allows you to send and receive invoices through the Italian [Servizio di Interscambio (SDI)][1], or Interchange Service. The API is designed to be simple and easy to use, abstracting away SDI complexity while providing complete control over the invoice send/receive process. It provides advanced features as encryption at rest, multi-language pre-flight invoice validation, multiple upload formats, webhooks, event logging, client SDKs, and CLI tools. For more information, see [Invoicetronic website][2] [1]: https://www.fatturapa.gov.it/it/sistemainterscambio/cose-il-sdi/ [2]: https://invoicetronic.com/
6
+ *
7
+ * The version of the OpenAPI document: 1
8
+ * Contact: info@invoicetronic.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
15
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
16
+ return new (P || (P = Promise))(function (resolve, reject) {
17
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
18
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
19
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
20
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
21
+ });
22
+ };
23
+ import globalAxios from 'axios';
24
+ // URLSearchParams not necessarily used
25
+ // @ts-ignore
26
+ import { URL } from 'url';
27
+ // Some imports not used depending on template conditions
28
+ // @ts-ignore
29
+ import { DUMMY_BASE_URL, setBasicAuthToObject, setSearchParams, toPathString, createRequestFunction } from '../../common';
30
+ // @ts-ignore
31
+ import { BASE_PATH, BaseAPI, operationServerMap } from '../../base';
32
+ /**
33
+ * ExportApi - axios parameter creator
34
+ */
35
+ export const ExportApiAxiosParamCreator = function (configuration) {
36
+ return {
37
+ /**
38
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
39
+ * @summary Export invoices as a ZIP archive
40
+ * @param {ExportGetTypeEnum} [type]
41
+ * @param {number} [companyId] Company id
42
+ * @param {number} [year]
43
+ * @param {number} [month]
44
+ * @param {number} [quarter]
45
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
46
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
47
+ * @param {*} [options] Override http request option.
48
+ * @throws {RequiredError}
49
+ */
50
+ exportGet: (type_1, companyId_1, year_1, month_1, quarter_1, documentDateFrom_1, documentDateTo_1, ...args_1) => __awaiter(this, [type_1, companyId_1, year_1, month_1, quarter_1, documentDateFrom_1, documentDateTo_1, ...args_1], void 0, function* (type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options = {}) {
51
+ const localVarPath = `/export`;
52
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
53
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
54
+ let baseOptions;
55
+ if (configuration) {
56
+ baseOptions = configuration.baseOptions;
57
+ }
58
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
59
+ const localVarHeaderParameter = {};
60
+ const localVarQueryParameter = {};
61
+ // authentication Basic required
62
+ // http basic authentication required
63
+ setBasicAuthToObject(localVarRequestOptions, configuration);
64
+ if (type !== undefined) {
65
+ localVarQueryParameter['type'] = type;
66
+ }
67
+ if (companyId !== undefined) {
68
+ localVarQueryParameter['company_id'] = companyId;
69
+ }
70
+ if (year !== undefined) {
71
+ localVarQueryParameter['year'] = year;
72
+ }
73
+ if (month !== undefined) {
74
+ localVarQueryParameter['month'] = month;
75
+ }
76
+ if (quarter !== undefined) {
77
+ localVarQueryParameter['quarter'] = quarter;
78
+ }
79
+ if (documentDateFrom !== undefined) {
80
+ localVarQueryParameter['document_date_from'] = (documentDateFrom instanceof Date) ?
81
+ documentDateFrom.toISOString() :
82
+ documentDateFrom;
83
+ }
84
+ if (documentDateTo !== undefined) {
85
+ localVarQueryParameter['document_date_to'] = (documentDateTo instanceof Date) ?
86
+ documentDateTo.toISOString() :
87
+ documentDateTo;
88
+ }
89
+ localVarHeaderParameter['Accept'] = 'application/problem+json';
90
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
91
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
92
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
93
+ return {
94
+ url: toPathString(localVarUrlObj),
95
+ options: localVarRequestOptions,
96
+ };
97
+ }),
98
+ };
99
+ };
100
+ /**
101
+ * ExportApi - functional programming interface
102
+ */
103
+ export const ExportApiFp = function (configuration) {
104
+ const localVarAxiosParamCreator = ExportApiAxiosParamCreator(configuration);
105
+ return {
106
+ /**
107
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
108
+ * @summary Export invoices as a ZIP archive
109
+ * @param {ExportGetTypeEnum} [type]
110
+ * @param {number} [companyId] Company id
111
+ * @param {number} [year]
112
+ * @param {number} [month]
113
+ * @param {number} [quarter]
114
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
115
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
116
+ * @param {*} [options] Override http request option.
117
+ * @throws {RequiredError}
118
+ */
119
+ exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options) {
120
+ return __awaiter(this, void 0, void 0, function* () {
121
+ var _a, _b, _c;
122
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options);
123
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
124
+ const localVarOperationServerBasePath = (_c = (_b = operationServerMap['ExportApi.exportGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
125
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
126
+ });
127
+ },
128
+ };
129
+ };
130
+ /**
131
+ * ExportApi - factory interface
132
+ */
133
+ export const ExportApiFactory = function (configuration, basePath, axios) {
134
+ const localVarFp = ExportApiFp(configuration);
135
+ return {
136
+ /**
137
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
138
+ * @summary Export invoices as a ZIP archive
139
+ * @param {ExportGetTypeEnum} [type]
140
+ * @param {number} [companyId] Company id
141
+ * @param {number} [year]
142
+ * @param {number} [month]
143
+ * @param {number} [quarter]
144
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
145
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
146
+ * @param {*} [options] Override http request option.
147
+ * @throws {RequiredError}
148
+ */
149
+ exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options) {
150
+ return localVarFp.exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options).then((request) => request(axios, basePath));
151
+ },
152
+ };
153
+ };
154
+ /**
155
+ * ExportApi - object-oriented interface
156
+ */
157
+ export class ExportApi extends BaseAPI {
158
+ /**
159
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
160
+ * @summary Export invoices as a ZIP archive
161
+ * @param {ExportGetTypeEnum} [type]
162
+ * @param {number} [companyId] Company id
163
+ * @param {number} [year]
164
+ * @param {number} [month]
165
+ * @param {number} [quarter]
166
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
167
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
168
+ * @param {*} [options] Override http request option.
169
+ * @throws {RequiredError}
170
+ */
171
+ exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options) {
172
+ return ExportApiFp(this.configuration).exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options).then((request) => request(this.axios, this.basePath));
173
+ }
174
+ }
175
+ export const ExportGetTypeEnum = {
176
+ Send: 'Send',
177
+ Receive: 'Receive',
178
+ Both: 'Both'
179
+ };
@@ -0,0 +1,115 @@
1
+ /**
2
+ * Invoicetronic API
3
+ * The [Invoicetronic API][2] is a RESTful service that allows you to send and receive invoices through the Italian [Servizio di Interscambio (SDI)][1], or Interchange Service. The API is designed to be simple and easy to use, abstracting away SDI complexity while providing complete control over the invoice send/receive process. It provides advanced features as encryption at rest, multi-language pre-flight invoice validation, multiple upload formats, webhooks, event logging, client SDKs, and CLI tools. For more information, see [Invoicetronic website][2] [1]: https://www.fatturapa.gov.it/it/sistemainterscambio/cose-il-sdi/ [2]: https://invoicetronic.com/
4
+ *
5
+ * The version of the OpenAPI document: 1
6
+ * Contact: info@invoicetronic.com
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { Configuration } from '../../configuration';
13
+ import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
14
+ import { type RequestArgs, BaseAPI } from '../../base';
15
+ /**
16
+ * ExportApi - axios parameter creator
17
+ */
18
+ export declare const ExportApiAxiosParamCreator: (configuration?: Configuration) => {
19
+ /**
20
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
21
+ * @summary Export invoices as a ZIP archive
22
+ * @param {ExportGetTypeEnum} [type]
23
+ * @param {number} [companyId] Company id
24
+ * @param {number} [year]
25
+ * @param {number} [month]
26
+ * @param {number} [quarter]
27
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
28
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
29
+ * @param {*} [options] Override http request option.
30
+ * @throws {RequiredError}
31
+ */
32
+ exportGet: (type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
33
+ };
34
+ /**
35
+ * ExportApi - functional programming interface
36
+ */
37
+ export declare const ExportApiFp: (configuration?: Configuration) => {
38
+ /**
39
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
40
+ * @summary Export invoices as a ZIP archive
41
+ * @param {ExportGetTypeEnum} [type]
42
+ * @param {number} [companyId] Company id
43
+ * @param {number} [year]
44
+ * @param {number} [month]
45
+ * @param {number} [quarter]
46
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
47
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
48
+ * @param {*} [options] Override http request option.
49
+ * @throws {RequiredError}
50
+ */
51
+ exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
52
+ };
53
+ /**
54
+ * ExportApi - factory interface
55
+ */
56
+ export declare const ExportApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
57
+ /**
58
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
59
+ * @summary Export invoices as a ZIP archive
60
+ * @param {ExportGetTypeEnum} [type]
61
+ * @param {number} [companyId] Company id
62
+ * @param {number} [year]
63
+ * @param {number} [month]
64
+ * @param {number} [quarter]
65
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
66
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
67
+ * @param {*} [options] Override http request option.
68
+ * @throws {RequiredError}
69
+ */
70
+ exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): AxiosPromise<void>;
71
+ };
72
+ /**
73
+ * ExportApi - interface
74
+ */
75
+ export interface ExportApiInterface {
76
+ /**
77
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
78
+ * @summary Export invoices as a ZIP archive
79
+ * @param {ExportGetTypeEnum} [type]
80
+ * @param {number} [companyId] Company id
81
+ * @param {number} [year]
82
+ * @param {number} [month]
83
+ * @param {number} [quarter]
84
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
85
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
86
+ * @param {*} [options] Override http request option.
87
+ * @throws {RequiredError}
88
+ */
89
+ exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): AxiosPromise<void>;
90
+ }
91
+ /**
92
+ * ExportApi - object-oriented interface
93
+ */
94
+ export declare class ExportApi extends BaseAPI implements ExportApiInterface {
95
+ /**
96
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
97
+ * @summary Export invoices as a ZIP archive
98
+ * @param {ExportGetTypeEnum} [type]
99
+ * @param {number} [companyId] Company id
100
+ * @param {number} [year]
101
+ * @param {number} [month]
102
+ * @param {number} [quarter]
103
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
104
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
105
+ * @param {*} [options] Override http request option.
106
+ * @throws {RequiredError}
107
+ */
108
+ exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
109
+ }
110
+ export declare const ExportGetTypeEnum: {
111
+ readonly Send: "Send";
112
+ readonly Receive: "Receive";
113
+ readonly Both: "Both";
114
+ };
115
+ export type ExportGetTypeEnum = typeof ExportGetTypeEnum[keyof typeof ExportGetTypeEnum];
@@ -0,0 +1,186 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Invoicetronic API
6
+ * The [Invoicetronic API][2] is a RESTful service that allows you to send and receive invoices through the Italian [Servizio di Interscambio (SDI)][1], or Interchange Service. The API is designed to be simple and easy to use, abstracting away SDI complexity while providing complete control over the invoice send/receive process. It provides advanced features as encryption at rest, multi-language pre-flight invoice validation, multiple upload formats, webhooks, event logging, client SDKs, and CLI tools. For more information, see [Invoicetronic website][2] [1]: https://www.fatturapa.gov.it/it/sistemainterscambio/cose-il-sdi/ [2]: https://invoicetronic.com/
7
+ *
8
+ * The version of the OpenAPI document: 1
9
+ * Contact: info@invoicetronic.com
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
16
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
17
+ return new (P || (P = Promise))(function (resolve, reject) {
18
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
19
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
20
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
21
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
22
+ });
23
+ };
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.ExportGetTypeEnum = exports.ExportApi = exports.ExportApiFactory = exports.ExportApiFp = exports.ExportApiAxiosParamCreator = void 0;
26
+ const axios_1 = require("axios");
27
+ // URLSearchParams not necessarily used
28
+ // @ts-ignore
29
+ const url_1 = require("url");
30
+ // Some imports not used depending on template conditions
31
+ // @ts-ignore
32
+ const common_1 = require("../../common");
33
+ // @ts-ignore
34
+ const base_1 = require("../../base");
35
+ /**
36
+ * ExportApi - axios parameter creator
37
+ */
38
+ const ExportApiAxiosParamCreator = function (configuration) {
39
+ return {
40
+ /**
41
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
42
+ * @summary Export invoices as a ZIP archive
43
+ * @param {ExportGetTypeEnum} [type]
44
+ * @param {number} [companyId] Company id
45
+ * @param {number} [year]
46
+ * @param {number} [month]
47
+ * @param {number} [quarter]
48
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
49
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
50
+ * @param {*} [options] Override http request option.
51
+ * @throws {RequiredError}
52
+ */
53
+ exportGet: (type_1, companyId_1, year_1, month_1, quarter_1, documentDateFrom_1, documentDateTo_1, ...args_1) => __awaiter(this, [type_1, companyId_1, year_1, month_1, quarter_1, documentDateFrom_1, documentDateTo_1, ...args_1], void 0, function* (type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options = {}) {
54
+ const localVarPath = `/export`;
55
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
56
+ const localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
57
+ let baseOptions;
58
+ if (configuration) {
59
+ baseOptions = configuration.baseOptions;
60
+ }
61
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
62
+ const localVarHeaderParameter = {};
63
+ const localVarQueryParameter = {};
64
+ // authentication Basic required
65
+ // http basic authentication required
66
+ (0, common_1.setBasicAuthToObject)(localVarRequestOptions, configuration);
67
+ if (type !== undefined) {
68
+ localVarQueryParameter['type'] = type;
69
+ }
70
+ if (companyId !== undefined) {
71
+ localVarQueryParameter['company_id'] = companyId;
72
+ }
73
+ if (year !== undefined) {
74
+ localVarQueryParameter['year'] = year;
75
+ }
76
+ if (month !== undefined) {
77
+ localVarQueryParameter['month'] = month;
78
+ }
79
+ if (quarter !== undefined) {
80
+ localVarQueryParameter['quarter'] = quarter;
81
+ }
82
+ if (documentDateFrom !== undefined) {
83
+ localVarQueryParameter['document_date_from'] = (documentDateFrom instanceof Date) ?
84
+ documentDateFrom.toISOString() :
85
+ documentDateFrom;
86
+ }
87
+ if (documentDateTo !== undefined) {
88
+ localVarQueryParameter['document_date_to'] = (documentDateTo instanceof Date) ?
89
+ documentDateTo.toISOString() :
90
+ documentDateTo;
91
+ }
92
+ localVarHeaderParameter['Accept'] = 'application/problem+json';
93
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
94
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
95
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
96
+ return {
97
+ url: (0, common_1.toPathString)(localVarUrlObj),
98
+ options: localVarRequestOptions,
99
+ };
100
+ }),
101
+ };
102
+ };
103
+ exports.ExportApiAxiosParamCreator = ExportApiAxiosParamCreator;
104
+ /**
105
+ * ExportApi - functional programming interface
106
+ */
107
+ const ExportApiFp = function (configuration) {
108
+ const localVarAxiosParamCreator = (0, exports.ExportApiAxiosParamCreator)(configuration);
109
+ return {
110
+ /**
111
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
112
+ * @summary Export invoices as a ZIP archive
113
+ * @param {ExportGetTypeEnum} [type]
114
+ * @param {number} [companyId] Company id
115
+ * @param {number} [year]
116
+ * @param {number} [month]
117
+ * @param {number} [quarter]
118
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
119
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
120
+ * @param {*} [options] Override http request option.
121
+ * @throws {RequiredError}
122
+ */
123
+ exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options) {
124
+ return __awaiter(this, void 0, void 0, function* () {
125
+ var _a, _b, _c;
126
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options);
127
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
128
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['ExportApi.exportGet']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
129
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
130
+ });
131
+ },
132
+ };
133
+ };
134
+ exports.ExportApiFp = ExportApiFp;
135
+ /**
136
+ * ExportApi - factory interface
137
+ */
138
+ const ExportApiFactory = function (configuration, basePath, axios) {
139
+ const localVarFp = (0, exports.ExportApiFp)(configuration);
140
+ return {
141
+ /**
142
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
143
+ * @summary Export invoices as a ZIP archive
144
+ * @param {ExportGetTypeEnum} [type]
145
+ * @param {number} [companyId] Company id
146
+ * @param {number} [year]
147
+ * @param {number} [month]
148
+ * @param {number} [quarter]
149
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
150
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
151
+ * @param {*} [options] Override http request option.
152
+ * @throws {RequiredError}
153
+ */
154
+ exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options) {
155
+ return localVarFp.exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options).then((request) => request(axios, basePath));
156
+ },
157
+ };
158
+ };
159
+ exports.ExportApiFactory = ExportApiFactory;
160
+ /**
161
+ * ExportApi - object-oriented interface
162
+ */
163
+ class ExportApi extends base_1.BaseAPI {
164
+ /**
165
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
166
+ * @summary Export invoices as a ZIP archive
167
+ * @param {ExportGetTypeEnum} [type]
168
+ * @param {number} [companyId] Company id
169
+ * @param {number} [year]
170
+ * @param {number} [month]
171
+ * @param {number} [quarter]
172
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
173
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
174
+ * @param {*} [options] Override http request option.
175
+ * @throws {RequiredError}
176
+ */
177
+ exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options) {
178
+ return (0, exports.ExportApiFp)(this.configuration).exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options).then((request) => request(this.axios, this.basePath));
179
+ }
180
+ }
181
+ exports.ExportApi = ExportApi;
182
+ exports.ExportGetTypeEnum = {
183
+ Send: 'Send',
184
+ Receive: 'Receive',
185
+ Both: 'Both'
186
+ };
@@ -0,0 +1,79 @@
1
+ # ExportApi
2
+
3
+ All URIs are relative to *http://localhost*
4
+
5
+ |Method | HTTP request | Description|
6
+ |------------- | ------------- | -------------|
7
+ |[**exportGet**](#exportget) | **GET** /export | Export invoices as a ZIP archive|
8
+
9
+ # **exportGet**
10
+ > exportGet()
11
+
12
+ Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
13
+
14
+ ### Example
15
+
16
+ ```typescript
17
+ import {
18
+ ExportApi,
19
+ Configuration
20
+ } from '@invoicetronic/ts-sdk';
21
+
22
+ const configuration = new Configuration();
23
+ const apiInstance = new ExportApi(configuration);
24
+
25
+ let type: 'Send' | 'Receive' | 'Both'; // (optional) (default to 'Both')
26
+ let companyId: number; //Company id (optional) (default to undefined)
27
+ let year: number; // (optional) (default to undefined)
28
+ let month: number; // (optional) (default to undefined)
29
+ let quarter: number; // (optional) (default to undefined)
30
+ let documentDateFrom: string; //UTC ISO 8601 (2024-11-29T12:34:56Z) (optional) (default to undefined)
31
+ let documentDateTo: string; //UTC ISO 8601 (2024-11-29T12:34:56Z) (optional) (default to undefined)
32
+
33
+ const { status, data } = await apiInstance.exportGet(
34
+ type,
35
+ companyId,
36
+ year,
37
+ month,
38
+ quarter,
39
+ documentDateFrom,
40
+ documentDateTo
41
+ );
42
+ ```
43
+
44
+ ### Parameters
45
+
46
+ |Name | Type | Description | Notes|
47
+ |------------- | ------------- | ------------- | -------------|
48
+ | **type** | [**&#39;Send&#39; | &#39;Receive&#39; | &#39;Both&#39;**]**Array<&#39;Send&#39; &#124; &#39;Receive&#39; &#124; &#39;Both&#39;>** | | (optional) defaults to 'Both'|
49
+ | **companyId** | [**number**] | Company id | (optional) defaults to undefined|
50
+ | **year** | [**number**] | | (optional) defaults to undefined|
51
+ | **month** | [**number**] | | (optional) defaults to undefined|
52
+ | **quarter** | [**number**] | | (optional) defaults to undefined|
53
+ | **documentDateFrom** | [**string**] | UTC ISO 8601 (2024-11-29T12:34:56Z) | (optional) defaults to undefined|
54
+ | **documentDateTo** | [**string**] | UTC ISO 8601 (2024-11-29T12:34:56Z) | (optional) defaults to undefined|
55
+
56
+
57
+ ### Return type
58
+
59
+ void (empty response body)
60
+
61
+ ### Authorization
62
+
63
+ [Basic](../README.md#Basic)
64
+
65
+ ### HTTP request headers
66
+
67
+ - **Content-Type**: Not defined
68
+ - **Accept**: application/problem+json
69
+
70
+
71
+ ### HTTP response details
72
+ | Status code | Description | Response headers |
73
+ |-------------|-------------|------------------|
74
+ |**200** | OK | - |
75
+ |**204** | No Content | - |
76
+ |**400** | Bad Request | - |
77
+
78
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
79
+
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@invoicetronic/ts-sdk",
3
- "version": "1.2.0",
3
+ "version": "1.3.0",
4
4
  "description": "OpenAPI client for @invoicetronic/ts-sdk",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "repository": {
@@ -0,0 +1,211 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Invoicetronic API
5
+ * The [Invoicetronic API][2] is a RESTful service that allows you to send and receive invoices through the Italian [Servizio di Interscambio (SDI)][1], or Interchange Service. The API is designed to be simple and easy to use, abstracting away SDI complexity while providing complete control over the invoice send/receive process. It provides advanced features as encryption at rest, multi-language pre-flight invoice validation, multiple upload formats, webhooks, event logging, client SDKs, and CLI tools. For more information, see [Invoicetronic website][2] [1]: https://www.fatturapa.gov.it/it/sistemainterscambio/cose-il-sdi/ [2]: https://invoicetronic.com/
6
+ *
7
+ * The version of the OpenAPI document: 1
8
+ * Contact: info@invoicetronic.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+
16
+ import type { Configuration } from '../../configuration';
17
+ import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
18
+ import globalAxios from 'axios';
19
+ // URLSearchParams not necessarily used
20
+ // @ts-ignore
21
+ import { URL, URLSearchParams } from 'url';
22
+ // Some imports not used depending on template conditions
23
+ // @ts-ignore
24
+ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction, replaceWithSerializableTypeIfNeeded } from '../../common';
25
+ // @ts-ignore
26
+ import { BASE_PATH, COLLECTION_FORMATS, type RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../../base';
27
+ // @ts-ignore
28
+ import type { ProblemDetails } from '../../src/models';
29
+ /**
30
+ * ExportApi - axios parameter creator
31
+ */
32
+ export const ExportApiAxiosParamCreator = function (configuration?: Configuration) {
33
+ return {
34
+ /**
35
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
36
+ * @summary Export invoices as a ZIP archive
37
+ * @param {ExportGetTypeEnum} [type]
38
+ * @param {number} [companyId] Company id
39
+ * @param {number} [year]
40
+ * @param {number} [month]
41
+ * @param {number} [quarter]
42
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
43
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
44
+ * @param {*} [options] Override http request option.
45
+ * @throws {RequiredError}
46
+ */
47
+ exportGet: async (type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
48
+ const localVarPath = `/export`;
49
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
50
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
51
+ let baseOptions;
52
+ if (configuration) {
53
+ baseOptions = configuration.baseOptions;
54
+ }
55
+
56
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
57
+ const localVarHeaderParameter = {} as any;
58
+ const localVarQueryParameter = {} as any;
59
+
60
+ // authentication Basic required
61
+ // http basic authentication required
62
+ setBasicAuthToObject(localVarRequestOptions, configuration)
63
+
64
+ if (type !== undefined) {
65
+ localVarQueryParameter['type'] = type;
66
+ }
67
+
68
+ if (companyId !== undefined) {
69
+ localVarQueryParameter['company_id'] = companyId;
70
+ }
71
+
72
+ if (year !== undefined) {
73
+ localVarQueryParameter['year'] = year;
74
+ }
75
+
76
+ if (month !== undefined) {
77
+ localVarQueryParameter['month'] = month;
78
+ }
79
+
80
+ if (quarter !== undefined) {
81
+ localVarQueryParameter['quarter'] = quarter;
82
+ }
83
+
84
+ if (documentDateFrom !== undefined) {
85
+ localVarQueryParameter['document_date_from'] = (documentDateFrom as any instanceof Date) ?
86
+ (documentDateFrom as any).toISOString() :
87
+ documentDateFrom;
88
+ }
89
+
90
+ if (documentDateTo !== undefined) {
91
+ localVarQueryParameter['document_date_to'] = (documentDateTo as any instanceof Date) ?
92
+ (documentDateTo as any).toISOString() :
93
+ documentDateTo;
94
+ }
95
+
96
+ localVarHeaderParameter['Accept'] = 'application/problem+json';
97
+
98
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
99
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
100
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
101
+
102
+ return {
103
+ url: toPathString(localVarUrlObj),
104
+ options: localVarRequestOptions,
105
+ };
106
+ },
107
+ }
108
+ };
109
+
110
+ /**
111
+ * ExportApi - functional programming interface
112
+ */
113
+ export const ExportApiFp = function(configuration?: Configuration) {
114
+ const localVarAxiosParamCreator = ExportApiAxiosParamCreator(configuration)
115
+ return {
116
+ /**
117
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
118
+ * @summary Export invoices as a ZIP archive
119
+ * @param {ExportGetTypeEnum} [type]
120
+ * @param {number} [companyId] Company id
121
+ * @param {number} [year]
122
+ * @param {number} [month]
123
+ * @param {number} [quarter]
124
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
125
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
126
+ * @param {*} [options] Override http request option.
127
+ * @throws {RequiredError}
128
+ */
129
+ async exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
130
+ const localVarAxiosArgs = await localVarAxiosParamCreator.exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options);
131
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
132
+ const localVarOperationServerBasePath = operationServerMap['ExportApi.exportGet']?.[localVarOperationServerIndex]?.url;
133
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
134
+ },
135
+ }
136
+ };
137
+
138
+ /**
139
+ * ExportApi - factory interface
140
+ */
141
+ export const ExportApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
142
+ const localVarFp = ExportApiFp(configuration)
143
+ return {
144
+ /**
145
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
146
+ * @summary Export invoices as a ZIP archive
147
+ * @param {ExportGetTypeEnum} [type]
148
+ * @param {number} [companyId] Company id
149
+ * @param {number} [year]
150
+ * @param {number} [month]
151
+ * @param {number} [quarter]
152
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
153
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
154
+ * @param {*} [options] Override http request option.
155
+ * @throws {RequiredError}
156
+ */
157
+ exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): AxiosPromise<void> {
158
+ return localVarFp.exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options).then((request) => request(axios, basePath));
159
+ },
160
+ };
161
+ };
162
+
163
+ /**
164
+ * ExportApi - interface
165
+ */
166
+ export interface ExportApiInterface {
167
+ /**
168
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
169
+ * @summary Export invoices as a ZIP archive
170
+ * @param {ExportGetTypeEnum} [type]
171
+ * @param {number} [companyId] Company id
172
+ * @param {number} [year]
173
+ * @param {number} [month]
174
+ * @param {number} [quarter]
175
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
176
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
177
+ * @param {*} [options] Override http request option.
178
+ * @throws {RequiredError}
179
+ */
180
+ exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig): AxiosPromise<void>;
181
+
182
+ }
183
+
184
+ /**
185
+ * ExportApi - object-oriented interface
186
+ */
187
+ export class ExportApi extends BaseAPI implements ExportApiInterface {
188
+ /**
189
+ * Export invoices as a ZIP archive of FatturaPA XML files, suitable for import into accounting software (TeamSystem, Zucchetti, etc.). **Sent invoices** are only included when they have reached a definitive state (e.g., `Consegnato` for private recipients, `AccettatoDalDestinatario`, `DecorrenzaTermini`, etc.). Invoices still being processed by SDI are excluded. **Received invoices** are always included. Unread invoices are automatically marked as read and counted as operations. ### Period filters You can filter by period using either: - `year` + `month` (e.g., `year=2026&month=3` for March 2026) - `year` + `quarter` (e.g., `year=2026&quarter=1` for Q1 Jan-Mar) - `document_date_from` / `document_date_to` for a custom date range These options are mutually exclusive. The `year` parameter alone is not valid and requires either `month` or `quarter`. ### Response Returns `200` with a ZIP archive, or `204 No Content` if no invoices match the given filters. Files in the archive are organized by company VAT number (`{vat}/send/`, `{vat}/receive/`). ### Rate limiting This endpoint has a dedicated rate limit: only one export request per user can be processed at a time. Concurrent requests will receive a `429 Too Many Requests` response.
190
+ * @summary Export invoices as a ZIP archive
191
+ * @param {ExportGetTypeEnum} [type]
192
+ * @param {number} [companyId] Company id
193
+ * @param {number} [year]
194
+ * @param {number} [month]
195
+ * @param {number} [quarter]
196
+ * @param {string} [documentDateFrom] UTC ISO 8601 (2024-11-29T12:34:56Z)
197
+ * @param {string} [documentDateTo] UTC ISO 8601 (2024-11-29T12:34:56Z)
198
+ * @param {*} [options] Override http request option.
199
+ * @throws {RequiredError}
200
+ */
201
+ public exportGet(type?: ExportGetTypeEnum, companyId?: number, year?: number, month?: number, quarter?: number, documentDateFrom?: string, documentDateTo?: string, options?: RawAxiosRequestConfig) {
202
+ return ExportApiFp(this.configuration).exportGet(type, companyId, year, month, quarter, documentDateFrom, documentDateTo, options).then((request) => request(this.axios, this.basePath));
203
+ }
204
+ }
205
+
206
+ export const ExportGetTypeEnum = {
207
+ Send: 'Send',
208
+ Receive: 'Receive',
209
+ Both: 'Both'
210
+ } as const;
211
+ export type ExportGetTypeEnum = typeof ExportGetTypeEnum[keyof typeof ExportGetTypeEnum];