@kirjapro/mcp-server 0.11.0 → 0.13.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/CHANGELOG.md +59 -1
- package/dist/index.js +1305 -596
- package/package.json +1 -1
- package/server.json +1 -1
- package/tool-fingerprints.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,64 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
## [0.
|
|
3
|
+
## [0.13.0] - 2026-10-04
|
|
4
|
+
|
|
5
|
+
No database prerequisite: every function, rule and VAT treatment it uses was
|
|
6
|
+
already live with 0.12.0, and 0.12.0 remains compatible with the same database.
|
|
7
|
+
|
|
8
|
+
- `kirjapro_create_invoice` runs on the invoice-draft core that Kirjapro's AI
|
|
9
|
+
Chat also uses (`src/shared/invoice-draft.ts`, generated from the repository's
|
|
10
|
+
`src/lib/invoice-draft.ts`). Line amounts round like the database (numeric
|
|
11
|
+
`ROUND`, half away from zero), so 3 × 1.255 € returns 3.77 €, as stored;
|
|
12
|
+
0.12.0 returned 3.76 €.
|
|
13
|
+
- The database allocates the invoice and reference number in the creation
|
|
14
|
+
transaction. The server no longer reads `get_next_invoice_number` first, and
|
|
15
|
+
the success message names the stored number.
|
|
16
|
+
- Errors are a stable code with a Finnish explanation, `CODE: viesti` (for
|
|
17
|
+
example `VAT_REQUIRES_EU_VAT_NUMBER: …` or `FISCAL_YEAR_CLOSED: …`), like the
|
|
18
|
+
existing `IDEMPOTENCY_*:` errors. Other tools keep their English messages.
|
|
19
|
+
- A lost database response returns `IDEMPOTENCY_OUTCOME_UNKNOWN` and leaves the
|
|
20
|
+
idempotency claim pending, so a retry with the same key never creates a
|
|
21
|
+
second invoice. 0.12.0 cached it as an ordinary failure.
|
|
22
|
+
- When the invoice is created but reading it back fails, the result is a
|
|
23
|
+
success with a `warning` and the invoice id, cached like any success.
|
|
24
|
+
- `paymentTermDays` must be a whole number of days (0–365). It still defaults
|
|
25
|
+
to 14, so the customer's own payment term applies only when it is passed.
|
|
26
|
+
- Returned `lines` no longer echo `reverse_charge_confirmation_text`; the
|
|
27
|
+
database sets the invoice's confirmation text.
|
|
28
|
+
- `kirjapro_send_invoice` declares `openWorldHint: true`: email and e-invoice
|
|
29
|
+
delivery are external effects. Only its fingerprint changes; the
|
|
30
|
+
`kirjapro_create_invoice` input schema and fingerprint are unchanged.
|
|
31
|
+
- `kirjapro://compliance/vat`: the reverse-charge `implementation_limits` now
|
|
32
|
+
says that `kirjapro_book_purchase` takes `deductionPercent` 0–100 with a
|
|
33
|
+
documented reason, also for reverse charge. 0.12.0 still said that the
|
|
34
|
+
parameter did not exist.
|
|
35
|
+
|
|
36
|
+
## [0.12.0] - 2026-10-04
|
|
37
|
+
|
|
38
|
+
Requires deployment of all seven migrations in the compliance batch before release:
|
|
39
|
+
|
|
40
|
+
1. `20261002140000_alv_era4a_rules`
|
|
41
|
+
2. `20261003090000_bank_vat_historical_supply_evidence`
|
|
42
|
+
3. `20261003103000_invoice_service_role_posting_guard`
|
|
43
|
+
4. `20261003150000_atomic_knowledge_corpus`
|
|
44
|
+
5. `20261003160000_purchase_vat_rate_basis`
|
|
45
|
+
6. `20261003160001_bank_purchase_vat_rate_basis`
|
|
46
|
+
7. `20261004080000_offer_financial_transfer` (U17)
|
|
47
|
+
|
|
48
|
+
Publish only after `db:deploy` and verification of the production-generated MCP database types. The U17 migration is required for `kirjapro_convert_offer_to_invoice` to preserve line discounts, the price-entry mode and line-specific VAT facts before the invoice lines are calculated.
|
|
49
|
+
|
|
50
|
+
- Invoice and offer tools accept `service_outside_eu` for general-rule B2B services to a non-EU business. The database posts to 5070 and reports field 309 with an AVL 65 § note. Check the receiving establishment and foreign buyer liability separately.
|
|
51
|
+
- This treatment supports PDF invoices. Finvoice transmission remains blocked pending complete O-category validation.
|
|
52
|
+
- VAT reconciliation no longer accepts manual purchase VAT rows as proof of a voucher link, even when net VAT is zero.
|
|
53
|
+
- New taxable purchases and single purchase templates require `vatRateBasis`: a documented supply/advance/period-end day, supply or EU-acquisition month, customs-acceptance day, or original-document reference and correction reason. Historical 24/14% rates are preserved; there is no blanket 12-month purchase-age limit. The posting date still selects the reporting period, which the caller must determine separately. Committed purchase retries return their original receipt before new evidence validation; a missing database capability refuses a new booking instead of silently dropping evidence.
|
|
54
|
+
- `kirjapro_book_purchase` accepts `deductionPercent` and `deductionReason`, retaining the original rounded VAT and its allocation group. On 18.40 € / 4.69 € at 60%, input VAT is 2.81 €, the remainder 1.88 €. Reverse charge always assesses the full buyer VAT, including entertainment and non-registered buyers' general-rule foreign services. These create one voucher with its facts; no additional manual VAT row is needed.
|
|
55
|
+
- The `import` category now means a customs VAT assessment on the complete customs tax base. It books only deductible VAT and any non-deductible tax against the full VAT liability. Supplier invoices and freight costs are booked separately; this command does not post the supplier cost or bank payment again. Outside-register imports remain outside this path.
|
|
56
|
+
- A positive-rate purchase retains its base/evidence when tax rounds to zero. Batch purchase templates remain refused when the batch command cannot write their facts, including zero-rounded tax. Updated tool fingerprints and server guidance reflect these contracts.
|
|
57
|
+
|
|
58
|
+
- Compliance resources now consume a generated package-local subset of the canonical regulatory registry. VAT history, payroll rates and micro/small thresholds no longer have a separate hand-maintained numeric table. Source reviews, legal validity and review-due dates are reported by topic and rule; source review expiry is distinct from an expired annual rate.
|
|
59
|
+
- Corrected conditional VAT deductions, historical 14% supplies/advances/credits, partial-deduction reverse charge, elective VAT-period boundaries, two-calendar-year small-business exemption, earnings-report/TyEL-payment guidance, invoice capability descriptions and retention start dates. Micro transition/odd-year interpretations remain expressly provisional. These resource changes do not make additional posting paths legally supported or deploy any database change.
|
|
60
|
+
|
|
61
|
+
## [0.11.0] - 2026-10-02
|
|
4
62
|
|
|
5
63
|
Requires the database migrations `20261002070106`–`20261002071619` (ALV report
|
|
6
64
|
audit batch 2), in particular `book_purchase_with_vat`, and
|