@dainamite/billing 0.17.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.
Files changed (248) hide show
  1. package/CHANGELOG.md +658 -0
  2. package/LICENSE +21 -0
  3. package/README.md +77 -0
  4. package/dist/modules/billing/acl.js +20 -0
  5. package/dist/modules/billing/acl.js.map +7 -0
  6. package/dist/modules/billing/api/accounts/route.js +182 -0
  7. package/dist/modules/billing/api/accounts/route.js.map +7 -0
  8. package/dist/modules/billing/api/export/account/[id]/route.js +170 -0
  9. package/dist/modules/billing/api/export/account/[id]/route.js.map +7 -0
  10. package/dist/modules/billing/api/invoices/[id]/route.js +85 -0
  11. package/dist/modules/billing/api/invoices/[id]/route.js.map +7 -0
  12. package/dist/modules/billing/api/invoices/add-line/route.js +69 -0
  13. package/dist/modules/billing/api/invoices/add-line/route.js.map +7 -0
  14. package/dist/modules/billing/api/invoices/edit-line/route.js +78 -0
  15. package/dist/modules/billing/api/invoices/edit-line/route.js.map +7 -0
  16. package/dist/modules/billing/api/invoices/post/route.js +74 -0
  17. package/dist/modules/billing/api/invoices/post/route.js.map +7 -0
  18. package/dist/modules/billing/api/invoices/remove-line/route.js +69 -0
  19. package/dist/modules/billing/api/invoices/remove-line/route.js.map +7 -0
  20. package/dist/modules/billing/api/invoices/route.js +109 -0
  21. package/dist/modules/billing/api/invoices/route.js.map +7 -0
  22. package/dist/modules/billing/api/items/bulk/route.js +74 -0
  23. package/dist/modules/billing/api/items/bulk/route.js.map +7 -0
  24. package/dist/modules/billing/api/items/route.js +224 -0
  25. package/dist/modules/billing/api/items/route.js.map +7 -0
  26. package/dist/modules/billing/api/openapi.js +25 -0
  27. package/dist/modules/billing/api/openapi.js.map +7 -0
  28. package/dist/modules/billing/api/run-outcomes/route.js +122 -0
  29. package/dist/modules/billing/api/run-outcomes/route.js.map +7 -0
  30. package/dist/modules/billing/api/runs/retry-failed/route.js +70 -0
  31. package/dist/modules/billing/api/runs/retry-failed/route.js.map +7 -0
  32. package/dist/modules/billing/api/runs/route.js +143 -0
  33. package/dist/modules/billing/api/runs/route.js.map +7 -0
  34. package/dist/modules/billing/api/test-invoices/wipe/route.js +65 -0
  35. package/dist/modules/billing/api/test-invoices/wipe/route.js.map +7 -0
  36. package/dist/modules/billing/api/usage/route.js +138 -0
  37. package/dist/modules/billing/api/usage/route.js.map +7 -0
  38. package/dist/modules/billing/backend/billing/accounts/[id]/page.js +402 -0
  39. package/dist/modules/billing/backend/billing/accounts/[id]/page.js.map +7 -0
  40. package/dist/modules/billing/backend/billing/accounts/[id]/page.meta.js +25 -0
  41. package/dist/modules/billing/backend/billing/accounts/[id]/page.meta.js.map +7 -0
  42. package/dist/modules/billing/backend/billing/accounts/create/page.js +82 -0
  43. package/dist/modules/billing/backend/billing/accounts/create/page.js.map +7 -0
  44. package/dist/modules/billing/backend/billing/accounts/create/page.meta.js +25 -0
  45. package/dist/modules/billing/backend/billing/accounts/create/page.meta.js.map +7 -0
  46. package/dist/modules/billing/backend/billing/accounts/page.js +173 -0
  47. package/dist/modules/billing/backend/billing/accounts/page.js.map +7 -0
  48. package/dist/modules/billing/backend/billing/accounts/page.meta.js +18 -0
  49. package/dist/modules/billing/backend/billing/accounts/page.meta.js.map +7 -0
  50. package/dist/modules/billing/backend/billing/invoices/[id]/page.js +500 -0
  51. package/dist/modules/billing/backend/billing/invoices/[id]/page.js.map +7 -0
  52. package/dist/modules/billing/backend/billing/invoices/[id]/page.meta.js +25 -0
  53. package/dist/modules/billing/backend/billing/invoices/[id]/page.meta.js.map +7 -0
  54. package/dist/modules/billing/backend/billing/invoices/page.js +187 -0
  55. package/dist/modules/billing/backend/billing/invoices/page.js.map +7 -0
  56. package/dist/modules/billing/backend/billing/invoices/page.meta.js +18 -0
  57. package/dist/modules/billing/backend/billing/invoices/page.meta.js.map +7 -0
  58. package/dist/modules/billing/backend/billing/items/[id]/page.js +265 -0
  59. package/dist/modules/billing/backend/billing/items/[id]/page.js.map +7 -0
  60. package/dist/modules/billing/backend/billing/items/[id]/page.meta.js +25 -0
  61. package/dist/modules/billing/backend/billing/items/[id]/page.meta.js.map +7 -0
  62. package/dist/modules/billing/backend/billing/items/create/page.js +90 -0
  63. package/dist/modules/billing/backend/billing/items/create/page.js.map +7 -0
  64. package/dist/modules/billing/backend/billing/items/create/page.meta.js +25 -0
  65. package/dist/modules/billing/backend/billing/items/create/page.meta.js.map +7 -0
  66. package/dist/modules/billing/backend/billing/items/page.js +208 -0
  67. package/dist/modules/billing/backend/billing/items/page.js.map +7 -0
  68. package/dist/modules/billing/backend/billing/items/page.meta.js +18 -0
  69. package/dist/modules/billing/backend/billing/items/page.meta.js.map +7 -0
  70. package/dist/modules/billing/backend/billing/runs/[id]/page.js +293 -0
  71. package/dist/modules/billing/backend/billing/runs/[id]/page.js.map +7 -0
  72. package/dist/modules/billing/backend/billing/runs/[id]/page.meta.js +21 -0
  73. package/dist/modules/billing/backend/billing/runs/[id]/page.meta.js.map +7 -0
  74. package/dist/modules/billing/backend/billing/runs/page.js +341 -0
  75. package/dist/modules/billing/backend/billing/runs/page.js.map +7 -0
  76. package/dist/modules/billing/backend/billing/runs/page.meta.js +18 -0
  77. package/dist/modules/billing/backend/billing/runs/page.meta.js.map +7 -0
  78. package/dist/modules/billing/backend/billing/usage/create/page.js +100 -0
  79. package/dist/modules/billing/backend/billing/usage/create/page.js.map +7 -0
  80. package/dist/modules/billing/backend/billing/usage/create/page.meta.js +25 -0
  81. package/dist/modules/billing/backend/billing/usage/create/page.meta.js.map +7 -0
  82. package/dist/modules/billing/ce.js +56 -0
  83. package/dist/modules/billing/ce.js.map +7 -0
  84. package/dist/modules/billing/cli.js +67 -0
  85. package/dist/modules/billing/cli.js.map +7 -0
  86. package/dist/modules/billing/commands/accounts.js +157 -0
  87. package/dist/modules/billing/commands/accounts.js.map +7 -0
  88. package/dist/modules/billing/commands/index.js +6 -0
  89. package/dist/modules/billing/commands/index.js.map +7 -0
  90. package/dist/modules/billing/commands/invoices.js +401 -0
  91. package/dist/modules/billing/commands/invoices.js.map +7 -0
  92. package/dist/modules/billing/commands/items.js +317 -0
  93. package/dist/modules/billing/commands/items.js.map +7 -0
  94. package/dist/modules/billing/commands/runs.js +123 -0
  95. package/dist/modules/billing/commands/runs.js.map +7 -0
  96. package/dist/modules/billing/commands/usage.js +88 -0
  97. package/dist/modules/billing/commands/usage.js.map +7 -0
  98. package/dist/modules/billing/components/AccountForm.js +420 -0
  99. package/dist/modules/billing/components/AccountForm.js.map +7 -0
  100. package/dist/modules/billing/components/DetailFields.js +37 -0
  101. package/dist/modules/billing/components/DetailFields.js.map +7 -0
  102. package/dist/modules/billing/components/ItemForm.js +440 -0
  103. package/dist/modules/billing/components/ItemForm.js.map +7 -0
  104. package/dist/modules/billing/components/LineFormDialog.js +195 -0
  105. package/dist/modules/billing/components/LineFormDialog.js.map +7 -0
  106. package/dist/modules/billing/components/UsageForm.js +262 -0
  107. package/dist/modules/billing/components/UsageForm.js.map +7 -0
  108. package/dist/modules/billing/data/entities.js +433 -0
  109. package/dist/modules/billing/data/entities.js.map +7 -0
  110. package/dist/modules/billing/data/entityIds.js +12 -0
  111. package/dist/modules/billing/data/entityIds.js.map +7 -0
  112. package/dist/modules/billing/data/validators.js +396 -0
  113. package/dist/modules/billing/data/validators.js.map +7 -0
  114. package/dist/modules/billing/di.js +6 -0
  115. package/dist/modules/billing/di.js.map +7 -0
  116. package/dist/modules/billing/events.js +35 -0
  117. package/dist/modules/billing/events.js.map +7 -0
  118. package/dist/modules/billing/i18n/en.json +336 -0
  119. package/dist/modules/billing/i18n/pl.json +336 -0
  120. package/dist/modules/billing/index.js +17 -0
  121. package/dist/modules/billing/index.js.map +7 -0
  122. package/dist/modules/billing/lib/billPeriod.js +101 -0
  123. package/dist/modules/billing/lib/billPeriod.js.map +7 -0
  124. package/dist/modules/billing/lib/billRunEngine.js +256 -0
  125. package/dist/modules/billing/lib/billRunEngine.js.map +7 -0
  126. package/dist/modules/billing/lib/billRunLabel.js +8 -0
  127. package/dist/modules/billing/lib/billRunLabel.js.map +7 -0
  128. package/dist/modules/billing/lib/idempotency.js +13 -0
  129. package/dist/modules/billing/lib/idempotency.js.map +7 -0
  130. package/dist/modules/billing/lib/invoiceStatus.js +38 -0
  131. package/dist/modules/billing/lib/invoiceStatus.js.map +7 -0
  132. package/dist/modules/billing/lib/invoiceWriter.js +153 -0
  133. package/dist/modules/billing/lib/invoiceWriter.js.map +7 -0
  134. package/dist/modules/billing/lib/itemSelector.js +77 -0
  135. package/dist/modules/billing/lib/itemSelector.js.map +7 -0
  136. package/dist/modules/billing/lib/seeds/demo.js +130 -0
  137. package/dist/modules/billing/lib/seeds/demo.js.map +7 -0
  138. package/dist/modules/billing/lib/tenantLock.js +32 -0
  139. package/dist/modules/billing/lib/tenantLock.js.map +7 -0
  140. package/dist/modules/billing/lib/usageRater.js +150 -0
  141. package/dist/modules/billing/lib/usageRater.js.map +7 -0
  142. package/dist/modules/billing/lib/usageRunner.js +82 -0
  143. package/dist/modules/billing/lib/usageRunner.js.map +7 -0
  144. package/dist/modules/billing/migrations/Migration20260519000000_billing.js +144 -0
  145. package/dist/modules/billing/migrations/Migration20260519000000_billing.js.map +7 -0
  146. package/dist/modules/billing/setup.js +190 -0
  147. package/dist/modules/billing/setup.js.map +7 -0
  148. package/dist/modules/billing/subscribers/payment-captured-to-paid.js +47 -0
  149. package/dist/modules/billing/subscribers/payment-captured-to-paid.js.map +7 -0
  150. package/dist/modules/billing/translations.js +5 -0
  151. package/dist/modules/billing/translations.js.map +7 -0
  152. package/dist/modules/billing/workers/reap-stale-bill-runs.js +31 -0
  153. package/dist/modules/billing/workers/reap-stale-bill-runs.js.map +7 -0
  154. package/package.json +148 -0
  155. package/src/modules/billing/__integration__/TC-BILL-001.spec.ts +116 -0
  156. package/src/modules/billing/__integration__/TC-BILL-002.spec.ts +169 -0
  157. package/src/modules/billing/__integration__/TC-BILL-003.spec.ts +28 -0
  158. package/src/modules/billing/__integration__/meta.ts +4 -0
  159. package/src/modules/billing/__tests__/commands/invoices.test.ts +464 -0
  160. package/src/modules/billing/__tests__/commands/itemsBulk.test.ts +284 -0
  161. package/src/modules/billing/__tests__/lib/billPeriod.test.ts +131 -0
  162. package/src/modules/billing/__tests__/lib/billRunEngine.test.ts +561 -0
  163. package/src/modules/billing/__tests__/lib/idempotency.test.ts +81 -0
  164. package/src/modules/billing/__tests__/lib/invoiceStatus.test.ts +97 -0
  165. package/src/modules/billing/__tests__/lib/invoiceWriter.test.ts +119 -0
  166. package/src/modules/billing/__tests__/lib/itemSelector.test.ts +192 -0
  167. package/src/modules/billing/__tests__/lib/seedsDemo.test.ts +86 -0
  168. package/src/modules/billing/__tests__/lib/tenantLock.test.ts +126 -0
  169. package/src/modules/billing/__tests__/lib/usageRater.test.ts +190 -0
  170. package/src/modules/billing/__tests__/package-isolation.test.ts +223 -0
  171. package/src/modules/billing/__tests__/setup.test.ts +107 -0
  172. package/src/modules/billing/__tests__/validators.test.ts +594 -0
  173. package/src/modules/billing/acl.ts +16 -0
  174. package/src/modules/billing/api/accounts/route.ts +198 -0
  175. package/src/modules/billing/api/export/account/[id]/route.ts +233 -0
  176. package/src/modules/billing/api/invoices/[id]/route.ts +143 -0
  177. package/src/modules/billing/api/invoices/add-line/route.ts +74 -0
  178. package/src/modules/billing/api/invoices/edit-line/route.ts +97 -0
  179. package/src/modules/billing/api/invoices/post/route.ts +97 -0
  180. package/src/modules/billing/api/invoices/remove-line/route.ts +75 -0
  181. package/src/modules/billing/api/invoices/route.ts +167 -0
  182. package/src/modules/billing/api/items/bulk/route.ts +92 -0
  183. package/src/modules/billing/api/items/route.ts +255 -0
  184. package/src/modules/billing/api/openapi.ts +33 -0
  185. package/src/modules/billing/api/run-outcomes/route.ts +149 -0
  186. package/src/modules/billing/api/runs/retry-failed/route.ts +88 -0
  187. package/src/modules/billing/api/runs/route.ts +170 -0
  188. package/src/modules/billing/api/test-invoices/wipe/route.ts +87 -0
  189. package/src/modules/billing/api/usage/route.ts +148 -0
  190. package/src/modules/billing/backend/billing/accounts/[id]/page.meta.ts +23 -0
  191. package/src/modules/billing/backend/billing/accounts/[id]/page.tsx +574 -0
  192. package/src/modules/billing/backend/billing/accounts/create/page.meta.ts +23 -0
  193. package/src/modules/billing/backend/billing/accounts/create/page.tsx +101 -0
  194. package/src/modules/billing/backend/billing/accounts/page.meta.ts +16 -0
  195. package/src/modules/billing/backend/billing/accounts/page.tsx +222 -0
  196. package/src/modules/billing/backend/billing/invoices/[id]/page.meta.ts +23 -0
  197. package/src/modules/billing/backend/billing/invoices/[id]/page.tsx +613 -0
  198. package/src/modules/billing/backend/billing/invoices/page.meta.ts +16 -0
  199. package/src/modules/billing/backend/billing/invoices/page.tsx +245 -0
  200. package/src/modules/billing/backend/billing/items/[id]/page.meta.ts +23 -0
  201. package/src/modules/billing/backend/billing/items/[id]/page.tsx +366 -0
  202. package/src/modules/billing/backend/billing/items/create/page.meta.ts +23 -0
  203. package/src/modules/billing/backend/billing/items/create/page.tsx +110 -0
  204. package/src/modules/billing/backend/billing/items/page.meta.ts +16 -0
  205. package/src/modules/billing/backend/billing/items/page.tsx +272 -0
  206. package/src/modules/billing/backend/billing/runs/[id]/page.meta.ts +19 -0
  207. package/src/modules/billing/backend/billing/runs/[id]/page.tsx +404 -0
  208. package/src/modules/billing/backend/billing/runs/page.meta.ts +16 -0
  209. package/src/modules/billing/backend/billing/runs/page.tsx +426 -0
  210. package/src/modules/billing/backend/billing/usage/create/page.meta.ts +23 -0
  211. package/src/modules/billing/backend/billing/usage/create/page.tsx +120 -0
  212. package/src/modules/billing/ce.ts +74 -0
  213. package/src/modules/billing/cli.ts +89 -0
  214. package/src/modules/billing/commands/accounts.ts +205 -0
  215. package/src/modules/billing/commands/index.ts +13 -0
  216. package/src/modules/billing/commands/invoices.ts +542 -0
  217. package/src/modules/billing/commands/items.ts +438 -0
  218. package/src/modules/billing/commands/runs.ts +166 -0
  219. package/src/modules/billing/commands/usage.ts +118 -0
  220. package/src/modules/billing/components/AccountForm.tsx +517 -0
  221. package/src/modules/billing/components/DetailFields.tsx +60 -0
  222. package/src/modules/billing/components/ItemForm.tsx +558 -0
  223. package/src/modules/billing/components/LineFormDialog.tsx +253 -0
  224. package/src/modules/billing/components/UsageForm.tsx +326 -0
  225. package/src/modules/billing/data/entities.ts +533 -0
  226. package/src/modules/billing/data/entityIds.ts +25 -0
  227. package/src/modules/billing/data/validators.ts +562 -0
  228. package/src/modules/billing/di.ts +14 -0
  229. package/src/modules/billing/events.ts +47 -0
  230. package/src/modules/billing/i18n/en.json +336 -0
  231. package/src/modules/billing/i18n/pl.json +336 -0
  232. package/src/modules/billing/index.ts +22 -0
  233. package/src/modules/billing/lib/billPeriod.ts +181 -0
  234. package/src/modules/billing/lib/billRunEngine.ts +416 -0
  235. package/src/modules/billing/lib/billRunLabel.ts +14 -0
  236. package/src/modules/billing/lib/idempotency.ts +46 -0
  237. package/src/modules/billing/lib/invoiceStatus.ts +61 -0
  238. package/src/modules/billing/lib/invoiceWriter.ts +260 -0
  239. package/src/modules/billing/lib/itemSelector.ts +154 -0
  240. package/src/modules/billing/lib/seeds/demo.ts +199 -0
  241. package/src/modules/billing/lib/tenantLock.ts +87 -0
  242. package/src/modules/billing/lib/usageRater.ts +250 -0
  243. package/src/modules/billing/lib/usageRunner.ts +189 -0
  244. package/src/modules/billing/migrations/Migration20260519000000_billing.ts +175 -0
  245. package/src/modules/billing/setup.ts +252 -0
  246. package/src/modules/billing/subscribers/payment-captured-to-paid.ts +89 -0
  247. package/src/modules/billing/translations.ts +9 -0
  248. package/src/modules/billing/workers/reap-stale-bill-runs.ts +57 -0
