gobl 0.23.0 → 0.24.1

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 (43) hide show
  1. checksums.yaml +4 -4
  2. data/data/regimes/ae.json +49 -83
  3. data/data/regimes/at.json +58 -69
  4. data/data/regimes/be.json +65 -76
  5. data/data/regimes/br.json +83 -54
  6. data/data/regimes/ca.json +3 -3
  7. data/data/regimes/ch.json +62 -62
  8. data/data/regimes/co.json +65 -70
  9. data/data/regimes/de.json +56 -83
  10. data/data/regimes/el.json +74 -73
  11. data/data/regimes/es.json +127 -88
  12. data/data/regimes/fr.json +64 -72
  13. data/data/regimes/gb.json +54 -68
  14. data/data/regimes/ie.json +172 -0
  15. data/data/regimes/it.json +77 -79
  16. data/data/regimes/mx.json +58 -81
  17. data/data/regimes/nl.json +55 -70
  18. data/data/regimes/pl.json +40 -364
  19. data/data/regimes/pt.json +66 -64
  20. data/data/regimes/se.json +215 -0
  21. data/data/regimes/sg.json +119 -0
  22. data/data/regimes/us.json +0 -58
  23. data/lib/generated/gobl/bill/delivery.rb +4 -1
  24. data/lib/generated/gobl/bill/invoice.rb +4 -1
  25. data/lib/generated/gobl/bill/line.rb +5 -0
  26. data/lib/generated/gobl/bill/order.rb +4 -1
  27. data/lib/generated/gobl/bill/ordering.rb +5 -0
  28. data/lib/generated/gobl/bill/payment.rb +4 -1
  29. data/lib/generated/gobl/org/attachment.rb +0 -5
  30. data/lib/generated/gobl/org/document_ref.rb +6 -1
  31. data/lib/generated/gobl/org/item.rb +5 -0
  32. data/lib/generated/gobl/org/person.rb +17 -2
  33. data/lib/generated/gobl/org/unit.rb +9 -0
  34. data/lib/generated/gobl/tax/category_def.rb +11 -1
  35. data/lib/generated/gobl/tax/category_total.rb +4 -0
  36. data/lib/generated/gobl/tax/combo.rb +8 -3
  37. data/lib/generated/gobl/tax/key_def.rb +36 -0
  38. data/lib/generated/gobl/tax/rate_def.rb +9 -14
  39. data/lib/generated/gobl/tax/rate_total.rb +5 -5
  40. data/lib/generated/gobl/tax/rate_value_def.rb +1 -6
  41. data/lib/generated/gobl/tax/scenario.rb +5 -0
  42. data/lib/gobl/version.rb +1 -1
  43. metadata +6 -2
data/data/regimes/nl.json CHANGED
@@ -8,64 +8,6 @@
8
8
  "country": "NL",
9
9
  "currency": "EUR",
10
10
  "tax_scheme": "VAT",
