@vitrina/api 17.101.1 → 17.102.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 CHANGED
@@ -42030,6 +42030,8 @@ interface paths {
42030
42030
  * Approve a nota de venta (the sale fan-out)
42031
42031
  * @description **Below the floor without `price_approval:approve` (app#7589):** **409** `details.reason: price_approval_required` with `details.price_approval_pending` and `details.price_approval_id`. When none was pending the call files one in the caller's name first, so the answer always says the approval is requested: «No puedes cerrar la venta V-41 todavía: el precio está bajo el mínimo y un administrador tiene que aprobarlo primero. La aprobación del precio ya está pedida.» The answer carries `price_approval` like every note read.
42032
42032
  *
42033
+ * **Closed by a member holding `price_approval:approve` (app#7704):** the note’s pending price request (if any, and not filed by that same member) is resolved `approved` by them in the same transaction, audited as `price_approvals.decide`; it leaves the approval queue and its count.
42034
+ *
42033
42035
  * Approves the document — the instant it becomes **legally valid** (BR-485) and the instant every consequence of the sale fires. All of it happens in **ONE database transaction**, so either all of it happened or none of it did:
42034
42036
  *
42035
42037
  * * the document is stamped with WHO approved it and WHEN (BR-484);
@@ -42307,6 +42309,8 @@ interface paths {
42307
42309
  * Void a nota de venta
42308
42310
  * @description Voids the document. It is **never deleted and it KEEPS ITS FOLIO** (ADR 0058 §10): the row records the time, the reason and the acting principal and remains listable. There is deliberately no `DELETE` verb on this resource.
42309
42311
  *
42312
+ * Its pending price requests are withdrawn in the same transaction (app#7704): resolved `rejected` by the voider with a note saying the sale was voided, audited as `price_approvals.decide`; they leave the approval queue and its count.
42313
+ *
42310
42314
  * `void_reason` is mandatory and must contain VISIBLE text — a reason made only of whitespace, a U+00A0 or a zero-width space is refused at the edge and by a table CHECK, because a reason nobody can see is not a reason.
42311
42315
  *
42312
42316
  * The actor comes from the authenticated principal; a `voided_by` in the body is IGNORED rather than rejected — a self-declared actor is not an attestation. Voiding twice is a **409**: the first actor and reason stand.
@@ -43960,7 +43964,13 @@ interface paths {
43960
43964
  };
43961
43965
  /**
43962
43966
  * List notas de compra
43963
- * @description The dealership’s PURCHASE documents, newest first by `issued_at`. A nota de compra is the instrument that CREATES a cost — the unit’s cost basis comes from it, linked through `vehicle_acquisition.purchase_note_id`.
43967
+ * @description **Every row carries `vehicle_ref`, the car it names**, read in ONE tenant-scoped batch for the page so a client never fetches the cars one by one: `{ id, title, make, model, version, year, registration_number, deleted }` (`registration_number` is the patente). It is served whatever the car’s state — sold, inactive, merged away or removed from Stock (`deleted: true`, last known name and plate kept) — and to any caller who may read the list, without `marketplace:read` and whatever sucursal the car sits at. `null` only when the row names no car or the car row is gone.
43968
+ *
43969
+ * **Every row carries `contact_ref`, the person it names** (the buyer of a nota de venta or cotización, the holder of a reserva, the owner of a consignación), read in ONE tenant-scoped batch for the page so a client never fetches the contacts one by one: `{ id, name, tax_id, tax_id_kind, archived }`. `name` is the display name; `archived: true` = archived or merged away (the name is kept). `tax_id` / `tax_id_kind` (the RUT) are `null` unless the caller also holds `contacts:read`. `null` only when the row names nobody or the contact row is gone.
43970
+ *
43971
+ * Here `contact_ref` is the SELLER (`seller_contact_id`) and `vehicle_ref` the first unit the document bought (the same car as `vehicle`).
43972
+ *
43973
+ * The dealership’s PURCHASE documents, newest first by `issued_at`. A nota de compra is the instrument that CREATES a cost — the unit’s cost basis comes from it, linked through `vehicle_acquisition.purchase_note_id`.
43964
43974
  *
43965
43975
  * **Voided documents are INCLUDED by default** — a voided nota de compra keeps its folio and stays listable so "where is nota de compra #47?" has an answer (ADR 0058 §10, BR-650–655). Pass `exclude_voided=true` to see only live ones; only the literal string `true` opts in, so `exclude_voided=false` does not hide them.
43966
43976
  *
@@ -44018,7 +44028,32 @@ interface paths {
44018
44028
  * "voided_by": null,
44019
44029
  * "created_at": "2026-09-12T10:15:00.000Z",
44020
44030
  * "updated_at": "2026-09-12T10:15:00.000Z",
44021
- * "sale_note_display_id": null
44031
+ * "sale_note_display_id": null,
44032
+ * "vehicle": {
44033
+ * "id": "f2a1c3d4-5b6e-4f70-8a91-b2c3d4e5f6a7",
44034
+ * "make": "Volvo",
44035
+ * "model": "S60",
44036
+ * "year": 2019,
44037
+ * "registration_number": "GDSL82"
44038
+ * },
44039
+ * "vehicle_count": 1,
44040
+ * "vehicle_ref": {
44041
+ * "id": "f2a1c3d4-5b6e-4f70-8a91-b2c3d4e5f6a7",
44042
+ * "title": null,
44043
+ * "make": "Volvo",
44044
+ * "model": "S60",
44045
+ * "version": "2.0 T5 Momentum",
44046
+ * "year": 2019,
44047
+ * "registration_number": "GDSL82",
44048
+ * "deleted": false
44049
+ * },
44050
+ * "contact_ref": {
44051
+ * "id": "22222222-0000-4000-8000-000000000003",
44052
+ * "name": "María José Fuentes",
44053
+ * "tax_id": "15432100-4",
44054
+ * "tax_id_kind": "rut",
44055
+ * "archived": false
44056
+ * }
44022
44057
  * }
44023
44058
  * ],
44024
44059
  * "meta": {
@@ -49953,6 +49988,8 @@ interface paths {
49953
49988
  * **Every row carries `subject`** (app#7589), the document the approval is about, read in one batch for the page: `{ kind: quote|reservation|sale_note, id, display_id, contact_ref, unit_label, unit_plate }`. `contact_ref` is the person, as on every dealer list (its RUT only with `contacts:read`); `unit_label` / `unit_plate` are the unit the cotización froze (null on a reserva or nota de venta). `null` only when the document row is gone.
49954
49989
  *
49955
49990
  * Oldest-first. Cost fields (e.g. `floor_price_snapshot_clp`) are ABSENT from the response unless the caller also holds `dealership_economics:read`.
49991
+ *
49992
+ * `status=pending` lists only requests still waiting (app#7704): a request on a voided nota de venta, or an ordinary request on a nota de venta that was closed anyway, is not listed nor counted in `meta.total`.
49956
49993
  */
49957
49994
  get: {
49958
49995
  parameters: {
@@ -73123,9 +73160,13 @@ interface paths {
73123
73160
  * "ready_out_of_hours": false,
73124
73161
  * "templates": [
73125
73162
  * {
73126
- * "name": "seguimiento_clinica_fuera_horario",
73163
+ * "name": "clinica_formulario_tratamiento_fuera_horario_usted",
73127
73164
  * "language": "es",
73128
- * "status": "PENDING"
73165
+ * "status": "PENDING",
73166
+ * "pack": "clinic_form",
73167
+ * "template_key": "treatment_out_of_hours",
73168
+ * "register": "usted",
73169
+ * "out_of_hours": true
73129
73170
  * }
73130
73171
  * ]
73131
73172
  * }
@@ -185067,6 +185108,8 @@ interface paths {
185067
185108
  * Filter by `vehicle_id` and/or `estado`, with `limit` / `offset`. No total is returned — the response carries the rows and nothing else.
185068
185109
  *
185069
185110
  * Each row also carries (app#7589) `dueno_name` (the consignante, `null` without one) and `liquidacion`: the booked settlement as `{ id, settlement_mode, amount_venta_clp, comision_type, comision_value, comision_amount_clp, comision_iva_clp, comision_minima_applied, monto_owner_clp, deducciones_clp, payout_method, paid_at }`, or `null` when the contract has none (a sale not settled yet, a return that moved no money). `comision_minima_applied: true` = the Comisión mínima won over the percentage: read the commission as «Comisión mínima». A list screen needs no per-contract `GET /consignments/{id}/liquidacion`.
185111
+ *
185112
+ * And (app#7704) `contract_document`: the mandato currently issued for the contract as `{ id, rendered_at }` (the `current` artefact of `GET /consignments/{id}/contract`), or `null` when none was ever issued, which is «Contrato sin emitir». Read in one batch for the page: a list screen needs no per-contract `GET /consignments/{id}/contract`.
185070
185113
  */
185071
185114
  get: {
185072
185115
  parameters: {
@@ -185134,6 +185177,10 @@ interface paths {
185134
185177
  * "tax_id": "15432100-4",
185135
185178
  * "tax_id_kind": "rut",
185136
185179
  * "archived": false
185180
+ * },
185181
+ * "contract_document": {
185182
+ * "id": "6f0e2d1c-3b4a-4c5d-8e6f-7a8b9c0d1e2f",
185183
+ * "rendered_at": "2026-08-20T10:05:00.000Z"
185137
185184
  * }
185138
185185
  * }
185139
185186
  * ],
@@ -185660,7 +185707,7 @@ interface paths {
185660
185707
  *
185661
185708
  * Moving `vencimiento` RE-ARMS the expiry reminder: the "already reminded" stamp is cleared, so a pushed-out date produces a fresh nudge rather than staying silent.
185662
185709
  *
185663
- * Supplying `minimo_clp` RENEGOTIATES the mínimo rather than editing a column: it appends an immutable revision to the contract’s terms history (`GET /consignments/{id}/terms`), dated `minimo_effective_on` or today. `precio_cliente_clp` is the same field under its new name. Sending the value already governing, with no `minimo_effective_on`, is a no-op (a form may resend every field); a second revision on a date already taken is a **409**.
185710
+ * Supplying `minimo_clp` RENEGOTIATES the mínimo rather than editing a column: it appends an immutable revision to the contract’s terms history (`GET /consignments/{id}/terms`), dated `minimo_effective_on` or today. `precio_cliente_clp` is the same field under its new name. Sending the value already governing, with no `minimo_effective_on`, is a no-op (a form may resend every field). A different value on a date that already has a revision, today or later, CORRECTS it (app#7704): that revision is marked replaced and the new value governs the same date, so the date keeps one revision with the last value (the audit row keeps the previous one). A date already past is never rewritten: a second revision there is a **409**.
185664
185711
  *
185665
185712
  * A raised Precio cliente writes through to the vehicle’s floor while the contract is active. Withdrawing it (null) clears the floor only while the floor still holds the withdrawn price, so a floor the dealer set by hand is kept; the contract ending never clears it.
185666
185713
  *
@@ -324989,7 +325036,7 @@ interface components {
324989
325036
  } | null;
324990
325037
  };
324991
325038
  /**
324992
- * @description `whatsapp_disconnected`: a WhatsApp number of the clinic is disconnected (critical; `detail`: `messaging_account_id`, `account_name`, `reason_code`, `is_first_contact_sender`). `whatsapp_attention`: a number needs attention (warning; same detail). `first_contact_templates_not_approved`: the clinic form first contact is on but its ladder cannot send (critical when step 1 or the in-hours step 2 has no approved template, warning when only the out-of-hours step 2 is missing; `detail`: `messaging_account_id`, `ready_in_hours`, `ready_out_of_hours`, `templates` [{name, language, status}]). `unmapped_forms`: submissions of the last 7 days came from a form that is not in the clinic’s current form map (warning; `detail`: `submissions_7d`, `forms` [{form_id, submissions}], `forms_total`, `without_form_id`). `first_contact_missed`: in the last 24 hours submissions ended without a first contact for a reason someone can fix, or a lead raised the first-contact-missing alarm (warning; `detail`: `outcomes` {outcome: count}, `missing_alarms`, `needs_form_setup`). `first_contact_off`: the clinic has a WhatsApp number and its clinic form first contact is switched off (low; `detail`: `submissions_7d` = forms that arrived while off). A value added later is a changelog entry.
325039
+ * @description `whatsapp_disconnected`: a WhatsApp number of the clinic is disconnected (critical; `detail`: `messaging_account_id`, `account_name`, `reason_code`, `is_first_contact_sender`). `whatsapp_attention`: a number needs attention (warning; same detail). `first_contact_templates_not_approved`: the clinic form first contact is on but its ladder cannot send (critical when step 1 or the in-hours step 2 has no approved template, warning when only the out-of-hours step 2 is missing; `detail`: `messaging_account_id`, `ready_in_hours`, `ready_out_of_hours`, `templates` [{name, language, status, pack, template_key, register, out_of_hours}]; `pack` is the template pack id (e.g. `clinic_form`), `template_key` the pack entry key, `register` `tu`/`usted`/`vos` when the name is a register variant, `out_of_hours` whether it is the out-of-hours copy; all four are null for a template no pack made, such as one the clinic wrote itself). `unmapped_forms`: submissions of the last 7 days came from a form that is not in the clinic’s current form map (warning; `detail`: `submissions_7d`, `forms` [{form_id, submissions}], `forms_total`, `without_form_id`). `first_contact_missed`: in the last 24 hours submissions ended without a first contact for a reason someone can fix, or a lead raised the first-contact-missing alarm (warning; `detail`: `outcomes` {outcome: count}, `missing_alarms`, `needs_form_setup`). `first_contact_off`: the clinic has a WhatsApp number and its clinic form first contact is switched off (low; `detail`: `submissions_7d` = forms that arrived while off). A value added later is a changelog entry.
324993
325040
  * @enum {string}
324994
325041
  */
324995
325042
  ClinicSignalKind: "whatsapp_disconnected" | "whatsapp_attention" | "first_contact_templates_not_approved" | "unmapped_forms" | "first_contact_missed" | "first_contact_off";
package/dist/index.d.ts CHANGED
@@ -42030,6 +42030,8 @@ interface paths {
42030
42030
  * Approve a nota de venta (the sale fan-out)
42031
42031
  * @description **Below the floor without `price_approval:approve` (app#7589):** **409** `details.reason: price_approval_required` with `details.price_approval_pending` and `details.price_approval_id`. When none was pending the call files one in the caller's name first, so the answer always says the approval is requested: «No puedes cerrar la venta V-41 todavía: el precio está bajo el mínimo y un administrador tiene que aprobarlo primero. La aprobación del precio ya está pedida.» The answer carries `price_approval` like every note read.
42032
42032
  *
42033
+ * **Closed by a member holding `price_approval:approve` (app#7704):** the note’s pending price request (if any, and not filed by that same member) is resolved `approved` by them in the same transaction, audited as `price_approvals.decide`; it leaves the approval queue and its count.
42034
+ *
42033
42035
  * Approves the document — the instant it becomes **legally valid** (BR-485) and the instant every consequence of the sale fires. All of it happens in **ONE database transaction**, so either all of it happened or none of it did:
42034
42036
  *
42035
42037
  * * the document is stamped with WHO approved it and WHEN (BR-484);
@@ -42307,6 +42309,8 @@ interface paths {
42307
42309
  * Void a nota de venta
42308
42310
  * @description Voids the document. It is **never deleted and it KEEPS ITS FOLIO** (ADR 0058 §10): the row records the time, the reason and the acting principal and remains listable. There is deliberately no `DELETE` verb on this resource.
42309
42311
  *
42312
+ * Its pending price requests are withdrawn in the same transaction (app#7704): resolved `rejected` by the voider with a note saying the sale was voided, audited as `price_approvals.decide`; they leave the approval queue and its count.
42313
+ *
42310
42314
  * `void_reason` is mandatory and must contain VISIBLE text — a reason made only of whitespace, a U+00A0 or a zero-width space is refused at the edge and by a table CHECK, because a reason nobody can see is not a reason.
42311
42315
  *
42312
42316
  * The actor comes from the authenticated principal; a `voided_by` in the body is IGNORED rather than rejected — a self-declared actor is not an attestation. Voiding twice is a **409**: the first actor and reason stand.
@@ -43960,7 +43964,13 @@ interface paths {
43960
43964
  };
43961
43965
  /**
43962
43966
  * List notas de compra
43963
- * @description The dealership’s PURCHASE documents, newest first by `issued_at`. A nota de compra is the instrument that CREATES a cost — the unit’s cost basis comes from it, linked through `vehicle_acquisition.purchase_note_id`.
43967
+ * @description **Every row carries `vehicle_ref`, the car it names**, read in ONE tenant-scoped batch for the page so a client never fetches the cars one by one: `{ id, title, make, model, version, year, registration_number, deleted }` (`registration_number` is the patente). It is served whatever the car’s state — sold, inactive, merged away or removed from Stock (`deleted: true`, last known name and plate kept) — and to any caller who may read the list, without `marketplace:read` and whatever sucursal the car sits at. `null` only when the row names no car or the car row is gone.
43968
+ *
43969
+ * **Every row carries `contact_ref`, the person it names** (the buyer of a nota de venta or cotización, the holder of a reserva, the owner of a consignación), read in ONE tenant-scoped batch for the page so a client never fetches the contacts one by one: `{ id, name, tax_id, tax_id_kind, archived }`. `name` is the display name; `archived: true` = archived or merged away (the name is kept). `tax_id` / `tax_id_kind` (the RUT) are `null` unless the caller also holds `contacts:read`. `null` only when the row names nobody or the contact row is gone.
43970
+ *
43971
+ * Here `contact_ref` is the SELLER (`seller_contact_id`) and `vehicle_ref` the first unit the document bought (the same car as `vehicle`).
43972
+ *
43973
+ * The dealership’s PURCHASE documents, newest first by `issued_at`. A nota de compra is the instrument that CREATES a cost — the unit’s cost basis comes from it, linked through `vehicle_acquisition.purchase_note_id`.
43964
43974
  *
43965
43975
  * **Voided documents are INCLUDED by default** — a voided nota de compra keeps its folio and stays listable so "where is nota de compra #47?" has an answer (ADR 0058 §10, BR-650–655). Pass `exclude_voided=true` to see only live ones; only the literal string `true` opts in, so `exclude_voided=false` does not hide them.
43966
43976
  *
@@ -44018,7 +44028,32 @@ interface paths {
44018
44028
  * "voided_by": null,
44019
44029
  * "created_at": "2026-09-12T10:15:00.000Z",
44020
44030
  * "updated_at": "2026-09-12T10:15:00.000Z",
44021
- * "sale_note_display_id": null
44031
+ * "sale_note_display_id": null,
44032
+ * "vehicle": {
44033
+ * "id": "f2a1c3d4-5b6e-4f70-8a91-b2c3d4e5f6a7",
44034
+ * "make": "Volvo",
44035
+ * "model": "S60",
44036
+ * "year": 2019,
44037
+ * "registration_number": "GDSL82"
44038
+ * },
44039
+ * "vehicle_count": 1,
44040
+ * "vehicle_ref": {
44041
+ * "id": "f2a1c3d4-5b6e-4f70-8a91-b2c3d4e5f6a7",
44042
+ * "title": null,
44043
+ * "make": "Volvo",
44044
+ * "model": "S60",
44045
+ * "version": "2.0 T5 Momentum",
44046
+ * "year": 2019,
44047
+ * "registration_number": "GDSL82",
44048
+ * "deleted": false
44049
+ * },
44050
+ * "contact_ref": {
44051
+ * "id": "22222222-0000-4000-8000-000000000003",
44052
+ * "name": "María José Fuentes",
44053
+ * "tax_id": "15432100-4",
44054
+ * "tax_id_kind": "rut",
44055
+ * "archived": false
44056
+ * }
44022
44057
  * }
44023
44058
  * ],
44024
44059
  * "meta": {
@@ -49953,6 +49988,8 @@ interface paths {
49953
49988
  * **Every row carries `subject`** (app#7589), the document the approval is about, read in one batch for the page: `{ kind: quote|reservation|sale_note, id, display_id, contact_ref, unit_label, unit_plate }`. `contact_ref` is the person, as on every dealer list (its RUT only with `contacts:read`); `unit_label` / `unit_plate` are the unit the cotización froze (null on a reserva or nota de venta). `null` only when the document row is gone.
49954
49989
  *
49955
49990
  * Oldest-first. Cost fields (e.g. `floor_price_snapshot_clp`) are ABSENT from the response unless the caller also holds `dealership_economics:read`.
49991
+ *
49992
+ * `status=pending` lists only requests still waiting (app#7704): a request on a voided nota de venta, or an ordinary request on a nota de venta that was closed anyway, is not listed nor counted in `meta.total`.
49956
49993
  */
49957
49994
  get: {
49958
49995
  parameters: {
@@ -73123,9 +73160,13 @@ interface paths {
73123
73160
  * "ready_out_of_hours": false,
73124
73161
  * "templates": [
73125
73162
  * {
73126
- * "name": "seguimiento_clinica_fuera_horario",
73163
+ * "name": "clinica_formulario_tratamiento_fuera_horario_usted",
73127
73164
  * "language": "es",
73128
- * "status": "PENDING"
73165
+ * "status": "PENDING",
73166
+ * "pack": "clinic_form",
73167
+ * "template_key": "treatment_out_of_hours",
73168
+ * "register": "usted",
73169
+ * "out_of_hours": true
73129
73170
  * }
73130
73171
  * ]
73131
73172
  * }
@@ -185067,6 +185108,8 @@ interface paths {
185067
185108
  * Filter by `vehicle_id` and/or `estado`, with `limit` / `offset`. No total is returned — the response carries the rows and nothing else.
185068
185109
  *
185069
185110
  * Each row also carries (app#7589) `dueno_name` (the consignante, `null` without one) and `liquidacion`: the booked settlement as `{ id, settlement_mode, amount_venta_clp, comision_type, comision_value, comision_amount_clp, comision_iva_clp, comision_minima_applied, monto_owner_clp, deducciones_clp, payout_method, paid_at }`, or `null` when the contract has none (a sale not settled yet, a return that moved no money). `comision_minima_applied: true` = the Comisión mínima won over the percentage: read the commission as «Comisión mínima». A list screen needs no per-contract `GET /consignments/{id}/liquidacion`.
185111
+ *
185112
+ * And (app#7704) `contract_document`: the mandato currently issued for the contract as `{ id, rendered_at }` (the `current` artefact of `GET /consignments/{id}/contract`), or `null` when none was ever issued, which is «Contrato sin emitir». Read in one batch for the page: a list screen needs no per-contract `GET /consignments/{id}/contract`.
185070
185113
  */
185071
185114
  get: {
185072
185115
  parameters: {
@@ -185134,6 +185177,10 @@ interface paths {
185134
185177
  * "tax_id": "15432100-4",
185135
185178
  * "tax_id_kind": "rut",
185136
185179
  * "archived": false
185180
+ * },
185181
+ * "contract_document": {
185182
+ * "id": "6f0e2d1c-3b4a-4c5d-8e6f-7a8b9c0d1e2f",
185183
+ * "rendered_at": "2026-08-20T10:05:00.000Z"
185137
185184
  * }
185138
185185
  * }
185139
185186
  * ],
@@ -185660,7 +185707,7 @@ interface paths {
185660
185707
  *
185661
185708
  * Moving `vencimiento` RE-ARMS the expiry reminder: the "already reminded" stamp is cleared, so a pushed-out date produces a fresh nudge rather than staying silent.
185662
185709
  *
185663
- * Supplying `minimo_clp` RENEGOTIATES the mínimo rather than editing a column: it appends an immutable revision to the contract’s terms history (`GET /consignments/{id}/terms`), dated `minimo_effective_on` or today. `precio_cliente_clp` is the same field under its new name. Sending the value already governing, with no `minimo_effective_on`, is a no-op (a form may resend every field); a second revision on a date already taken is a **409**.
185710
+ * Supplying `minimo_clp` RENEGOTIATES the mínimo rather than editing a column: it appends an immutable revision to the contract’s terms history (`GET /consignments/{id}/terms`), dated `minimo_effective_on` or today. `precio_cliente_clp` is the same field under its new name. Sending the value already governing, with no `minimo_effective_on`, is a no-op (a form may resend every field). A different value on a date that already has a revision, today or later, CORRECTS it (app#7704): that revision is marked replaced and the new value governs the same date, so the date keeps one revision with the last value (the audit row keeps the previous one). A date already past is never rewritten: a second revision there is a **409**.
185664
185711
  *
185665
185712
  * A raised Precio cliente writes through to the vehicle’s floor while the contract is active. Withdrawing it (null) clears the floor only while the floor still holds the withdrawn price, so a floor the dealer set by hand is kept; the contract ending never clears it.
185666
185713
  *
@@ -324989,7 +325036,7 @@ interface components {
324989
325036
  } | null;
324990
325037
  };
324991
325038
  /**
324992
- * @description `whatsapp_disconnected`: a WhatsApp number of the clinic is disconnected (critical; `detail`: `messaging_account_id`, `account_name`, `reason_code`, `is_first_contact_sender`). `whatsapp_attention`: a number needs attention (warning; same detail). `first_contact_templates_not_approved`: the clinic form first contact is on but its ladder cannot send (critical when step 1 or the in-hours step 2 has no approved template, warning when only the out-of-hours step 2 is missing; `detail`: `messaging_account_id`, `ready_in_hours`, `ready_out_of_hours`, `templates` [{name, language, status}]). `unmapped_forms`: submissions of the last 7 days came from a form that is not in the clinic’s current form map (warning; `detail`: `submissions_7d`, `forms` [{form_id, submissions}], `forms_total`, `without_form_id`). `first_contact_missed`: in the last 24 hours submissions ended without a first contact for a reason someone can fix, or a lead raised the first-contact-missing alarm (warning; `detail`: `outcomes` {outcome: count}, `missing_alarms`, `needs_form_setup`). `first_contact_off`: the clinic has a WhatsApp number and its clinic form first contact is switched off (low; `detail`: `submissions_7d` = forms that arrived while off). A value added later is a changelog entry.
325039
+ * @description `whatsapp_disconnected`: a WhatsApp number of the clinic is disconnected (critical; `detail`: `messaging_account_id`, `account_name`, `reason_code`, `is_first_contact_sender`). `whatsapp_attention`: a number needs attention (warning; same detail). `first_contact_templates_not_approved`: the clinic form first contact is on but its ladder cannot send (critical when step 1 or the in-hours step 2 has no approved template, warning when only the out-of-hours step 2 is missing; `detail`: `messaging_account_id`, `ready_in_hours`, `ready_out_of_hours`, `templates` [{name, language, status, pack, template_key, register, out_of_hours}]; `pack` is the template pack id (e.g. `clinic_form`), `template_key` the pack entry key, `register` `tu`/`usted`/`vos` when the name is a register variant, `out_of_hours` whether it is the out-of-hours copy; all four are null for a template no pack made, such as one the clinic wrote itself). `unmapped_forms`: submissions of the last 7 days came from a form that is not in the clinic’s current form map (warning; `detail`: `submissions_7d`, `forms` [{form_id, submissions}], `forms_total`, `without_form_id`). `first_contact_missed`: in the last 24 hours submissions ended without a first contact for a reason someone can fix, or a lead raised the first-contact-missing alarm (warning; `detail`: `outcomes` {outcome: count}, `missing_alarms`, `needs_form_setup`). `first_contact_off`: the clinic has a WhatsApp number and its clinic form first contact is switched off (low; `detail`: `submissions_7d` = forms that arrived while off). A value added later is a changelog entry.
324993
325040
  * @enum {string}
324994
325041
  */
324995
325042
  ClinicSignalKind: "whatsapp_disconnected" | "whatsapp_attention" | "first_contact_templates_not_approved" | "unmapped_forms" | "first_contact_missed" | "first_contact_off";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vitrina/api",
3
- "version": "17.101.1",
3
+ "version": "17.102.0",
4
4
  "description": "Typed TypeScript SDK for the Vitrina API pública — generated from the committed openapi.public.json (ADR 0106).",
5
5
  "type": "module",
6
6
  "license": "MIT",