@@ -0,0 +1,336 @@
1
+ {
2
+ "billing.accounts.actions.open": "Open",
3
+ "billing.accounts.columns.currency": "Currency",
4
+ "billing.accounts.columns.customer": "Customer",
5
+ "billing.accounts.columns.cycle": "Cycle",
6
+ "billing.accounts.columns.last_bill": "Last bill",
7
+ "billing.accounts.columns.name": "Name",
8
+ "billing.accounts.columns.next_bill": "Next bill",
9
+ "billing.accounts.columns.status": "Status",
10
+ "billing.accounts.create.action": "New account",
11
+ "billing.accounts.create.error": "Failed to create account",
12
+ "billing.accounts.create.success": "Billing account created",
13
+ "billing.accounts.create.title": "Create Billing Account",
14
+ "billing.accounts.detail.add_item": "Add item",
15
+ "billing.accounts.detail.add_usage": "Add usage",
16
+ "billing.accounts.detail.delete.action": "Soft delete",
17
+ "billing.accounts.detail.delete.confirm.button": "Soft delete",
18
+ "billing.accounts.detail.delete.confirm.text": "Soft-deletes the account. Its items + usage records stay in the database for audit; the Bill Run engine will stop picking it up immediately.",
19
+ "billing.accounts.detail.delete.confirm.title": "Delete account?",
20
+ "billing.accounts.detail.delete.error": "Delete failed",
21
+ "billing.accounts.detail.delete.in_progress": "Deleting…",
22
+ "billing.accounts.detail.delete.success": "Account deleted",
23
+ "billing.accounts.detail.error.load": "Failed to load account",
24
+ "billing.accounts.detail.error.not_found": "Account not found",
25
+ "billing.accounts.detail.items.empty": "No items for this account yet.",
26
+ "billing.accounts.detail.items.title": "Items",
27
+ "billing.accounts.detail.loading": "Loading account…",
28
+ "billing.accounts.detail.save.error": "Save failed",
29
+ "billing.accounts.detail.save.success": "Account updated",
30
+ "billing.accounts.detail.title": "Billing Account",
31
+ "billing.accounts.detail.usage.empty": "No usage records for this account yet.",
32
+ "billing.accounts.detail.usage.title": "Usage",
33
+ "billing.accounts.detail.view_items": "View items",
34
+ "billing.accounts.filters.active": "Active",
35
+ "billing.accounts.filters.currency": "Currency",
36
+ "billing.accounts.filters.cycle": "Bill cycle",
37
+ "billing.accounts.form.active": "Active",
38
+ "billing.accounts.form.active.help": "Inactive accounts stay billable until soft-deleted — toggle for visibility filtering only.",
39
+ "billing.accounts.form.address.city": "City",
40
+ "billing.accounts.form.address.country": "Country (ISO 3166)",
41
+ "billing.accounts.form.address.line1": "Line 1",
42
+ "billing.accounts.form.address.line2": "Line 2",
43
+ "billing.accounts.form.address.postal_code": "Postal code",
44
+ "billing.accounts.form.address.title": "Invoice address",
45
+ "billing.accounts.form.bill_cycle": "Bill cycle",
46
+ "billing.accounts.form.cancel_hint": "to discard",
47
+ "billing.accounts.form.create": "Create account",
48
+ "billing.accounts.form.currency": "Currency (ISO 4217)",
49
+ "billing.accounts.form.currency.locked": "Immutable — frozen at account create time.",
50
+ "billing.accounts.form.customer": "Customer",
51
+ "billing.accounts.form.customer.placeholder": "Search customers by name or email…",
52
+ "billing.accounts.form.customer_id": "Customer ID",
53
+ "billing.accounts.form.customer_id.locked": "Immutable — create a new account to re-link the customer.",
54
+ "billing.accounts.form.cycle_anchor": "Cycle anchor",
55
+ "billing.accounts.form.cycle_anchor.month_hint": "1 — 28",
56
+ "billing.accounts.form.cycle_anchor.weekly_hint": "mon | tue | … | sun",
57
+ "billing.accounts.form.error.address_required": "Invoice address (line 1 + city) is required",
58
+ "billing.accounts.form.error.currency_invalid": "Currency must be a 3-letter ISO code",
59
+ "billing.accounts.form.error.customerId_required": "Please select a customer",
60
+ "billing.accounts.form.error.email_invalid": "Invoice email looks invalid",
61
+ "billing.accounts.form.error.name_required": "Name is required",
62
+ "billing.accounts.form.error.next_bill_date_required": "Next bill date is required",
63
+ "billing.accounts.form.invoice_email": "Invoice email",
64
+ "billing.accounts.form.invoice_language": "Invoice language (ISO 639-1)",
65
+ "billing.accounts.form.name": "Name",
66
+ "billing.accounts.form.name.placeholder": "Auto-filled from customer — override e.g. \"Acme — production\"",
67
+ "billing.accounts.form.next_bill_date": "Next bill date",
68
+ "billing.accounts.form.save": "Save changes",
69
+ "billing.accounts.form.saving": "Saving…",
70
+ "billing.accounts.form.submit_hint": "to save,",
71
+ "billing.accounts.form.tax_id": "Tax ID (NIP / VATIN, optional)",
72
+ "billing.accounts.title": "Billing Accounts",
73
+ "billing.common.active": "Active",
74
+ "billing.common.cancel": "Cancel",
75
+ "billing.common.edit": "Edit",
76
+ "billing.common.id": "ID",
77
+ "billing.common.inactive": "Inactive",
78
+ "billing.common.refresh": "Refresh",
79
+ "billing.common.save": "Save",
80
+ "billing.common.yes": "Yes",
81
+ "billing.cycle.annually": "Annually",
82
+ "billing.cycle.monthly": "Monthly",
83
+ "billing.cycle.quarterly": "Quarterly",
84
+ "billing.cycle.weekly": "Weekly",
85
+ "billing.invoices.actions.open": "Open",
86
+ "billing.invoices.columns.issued": "Issued",
87
+ "billing.invoices.columns.number": "Number",
88
+ "billing.invoices.columns.outstanding": "Outstanding",
89
+ "billing.invoices.columns.period": "Period",
90
+ "billing.invoices.columns.status": "Status",
91
+ "billing.invoices.columns.total": "Total",
92
+ "billing.invoices.detail.error.load": "Failed to load invoice",
93
+ "billing.invoices.detail.field.account": "Billing Account",
94
+ "billing.invoices.detail.field.bill_run": "Bill Run",
95
+ "billing.invoices.detail.field.issued": "Issued",
96
+ "billing.invoices.detail.field.period": "Bill period",
97
+ "billing.invoices.detail.loading": "Loading invoice…",
98
+ "billing.invoices.detail.outstanding": "Outstanding",
99
+ "billing.invoices.detail.paid": "Paid",
100
+ "billing.invoices.detail.subtotal": "Subtotal net",
101
+ "billing.invoices.detail.title": "Billing Invoice",
102
+ "billing.invoices.detail.total": "Grand total",
103
+ "billing.invoices.filters.status": "Status",
104
+ "billing.invoices.filters.test_run": "Test runs",
105
+ "billing.invoices.filters.test_run.exclude": "Exclude test",
106
+ "billing.invoices.filters.test_run.only": "Only test",
107
+ "billing.invoices.lines.actions.edit": "Edit line",
108
+ "billing.invoices.lines.actions.remove": "Remove line",
109
+ "billing.invoices.lines.add.action": "Add line",
110
+ "billing.invoices.lines.add.success": "Line added",
111
+ "billing.invoices.lines.columns.description": "Description",
112
+ "billing.invoices.lines.columns.quantity": "Qty",
113
+ "billing.invoices.lines.columns.total": "Total net",
114
+ "billing.invoices.lines.columns.unit_price": "Unit price",
115
+ "billing.invoices.lines.edit.success": "Line updated",
116
+ "billing.invoices.lines.form.cancel_hint": "to cancel",
117
+ "billing.invoices.lines.form.computed_total": "Computed total: {computed}",
118
+ "billing.invoices.lines.form.description": "Description",
119
+ "billing.invoices.lines.form.error.description_required": "Description is required",
120
+ "billing.invoices.lines.form.error.quantity_invalid": "Quantity must be a non-negative number",
121
+ "billing.invoices.lines.form.error.total_invalid": "Total override must be a number when set",
122
+ "billing.invoices.lines.form.error.unit_price_invalid": "Unit price must be a number",
123
+ "billing.invoices.lines.form.help": "Changes are recorded in the draft-edit audit log.",
124
+ "billing.invoices.lines.form.quantity": "Quantity",
125
+ "billing.invoices.lines.form.saving": "Saving…",
126
+ "billing.invoices.lines.form.submit_hint": "to save,",
127
+ "billing.invoices.lines.form.title_add": "Add invoice line",
128
+ "billing.invoices.lines.form.title_edit": "Edit invoice line",
129
+ "billing.invoices.lines.form.total_override": "Total override (optional)",
130
+ "billing.invoices.lines.form.unit_price": "Unit price (net)",
131
+ "billing.invoices.lines.operator_added": "Operator-added",
132
+ "billing.invoices.lines.remove.confirm.button": "Remove line",
133
+ "billing.invoices.lines.remove.confirm.text": "The line will be deleted and recorded in the draft-edit audit log.",
134
+ "billing.invoices.lines.remove.confirm.title": "Remove line?",
135
+ "billing.invoices.lines.remove.error": "Remove failed",
136
+ "billing.invoices.lines.remove.success": "Line removed",
137
+ "billing.invoices.lines.save.error": "Save failed",
138
+ "billing.invoices.lines.title": "Lines",
139
+ "billing.invoices.post.action": "Post invoice",
140
+ "billing.invoices.post.error": "Post failed",
141
+ "billing.invoices.post.in_progress": "Posting…",
142
+ "billing.invoices.post.success": "Invoice posted",
143
+ "billing.invoices.status.draft": "Draft",
144
+ "billing.invoices.status.paid": "Paid",
145
+ "billing.invoices.status.posted": "Posted",
146
+ "billing.invoices.status.void": "Void",
147
+ "billing.invoices.title": "Billing Invoices",
148
+ "billing.invoices.wipe.action": "Wipe test invoices for this run",
149
+ "billing.invoices.wipe.confirm.button": "Delete test invoices",
150
+ "billing.invoices.wipe.confirm.text": "Every test invoice from this Bill Run will be permanently deleted. This cannot be undone.",
151
+ "billing.invoices.wipe.confirm.title": "Wipe test invoices?",
152
+ "billing.invoices.wipe.error": "Wipe failed",
153
+ "billing.invoices.wipe.in_progress": "Wiping…",
154
+ "billing.invoices.wipe.success": "Test invoices removed",
155
+ "billing.items.actions.open": "Open",
156
+ "billing.items.columns.account": "Account",
157
+ "billing.items.columns.description": "Description",
158
+ "billing.items.columns.end": "End",
159
+ "billing.items.columns.start": "Start",
160
+ "billing.items.columns.status": "Status",
161
+ "billing.items.columns.type": "Type",
162
+ "billing.items.columns.uom": "UoM",
163
+ "billing.items.create.action": "New item",
164
+ "billing.items.create.error": "Failed to create item",
165
+ "billing.items.create.loading": "Loading accounts…",
166
+ "billing.items.create.success": "Billing item created",
167
+ "billing.items.create.title": "Create Billing Item",
168
+ "billing.items.detail.billed_to": "Billed through {date}",
169
+ "billing.items.detail.currency_mismatch": "Currency mismatch",
170
+ "billing.items.detail.delete.action": "Soft delete",
171
+ "billing.items.detail.delete.confirm.button": "Soft delete",
172
+ "billing.items.detail.delete.confirm.text": "Soft-deletes the item. Its row stays in the database for audit; the Bill Run engine will stop including it immediately.",
173
+ "billing.items.detail.delete.confirm.title": "Delete item?",
174
+ "billing.items.detail.delete.error": "Delete failed",
175
+ "billing.items.detail.delete.in_progress": "Deleting…",
176
+ "billing.items.detail.delete.success": "Item deleted",
177
+ "billing.items.detail.error.load": "Failed to load item",
178
+ "billing.items.detail.error.not_found": "Item not found",
179
+ "billing.items.detail.field.account": "Account",
180
+ "billing.items.detail.field.billed_to": "Billed through",
181
+ "billing.items.detail.field.source_ref": "Source ref",
182
+ "billing.items.detail.loading": "Loading item…",
183
+ "billing.items.detail.save.error": "Save failed",
184
+ "billing.items.detail.save.success": "Item updated",
185
+ "billing.items.detail.source_ref": "source_ref: {ref}",
186
+ "billing.items.detail.title": "Billing Item",
187
+ "billing.items.filters.account": "Billing Account",
188
+ "billing.items.filters.active": "Active",
189
+ "billing.items.filters.subscription": "Subscription ID",
190
+ "billing.items.filters.type": "Type",
191
+ "billing.items.form.account": "Billing Account",
192
+ "billing.items.form.account.placeholder": "Select an account",
193
+ "billing.items.form.active": "Active",
194
+ "billing.items.form.active.help": "Inactive items are skipped by the Bill Run engine.",
195
+ "billing.items.form.cancel_hint": "to discard",
196
+ "billing.items.form.create": "Create item",
197
+ "billing.items.form.description": "Description",
198
+ "billing.items.form.description.help": "Shown verbatim on the invoice line.",
199
+ "billing.items.form.end_date": "Bill end date (optional)",
200
+ "billing.items.form.error.account_required": "Billing Account is required",
201
+ "billing.items.form.error.amount_invalid": "Amount must be a number",
202
+ "billing.items.form.error.description_required": "Description is required",
203
+ "billing.items.form.error.start_date_required": "Bill start date is required",
204
+ "billing.items.form.error.tiered_json": "Tiered rate JSON is not valid JSON",
205
+ "billing.items.form.error.tiered_required": "Tiered rate JSON is required for tiered usage",
206
+ "billing.items.form.error.tiered_shape": "Tiered JSON must include `model` and `tiers`",
207
+ "billing.items.form.error.unit_price_invalid": "Unit price must be a non-negative number",
208
+ "billing.items.form.error.uom_required": "UoM code is required for usage items",
209
+ "billing.items.form.rate.amount": "Amount",
210
+ "billing.items.form.rate.amount.help": "Negative allowed for refunds / credits / proration credits.",
211
+ "billing.items.form.rate.tiered_json": "Tiered rate JSON",
212
+ "billing.items.form.rate.tiered_json.help": "Models: volume / graduated / flat. Exactly one tier must have `up_to: null` (the open-ended top tier). Server-side validators reject malformed shapes.",
213
+ "billing.items.form.rate.title": "Rate",
214
+ "billing.items.form.rate.unit_price_recurring": "Unit price per cycle",
215
+ "billing.items.form.rate.unit_price_usage": "Unit price per unit consumed",
216
+ "billing.items.form.rate.usage_mode": "Rate model",
217
+ "billing.items.form.rate.usage_mode.simple": "Simple flat rate",
218
+ "billing.items.form.rate.usage_mode.tiered": "Tiered (volume / graduated / flat)",
219
+ "billing.items.form.refs.title": "External references (optional)",
220
+ "billing.items.form.save": "Save changes",
221
+ "billing.items.form.saving": "Saving…",
222
+ "billing.items.form.start_date": "Bill start date",
223
+ "billing.items.form.submit_hint": "to save,",
224
+ "billing.items.form.subscription_id": "Subscription ID",
225
+ "billing.items.form.subscription_item_id": "Subscription item ID",
226
+ "billing.items.form.type": "Type",
227
+ "billing.items.form.type.one_time": "One-time charge",
228
+ "billing.items.form.type.recurring": "Recurring (per cycle)",
229
+ "billing.items.form.type.usage": "Usage (metered)",
230
+ "billing.items.form.uom_code": "UoM code",
231
+ "billing.items.form.uom_code.help": "Must exactly match the `uom_code` on usage records. No conversion.",
232
+ "billing.items.title": "Billing Items",
233
+ "billing.items.type.one_time": "One-time",
234
+ "billing.items.type.recurring": "Recurring",
235
+ "billing.items.type.usage": "Usage",
236
+ "billing.runs.actions.open": "Open",
237
+ "billing.runs.columns.accounts": "Accounts",
238
+ "billing.runs.columns.as_of_date": "As-of date",
239
+ "billing.runs.columns.drafts": "Drafts",
240
+ "billing.runs.columns.failed": "Failed",
241
+ "billing.runs.columns.finished_at": "Finished",
242
+ "billing.runs.columns.name": "Bill Run",
243
+ "billing.runs.columns.started_at": "Started",
244
+ "billing.runs.columns.status": "Status",
245
+ "billing.runs.columns.triggered_by": "Trigger",
246
+ "billing.runs.detail.error.load": "Failed to load run",
247
+ "billing.runs.detail.error.not_found": "Run not found",
248
+ "billing.runs.detail.field.as_of_date": "As-of date",
249
+ "billing.runs.detail.field.finished_at": "Finished",
250
+ "billing.runs.detail.field.mode": "Mode",
251
+ "billing.runs.detail.field.parent_run": "Parent run",
252
+ "billing.runs.detail.field.run_id": "Run ID",
253
+ "billing.runs.detail.field.started_at": "Started",
254
+ "billing.runs.detail.field.triggered_by": "Trigger",
255
+ "billing.runs.detail.loading": "Loading run…",
256
+ "billing.runs.detail.title": "Bill Run",
257
+ "billing.runs.filters.status": "Status",
258
+ "billing.runs.filters.triggered_by": "Trigger",
259
+ "billing.runs.outcomes.columns.account": "Account",
260
+ "billing.runs.outcomes.columns.error": "Error",
261
+ "billing.runs.outcomes.columns.invoice": "Invoice",
262
+ "billing.runs.outcomes.columns.status": "Status",
263
+ "billing.runs.outcomes.columns.warnings": "Warnings",
264
+ "billing.runs.outcomes.title": "Per-account outcomes",
265
+ "billing.runs.retry.action": "Retry failed accounts",
266
+ "billing.runs.retry.error": "Retry failed",
267
+ "billing.runs.retry.in_progress": "Retrying…",
268
+ "billing.runs.retry.success": "Retry run created",
269
+ "billing.runs.status.completed": "Completed",
270
+ "billing.runs.status.failed": "Failed",
271
+ "billing.runs.status.partial_failure": "Partial failure",
272
+ "billing.runs.status.running": "Running",
273
+ "billing.runs.summary.accounts": "Accounts",
274
+ "billing.runs.summary.drafts": "Drafts",
275
+ "billing.runs.summary.failed": "Failed",
276
+ "billing.runs.summary.skipped": "Skipped",
277
+ "billing.runs.summary.title": "Summary",
278
+ "billing.runs.summary.usage": "Usage rated",
279
+ "billing.runs.summary.warnings": "Warnings",
280
+ "billing.runs.mode.catch_up": "Catch-up",
281
+ "billing.runs.mode.dry_run": "Dry-run",
282
+ "billing.runs.mode.real": "Real",
283
+ "billing.runs.mode.test": "Test",
284
+ "billing.runs.title": "Bill Runs",
285
+ "billing.runs.trigger.action": "New run",
286
+ "billing.runs.trigger.dialog.as_of_date": "As-of date",
287
+ "billing.runs.trigger.dialog.as_of_date.help": "Accounts whose next bill date is on or before this date will be billed.",
288
+ "billing.runs.trigger.dialog.cancel_hint": "to cancel",
289
+ "billing.runs.trigger.dialog.description": "Runs the bill cycle for every account whose next bill date has passed. Dry-run / Test produce drafts without posting any invoices.",
290
+ "billing.runs.trigger.dialog.mode": "Mode",
291
+ "billing.runs.trigger.dialog.mode.dry": "Dry-run — no rows written",
292
+ "billing.runs.trigger.dialog.mode.real": "Real — create draft invoices",
293
+ "billing.runs.trigger.dialog.mode.test": "Test — drafts tagged for cleanup",
294
+ "billing.runs.trigger.dialog.running": "Running…",
295
+ "billing.runs.trigger.dialog.submit": "Run now",
296
+ "billing.runs.trigger.dialog.submit_hint": "to run,",
297
+ "billing.runs.trigger.dialog.title": "Trigger Bill Run",
298
+ "billing.runs.trigger.error": "Failed to trigger run",
299
+ "billing.runs.trigger.manual": "Manual",
300
+ "billing.runs.trigger.schedule": "Schedule",
301
+ "billing.runs.trigger.success": "Bill Run triggered",
302
+ "billing.usage.columns.description": "Description",
303
+ "billing.usage.columns.period": "Period",
304
+ "billing.usage.columns.quantity": "Quantity",
305
+ "billing.usage.columns.rated": "Rated",
306
+ "billing.usage.columns.uom": "Unit",
307
+ "billing.usage.create.deduplicated": "A usage record with that source reference already existed — nothing was duplicated.",
308
+ "billing.usage.create.error": "Failed to record usage",
309
+ "billing.usage.create.loading": "Loading accounts…",
310
+ "billing.usage.create.success": "Usage record created",
311
+ "billing.usage.create.title": "Record Usage",
312
+ "billing.usage.form.account": "Billing Account",
313
+ "billing.usage.form.account.placeholder": "Select an account",
314
+ "billing.usage.form.cancel_hint": "to discard",
315
+ "billing.usage.form.create": "Record usage",
316
+ "billing.usage.form.description": "Description (optional)",
317
+ "billing.usage.form.description.help": "Shown on its own invoice line when set; otherwise matching records are aggregated into one line.",
318
+ "billing.usage.form.error.account_required": "Billing Account is required",
319
+ "billing.usage.form.error.period_order": "Period end must be on or after period start",
320
+ "billing.usage.form.error.period_required": "Period start and end are required",
321
+ "billing.usage.form.error.quantity_invalid": "Quantity must be a non-negative number",
322
+ "billing.usage.form.error.uom_required": "UoM code is required",
323
+ "billing.usage.form.period_end": "Period end",
324
+ "billing.usage.form.period_start": "Period start",
325
+ "billing.usage.form.quantity": "Quantity",
326
+ "billing.usage.form.quantity.help": "Total units consumed in the period (pre-aggregated).",
327
+ "billing.usage.form.saving": "Saving…",
328
+ "billing.usage.form.source_ref": "Source reference (optional)",
329
+ "billing.usage.form.source_ref.help": "Idempotency key — re-submitting the same reference for this account is deduplicated.",
330
+ "billing.usage.form.submit_hint": "to save,",
331
+ "billing.usage.form.uom_code": "UoM code",
332
+ "billing.usage.form.uom_code.help": "Must exactly match the UoM on a usage Billing Item for this account — no conversion.",
333
+ "billing.usage.form.uom_code.placeholder": "api_request, gb, seat, …",
334
+ "billing.usage.rated.no": "Unrated",
335
+ "billing.usage.rated.yes": "Rated"
336
+ }