@ramiidv/arca-mtxca 0.2.0 → 0.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/README.md +171 -318
- package/dist/arca-mtxca.d.ts +83 -75
- package/dist/arca-mtxca.d.ts.map +1 -1
- package/dist/arca-mtxca.js +197 -141
- package/dist/arca-mtxca.js.map +1 -1
- package/dist/constants.d.ts +37 -21
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +49 -22
- package/dist/constants.js.map +1 -1
- package/dist/format.d.ts +18 -0
- package/dist/format.d.ts.map +1 -0
- package/dist/format.js +65 -0
- package/dist/format.js.map +1 -0
- package/dist/index.d.ts +7 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +11 -10
- package/dist/index.js.map +1 -1
- package/dist/mtxca-client.d.ts +90 -32
- package/dist/mtxca-client.d.ts.map +1 -1
- package/dist/mtxca-client.js +416 -324
- package/dist/mtxca-client.js.map +1 -1
- package/dist/parse.d.ts +31 -0
- package/dist/parse.d.ts.map +1 -0
- package/dist/parse.js +82 -0
- package/dist/parse.js.map +1 -0
- package/dist/serialize.d.ts +43 -0
- package/dist/serialize.d.ts.map +1 -0
- package/dist/serialize.js +323 -0
- package/dist/serialize.js.map +1 -0
- package/dist/types.d.ts +314 -174
- package/dist/types.d.ts.map +1 -1
- package/dist/validation.d.ts +16 -7
- package/dist/validation.d.ts.map +1 -1
- package/dist/validation.js +292 -92
- package/dist/validation.js.map +1 -1
- package/llms.txt +81 -159
- package/package.json +4 -3
package/dist/types.d.ts
CHANGED
|
@@ -1,211 +1,351 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export interface ArcaMtxcaConfig {
|
|
4
|
-
/**
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
|
|
8
|
-
/** CUIT del contribuyente (sin guiones) */
|
|
9
|
-
cuit: number;
|
|
10
|
-
/** Usar entorno de produccion (default: false = testing/homologacion) */
|
|
11
|
-
production?: boolean;
|
|
12
|
-
/** Timeout para requests HTTP en milisegundos (default: 30000) */
|
|
13
|
-
timeout?: number;
|
|
14
|
-
/** Cantidad de reintentos en caso de error transitorio (default: 1) */
|
|
15
|
-
retries?: number;
|
|
16
|
-
/** Delay inicial entre reintentos en milisegundos, se duplica con cada intento (default: 1000) */
|
|
17
|
-
retryDelayMs?: number;
|
|
18
|
-
/** Callback para eventos del SDK (auth, requests, retries) */
|
|
19
|
-
onEvent?: (event: ArcaEvent) => void;
|
|
1
|
+
import type { ArcaBaseConfig, CallOptions } from '@ramiidv/arca-common';
|
|
2
|
+
export type { AccessTicket, ArcaEvent, CallOptions, LegacyTlsMode, ServerStatus, TicketStorage, } from '@ramiidv/arca-common';
|
|
3
|
+
export interface ArcaMtxcaConfig extends ArcaBaseConfig {
|
|
4
|
+
/** URL de WSMTXCA. Si se indica, ignora `production`. */
|
|
5
|
+
endpoint?: string;
|
|
6
|
+
/** URL de WSAA. Si se indica, ignora `production` para el login. */
|
|
7
|
+
wsaaEndpoint?: string;
|
|
20
8
|
}
|
|
9
|
+
/** Credenciales de cada request (`AuthRequestType`). */
|
|
21
10
|
export interface MtxcaAuth {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
11
|
+
token: string;
|
|
12
|
+
sign: string;
|
|
13
|
+
/** CUIT representada (11 dígitos). */
|
|
14
|
+
cuitRepresentada: string;
|
|
25
15
|
}
|
|
16
|
+
/**
|
|
17
|
+
* Fecha de un campo `xsd:date`: `Date` (se toma la fecha calendario de
|
|
18
|
+
* Argentina) o string `YYYY-MM-DD` / `YYYYMMDD`. Se envía como `YYYY-MM-DD`.
|
|
19
|
+
*/
|
|
20
|
+
export type FechaInput = Date | string;
|
|
21
|
+
/** `ItemType`. Los importes se redondean según el XSD antes de enviarse. */
|
|
26
22
|
export interface MtxcaItem {
|
|
27
|
-
/**
|
|
23
|
+
/** Unidades MTX (int >= 1). Obligatorio salvo unidad 97/99 (validación 500). */
|
|
24
|
+
unidadesMtx?: number;
|
|
25
|
+
/** Código MTX/GTIN. Obligatorio salvo unidad 97/99 (validación 503). */
|
|
26
|
+
codigoMtx?: string;
|
|
27
|
+
/** Código interno del producto (máx. 50). */
|
|
28
28
|
codigo?: string;
|
|
29
|
-
/**
|
|
29
|
+
/** Descripción (máx. 4000). */
|
|
30
30
|
descripcion: string;
|
|
31
|
-
/** Cantidad */
|
|
32
|
-
cantidad
|
|
33
|
-
/**
|
|
34
|
-
|
|
35
|
-
/**
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
/** Importe de IVA del item */
|
|
42
|
-
importeIVA: number;
|
|
43
|
-
/** Importe de bonificacion/descuento. Default: 0 */
|
|
31
|
+
/** Cantidad (6 decimales). No corresponde con unidad 97/99; obligatoria en el resto. */
|
|
32
|
+
cantidad?: number;
|
|
33
|
+
/** Código de unidad de medida (`getUnidadesMedida()`). */
|
|
34
|
+
codigoUnidadMedida: number;
|
|
35
|
+
/**
|
|
36
|
+
* Precio unitario (6 decimales). Sin IVA en clase A, con IVA en clase B.
|
|
37
|
+
* No corresponde con unidad 97/99; obligatorio en el resto.
|
|
38
|
+
*/
|
|
39
|
+
precioUnitario?: number;
|
|
40
|
+
/** Bonificación (6 decimales). No corresponde con unidad 97/99. */
|
|
44
41
|
importeBonificacion?: number;
|
|
42
|
+
/** Condición de IVA del ítem (`CodigoCondicionIVA`). */
|
|
43
|
+
codigoCondicionIVA: number;
|
|
44
|
+
/** IVA del ítem (2 decimales). Obligatorio en clase A (1, 2, 3, 51, 52, 53); no corresponde en 6, 7, 8. */
|
|
45
|
+
importeIVA?: number;
|
|
46
|
+
/** Importe del ítem con IVA incluido (2 decimales). Negativo en unidad 95/99. */
|
|
47
|
+
importeItem: number;
|
|
45
48
|
}
|
|
46
|
-
|
|
47
|
-
|
|
49
|
+
/** `SubtotalIVAType`: total de IVA de una alícuota (códigos 4, 5, 6). */
|
|
50
|
+
export interface MtxcaSubtotalIVA {
|
|
48
51
|
codigo: number;
|
|
49
|
-
|
|
52
|
+
importe: number;
|
|
53
|
+
}
|
|
54
|
+
/** `OtroTributoType`. */
|
|
55
|
+
export interface MtxcaOtroTributo {
|
|
56
|
+
/** Código de tributo (`getTiposTributo()`). */
|
|
57
|
+
codigo: number;
|
|
58
|
+
/** Obligatoria si `codigo` es 99. */
|
|
59
|
+
descripcion?: string;
|
|
50
60
|
baseImponible: number;
|
|
51
|
-
/** Importe de IVA */
|
|
52
61
|
importe: number;
|
|
53
62
|
}
|
|
63
|
+
/** `ComprobanteAsociadoType`. */
|
|
54
64
|
export interface MtxcaComprobanteAsociado {
|
|
55
|
-
/** Tipo de comprobante asociado */
|
|
56
65
|
codigoTipoComprobante: number;
|
|
57
|
-
/** Punto de venta del comprobante asociado */
|
|
58
66
|
numeroPuntoVenta: number;
|
|
59
|
-
/** Numero de comprobante asociado */
|
|
60
67
|
numeroComprobante: number;
|
|
61
|
-
|
|
62
|
-
|
|
68
|
+
cuit?: number | string;
|
|
69
|
+
fechaEmision?: FechaInput;
|
|
63
70
|
}
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
descripcion?: string;
|
|
69
|
-
/** Base imponible */
|
|
70
|
-
baseImponible: number;
|
|
71
|
-
/** Alicuota del tributo */
|
|
72
|
-
alicuota?: number;
|
|
73
|
-
/** Importe del tributo */
|
|
74
|
-
importe: number;
|
|
71
|
+
/** `PeriodoComprobantesAsociadosType`. */
|
|
72
|
+
export interface MtxcaPeriodo {
|
|
73
|
+
fechaDesde: FechaInput;
|
|
74
|
+
fechaHasta: FechaInput;
|
|
75
75
|
}
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
76
|
+
/** `DatoAdicionalType` (`getTiposDatosAdicionales()`). */
|
|
77
|
+
export interface MtxcaDatoAdicional {
|
|
78
|
+
t: number;
|
|
79
|
+
c1?: string;
|
|
80
|
+
c2?: string;
|
|
81
|
+
c3?: string;
|
|
82
|
+
c4?: string;
|
|
83
|
+
c5?: string;
|
|
84
|
+
c6?: string;
|
|
85
|
+
}
|
|
86
|
+
/** `CompradorType`. */
|
|
87
|
+
export interface MtxcaComprador {
|
|
88
|
+
codigoTipoDocumento: number;
|
|
89
|
+
numeroDocumento: number | string;
|
|
90
|
+
/** Porcentaje de titularidad (2 decimales). */
|
|
91
|
+
porcentaje: number;
|
|
92
|
+
}
|
|
93
|
+
/** Campos de `ComprobanteType` comunes a CAE, CAEA y ajustes de IVA. */
|
|
94
|
+
export interface MtxcaComprobanteBase {
|
|
95
|
+
codigoTipoComprobante: number;
|
|
96
|
+
numeroPuntoVenta: number;
|
|
97
|
+
/** Opcional: si no se envía, ARCA usa la fecha de proceso. */
|
|
98
|
+
fechaEmision?: FechaInput;
|
|
99
|
+
codigoTipoDocumento?: number;
|
|
100
|
+
numeroDocumento?: number | string;
|
|
101
|
+
/** Condición de IVA del receptor, RG 5616 (`getCondicionesIVAReceptor()`). */
|
|
102
|
+
condicionIVAReceptor?: number;
|
|
92
103
|
importeGravado?: number;
|
|
93
|
-
/** Importe no gravado */
|
|
94
104
|
importeNoGravado?: number;
|
|
95
|
-
/** Importe exento */
|
|
96
105
|
importeExento?: number;
|
|
97
|
-
/**
|
|
98
|
-
|
|
99
|
-
/** Importe total de tributos */
|
|
106
|
+
/** Gravado + no gravado + exento. */
|
|
107
|
+
importeSubtotal: number;
|
|
100
108
|
importeOtrosTributos?: number;
|
|
101
|
-
/** Detalle de tributos */
|
|
102
|
-
otrosTributos?: MtxcaTributo[];
|
|
103
|
-
/** Importe total del comprobante */
|
|
104
109
|
importeTotal: number;
|
|
105
|
-
/**
|
|
106
|
-
|
|
107
|
-
/**
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
fechaHasta?: string;
|
|
111
|
-
/** Fecha de vencimiento de pago (formato YYYY-MM-DD, requerido para servicios) */
|
|
112
|
-
fechaVtoPago?: string;
|
|
113
|
-
/** Observaciones */
|
|
110
|
+
/** Código de moneda (`Moneda` o `getMonedas()`). */
|
|
111
|
+
codigoMoneda: string;
|
|
112
|
+
/** Cotización (6 decimales). Debe ser 1 para PES. */
|
|
113
|
+
cotizacionMoneda?: number;
|
|
114
|
+
cancelaEnMismaMonedaExtranjera?: 'S' | 'N';
|
|
114
115
|
observaciones?: string;
|
|
116
|
+
codigoConcepto: number;
|
|
117
|
+
/** Obligatoria si `codigoConcepto` es 2 o 3. */
|
|
118
|
+
fechaServicioDesde?: FechaInput;
|
|
119
|
+
/** Obligatoria si `codigoConcepto` es 2 o 3. */
|
|
120
|
+
fechaServicioHasta?: FechaInput;
|
|
121
|
+
/** Obligatoria si `codigoConcepto` es 2 o 3. */
|
|
122
|
+
fechaVencimientoPago?: FechaInput;
|
|
123
|
+
comprobantesAsociados?: MtxcaComprobanteAsociado[];
|
|
124
|
+
periodoComprobantesAsociados?: MtxcaPeriodo;
|
|
125
|
+
otrosTributos?: MtxcaOtroTributo[];
|
|
126
|
+
items: MtxcaItem[];
|
|
127
|
+
subtotalesIVA?: MtxcaSubtotalIVA[];
|
|
128
|
+
datosAdicionales?: MtxcaDatoAdicional[];
|
|
129
|
+
compradores?: MtxcaComprador[];
|
|
130
|
+
/** Códigos de actividad (`getActividadesVigentes()`). */
|
|
131
|
+
actividades?: number[];
|
|
132
|
+
}
|
|
133
|
+
/** Comprobante a autorizar con CAE (`autorizarComprobante` / `autorizarAjusteIVA`), con número explícito. */
|
|
134
|
+
export interface MtxcaComprobanteCAE extends MtxcaComprobanteBase {
|
|
135
|
+
numeroComprobante: number;
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Request de `ArcaMtxca.autorizar()`. Si no se indica `numeroComprobante`, se
|
|
139
|
+
* usa el último autorizado + 1 (`consultarUltimoComprobanteAutorizado`).
|
|
140
|
+
*/
|
|
141
|
+
export interface AutorizarRequest extends MtxcaComprobanteBase {
|
|
142
|
+
numeroComprobante?: number;
|
|
143
|
+
}
|
|
144
|
+
/** Comprobante emitido con CAEA a informar (`informarComprobanteCAEA` / `informarAjusteIVACAEA`). */
|
|
145
|
+
export interface MtxcaComprobanteCAEA extends MtxcaComprobanteBase {
|
|
146
|
+
numeroComprobante: number;
|
|
147
|
+
/** CAEA usado (14 dígitos). Se envía como `codigoAutorizacion`. */
|
|
148
|
+
caea: string;
|
|
149
|
+
/** Opcional; si se informa debe ser "A". */
|
|
150
|
+
codigoTipoAutorizacion?: 'A';
|
|
151
|
+
/** Opcional; si se informa debe coincidir con la fecha hasta del CAEA. */
|
|
152
|
+
fechaVencimiento?: FechaInput;
|
|
153
|
+
/** Fecha/hora de generación: `Date` (hora de Argentina) o string `YYYY-MM-DDTHH:MM:SS`. */
|
|
154
|
+
fechaHoraGen?: Date | string;
|
|
115
155
|
}
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
invoice: MtxcaInvoice;
|
|
141
|
-
}
|
|
142
|
-
export interface MtxcaComprobante {
|
|
156
|
+
/** Opciones de `ArcaMtxca.autorizar()`. */
|
|
157
|
+
export interface AutorizarOptions extends CallOptions {
|
|
158
|
+
/**
|
|
159
|
+
* Valida localmente la coherencia de importes según las validaciones
|
|
160
|
+
* excluyentes del manual (default: true). Desactivalo solo si ARCA acepta
|
|
161
|
+
* un caso que esta validación rechaza.
|
|
162
|
+
*/
|
|
163
|
+
validarImportes?: boolean;
|
|
164
|
+
}
|
|
165
|
+
/** `CodigoDescripcionType`. */
|
|
166
|
+
export interface CodigoDescripcion {
|
|
167
|
+
codigo: number;
|
|
168
|
+
descripcion: string;
|
|
169
|
+
}
|
|
170
|
+
/** `CodigoDescripcionStringType` (monedas). */
|
|
171
|
+
export interface CodigoDescripcionString {
|
|
172
|
+
codigo: string;
|
|
173
|
+
descripcion: string;
|
|
174
|
+
}
|
|
175
|
+
/** Resultado de una autorización: A = aprobado, O = aprobado con observaciones, R = rechazado. */
|
|
176
|
+
export type MtxcaResultado = 'A' | 'O' | 'R';
|
|
177
|
+
/** `ComprobanteCAEResponseType`. */
|
|
178
|
+
export interface MtxcaComprobanteCAEResponse {
|
|
179
|
+
cuit: string;
|
|
143
180
|
codigoTipoComprobante: number;
|
|
144
181
|
numeroPuntoVenta: number;
|
|
145
182
|
numeroComprobante: number;
|
|
146
183
|
fechaEmision: string;
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
184
|
+
/** CAE (14 dígitos). */
|
|
185
|
+
cae: string;
|
|
186
|
+
fechaVencimientoCAE: string;
|
|
187
|
+
}
|
|
188
|
+
interface ResultadoBase {
|
|
189
|
+
/** Observaciones (en A no suele haber; en O explican por qué). */
|
|
190
|
+
observaciones: CodigoDescripcion[];
|
|
191
|
+
/** Motivos del rechazo (resultado R). */
|
|
192
|
+
errores: CodigoDescripcion[];
|
|
193
|
+
/** Anuncio informativo del sistema, si lo hay. */
|
|
194
|
+
evento?: CodigoDescripcion;
|
|
195
|
+
}
|
|
196
|
+
/**
|
|
197
|
+
* Respuesta de `autorizarComprobante` / `autorizarAjusteIVA`. Un rechazo NO
|
|
198
|
+
* lanza: devuelve `resultado: 'R'` con `errores`. Revisá `resultado` antes de
|
|
199
|
+
* usar `comprobante`.
|
|
200
|
+
*/
|
|
201
|
+
export type MtxcaAutorizarResult = (ResultadoBase & {
|
|
202
|
+
resultado: 'A' | 'O';
|
|
203
|
+
comprobante: MtxcaComprobanteCAEResponse;
|
|
204
|
+
}) | (ResultadoBase & {
|
|
205
|
+
resultado: 'R';
|
|
206
|
+
comprobante?: undefined;
|
|
207
|
+
});
|
|
208
|
+
/** `ComprobanteCAEAResponseType`. */
|
|
209
|
+
export interface MtxcaComprobanteCAEAResponse {
|
|
210
|
+
caea: string;
|
|
211
|
+
codigoTipoComprobante: number;
|
|
212
|
+
numeroPuntoVenta: number;
|
|
213
|
+
numeroComprobante: number;
|
|
214
|
+
}
|
|
215
|
+
/**
|
|
216
|
+
* Respuesta de `informarComprobanteCAEA` / `informarAjusteIVACAEA`. Un rechazo
|
|
217
|
+
* NO lanza: devuelve `resultado: 'R'` con `errores`.
|
|
218
|
+
*/
|
|
219
|
+
export type MtxcaInformarCAEAResult = (ResultadoBase & {
|
|
220
|
+
resultado: 'A' | 'O';
|
|
221
|
+
fechaProceso: string;
|
|
222
|
+
comprobante: MtxcaComprobanteCAEAResponse;
|
|
223
|
+
}) | (ResultadoBase & {
|
|
224
|
+
resultado: 'R';
|
|
225
|
+
fechaProceso?: string;
|
|
226
|
+
comprobante?: undefined;
|
|
227
|
+
});
|
|
228
|
+
/** `CAEAResponseType`. */
|
|
229
|
+
export interface MtxcaCAEA {
|
|
230
|
+
fechaProceso: string;
|
|
231
|
+
/** CAEA (14 dígitos). */
|
|
232
|
+
caea: string;
|
|
233
|
+
/** AAAAMM */
|
|
234
|
+
periodo: number;
|
|
235
|
+
/** 1 = primera quincena, 2 = segunda. */
|
|
236
|
+
orden: number;
|
|
237
|
+
fechaDesde: string;
|
|
238
|
+
fechaHasta: string;
|
|
239
|
+
fechaTopeInforme: string;
|
|
240
|
+
observaciones: CodigoDescripcion[];
|
|
241
|
+
}
|
|
242
|
+
/**
|
|
243
|
+
* Respuesta de `informarCAEANoUtilizado` / `informarCAEANoUtilizadoPtoVta`.
|
|
244
|
+
* Un rechazo NO lanza: devuelve `resultado: 'R'` con `errores`.
|
|
245
|
+
*/
|
|
246
|
+
export interface MtxcaCAEANoUtilizadoResult {
|
|
247
|
+
resultado: MtxcaResultado;
|
|
248
|
+
fechaProceso?: string;
|
|
249
|
+
caea?: string;
|
|
250
|
+
numeroPuntoVenta?: number;
|
|
251
|
+
errores: CodigoDescripcion[];
|
|
252
|
+
evento?: CodigoDescripcion;
|
|
253
|
+
}
|
|
254
|
+
/** Ítem tal como lo devuelve `consultarComprobante`. */
|
|
255
|
+
export interface MtxcaItemConsultado {
|
|
256
|
+
unidadesMtx?: number;
|
|
257
|
+
codigoMtx?: string;
|
|
258
|
+
codigo?: string;
|
|
259
|
+
descripcion: string;
|
|
260
|
+
cantidad?: number;
|
|
261
|
+
codigoUnidadMedida: number;
|
|
262
|
+
precioUnitario?: number;
|
|
263
|
+
importeBonificacion?: number;
|
|
264
|
+
codigoCondicionIVA: number;
|
|
265
|
+
importeIVA?: number;
|
|
266
|
+
importeItem: number;
|
|
267
|
+
}
|
|
268
|
+
/** `ComprobanteType` tal como lo devuelve `consultarComprobante`. */
|
|
269
|
+
export interface MtxcaComprobanteConsultado {
|
|
270
|
+
codigoTipoComprobante: number;
|
|
271
|
+
numeroPuntoVenta: number;
|
|
272
|
+
numeroComprobante: number;
|
|
273
|
+
fechaEmision?: string;
|
|
274
|
+
/** "E" = CAE, "A" = CAEA. */
|
|
275
|
+
codigoTipoAutorizacion?: string;
|
|
276
|
+
/** CAE o CAEA (14 dígitos). */
|
|
158
277
|
codigoAutorizacion?: string;
|
|
159
278
|
fechaVencimiento?: string;
|
|
160
|
-
|
|
161
|
-
|
|
279
|
+
codigoTipoDocumento?: number;
|
|
280
|
+
numeroDocumento?: string;
|
|
281
|
+
condicionIVAReceptor?: number;
|
|
282
|
+
importeGravado?: number;
|
|
283
|
+
importeNoGravado?: number;
|
|
284
|
+
importeExento?: number;
|
|
285
|
+
importeSubtotal: number;
|
|
286
|
+
importeOtrosTributos?: number;
|
|
287
|
+
importeTotal: number;
|
|
288
|
+
codigoMoneda: string;
|
|
289
|
+
cotizacionMoneda?: number;
|
|
290
|
+
cancelaEnMismaMonedaExtranjera?: string;
|
|
291
|
+
observaciones?: string;
|
|
292
|
+
codigoConcepto: number;
|
|
293
|
+
fechaServicioDesde?: string;
|
|
294
|
+
fechaServicioHasta?: string;
|
|
295
|
+
fechaVencimientoPago?: string;
|
|
296
|
+
fechaHoraGen?: string;
|
|
297
|
+
comprobantesAsociados: Array<{
|
|
298
|
+
codigoTipoComprobante: number;
|
|
299
|
+
numeroPuntoVenta: number;
|
|
300
|
+
numeroComprobante: number;
|
|
301
|
+
cuit?: string;
|
|
302
|
+
fechaEmision?: string;
|
|
303
|
+
}>;
|
|
304
|
+
periodoComprobantesAsociados?: {
|
|
305
|
+
fechaDesde: string;
|
|
306
|
+
fechaHasta: string;
|
|
307
|
+
};
|
|
308
|
+
otrosTributos: Array<{
|
|
309
|
+
codigo: number;
|
|
310
|
+
descripcion?: string;
|
|
311
|
+
baseImponible: number;
|
|
312
|
+
importe: number;
|
|
313
|
+
}>;
|
|
314
|
+
items: MtxcaItemConsultado[];
|
|
315
|
+
subtotalesIVA: MtxcaSubtotalIVA[];
|
|
316
|
+
datosAdicionales: MtxcaDatoAdicional[];
|
|
317
|
+
compradores: Array<{
|
|
318
|
+
codigoTipoDocumento: number;
|
|
319
|
+
numeroDocumento: string;
|
|
320
|
+
porcentaje: number;
|
|
321
|
+
}>;
|
|
322
|
+
actividades: number[];
|
|
323
|
+
}
|
|
324
|
+
/** Respuesta de `consultarComprobante`. */
|
|
325
|
+
export interface MtxcaConsultaComprobanteResult {
|
|
326
|
+
comprobante: MtxcaComprobanteConsultado;
|
|
327
|
+
observaciones: CodigoDescripcion[];
|
|
328
|
+
evento?: CodigoDescripcion;
|
|
329
|
+
}
|
|
330
|
+
/** `PuntoVentaType`. */
|
|
331
|
+
export interface PuntoVenta {
|
|
332
|
+
numeroPuntoVenta: number;
|
|
333
|
+
/** "S" o "N". */
|
|
334
|
+
bloqueado: string;
|
|
335
|
+
fechaBaja?: string;
|
|
162
336
|
}
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
/** Fecha vigencia desde */
|
|
169
|
-
FchDesde?: string;
|
|
170
|
-
/** Fecha vigencia hasta */
|
|
171
|
-
FchHasta?: string;
|
|
172
|
-
}
|
|
173
|
-
export interface MonedaItem {
|
|
174
|
-
/** Codigo de moneda (ej: "PES", "DOL") */
|
|
175
|
-
Id: string;
|
|
176
|
-
/** Descripcion */
|
|
177
|
-
Desc: string;
|
|
178
|
-
/** Fecha vigencia desde */
|
|
179
|
-
FchDesde?: string;
|
|
180
|
-
/** Fecha vigencia hasta */
|
|
181
|
-
FchHasta?: string;
|
|
182
|
-
}
|
|
183
|
-
export interface UnidadMedidaItem {
|
|
184
|
-
/** Codigo de unidad de medida */
|
|
185
|
-
Id: number;
|
|
186
|
-
/** Descripcion */
|
|
187
|
-
Desc: string;
|
|
188
|
-
/** Fecha vigencia desde */
|
|
189
|
-
FchDesde?: string;
|
|
190
|
-
/** Fecha vigencia hasta */
|
|
191
|
-
FchHasta?: string;
|
|
192
|
-
}
|
|
193
|
-
export interface PtoVentaItem {
|
|
194
|
-
/** Numero de punto de venta */
|
|
195
|
-
Nro: number;
|
|
196
|
-
/** Tipo de emision (CAE/CAEA) */
|
|
197
|
-
EmisionTipo: string;
|
|
198
|
-
/** Si esta bloqueado */
|
|
199
|
-
Bloqueado: string;
|
|
200
|
-
/** Fecha de baja */
|
|
201
|
-
FchBaja: string;
|
|
337
|
+
/** `ActividadVigenteType`. */
|
|
338
|
+
export interface ActividadVigente {
|
|
339
|
+
codigo: number;
|
|
340
|
+
orden: number;
|
|
341
|
+
descripcion: string;
|
|
202
342
|
}
|
|
343
|
+
/** Respuesta de `consultarCotizacionMoneda`. */
|
|
203
344
|
export interface CotizacionResult {
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
/** Cotizacion */
|
|
207
|
-
cotizacion: number;
|
|
208
|
-
/** Fecha de cotizacion */
|
|
345
|
+
codigoMoneda: string;
|
|
346
|
+
/** Fecha consultada (YYYY-MM-DD). */
|
|
209
347
|
fechaCotizacion: string;
|
|
348
|
+
/** Cotización, o `null` si ARCA no tiene cotización para esa moneda (respuesta sin valor, sin error). */
|
|
349
|
+
cotizacion: number | null;
|
|
210
350
|
}
|
|
211
351
|
//# sourceMappingURL=types.d.ts.map
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAGxE,YAAY,EACV,YAAY,EACZ,SAAS,EACT,WAAW,EACX,aAAa,EACb,YAAY,EACZ,aAAa,GACd,MAAM,sBAAsB,CAAC;AAM9B,MAAM,WAAW,eAAgB,SAAQ,cAAc;IACrD,yDAAyD;IACzD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,oEAAoE;IACpE,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,wDAAwD;AACxD,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,sCAAsC;IACtC,gBAAgB,EAAE,MAAM,CAAC;CAC1B;AAED;;;GAGG;AACH,MAAM,MAAM,UAAU,GAAG,IAAI,GAAG,MAAM,CAAC;AAMvC,4EAA4E;AAC5E,MAAM,WAAW,SAAS;IACxB,gFAAgF;IAChF,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,wEAAwE;IACxE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,6CAA6C;IAC7C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,+BAA+B;IAC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A;KAAE,CAAC,CAAC;IACvG,KAAK,EAAE,mBAAmB,EAAE,CAAC;IAC7B,aAAa,EAAE,gBAAgB,EAAE,CAAC;IAClC,gBAAgB,EAAE,kBAAkB,EAAE,CAAC;IACvC,WAAW,EAAE,KAAK,CAAC;QAAE,mBAAmB,EAAE,MAAM,CAAC;QAAC,eAAe,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IACjG,WAAW,EAAE,MAAM,EAAE,CAAC;CACvB;AAED,2CAA2C;AAC3C,MAAM,WAAW,8BAA8B;IAC7C,WAAW,EAAE,0BAA0B,CAAC;IACxC,aAAa,EAAE,iBAAiB,EAAE,CAAC;IACnC,MAAM,CAAC,EAAE,iBAAiB,CAAC;CAC5B;AAED,wBAAwB;AACxB,MAAM,WAAW,UAAU;IACzB,gBAAgB,EAAE,MAAM,CAAC;IACzB,iBAAiB;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,8BAA8B;AAC9B,MAAM,WAAW,gBAAgB;IAC/B,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,gDAAgD;AAChD,MAAM,WAAW,gBAAgB;IAC/B,YAAY,EAAE,MAAM,CAAC;IACrB,qCAAqC;IACrC,eAAe,EAAE,MAAM,CAAC;IACxB,yGAAyG;IACzG,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;CAC3B"}
|
package/dist/validation.d.ts
CHANGED
|
@@ -1,14 +1,23 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { MtxcaComprobanteBase } from './types.js';
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
3
|
+
* Valida las reglas de ítems que el manual marca como excluyentes para
|
|
4
|
+
* `informarComprobanteCAEA` (1100-1112, 1121) y el par tipo/número de documento (707).
|
|
4
5
|
*
|
|
5
|
-
* @throws ArcaValidationError
|
|
6
|
+
* @throws ArcaValidationError
|
|
6
7
|
*/
|
|
7
|
-
export declare function
|
|
8
|
+
export declare function validateComprobanteCAEA(c: MtxcaComprobanteBase): void;
|
|
8
9
|
/**
|
|
9
|
-
*
|
|
10
|
+
* Valida un comprobante a autorizar con CAE (`autorizarComprobante`) según
|
|
11
|
+
* las validaciones excluyentes del manual: presencia de campos por unidad de
|
|
12
|
+
* medida y tipo de comprobante, fórmulas de importe e IVA por ítem, subtotales
|
|
13
|
+
* de IVA por alícuota y la coherencia de gravado/no gravado/exento/subtotal/
|
|
14
|
+
* otros tributos/total, con el margen de error del manual. Usa los importes ya
|
|
15
|
+
* redondeados como se envían (2 decimales; 6 en cantidad y precio).
|
|
10
16
|
*
|
|
11
|
-
*
|
|
17
|
+
* No reemplaza las validaciones de padrón que hace ARCA (CUIT activa, punto de
|
|
18
|
+
* venta habilitado, correlatividad, etc.).
|
|
19
|
+
*
|
|
20
|
+
* @throws ArcaValidationError con todos los errores encontrados.
|
|
12
21
|
*/
|
|
13
|
-
export declare function
|
|
22
|
+
export declare function validateComprobanteCAE(c: MtxcaComprobanteBase): void;
|
|
14
23
|
//# sourceMappingURL=validation.d.ts.map
|
package/dist/validation.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validation.d.ts","sourceRoot":"","sources":["../src/validation.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"validation.d.ts","sourceRoot":"","sources":["../src/validation.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAc,oBAAoB,EAAa,MAAM,YAAY,CAAC;AA4F9E;;;;;GAKG;AACH,wBAAgB,uBAAuB,CAAC,CAAC,EAAE,oBAAoB,GAAG,IAAI,CAOrE;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,sBAAsB,CAAC,CAAC,EAAE,oBAAoB,GAAG,IAAI,CA8LpE"}
|