eu_vat_rates_data 2026.3.25 → 2026.3.26

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c96dbe5b380560ec31c88250ce483152a9ea72d9423d9b9dc1dab17cdf6350ef
4
- data.tar.gz: 8deb6048c12a323fc3e96e4d871ae05021eca9fa75e5f15412b9197784bea561
3
+ metadata.gz: 8427c28b7f6de6b2d18decd10b5ef180708689045f8ffce380877ef108fa93e3
4
+ data.tar.gz: 35cc04e92957c359367a48db96c5de27e8d3a5ccb89284fcd4174f1f875d586a
5
5
  SHA512:
6
- metadata.gz: 60231d37b4dfe87e26fa694cb0921fa495b68401ad5846b54f91cd01a03ec98debbabc4d7169a0436a1ba132767dd775b0fdf5bfd37bc7a21ee81748f0870b3e
7
- data.tar.gz: b250add073cbc7be2362200e20fe03b145e525fc78d9c2ba7b9114f5876b450ef2fb56036cd7377ca217a58a059970a56404646f9fd894c54a1f5cc08bae6aac
6
+ metadata.gz: 6c29685f3a7e99e9d29a53025234b8f00b464d054d4bef91fc197a00e32bc428378fc0fc372f56a4c1130bcd2d815eac0123b09e9c16f3c84ca0a559a061ad33
7
+ data.tar.gz: 6b4a9dc0473e3455b199b9f64a12a004719a748b1d58b719556603c03b7290974fe2de37211ff825b234aa07cc47093235bb0e9290bfc69ad8f6b835d9028642
data/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
  [![Last updated](https://img.shields.io/github/last-commit/vatnode/eu-vat-rates-data-ruby?path=data%2Feu-vat-rates-data.json&label=last%20updated)](https://github.com/vatnode/eu-vat-rates-data-ruby/commits/main)
5
5
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
6
6
 
7
- VAT rates for **44 European countries** — EU-27 plus Norway, Switzerland, UK, and more. EU rates sourced from the [European Commission TEDB](https://taxation-customs.ec.europa.eu/tedb/vatRates.html) and checked daily. Non-EU rates maintained manually.
7
+ VAT rates for **44 European countries** — EU-27 plus Norway, Switzerland, UK, and more. EU rates sourced from the [European Commission TEDB](https://ec.europa.eu/taxation_customs/tedb/) and checked daily. Non-EU rates maintained manually.
8
8
 
9
9
  - Standard, reduced, super-reduced, and parking rates
10
10
  - `eu_member` flag on every country — `true` for EU-27, `false` for non-EU
@@ -53,6 +53,11 @@ if EuVatRatesData.eu_member?(user_input)
53
53
  rate = EuVatRatesData.get_rate(user_input)
54
54
  end
55
55
 
56
+ # Dataset membership check (all 44 countries)
57
+ if EuVatRatesData.has_rate?(user_input)
58
+ rate = EuVatRatesData.get_rate(user_input)
59
+ end
60
+
56
61
  # All 44 countries at once
57
62
  EuVatRatesData.all_rates.each do |code, rate|
58
63
  puts "#{code}: #{rate['standard']}%"
@@ -1,7 +1,7 @@
1
1
  {
2
- "version": "2026-03-18",
2
+ "version": "2026-03-26",
3
3
  "source": "European Commission TEDB",
4
- "url": "https://taxation-customs.ec.europa.eu/tedb/vatRates.html",
4
+ "url": "https://ec.europa.eu/taxation_customs/tedb/",
5
5
  "rates": {
6
6
  "AD": {
7
7
  "country": "Andorra",
@@ -1,3 +1,3 @@
1
1
  module EuVatRatesData
2
- VERSION = "2026.3.25"
2
+ VERSION = "2026.3.26"
3
3
  end
@@ -60,7 +60,15 @@ module EuVatRatesData
60
60
  rate ? rate["eu_member"] == true : false
61
61
  end
62
62
 
63
- # Return the ISO 8601 date when EU data was last fetched from EC TEDB.
63
+ # Return true if the country code is present in the dataset (all 44 countries).
64
+ # Use eu_member? to check EU membership specifically.
65
+ # @param country_code [String] ISO 3166-1 alpha-2 code
66
+ # @return [Boolean]
67
+ def self.has_rate?(country_code)
68
+ rates.key?(country_code.upcase)
69
+ end
70
+
71
+ # Return the ISO 8601 date when EU data was last fetched from EC TEDB.
64
72
  # @return [String] e.g. "2026-03-18"
65
73
  def self.data_version
66
74
  dataset["version"]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: eu_vat_rates_data
3
3
  version: !ruby/object:Gem::Version
4
- version: 2026.3.25
4
+ version: 2026.3.26
5
5
  platform: ruby
6
6
  authors:
7
7
  - Iurii Rogulia
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-03-25 00:00:00.000000000 Z
11
+ date: 2026-03-26 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: VAT rates (standard, reduced, super-reduced, parking) for 44 European
14
14
  countries — EU-27 plus Norway, Switzerland, UK, and more. Updated daily from the
@@ -32,7 +32,7 @@ metadata:
32
32
  homepage_uri: https://github.com/vatnode/eu-vat-rates-data-ruby
33
33
  source_code_uri: https://github.com/vatnode/eu-vat-rates-data-ruby
34
34
  bug_tracker_uri: https://github.com/vatnode/eu-vat-rates-data-ruby/issues
35
- post_install_message:
35
+ post_install_message:
36
36
  rdoc_options: []
37
37
  require_paths:
38
38
  - lib
@@ -47,8 +47,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
47
47
  - !ruby/object:Gem::Version
48
48
  version: '0'
49
49
  requirements: []
50
- rubygems_version: 3.0.3.1
51
- signing_key:
50
+ rubygems_version: 3.5.22
51
+ signing_key:
52
52
  specification_version: 4
53
53
  summary: VAT rates for 44 European countries — EU-27 plus Norway, Switzerland, UK,
54
54
  and more. Daily auto-updates from EC TEDB.