Download the PHP package gwharton/module-autocustomergroup-eu without Composer
On this page you can find all versions of the php package gwharton/module-autocustomergroup-eu. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package module-autocustomergroup-eu
AutoCustomerGroup - European Union Addon
Magento 2 Module - Module to add European Union functionality to gwharton/module-autocustomergroup
European Union VAT OSS/IOSS Scheme
This Scheme applies to shipments being sent from anywhere in the world to the EU. Note special procedures apply for shipments from Northern Ireland (NI, Part of UK) to the EU.
As of 1st July 2021, sellers may register for the EU OSS/IOSS scheme in an EU country of their choice, and collect the appropriate EU VAT at the point of sale and remit to the EU.
The module is capable of automatically assigning customers to the following categories.
- Domestic - For shipments within a single EU country, normal EU VAT rules apply.
- Intra-EU B2B - For shipments between different countries within the EU, or from NI to the EU and the buyer presents a validated EU VAT number, then the sale can be zero rated for EU VAT. Zero Rate notice to be included on Invoice.
- Intra-EU B2C - For shipments between different countries within the EU, or from NI to the EU and the buyer does NOT present a validated EU VAT number, then Destination Country VAT should be charged.
- Import B2B - For shipments from outside of the EU to within the EU and the buyer presents a validated EU VAT number, then VAT should not be charged. Reverse Charge notice to be included on Invoice.
- Import Taxed - For shipments from outside of the EU to the EU and the total goods value is equal to or below 150 EUR, then Destination Country VAT should be charged.
- Import Untaxed - For shipments from outside of the EU to the EU and the total goods value is above 150 EUR, then VAT should NOT be charged and instead will be collected at the EU border along with any duties due.
You need to create the appropriate tax rules and customer groups, and assign these customer groups to the above categories within the module configuration. Please ensure you fully understand the tax rules of the country you are shipping to. The above should only be taken as a guide.
Government Information
Scheme information can be found on the EU website here.
Order Value
For the EU OSS/IOSS VAT Scheme, the following applies (This can be confirmed here in Section 1.3.1) :
- Order value (for the purpose of thresholding) is the sum of the sale price of all items sold (including any discounts)
- When determining whether VAT should be charged (VAT Threshold) Shipping or Insurance Costs are not included in the value of the goods.
- When determining the amount of VAT to charge the Goods value does include Shipping and Insurance Costs.
More information on the scheme can be found on the European Commission Website
Pseudocode for group allocation
Groups are allocated by evaluating the following rules in this order (If a rule matches, no further rules are evaluated).
- IF MerchantCountry IN EU AND CustomerCountry IN EU AND MerchantCountry EQUALS CustomerCountry THEN Group IS Domestic.
- IF (MerchantCountry IN EU OR MerchantCountry IS NI) AND CustomerCountry IN EU AND MerchantCountry NOT EQUALS CustomerCountry AND TaxIdentifier IS VALID THEN Group IS IntraEUB2B.
- IF (MerchantCountry IN EU OR MerchantCountry IS NI) AND CustomerCountry IN EU AND MerchantCountry NOT EQUALS CustomerCountry AND TaxIdentifier IS NOT VALID THEN Group IS IntraEUB2C.
- IF MerchantCountry IS NOT IN EU AND CustomerCountry IN EU AND TaxIdentifier IS VALID THEN Group IS ImportB2B.
- IF MerchantCountry IS NOT IN EU AND CustomerCountry IN EU AND OrderValue IS LESS THAN OR EQUAL TO Threshold THEN Group IS ImportTaxed.
- IF MerchantCountry IS NOT IN EU AND CustomerCountry IN EU AND OrderValue IS MORE THAN Threshold THEN Group IS ImportUntaxed.
- ELSE NO GROUP CHANGE
VAT Number Verification
- Offline Validation - A simple format validation is performed.
- Online Validation - In addition to the offline checks above, an online validation check is performed with the EU VIES service.
When the module submits requests to the VIES service for VAT number validation, it can do so in two ways, depending on whether VIES Registration Country and VIES Registration number is set or left blank.
- The first method is anonymous, and a basic response to the validation request is given. If you leave these two fields blank, the module will use this method.
- The second method provides more details and includes a "proof of validation" identifier which the module will store with the VAT validation details in the Magento database after verification. You can use this as proof that you checked the status. The only issue is that you have to provide a VAT registration country and VAT registration number of a business registered for VAT in the EU. Providing your IOSS details will not work. It is up to you, if you want to enable this feature, to locate suitable details to enter here. The EU will log the request with those company details, and no doubt, the IP address of your server.
Configuration Options
- Enabled - Enable/Disable this Tax Scheme.
- Tax Identifier Field - Customer Prompt - Displayed under the Tax Identifier field at checkout when a shipping country supported by this module is selected. Use this to include information to the user about why to include their Tax Identifier.
- Validate Online - Whether to validate VAT numbers with the EU VIES Service, or just perform simple format validation.
- VIES Registration Country - Optional. Must be valid EU country, if completed, it will be passed to the VIES with the validation request and a unique verification code will be returned and stored with the order as proof of validation.
- VIES Registration Number - Optional. Must be valid EU VAT number, if completed, it will be passed to the VIES with the validation request and a unique verification code will be returned and stored with the order as proof of validation.
- VAT Registration Number - The Scheme Registration Number for the Merchant. Supplementary functions in AutoCustomerGroup may use this, for example displaying on invoices etc.
- Import VAT Threshold - If the order value is above the VAT Threshold, no VAT should be charged.
- Use Magento Exchange Rate - To convert from EUR Threshold to Store Currency Threshold, should we use the Magento Exchange Rate, or our own.
- Exchange Rate - The exchange rate to use to convert from EUR Threshold to Store Currency Threshold.
- Customer Group - Domestic - Merchant Country is within the EU, Item is being shipped to the same country.
- Customer Group - Intra-EU B2B - Merchant Country is within the EU or NI, Item is being shipped to the EU, Merchant Country and Shipping Country are not the same, VAT Number passed validation by module.
- Customer Group - Intra-EU B2C - Merchant Country is within the EU or NI, Item is being shipped to the EU, Merchant Country and Shipping Country are not the same.
- Customer Group - Import B2B - Merchant Country is not within the EU, Item is being shipped to the EU, VAT Number passed validation by module.
- Customer Group - Import Taxed - Merchant Country is not within the EU, Item is being shipped to the EU, Order Value is below or equal to the Import VAT Threshold.
- Customer Group - Import Untaxed - Merchant Country is not within the EU, Item is being shipped to the EU, Order Value is above the Import VAT Threshold.
Integration Tests
To run the integration tests, it is optional, but to support all functions, you should add the VIES Registration Country and VIES Registration Number. Please add them to config-global.php.
Please note that the EU VIES Service does not have a sandbox for testing, so live details should be used.
- autocustomergroup/euvat/viesregistrationcountry
- autocustomergroup/euvat/viesregistrationnumber
All versions of module-autocustomergroup-eu with dependencies
gwharton/module-autocustomergroup Version *
magento/framework Version *
magento/module-catalog Version *
magento/module-directory Version *
magento/module-quote Version *
magento/module-store Version *
psr/log Version *