@vitrina/api 17.22.1 → 17.24.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.cts +100 -6
- package/dist/index.d.ts +100 -6
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -94395,7 +94395,7 @@ interface paths {
|
|
|
94395
94395
|
};
|
|
94396
94396
|
/**
|
|
94397
94397
|
* Producción, cobrado y boleteado (clinics)
|
|
94398
|
-
* @description The clinic’s bridge per month and for the range: **producción** (treatments performed), **cobrado** (patient payments received) and **boleteado** (boletas DTE 39/41 issued, at totals, minus notas de crédito on boletas), with **por cobrar** (produced, not paid) and **anticipos** (paid, not produced) per patient, so that producción − por cobrar + anticipos = cobrado; the range column nets per patient. Clinic money authority: a clinic mirrored from Dentalink/Medilink reads producción and cobrado only from the mirror (`source: clinic_mirror`), otherwise from Vitrina’s registers; bank movements are never income. Boletas are checked against payments both ways (`payments_without_boleta`, `boletas_without_payment`): first the link the clinic system holds, then a boleta to the payment’s own patient, then a monthly summary boleta (to the generic receiver 66.666.666-6 or to nobody, named by no payment) covers its month’s remaining payments (`monthly_boletas`). `ingresos_resultado_clp` is the Resultado’s income for the same months, to read next to it. A caller without the patient roster sees «Paciente A. P.» and no RUT. Other verticals answer `is_clinic: false` with empty figures. Requires the `finanzas` add-on — without it every Finanzas operation answers `402 ENTITLEMENT_NOT_ACTIVE` (`details.required = ["finanzas"]`). Requires `finanzas_reports:read`.
|
|
94398
|
+
* @description The clinic’s bridge per month and for the range: **producción** (treatments performed), **cobrado** (patient payments received) and **boleteado** (boletas DTE 39/41 issued, at totals, minus notas de crédito on boletas), with **por cobrar** (produced, not paid) and **anticipos** (paid, not produced) per patient, so that producción − por cobrar + anticipos = cobrado; the range column nets per patient. Clinic money authority: a clinic mirrored from Dentalink/Medilink reads producción and cobrado only from the mirror (`source: clinic_mirror`), otherwise from Vitrina’s registers; bank movements are never income. Boletas are checked against payments both ways (`payments_without_boleta`, `boletas_without_payment`): first the link the clinic system holds, then a boleta to the payment’s own patient, then a monthly summary boleta (to the generic receiver 66.666.666-6 or to nobody, named by no payment) covers its month’s remaining payments (`monthly_boletas`); a month’s leftover is then covered by what the NEXT month’s summary has left (month-end cash is billed in the next summary), shown as the signed `boleteado_otro_mes_clp`, and a leftover whose next summary is not issued yet is `resumen_pendiente`, not a gap. `payments_without_boleta` is also grouped `by_month` (`per_month` items each); `sin_boleta_month` lists one month completely. `ingresos_resultado_clp` is the Resultado’s income for the same months, to read next to it. A caller without the patient roster sees «Paciente A. P.» and no RUT. Other verticals answer `is_clinic: false` with empty figures. Requires the `finanzas` add-on — without it every Finanzas operation answers `402 ENTITLEMENT_NOT_ACTIVE` (`details.required = ["finanzas"]`). Requires `finanzas_reports:read`.
|
|
94399
94399
|
*/
|
|
94400
94400
|
get: {
|
|
94401
94401
|
parameters: {
|
|
@@ -94403,6 +94403,8 @@ interface paths {
|
|
|
94403
94403
|
from?: string;
|
|
94404
94404
|
to?: string;
|
|
94405
94405
|
limit?: number;
|
|
94406
|
+
per_month?: number;
|
|
94407
|
+
sin_boleta_month?: string;
|
|
94406
94408
|
};
|
|
94407
94409
|
header?: never;
|
|
94408
94410
|
path?: never;
|
|
@@ -94438,7 +94440,11 @@ interface paths {
|
|
|
94438
94440
|
* "anticipos_clp": 1820000,
|
|
94439
94441
|
* "cobrado_sin_boleta_clp": 478076,
|
|
94440
94442
|
* "boletas_sin_pago_clp": 0,
|
|
94441
|
-
* "ingresos_resultado_clp": 57726146
|
|
94443
|
+
* "ingresos_resultado_clp": 57726146,
|
|
94444
|
+
* "pagos_sin_boleta": 3,
|
|
94445
|
+
* "pendiente_resumen_clp": 0,
|
|
94446
|
+
* "pagos_pendiente_resumen": 0,
|
|
94447
|
+
* "boleteado_otro_mes_clp": 0
|
|
94442
94448
|
* }
|
|
94443
94449
|
* ],
|
|
94444
94450
|
* "total": {
|
|
@@ -94449,7 +94455,11 @@ interface paths {
|
|
|
94449
94455
|
* "anticipos_clp": 1820000,
|
|
94450
94456
|
* "cobrado_sin_boleta_clp": 478076,
|
|
94451
94457
|
* "boletas_sin_pago_clp": 0,
|
|
94452
|
-
* "ingresos_resultado_clp": 57726146
|
|
94458
|
+
* "ingresos_resultado_clp": 57726146,
|
|
94459
|
+
* "pagos_sin_boleta": 3,
|
|
94460
|
+
* "pendiente_resumen_clp": 0,
|
|
94461
|
+
* "pagos_pendiente_resumen": 0,
|
|
94462
|
+
* "boleteado_otro_mes_clp": 0
|
|
94453
94463
|
* },
|
|
94454
94464
|
* "payments_without_boleta": {
|
|
94455
94465
|
* "count": 3,
|
|
@@ -94469,6 +94479,29 @@ interface paths {
|
|
|
94469
94479
|
* "rut": null
|
|
94470
94480
|
* }
|
|
94471
94481
|
* }
|
|
94482
|
+
* ],
|
|
94483
|
+
* "by_month": [
|
|
94484
|
+
* {
|
|
94485
|
+
* "month": "2026-10",
|
|
94486
|
+
* "count": 3,
|
|
94487
|
+
* "total_clp": 478076,
|
|
94488
|
+
* "items": [
|
|
94489
|
+
* {
|
|
94490
|
+
* "payment_id": "0190a3c2-5d1e-7b6a-9f20-4c1d2e3f7101",
|
|
94491
|
+
* "source": "clinic_mirror",
|
|
94492
|
+
* "day": "2026-10-31",
|
|
94493
|
+
* "amount_clp": 250000,
|
|
94494
|
+
* "without_boleta_clp": 250000,
|
|
94495
|
+
* "reason": "sin_boleta",
|
|
94496
|
+
* "folios": [],
|
|
94497
|
+
* "patient": {
|
|
94498
|
+
* "id": "0190a3c2-5d1e-7b6a-9f20-4c1d2e3f7301",
|
|
94499
|
+
* "name": "Paciente A. P.",
|
|
94500
|
+
* "rut": null
|
|
94501
|
+
* }
|
|
94502
|
+
* }
|
|
94503
|
+
* ]
|
|
94504
|
+
* }
|
|
94472
94505
|
* ]
|
|
94473
94506
|
* },
|
|
94474
94507
|
* "boletas_without_payment": {
|
|
@@ -284312,6 +284345,16 @@ interface components {
|
|
|
284312
284345
|
/** @description The missing recurring account (`recurring_cost_missing`), else null. */
|
|
284313
284346
|
account_name: string | null;
|
|
284314
284347
|
} | null;
|
|
284348
|
+
/** @description Recurring fixed costs not booked yet in this closed month, at their usual amount (the sum of `fijos_faltantes`). Already inside `equilibrio_clp`; never inside `fijos_clp` or `resultado_clp`. 0 on a proforma month. */
|
|
284349
|
+
fijos_faltantes_clp: number;
|
|
284350
|
+
/** @description The accounts behind `fijos_faltantes_clp`, usual amount descending. */
|
|
284351
|
+
fijos_faltantes: {
|
|
284352
|
+
/** Format: uuid */
|
|
284353
|
+
account_id: string;
|
|
284354
|
+
account_name: string;
|
|
284355
|
+
/** @description Median of the account’s last 3 non-zero months before the gap. */
|
|
284356
|
+
usual_clp: number;
|
|
284357
|
+
}[];
|
|
284315
284358
|
/** @description The Resultado’s «Ingresos» (net). */
|
|
284316
284359
|
ingresos_clp: number;
|
|
284317
284360
|
/** @description Costs on accounts flagged variable (documented or not) + «Egresos sin clasificar». */
|
|
@@ -284324,7 +284367,7 @@ interface components {
|
|
|
284324
284367
|
contribucion_clp: number;
|
|
284325
284368
|
/** @description Percent, one decimal. */
|
|
284326
284369
|
contribucion_pct: number | null;
|
|
284327
|
-
/** @description Punto de equilibrio: fijos ÷ margen de contribución %, the monthly income at which the result is zero. Null when it cannot be reached (see `equilibrio_sin_calculo`). */
|
|
284370
|
+
/** @description Punto de equilibrio: (fijos + fijos faltantes) ÷ margen de contribución %, the monthly income at which the result is zero. `fijos_clp` stays the books; the recurring fixed costs not booked yet enter here at their usual amount (month rows: `fijos_faltantes_clp`). Null when it cannot be reached (see `equilibrio_sin_calculo`). */
|
|
284328
284371
|
equilibrio_clp: number | null;
|
|
284329
284372
|
/** @enum {string|null} */
|
|
284330
284373
|
equilibrio_sin_calculo: "sin_ingresos" | "margen_no_positivo" | null;
|
|
@@ -284346,6 +284389,10 @@ interface components {
|
|
|
284346
284389
|
label: string;
|
|
284347
284390
|
equilibrio_clp: number;
|
|
284348
284391
|
}[];
|
|
284392
|
+
/** @description Mean of the bar months’ `fijos_faltantes_clp`; already inside `equilibrio_clp`. */
|
|
284393
|
+
fijos_faltantes_clp: number;
|
|
284394
|
+
/** @description Distinct names of the accounts missing in any bar month, usual amount descending. */
|
|
284395
|
+
fijos_faltantes_accounts: string[];
|
|
284349
284396
|
} | null;
|
|
284350
284397
|
/** @description Monthly averages over the range; equilibrio = average fijos ÷ the range’s margin %. */
|
|
284351
284398
|
period: {
|
|
@@ -284361,7 +284408,7 @@ interface components {
|
|
|
284361
284408
|
contribucion_clp: number;
|
|
284362
284409
|
/** @description Percent, one decimal. */
|
|
284363
284410
|
contribucion_pct: number | null;
|
|
284364
|
-
/** @description Punto de equilibrio: fijos ÷ margen de contribución %, the monthly income at which the result is zero. Null when it cannot be reached (see `equilibrio_sin_calculo`). */
|
|
284411
|
+
/** @description Punto de equilibrio: (fijos + fijos faltantes) ÷ margen de contribución %, the monthly income at which the result is zero. `fijos_clp` stays the books; the recurring fixed costs not booked yet enter here at their usual amount (month rows: `fijos_faltantes_clp`). Null when it cannot be reached (see `equilibrio_sin_calculo`). */
|
|
284365
284412
|
equilibrio_clp: number | null;
|
|
284366
284413
|
/** @enum {string|null} */
|
|
284367
284414
|
equilibrio_sin_calculo: "sin_ingresos" | "margen_no_positivo" | null;
|
|
@@ -284383,6 +284430,12 @@ interface components {
|
|
|
284383
284430
|
/** @enum {string} */
|
|
284384
284431
|
behavior: "fijo" | "variable";
|
|
284385
284432
|
behavior_inherited: boolean;
|
|
284433
|
+
/** @description Fijo accounts: median of the last 3 non-zero closed months within 12 months before the current one. Null for variable accounts or when never seen. */
|
|
284434
|
+
usual_monthly_clp: number | null;
|
|
284435
|
+
/** @description The recurring (non-zero in 3 of the 6 months up to its last booking) and stable (last amount within 25 % of the usual) test holds. */
|
|
284436
|
+
recurring: boolean;
|
|
284437
|
+
/** @description `YYYY-MM`: the account is missing in the last closed month; the first month of that run of zeros. Null otherwise. */
|
|
284438
|
+
missing_since: string | null;
|
|
284386
284439
|
/** @description One value per entry of `months`, same order. Whole CLP. */
|
|
284387
284440
|
values: number[];
|
|
284388
284441
|
total_clp: number;
|
|
@@ -284679,6 +284732,14 @@ interface components {
|
|
|
284679
284732
|
boletas_sin_pago_clp: number;
|
|
284680
284733
|
/** @description The Resultado’s «Ingresos» (issued documents, net) for the same months. */
|
|
284681
284734
|
ingresos_resultado_clp: number;
|
|
284735
|
+
/** @description Payments (or payment parts) without a boleta: the count behind `cobrado_sin_boleta_clp`. */
|
|
284736
|
+
pagos_sin_boleta: number;
|
|
284737
|
+
/** @description Part of `cobrado_sin_boleta_clp` waiting for next month’s summary boleta, which is not issued yet (reason `resumen_pendiente`). Included in `cobrado_sin_boleta_clp`. */
|
|
284738
|
+
pendiente_resumen_clp: number;
|
|
284739
|
+
/** @description Count behind `pendiente_resumen_clp`; included in `pagos_sin_boleta`. */
|
|
284740
|
+
pagos_pendiente_resumen: number;
|
|
284741
|
+
/** @description Signed: payments of the previous month covered by THIS month’s summary boleta (+), minus payments of this month covered by the NEXT month’s summary (−). cobrado − cobrado_sin_boleta + boletas_sin_pago + boleteado_otro_mes = boleteado, apart from notas de crédito that name no boleta (they lower `boleteado_clp` but not a boleta’s capacity). */
|
|
284742
|
+
boleteado_otro_mes_clp: number;
|
|
284682
284743
|
}[];
|
|
284683
284744
|
/** @description The range, netted per patient. */
|
|
284684
284745
|
total: {
|
|
@@ -284696,6 +284757,14 @@ interface components {
|
|
|
284696
284757
|
boletas_sin_pago_clp: number;
|
|
284697
284758
|
/** @description The Resultado’s «Ingresos» (issued documents, net) for the same months. */
|
|
284698
284759
|
ingresos_resultado_clp: number;
|
|
284760
|
+
/** @description Payments (or payment parts) without a boleta: the count behind `cobrado_sin_boleta_clp`. */
|
|
284761
|
+
pagos_sin_boleta: number;
|
|
284762
|
+
/** @description Part of `cobrado_sin_boleta_clp` waiting for next month’s summary boleta, which is not issued yet (reason `resumen_pendiente`). Included in `cobrado_sin_boleta_clp`. */
|
|
284763
|
+
pendiente_resumen_clp: number;
|
|
284764
|
+
/** @description Count behind `pendiente_resumen_clp`; included in `pagos_sin_boleta`. */
|
|
284765
|
+
pagos_pendiente_resumen: number;
|
|
284766
|
+
/** @description Signed: payments of the previous month covered by THIS month’s summary boleta (+), minus payments of this month covered by the NEXT month’s summary (−). cobrado − cobrado_sin_boleta + boletas_sin_pago + boleteado_otro_mes = boleteado, apart from notas de crédito that name no boleta (they lower `boleteado_clp` but not a boleta’s capacity). */
|
|
284767
|
+
boleteado_otro_mes_clp: number;
|
|
284699
284768
|
};
|
|
284700
284769
|
payments_without_boleta: {
|
|
284701
284770
|
count: number;
|
|
@@ -284709,7 +284778,7 @@ interface components {
|
|
|
284709
284778
|
amount_clp: number;
|
|
284710
284779
|
without_boleta_clp: number;
|
|
284711
284780
|
/** @enum {string} */
|
|
284712
|
-
reason: "sin_boleta" | "boleta_no_encontrada";
|
|
284781
|
+
reason: "sin_boleta" | "boleta_no_encontrada" | "resumen_pendiente";
|
|
284713
284782
|
folios: string[];
|
|
284714
284783
|
patient: {
|
|
284715
284784
|
/** Format: uuid */
|
|
@@ -284719,6 +284788,31 @@ interface components {
|
|
|
284719
284788
|
rut: string | null;
|
|
284720
284789
|
} | null;
|
|
284721
284790
|
}[];
|
|
284791
|
+
/** @description Months with a gap, ascending, each with its `per_month` largest items (patients redacted like `items`). */
|
|
284792
|
+
by_month: {
|
|
284793
|
+
month: string;
|
|
284794
|
+
count: number;
|
|
284795
|
+
total_clp: number;
|
|
284796
|
+
items: {
|
|
284797
|
+
/** Format: uuid */
|
|
284798
|
+
payment_id: string;
|
|
284799
|
+
/** @enum {string} */
|
|
284800
|
+
source: "clinic_mirror" | "vitrina";
|
|
284801
|
+
day: string;
|
|
284802
|
+
amount_clp: number;
|
|
284803
|
+
without_boleta_clp: number;
|
|
284804
|
+
/** @enum {string} */
|
|
284805
|
+
reason: "sin_boleta" | "boleta_no_encontrada" | "resumen_pendiente";
|
|
284806
|
+
folios: string[];
|
|
284807
|
+
patient: {
|
|
284808
|
+
/** Format: uuid */
|
|
284809
|
+
id: string;
|
|
284810
|
+
/** @description Full name; «Paciente A. P.» for a caller without the patient roster. */
|
|
284811
|
+
name: string;
|
|
284812
|
+
rut: string | null;
|
|
284813
|
+
} | null;
|
|
284814
|
+
}[];
|
|
284815
|
+
}[];
|
|
284722
284816
|
};
|
|
284723
284817
|
boletas_without_payment: {
|
|
284724
284818
|
count: number;
|
package/dist/index.d.ts
CHANGED
|
@@ -94395,7 +94395,7 @@ interface paths {
|
|
|
94395
94395
|
};
|
|
94396
94396
|
/**
|
|
94397
94397
|
* Producción, cobrado y boleteado (clinics)
|
|
94398
|
-
* @description The clinic’s bridge per month and for the range: **producción** (treatments performed), **cobrado** (patient payments received) and **boleteado** (boletas DTE 39/41 issued, at totals, minus notas de crédito on boletas), with **por cobrar** (produced, not paid) and **anticipos** (paid, not produced) per patient, so that producción − por cobrar + anticipos = cobrado; the range column nets per patient. Clinic money authority: a clinic mirrored from Dentalink/Medilink reads producción and cobrado only from the mirror (`source: clinic_mirror`), otherwise from Vitrina’s registers; bank movements are never income. Boletas are checked against payments both ways (`payments_without_boleta`, `boletas_without_payment`): first the link the clinic system holds, then a boleta to the payment’s own patient, then a monthly summary boleta (to the generic receiver 66.666.666-6 or to nobody, named by no payment) covers its month’s remaining payments (`monthly_boletas`). `ingresos_resultado_clp` is the Resultado’s income for the same months, to read next to it. A caller without the patient roster sees «Paciente A. P.» and no RUT. Other verticals answer `is_clinic: false` with empty figures. Requires the `finanzas` add-on — without it every Finanzas operation answers `402 ENTITLEMENT_NOT_ACTIVE` (`details.required = ["finanzas"]`). Requires `finanzas_reports:read`.
|
|
94398
|
+
* @description The clinic’s bridge per month and for the range: **producción** (treatments performed), **cobrado** (patient payments received) and **boleteado** (boletas DTE 39/41 issued, at totals, minus notas de crédito on boletas), with **por cobrar** (produced, not paid) and **anticipos** (paid, not produced) per patient, so that producción − por cobrar + anticipos = cobrado; the range column nets per patient. Clinic money authority: a clinic mirrored from Dentalink/Medilink reads producción and cobrado only from the mirror (`source: clinic_mirror`), otherwise from Vitrina’s registers; bank movements are never income. Boletas are checked against payments both ways (`payments_without_boleta`, `boletas_without_payment`): first the link the clinic system holds, then a boleta to the payment’s own patient, then a monthly summary boleta (to the generic receiver 66.666.666-6 or to nobody, named by no payment) covers its month’s remaining payments (`monthly_boletas`); a month’s leftover is then covered by what the NEXT month’s summary has left (month-end cash is billed in the next summary), shown as the signed `boleteado_otro_mes_clp`, and a leftover whose next summary is not issued yet is `resumen_pendiente`, not a gap. `payments_without_boleta` is also grouped `by_month` (`per_month` items each); `sin_boleta_month` lists one month completely. `ingresos_resultado_clp` is the Resultado’s income for the same months, to read next to it. A caller without the patient roster sees «Paciente A. P.» and no RUT. Other verticals answer `is_clinic: false` with empty figures. Requires the `finanzas` add-on — without it every Finanzas operation answers `402 ENTITLEMENT_NOT_ACTIVE` (`details.required = ["finanzas"]`). Requires `finanzas_reports:read`.
|
|
94399
94399
|
*/
|
|
94400
94400
|
get: {
|
|
94401
94401
|
parameters: {
|
|
@@ -94403,6 +94403,8 @@ interface paths {
|
|
|
94403
94403
|
from?: string;
|
|
94404
94404
|
to?: string;
|
|
94405
94405
|
limit?: number;
|
|
94406
|
+
per_month?: number;
|
|
94407
|
+
sin_boleta_month?: string;
|
|
94406
94408
|
};
|
|
94407
94409
|
header?: never;
|
|
94408
94410
|
path?: never;
|
|
@@ -94438,7 +94440,11 @@ interface paths {
|
|
|
94438
94440
|
* "anticipos_clp": 1820000,
|
|
94439
94441
|
* "cobrado_sin_boleta_clp": 478076,
|
|
94440
94442
|
* "boletas_sin_pago_clp": 0,
|
|
94441
|
-
* "ingresos_resultado_clp": 57726146
|
|
94443
|
+
* "ingresos_resultado_clp": 57726146,
|
|
94444
|
+
* "pagos_sin_boleta": 3,
|
|
94445
|
+
* "pendiente_resumen_clp": 0,
|
|
94446
|
+
* "pagos_pendiente_resumen": 0,
|
|
94447
|
+
* "boleteado_otro_mes_clp": 0
|
|
94442
94448
|
* }
|
|
94443
94449
|
* ],
|
|
94444
94450
|
* "total": {
|
|
@@ -94449,7 +94455,11 @@ interface paths {
|
|
|
94449
94455
|
* "anticipos_clp": 1820000,
|
|
94450
94456
|
* "cobrado_sin_boleta_clp": 478076,
|
|
94451
94457
|
* "boletas_sin_pago_clp": 0,
|
|
94452
|
-
* "ingresos_resultado_clp": 57726146
|
|
94458
|
+
* "ingresos_resultado_clp": 57726146,
|
|
94459
|
+
* "pagos_sin_boleta": 3,
|
|
94460
|
+
* "pendiente_resumen_clp": 0,
|
|
94461
|
+
* "pagos_pendiente_resumen": 0,
|
|
94462
|
+
* "boleteado_otro_mes_clp": 0
|
|
94453
94463
|
* },
|
|
94454
94464
|
* "payments_without_boleta": {
|
|
94455
94465
|
* "count": 3,
|
|
@@ -94469,6 +94479,29 @@ interface paths {
|
|
|
94469
94479
|
* "rut": null
|
|
94470
94480
|
* }
|
|
94471
94481
|
* }
|
|
94482
|
+
* ],
|
|
94483
|
+
* "by_month": [
|
|
94484
|
+
* {
|
|
94485
|
+
* "month": "2026-10",
|
|
94486
|
+
* "count": 3,
|
|
94487
|
+
* "total_clp": 478076,
|
|
94488
|
+
* "items": [
|
|
94489
|
+
* {
|
|
94490
|
+
* "payment_id": "0190a3c2-5d1e-7b6a-9f20-4c1d2e3f7101",
|
|
94491
|
+
* "source": "clinic_mirror",
|
|
94492
|
+
* "day": "2026-10-31",
|
|
94493
|
+
* "amount_clp": 250000,
|
|
94494
|
+
* "without_boleta_clp": 250000,
|
|
94495
|
+
* "reason": "sin_boleta",
|
|
94496
|
+
* "folios": [],
|
|
94497
|
+
* "patient": {
|
|
94498
|
+
* "id": "0190a3c2-5d1e-7b6a-9f20-4c1d2e3f7301",
|
|
94499
|
+
* "name": "Paciente A. P.",
|
|
94500
|
+
* "rut": null
|
|
94501
|
+
* }
|
|
94502
|
+
* }
|
|
94503
|
+
* ]
|
|
94504
|
+
* }
|
|
94472
94505
|
* ]
|
|
94473
94506
|
* },
|
|
94474
94507
|
* "boletas_without_payment": {
|
|
@@ -284312,6 +284345,16 @@ interface components {
|
|
|
284312
284345
|
/** @description The missing recurring account (`recurring_cost_missing`), else null. */
|
|
284313
284346
|
account_name: string | null;
|
|
284314
284347
|
} | null;
|
|
284348
|
+
/** @description Recurring fixed costs not booked yet in this closed month, at their usual amount (the sum of `fijos_faltantes`). Already inside `equilibrio_clp`; never inside `fijos_clp` or `resultado_clp`. 0 on a proforma month. */
|
|
284349
|
+
fijos_faltantes_clp: number;
|
|
284350
|
+
/** @description The accounts behind `fijos_faltantes_clp`, usual amount descending. */
|
|
284351
|
+
fijos_faltantes: {
|
|
284352
|
+
/** Format: uuid */
|
|
284353
|
+
account_id: string;
|
|
284354
|
+
account_name: string;
|
|
284355
|
+
/** @description Median of the account’s last 3 non-zero months before the gap. */
|
|
284356
|
+
usual_clp: number;
|
|
284357
|
+
}[];
|
|
284315
284358
|
/** @description The Resultado’s «Ingresos» (net). */
|
|
284316
284359
|
ingresos_clp: number;
|
|
284317
284360
|
/** @description Costs on accounts flagged variable (documented or not) + «Egresos sin clasificar». */
|
|
@@ -284324,7 +284367,7 @@ interface components {
|
|
|
284324
284367
|
contribucion_clp: number;
|
|
284325
284368
|
/** @description Percent, one decimal. */
|
|
284326
284369
|
contribucion_pct: number | null;
|
|
284327
|
-
/** @description Punto de equilibrio: fijos ÷ margen de contribución %, the monthly income at which the result is zero. Null when it cannot be reached (see `equilibrio_sin_calculo`). */
|
|
284370
|
+
/** @description Punto de equilibrio: (fijos + fijos faltantes) ÷ margen de contribución %, the monthly income at which the result is zero. `fijos_clp` stays the books; the recurring fixed costs not booked yet enter here at their usual amount (month rows: `fijos_faltantes_clp`). Null when it cannot be reached (see `equilibrio_sin_calculo`). */
|
|
284328
284371
|
equilibrio_clp: number | null;
|
|
284329
284372
|
/** @enum {string|null} */
|
|
284330
284373
|
equilibrio_sin_calculo: "sin_ingresos" | "margen_no_positivo" | null;
|
|
@@ -284346,6 +284389,10 @@ interface components {
|
|
|
284346
284389
|
label: string;
|
|
284347
284390
|
equilibrio_clp: number;
|
|
284348
284391
|
}[];
|
|
284392
|
+
/** @description Mean of the bar months’ `fijos_faltantes_clp`; already inside `equilibrio_clp`. */
|
|
284393
|
+
fijos_faltantes_clp: number;
|
|
284394
|
+
/** @description Distinct names of the accounts missing in any bar month, usual amount descending. */
|
|
284395
|
+
fijos_faltantes_accounts: string[];
|
|
284349
284396
|
} | null;
|
|
284350
284397
|
/** @description Monthly averages over the range; equilibrio = average fijos ÷ the range’s margin %. */
|
|
284351
284398
|
period: {
|
|
@@ -284361,7 +284408,7 @@ interface components {
|
|
|
284361
284408
|
contribucion_clp: number;
|
|
284362
284409
|
/** @description Percent, one decimal. */
|
|
284363
284410
|
contribucion_pct: number | null;
|
|
284364
|
-
/** @description Punto de equilibrio: fijos ÷ margen de contribución %, the monthly income at which the result is zero. Null when it cannot be reached (see `equilibrio_sin_calculo`). */
|
|
284411
|
+
/** @description Punto de equilibrio: (fijos + fijos faltantes) ÷ margen de contribución %, the monthly income at which the result is zero. `fijos_clp` stays the books; the recurring fixed costs not booked yet enter here at their usual amount (month rows: `fijos_faltantes_clp`). Null when it cannot be reached (see `equilibrio_sin_calculo`). */
|
|
284365
284412
|
equilibrio_clp: number | null;
|
|
284366
284413
|
/** @enum {string|null} */
|
|
284367
284414
|
equilibrio_sin_calculo: "sin_ingresos" | "margen_no_positivo" | null;
|
|
@@ -284383,6 +284430,12 @@ interface components {
|
|
|
284383
284430
|
/** @enum {string} */
|
|
284384
284431
|
behavior: "fijo" | "variable";
|
|
284385
284432
|
behavior_inherited: boolean;
|
|
284433
|
+
/** @description Fijo accounts: median of the last 3 non-zero closed months within 12 months before the current one. Null for variable accounts or when never seen. */
|
|
284434
|
+
usual_monthly_clp: number | null;
|
|
284435
|
+
/** @description The recurring (non-zero in 3 of the 6 months up to its last booking) and stable (last amount within 25 % of the usual) test holds. */
|
|
284436
|
+
recurring: boolean;
|
|
284437
|
+
/** @description `YYYY-MM`: the account is missing in the last closed month; the first month of that run of zeros. Null otherwise. */
|
|
284438
|
+
missing_since: string | null;
|
|
284386
284439
|
/** @description One value per entry of `months`, same order. Whole CLP. */
|
|
284387
284440
|
values: number[];
|
|
284388
284441
|
total_clp: number;
|
|
@@ -284679,6 +284732,14 @@ interface components {
|
|
|
284679
284732
|
boletas_sin_pago_clp: number;
|
|
284680
284733
|
/** @description The Resultado’s «Ingresos» (issued documents, net) for the same months. */
|
|
284681
284734
|
ingresos_resultado_clp: number;
|
|
284735
|
+
/** @description Payments (or payment parts) without a boleta: the count behind `cobrado_sin_boleta_clp`. */
|
|
284736
|
+
pagos_sin_boleta: number;
|
|
284737
|
+
/** @description Part of `cobrado_sin_boleta_clp` waiting for next month’s summary boleta, which is not issued yet (reason `resumen_pendiente`). Included in `cobrado_sin_boleta_clp`. */
|
|
284738
|
+
pendiente_resumen_clp: number;
|
|
284739
|
+
/** @description Count behind `pendiente_resumen_clp`; included in `pagos_sin_boleta`. */
|
|
284740
|
+
pagos_pendiente_resumen: number;
|
|
284741
|
+
/** @description Signed: payments of the previous month covered by THIS month’s summary boleta (+), minus payments of this month covered by the NEXT month’s summary (−). cobrado − cobrado_sin_boleta + boletas_sin_pago + boleteado_otro_mes = boleteado, apart from notas de crédito that name no boleta (they lower `boleteado_clp` but not a boleta’s capacity). */
|
|
284742
|
+
boleteado_otro_mes_clp: number;
|
|
284682
284743
|
}[];
|
|
284683
284744
|
/** @description The range, netted per patient. */
|
|
284684
284745
|
total: {
|
|
@@ -284696,6 +284757,14 @@ interface components {
|
|
|
284696
284757
|
boletas_sin_pago_clp: number;
|
|
284697
284758
|
/** @description The Resultado’s «Ingresos» (issued documents, net) for the same months. */
|
|
284698
284759
|
ingresos_resultado_clp: number;
|
|
284760
|
+
/** @description Payments (or payment parts) without a boleta: the count behind `cobrado_sin_boleta_clp`. */
|
|
284761
|
+
pagos_sin_boleta: number;
|
|
284762
|
+
/** @description Part of `cobrado_sin_boleta_clp` waiting for next month’s summary boleta, which is not issued yet (reason `resumen_pendiente`). Included in `cobrado_sin_boleta_clp`. */
|
|
284763
|
+
pendiente_resumen_clp: number;
|
|
284764
|
+
/** @description Count behind `pendiente_resumen_clp`; included in `pagos_sin_boleta`. */
|
|
284765
|
+
pagos_pendiente_resumen: number;
|
|
284766
|
+
/** @description Signed: payments of the previous month covered by THIS month’s summary boleta (+), minus payments of this month covered by the NEXT month’s summary (−). cobrado − cobrado_sin_boleta + boletas_sin_pago + boleteado_otro_mes = boleteado, apart from notas de crédito that name no boleta (they lower `boleteado_clp` but not a boleta’s capacity). */
|
|
284767
|
+
boleteado_otro_mes_clp: number;
|
|
284699
284768
|
};
|
|
284700
284769
|
payments_without_boleta: {
|
|
284701
284770
|
count: number;
|
|
@@ -284709,7 +284778,7 @@ interface components {
|
|
|
284709
284778
|
amount_clp: number;
|
|
284710
284779
|
without_boleta_clp: number;
|
|
284711
284780
|
/** @enum {string} */
|
|
284712
|
-
reason: "sin_boleta" | "boleta_no_encontrada";
|
|
284781
|
+
reason: "sin_boleta" | "boleta_no_encontrada" | "resumen_pendiente";
|
|
284713
284782
|
folios: string[];
|
|
284714
284783
|
patient: {
|
|
284715
284784
|
/** Format: uuid */
|
|
@@ -284719,6 +284788,31 @@ interface components {
|
|
|
284719
284788
|
rut: string | null;
|
|
284720
284789
|
} | null;
|
|
284721
284790
|
}[];
|
|
284791
|
+
/** @description Months with a gap, ascending, each with its `per_month` largest items (patients redacted like `items`). */
|
|
284792
|
+
by_month: {
|
|
284793
|
+
month: string;
|
|
284794
|
+
count: number;
|
|
284795
|
+
total_clp: number;
|
|
284796
|
+
items: {
|
|
284797
|
+
/** Format: uuid */
|
|
284798
|
+
payment_id: string;
|
|
284799
|
+
/** @enum {string} */
|
|
284800
|
+
source: "clinic_mirror" | "vitrina";
|
|
284801
|
+
day: string;
|
|
284802
|
+
amount_clp: number;
|
|
284803
|
+
without_boleta_clp: number;
|
|
284804
|
+
/** @enum {string} */
|
|
284805
|
+
reason: "sin_boleta" | "boleta_no_encontrada" | "resumen_pendiente";
|
|
284806
|
+
folios: string[];
|
|
284807
|
+
patient: {
|
|
284808
|
+
/** Format: uuid */
|
|
284809
|
+
id: string;
|
|
284810
|
+
/** @description Full name; «Paciente A. P.» for a caller without the patient roster. */
|
|
284811
|
+
name: string;
|
|
284812
|
+
rut: string | null;
|
|
284813
|
+
} | null;
|
|
284814
|
+
}[];
|
|
284815
|
+
}[];
|
|
284722
284816
|
};
|
|
284723
284817
|
boletas_without_payment: {
|
|
284724
284818
|
count: number;
|
package/package.json
CHANGED