Add VAT to SuiteCRM Core

Hiya all

In the past days I’ve been looking around to SuiteCRM and one of the things that I feel it is missing the most is the implementation of a VAT System to SuiteCRM core.

VAT is mandatory for most companies in EU, even in the USA there are different VAT rates in different States.

I believe how this could be implemented would depend on the good will of the developers… as I suggest one of two options:

  1. A simpler VAT system (a bit alike WooCommerce VAT) where you get a simple table and can add regions and VAT rates for each region.
  2. A more powerful VAT system that uses the VIES API validator to check VAT numbers for European countries and I imagine there’s some sort of open system that allows to validate in the US as well and users simply had to add the VAT number and select the country.
1 Like

Aren’t the tax fields and settings enough for what you need to do with VAT in Invoices module?

If you had a flat line taxation amount on each invoice like in the UK - Most cases are standard 20 percent across the board which is great to use AOS logic here.

If you work in industries where the tax varies on item basis and nexus/location / medical relief items / food items lesser tax it’s a bit of a nightmare ;/

What I have done on a few sale items is build the tax into a custom field and triggers and then work that into the invoice templates manually and completely bypass Suitecrm’s tax/vat offerings.

@pgr my company works with OSS (One Stop Shop) scheme which means the tax applied on sales is based on the buyer location rather than one flat fee.
Been in adoption since 2015 and today it’s broadly used by most companies that sell online and abroad.

If the customer is in Germany tax is 19%. If the company is VIES valid the tax is ZERO but it has to be printed out on the invoice that tax is reverse charge. If the client is not VIES valid we have to charge tax.
So, I would rather ask how are the tax fields and settings enough? Today most CRM’s and invoicing apps all have this features and validate the VAT numbers automatically. I can only see companies in Europe using this if: they only sell locally and are ok with a flat rate, or skip taxes.

Thanks for the explanation, I really don’t know much about all that.

So, just brainstorming, the requirements would be:

  1. Validate VAT number using VIES API validator (whatever that is :stuck_out_tongue:)
  2. Lookup VAT tax according to buyer location
  3. Have the invoice template print some extra stuff on some cases

My add-ons could do all of this, PowerFields (requirements 1, 2) and PowerReplacer (3), but I get that this should really be core functionality. I am pretty sure SalesAgility won’t do it (unless one of their project clients asks for it, pays it, and gives it to the community).

So perhaps the only route forward if for someone interested to take on the project, or for people to get together and pay for it, possibly giving the project to SA, or possibly to some other company or even Upwork developer.

@pgr morning!

Ok so you have the manual validator here:
https://ec.europa.eu/taxation_customs/vies/#/vat-validation

You don’t need to fill the requester state and vat, only the first two.

The VIES database and API, I have some notes on this from a stackoverflow answer and it includes some examples.

About the requirements:

  1. Account must have Address Country and VAT number,
  2. The number is validated against VIES. If it is VALID, then the company is registered for intra-community transactions and subject to the OSS scheme. VAT isn’t charged and the reason must be printed, here in Portugal it’s code M40 - (IVA Autoliquidação - Prestação de serviços no estrangeiro - “Art. 6º nº6 alínea A do Código IVA, ao contrário”). (for this some software allow the user to fill in the exemptions reasons so the programmers don’t have to contemplate all possible exemptions for all EU countries).
  3. Invoices should always print out VAT even if the VAT is 0%, that should be on the invoice.

Now, things to know: VIES only tells you if a VAT number is valid for intra-comm transactions or not. Doesn’t tell you any countries VAT rate.
If the number is valid, VAT isn’t charged - reverse-charge
If the number is NOT valid, tax is charged.
If the buyer is on the same country as the seller, VAT is always charged. (So in our case if the customer is in Portugal, he can be VIES valid or not, we always have to charge VAT).

In WooCommerce you can upload a CSV file with all the EU (and USA) VAT rates. Then the system matches the Country to the VAT rate. It also allows to configure different Rates (Normal, intermediate, basic) so on.

I would definitely contribute to a fund to bring this to SuiteCRM core. I also believe many potential users will look into the VAT and Tax mechanisms on SuiteCRM and just ditch it. Just the detail of not having VAT builtin for an account … seems like a dealbreaker.

Would you say those VAT details like the rate and VIES status should be stored with the account?

Or should that be calculated at the moment when the invoice is being generated?

I’m basing on the experience with apps that already work with VAT/VIES, most even perform the following:

You create a “new account” for example;
Enter the VAT number and hit a button to validate against VIES
The verification will return:

  • Account name (Company name or individual if VIES-able)
  • Account address (complete)

Usually what happens is the values returned from VIES validation are automatically filled into the corresponding fields (name/address)
However, when emitting an invoice, the VIES validation has to be always done. This bc VIES validity is an option the company has to enable - the intracommunity transactions - (and can be disabled), so in the moment the invoice is finalised the check for VIES status is needed as if the number is not valid at then VAT must be charged. Because if you wrongly don’t charge it, still have to pay it.

The VAT rate database would serve to match “country”, “region” and then “VAT rate” from those available to that country. Example with Portugal:

PT mainland VAT rates:
23% normal rate
13% intermediate rate
6% reduced rate

PT Madeira:
22% normal rate
12% intermediate rate
5% reduced rate

PT Azores:
16% normal rate
9% intermediate rate
4% reduced rate

Plus the 0% rate for the tax exempt products (Like the basic basket thing to counter the inflation).

The same logic of country, region, rates applies to most countries in Europe and the US for example.

1 Like

With this fine description of the requirements, I guess somebody could try and reach SalesAgility for a quote to see how much it would cost…

EDIT: or if some other company or developer is used for this, I would recommend asking him to make the development not as an add-on, but as a core feature. Then that would have to be sent as a PR and we’d have to wait for SalesAgility to merge it…

1 Like

Unfortunately it seems to me like its very, very hard to reach someone at SalesAgility, unless you’re probably paying one of their managed solutions.

I even believe a project could be made, funds raised, and poured directly on developing this feature. I do believe many SuiteCRM users and even enthusiasts would contribute something, as this is an insanely needed feature that is lacking IMO. And if we search around for the amount of topics and people asking for VAT, I’m not alone.

It would be definitely interesting to have a word from SalesAgility here. Thoughts about this, is something they already thought of, haven’t, will consider, won’t, consider, how can community and themselves work together.

By the way would like to add another detail to the VAT system that should be considered also to ease the development:

  • Differentiated VAT rates apply to products.
  • VAT regime applies to accounts.

By this I mean:
Accounts: Checks if the customer is VIES valid - requires country and VAT number.
Accounts: must have country and postal code, so the postal code can be used to check the region (again with PT example, a Madeira postal code would place the customer in Madeira subject to the Madeira tax rates)
Products: Product must have a setting to identify which class of products/tax rates it belongs to:

  • Normal
  • Intermediate
  • Reduced
  • Exempt

So in the final calculation, account provides country and region, product identifies the tax rate it’s subject to.

If the customers don’t provide details like VAT number and country (or even the default VAT 999999990), or any other situation except those already mentioned, VAT must be charged at the full rate for the store country location.