11
- "tags": [
12
- {
13
- "schema": "bill/invoice",
14
- "list": [
15
- {
16
- "key": "simplified",
17
- "name": {
18
- "de": "Vereinfachte Rechnung",
19
- "en": "Simplified Invoice",
20
- "es": "Factura Simplificada",
21
- "it": "Fattura Semplificata"
22
- },
23
- "desc": {
24
- "de": "Wird für B2C-Transaktionen verwendet, wenn die Kundendaten nicht verfügbar sind. Bitte wenden Sie sich an die örtlichen Behörden, um die Grenzwerte zu ermitteln.",
25
- "en": "Used for B2C transactions when the client details are not available, check with local authorities for limits.",
26
- "es": "Usado para transacciones B2C cuando los detalles del cliente no están disponibles, consulte con las autoridades locales para los límites.",
27
- "it": "Utilizzato per le transazioni B2C quando i dettagli del cliente non sono disponibili, controllare con le autorità locali per i limiti."
28
- }
29
- },
30
- {
31
- "key": "reverse-charge",
32
- "name": {
33
- "de": "Umkehr der Steuerschuld",
34
- "en": "Reverse Charge",
35
- "es": "Inversión del Sujeto Pasivo",
36
- "it": "Inversione del soggetto passivo"
37
- }
38
- },
39
- {
40
- "key": "self-billed",
41
- "name": {
42
- "de": "Rechnung durch den Leistungsempfänger",
43
- "en": "Self-billed",
44
- "es": "Facturación por el destinatario",
45
- "it": "Autofattura"
46
- }
47
- },
48
- {
49
- "key": "customer-rates",
50
- "name": {
51
- "de": "Kundensätze",
52
- "en": "Customer rates",
53
- "es": "Tarifas aplicables al destinatario",
54
- "it": "Aliquote applicabili al destinatario"
55
- }
56
- },
57
- {
58
- "key": "partial",
59
- "name": {
60
- "de": "Teilweise",
61
- "en": "Partial",
62
- "es": "Parcial",
63
- "it": "Parziale"
64
- }
65
- }
66
- ]
67
- }
68
- ],
69
11
  "scenarios": [
70
12
  {
71
13
  "schema": "bill/invoice",
@@ -102,24 +44,64 @@
102
44
  "en": "Value Added Tax",
103
45
  "nl": "Belasting Toegevoegde Waarde"
104
46
  },
105
- "rates": [
47
+ "keys": [
48
+ {
49
+ "key": "standard",
50
+ "name": {
51
+ "en": "Standard"
52
+ }
53
+ },
106
54
  {
107
55
  "key": "zero",
108
56
  "name": {
109
- "en": "Zero Rate",
110
- "nl": "0%-tarief"
57
+ "en": "Zero"
58
+ }
59
+ },
60
+ {
61
+ "key": "reverse-charge",
62
+ "name": {
63
+ "en": "Reverse charge"
111
64
  },
112
- "values": [
113
- {
114
- "percent": "0.0%"
115
- }
116
- ]
65
+ "no_percent": true
117
66
  },
118
67
  {
119
- "key": "standard",
68
+ "key": "exempt",
69
+ "name": {
70
+ "en": "Exempt"
71
+ },
72
+ "no_percent": true
73
+ },
74
+ {
75
+ "key": "export",
120
76
  "name": {
121
- "en": "Standard Rate",
122
- "nl": "Standaardtarief"
77
+ "en": "Export"
78
+ },
79
+ "no_percent": true
80
+ },
81
+ {
82
+ "key": "intra-community",
83
+ "name": {
84
+ "en": "Intra-community"
85
+ },
86
+ "no_percent": true
87
+ },
88
+ {
89
+ "key": "outside-scope",
90
+ "name": {
91
+ "en": "Outside scope"
92
+ },
93
+ "no_percent": true
94
+ }
95
+ ],
96
+ "rates": [
97
+ {
98
+ "rate": "general",
99
+ "keys": [
100
+ "standard"
101
+ ],
102
+ "name": {
103
+ "en": "General Rate",
104
+ "nl": "Algemeen Tarief"
123
105
  },
124
106
  "values": [
125
107
  {
@@ -128,7 +110,10 @@
128
110
  ]
129
111
  },
130
112
  {
131
- "key": "reduced",
113
+ "rate": "reduced",
114
+ "keys": [
115
+ "standard"
116
+ ],
132
117
  "name": {
133
118
  "en": "Reduced Rate",
134
119
  "nl": "Gereduceerd Tarief"
data/data/regimes/pl.json CHANGED
@@ -8,373 +8,74 @@
8
8
  "country": "PL",
9
9
  "currency": "PLN",
10
10
  "tax_scheme": "VAT",
11
- "tags": [
12
- {
13
- "schema": "bill/invoice",
14
- "list": [
15
- {
16
- "key": "simplified",
17
- "name": {
18
- "de": "Vereinfachte Rechnung",
19
- "en": "Simplified Invoice",
20
- "es": "Factura Simplificada",
21
- "it": "Fattura Semplificata"
22
- },
23
- "desc": {
24
- "de": "Wird für B2C-Transaktionen verwendet, wenn die Kundendaten nicht verfügbar sind. Bitte wenden Sie sich an die örtlichen Behörden, um die Grenzwerte zu ermitteln.",
25
- "en": "Used for B2C transactions when the client details are not available, check with local authorities for limits.",
26
- "es": "Usado para transacciones B2C cuando los detalles del cliente no están disponibles, consulte con las autoridades locales para los límites.",
27
- "it": "Utilizzato per le transazioni B2C quando i dettagli del cliente non sono disponibili, controllare con le autorità locali per i limiti."
28
- }
29
- },
30
- {
31
- "key": "reverse-charge",
32
- "name": {
33
- "de": "Umkehr der Steuerschuld",
34
- "en": "Reverse Charge",
35
- "es": "Inversión del Sujeto Pasivo",
36
- "it": "Inversione del soggetto passivo"
37
- }
38
- },
39
- {
40
- "key": "self-billed",
41
- "name": {
42
- "de": "Rechnung durch den Leistungsempfänger",
43
- "en": "Self-billed",
44
- "es": "Facturación por el destinatario",
45
- "it": "Autofattura"
46
- }
47
- },
48
- {
49
- "key": "customer-rates",
50
- "name": {
51
- "de": "Kundensätze",
52
- "en": "Customer rates",
53
- "es": "Tarifas aplicables al destinatario",
54
- "it": "Aliquote applicabili al destinatario"
55
- }
56
- },
57
- {
58
- "key": "partial",
59
- "name": {
60
- "de": "Teilweise",
61
- "en": "Partial",
62
- "es": "Parcial",
63
- "it": "Parziale"
64
- }
65
- },
66
- {
67
- "key": "settlement",
68
- "name": {
69
- "en": "Settlement Invoice",
70
- "pl": "Faktura Rozliczeniowa"
71
- }
72
- }
73
- ]
74
- }
75
- ],
76
- "extensions": [
77
- {
78
- "key": "pl-ksef-vat-special",
79
- "name": {
80
- "en": "Special VAT Extensions for KSeF",
81
- "pl": "Rozszerzenia specjalne dla KSeF"
82
- },
83
- "values": [
84
- {
85
- "code": "taxi",
86
- "name": {
87
- "en": "Taxi Rate",
88
- "pl": "Ryczałt dla taksówek"
89
- },
90
- "desc": {
91
- "en": "Special flat rate for taxi drivers.",
92
- "pl": "Specjalna stawka ryczałtu dla taksówkarzy."
93
- }
94
- }
95
- ]
96
- },
97
- {
98
- "key": "pl-ksef-vat-zero",
99
- "name": {
100
- "en": "Zero VAT Extensions for KSeF"
101
- },
102
- "values": [
103
- {
104
- "code": "wdt",
105
- "name": {
106
- "en": "WDT",
107
- "pl": "WDT"
108
- }
109
- },
110
- {
111
- "code": "domestic",
112
- "name": {
113
- "en": "Domestic",
114
- "pl": "Krajowy"
115
- }
116
- },
117
- {
118
- "code": "export",
119
- "name": {
120
- "en": "Export",
121
- "pl": "Eksport"
122
- }
123
- }
124
- ]
125
- },
126
- {
127
- "key": "pl-ksef-effective-date",
128
- "name": {
129
- "en": "Effective date code.",
130
- "pl": "Kod daty wejścia w życie."
131
- },
132
- "values": [
133
- {
134
- "code": "1",
135
- "name": {
136
- "en": "Original",
137
- "pl": "Pierwotna"
138
- },
139
- "desc": {
140
- "en": "Effective according to date of the original invoice.",
141
- "pl": "Faktura skutkująca w dacie ujęcia faktury pierwotnej."
142
- }
143
- },
144
- {
145
- "code": "2",
146
- "name": {
147
- "en": "Correction",
148
- "pl": "Korygująca"
149
- },
150
- "desc": {
151
- "en": "Effective according to date of correction.",
152
- "pl": "Faktura skutkująca w dacie ujęcia faktury korygującej."
153
- }
154
- },
155
- {
156
- "code": "3",
157
- "name": {
158
- "en": "Other",
159
- "pl": "Inna"
160
- },
161
- "desc": {
162
- "en": "Correction has legal consequences in another date or the dates are different for different position on the invoice",
163
- "pl": "Faktura skutkująca w innej dacie. W tym gdy dla różnych pozycji faktury korygującej data jest różna."
164
- }
165
- }
166
- ]
167
- }
168
- ],
169
- "payment_means_keys": [
170
- {
171
- "key": "cash",
172
- "name": {
173
- "en": "Cash",
174
- "pl": "Gotówka"
175
- },
176
- "map": {
177
- "favat-forma-platnosci": "1"
178
- }
179
- },
180
- {
181
- "key": "card",
182
- "name": {
183
- "en": "Card",
184
- "pl": "Karta"
185
- },
186
- "map": {
187
- "favat-forma-platnosci": "2"
188
- }
189
- },
190
- {
191
- "key": "other+coupon",
192
- "name": {
193
- "en": "Coupon",
194
- "pl": "Bon"
195
- },
196
- "map": {
197
- "favat-forma-platnosci": "3"
198
- }
199
- },
200
- {
201
- "key": "cheque",
202
- "name": {
203
- "en": "Cheque",
204
- "pl": "Czek"
205
- },
206
- "map": {
207
- "favat-forma-platnosci": "4"
208
- }
209
- },
210
- {
211
- "key": "online+loan",
212
- "name": {
213
- "en": "Loan",
214
- "pl": "Kredyt"
215
- },
216
- "map": {
217
- "favat-forma-platnosci": "5"
218
- }
219
- },
11
+ "categories": [
220
12
  {
221
- "key": "credit-transfer",
13
+ "code": "VAT",
222
14
  "name": {
223
- "en": "Wire Transfer",
224
- "pl": "Przelew"
15
+ "en": "VAT",
16
+ "pl": "VAT"
225
17
  },
226
- "map": {
227
- "favat-forma-platnosci": "6"
228
- }
229
- },
230
- {
231
- "key": "other+mobile",
232
- "name": {
233
- "en": "Mobile",
234
- "pl": "Mobilna"
18
+ "title": {
19
+ "en": "Value Added Tax",
20
+ "pl": "Podatek od Wartości Dodanej"
235
21
  },
236
- "map": {
237
- "favat-forma-platnosci": "7"
238
- }
239
- }
240
- ],
241
- "scenarios": [
242
- {
243
- "schema": "bill/invoice",
244
- "list": [
22
+ "keys": [
245
23
  {
24
+ "key": "standard",
246
25
  "name": {
247
- "en": "Regular Invoice",
248
- "pl": "Faktura Podstawowa"
249
- },
250
- "type": [
251
- "standard"
252
- ],
253
- "codes": {
254
- "favat-rodzaj-faktury": "VAT"
26
+ "en": "Standard"
255
27
  }
256
28
  },
257
29
  {
30
+ "key": "zero",
258
31
  "name": {
259
- "en": "Prepayment Invoice",
260
- "pl": "Faktura Zaliczkowa"
261
- },
262
- "type": [
263
- "standard"
264
- ],
265
- "tags": [
266
- "partial"
267
- ],
268
- "codes": {
269
- "favat-rodzaj-faktury": "ZAL"
32
+ "en": "Zero"
270
33
  }
271
34
  },
272
35
  {
36
+ "key": "reverse-charge",
273
37
  "name": {
274
- "en": "Settlement Invoice",
275
- "pl": "Faktura Rozliczeniowa"
38
+ "en": "Reverse charge"
276
39
  },
277
- "type": [
278
- "standard"
279
- ],
280
- "tags": [
281
- "settlement"
282
- ],
283
- "codes": {
284
- "favat-rodzaj-faktury": "ROZ"
285
- }
40
+ "no_percent": true
286
41
  },
287
42
  {
43
+ "key": "exempt",
288
44
  "name": {
289
- "en": "Simplified Invoice",
290
- "pl": "Faktura Uproszczona"
45
+ "en": "Exempt"
291
46
  },
292
- "type": [
293
- "standard"
294
- ],
295
- "tags": [
296
- "simplified"
297
- ],
298
- "codes": {
299
- "favat-rodzaj-faktury": "UPR"
300
- }
47
+ "no_percent": true
301
48
  },
302
49
  {
50
+ "key": "export",
303
51
  "name": {
304
- "en": "Credit note",
305
- "pl": "Faktura korygująca"
52
+ "en": "Export"
306
53
  },
307
- "type": [
308
- "credit-note"
309
- ],
310
- "codes": {
311
- "favat-rodzaj-faktury": "KOR"
312
- }
54
+ "no_percent": true
313
55
  },
314
56
  {
57
+ "key": "intra-community",
315
58
  "name": {
316
- "en": "Prepayment credit note",
317
- "pl": "Faktura korygująca fakturę zaliczkową"
59
+ "en": "Intra-community"
318
60
  },
319
- "type": [
320
- "credit-note"
321
- ],
322
- "tags": [
323
- "partial"
324
- ],
325
- "codes": {
326
- "favat-rodzaj-faktury": "KOR_ZAL"
327
- }
61
+ "no_percent": true
328
62
  },
329
63
  {
64
+ "key": "outside-scope",
330
65
  "name": {
331
- "en": "Settlement credit note",
332
- "pl": "Faktura korygująca fakturę rozliczeniową"
66
+ "en": "Outside scope"
333
67
  },
334
- "type": [
335
- "credit-note"
336
- ],
337
- "tags": [
338
- "settlement"
339
- ],
340
- "codes": {
341
- "favat-rodzaj-faktury": "KOR_ROZ"
342
- }
68
+ "no_percent": true
343
69
  }
344
- ]
345
- }
346
- ],
347
- "corrections": [
348
- {
349
- "schema": "bill/invoice",
350
- "types": [
351
- "credit-note"
352
- ],
353
- "extensions": [
354
- "pl-ksef-effective-date"
355
70
  ],
356
- "reason_required": true,
357
- "stamps": [
358
- "ksef-id"
359
- ]
360
- }
361
- ],
362
- "categories": [
363
- {
364
- "code": "VAT",
365
- "name": {
366
- "en": "VAT",
367
- "pl": "VAT"
368
- },
369
- "title": {
370
- "en": "Value Added Tax",
371
- "pl": "Podatek od Wartości Dodanej"
372
- },
373
71
  "rates": [
374
72
  {
375
- "key": "standard",
73
+ "rate": "general",
74
+ "keys": [
75
+ "standard"
76
+ ],
376
77
  "name": {
377
- "en": "Standard Rate",
78
+ "en": "General Rate",
378
79
  "pl": "Stawka Podstawowa"
379
80
  },
380
81
  "values": [
@@ -389,7 +90,10 @@
389
90
  ]
390
91
  },
391
92
  {
392
- "key": "reduced",
93
+ "rate": "reduced",
94
+ "keys": [
95
+ "standard"
96
+ ],
393
97
  "name": {
394
98
  "en": "First Reduced Rate",
395
99
  "pl": "Stawka Obniżona Pierwsza"
@@ -406,7 +110,10 @@
406
110
  ]
407
111
  },
408
112
  {
409
- "key": "super-reduced",
113
+ "rate": "super-reduced",
114
+ "keys": [
115
+ "standard"
116
+ ],
410
117
  "name": {
411
118
  "en": "Second Reduced Rate",
412
119
  "pl": "Stawka Obniżona Druga"
@@ -421,38 +128,7 @@
421
128
  "percent": "3.0%"
422
129
  }
423
130
  ]
424
- },
425
- {
426
- "key": "zero",
427
- "name": {
428
- "en": "Zero Rate",
429
- "pl": "Stawka Zerowa"
430
- },
431
- "values": [
432
- {
433
- "percent": "0.0%"
434
- }
435
- ]
436
- },
437
- {
438
- "key": "exempt",
439
- "name": {
440
- "en": "Exempt",
441
- "pl": "Zwolnione"
442
- },
443
- "exempt": true
444
- },
445
- {
446
- "key": "special",
447
- "name": {
448
- "en": "Special Rate",
449
- "pl": "Stawka Specjalna"
450
- }
451
131
  }
452
- ],
453
- "extensions": [
454
- "pl-ksef-vat-zero",
455
- "pl-ksef-vat-special"
456
132
  ]
457
133
  }
458
134
  ]