Vatfallback module provides an extra API based validation and a fallback offline regex validation for the unstable VIES database used by Magento
Please find the Magento 1 version here.
- Built in Magento VIES check
- Custom VIES check (this is not the official endpoint but an internal one)
- vatlayer.com check
- Regex fallback check for following countries; AT, BE, CZ, DE, CY, DK, EE, GR, ES, FI, FR, GB, HU, IE, IT, LT, LU, LV, MT, NL, PL, PT, SE, SI, SK
-
A plugin wraps the existing Vat check in Magento Customer implementing various services as fallback.
-
Use the console task:
./bin/magento vat:validate NL NL133001477B01
-
Use the API endpoint to get company data by VAT number
http://domain.com/rest/V1/vat/companylookup/NL133001477B01
composer require dutchento/m2-vatfallback
bin/magento setup:upgrade
- Magento 2.2
- Magento 2.3
- Magento 2.4
[1.5.0] Better error handling if services are unavailable, no next service checking if 100% sure invalid result
[1.4.0] Refactor __constructors, decoupled validationservices from validator
[1.3.0] Regex validation now configurable via XML. Improved tests and regex validation
[1.2.0] added a timeout sys conf value for connecting to APIs
[1.1.1] fixed a logic error in calling fallback services including a false positives fix for the unofficial VIES endpoint by Laura Folco
[1.1.0] add an API endpoint for company data
[1.0.0] ported version of the Magento 1 module
- PHP >= 7.0
- GuzzleHTTP
Warning: Since all of the free VIES API's are slow and somewhat unreliable the checkout steps could become slow while checking.
- Sander Mangel @sandermangel
- Peter Jaap Blaakmeer @peterjaap
- Laura Folco @lfolco