Can SAP Tax Service to replace TAXBRA/RVABRA ?

service-tax-payment

This post’s content is based on a post from Fausto Motter who wrote an article in Portuguese in the SAP Community to discuss how the Brazilian Tax Calculation could be replaced by a cloud solution. I translated part of his article, added and adapted some content and the goal is to help SAP users, consultants, customers and partners around the globe to understand better how Tax Service seems to be a replacement to the TAXBRA and RVABRA.

Enjoy the lecture…

The TAXBRA and RVABRA (SAP Standard Brazilian Tax Calculation Schema) has a replacement already, and that comes with many benefits to the SAP customers. The replacement is called “SAP Tax Service” and it is available to Brazil in the SAP S/4HANA 1805 (cloud) version.

Tax service has the following features:

  • Taxes computed as per local tax guidelines.
  • Supported for over 120 countries.
  • Tax computation content pre-delivered, with inbuilt rules for each country. Tax content includes tax types, tax rates, deductibility, exemption, and so on, for each of the supported countries.
  • Tax computations updated on time, and in accordance to notified country-specific legal changes.
  • Service offered is as a REST API on the SAP HANA Cloud Platform.
  • Security provided using oAuth protocol, authenticating/authorizing the service call/request from the initiating system

The SAP Tax Service is the natural way for taxes calculation since it is already available to many other countries with taxes in the same level of complexity as Brazil taxes, and it counts with the cloud strategy and the APIs to grow. When the S/4HANA context is evaluated, the new way of extending enhancements, the APIs and the governance on developments, as well as the agility and flexibility of Cloud solutions, it is obvious that the TAXBRA and the formula 320 and their many hard-codes will not have a much longer life. Changing makes all sense now.

Going into the details of the new tax calculation formula, basically the functionality is an API (SAP or Partner delivered), a service on cloud that gets the data from the application (S/4HANA), either sales or procurement. The tax calculation is then performed in the cloud application, in Brazil using APIs from certified partners, and it will return all the relevant data to the tax calculation:

W1

Tax Services Capabilities:

W2

SAP API Architecture:

W3

Benefits of implementing the Tax Service on Cloud:

W4

  • The call

To the API service is sent: unit cost, origin, destination, business partners, material and other data relevant to the taxes and rates calculation. Note that, the J1BTAX will no longer be the main source of taxes and rates, instead, the service is. The Cloud service will be responsible for being on top of the calculation rules, changes, legal updates and etc.

  • The return

The payload return is much more comprehensive, see below some of the tags as an example:

          quote {
          total (Nota Fiscal Total Amount)
          subtotal (All products total amount)
          country
          …
          }
          taxLine {
          id (Nota Fiscal Item)
          totalTax (Item total amount, including ICMS + ICMS-FCP + PIS + COFINS)
          taxcode (CFOP)
          …
          }
          taxValue {
          taxTypeCode (IPI, ICMS, ICMS-ST, ICMS-FCP, ICMS-ST-FCP, PIS, COFINS, ISS, IR, CSLL)
          name (Tax Name)
          taxable (calculation base)
          exemptedBaseAmount (base reduction)
          otherBaseAmount (other bases)
          …
          withholdingRelevant (withholding tax)
          …
          }
          taxAttributes {
          attributeType (Amounts such as CST, CENQ, IVA)
          attributeValue (Attribute amount)

The true is that tax calculation is not a differentiation on the Digitization path, and segregate it, taking the Tax calculation from the core ERP, makes a lot more sense. Add to that services that are available in the Cloud Platform, such as Machine Learning, Blockchain, Artificial Intelligence, that could be used in the future in the Tax Service API, either to automate the parameters and configuration, to help the taxes and fiscal activities, or even keep record of a block of taxes information for subsequent tax audit.

After visiting SAP Labs in Sao Leopoldo, RS – Brasil, Motter explains that looking the Tax Service solution working in a Sales Order or Purchase Order, and after discussing the solution with the product’s architects, he felt that the Tax Service is incredible.

The Tax Service is available to the SAP S/4HANA 1809 (on-premise and private cloud) and at the SAP S/4HANA 1805 (public cloud). The main difference between the 1809 and 1805 is that at 1809 the customer can define if the tax calculation goes to the Tax Service or it will still use TAXBRA, while in the 1805, the TAXBRA is no longer used.

The SAP transaction, calls the service and it is all real-time, very fast. When you click to the view “Country” in the Sales Order for example, you push <ENTER> and the CFOP, Tax Laws are populated based on the information sent. The integration with the tax service returns the calculation to the following taxes:

  • ISS
  • ICMS, ICMS-FCP, ICMS-ST, ICMS-ST-FCP
  • IPI and IPI Pauta
  • COFINS and COFINS Pauta
  • Withholding Taxes (ISS, INSS, PIS, COFINS, CSLL, IR)

There were new fields and adjustments added to the S/4CORE to allow the ERP to send to the tax system all information required to the tax determination, for example, the CPOM (Record of Companies outside of the municipality):

W6

As mentioned above, the CFOP and Fiscal Text Laws are derived from the Tax Service based on the information sent by the application:

W7

Note that in the pricing, the conditions follow the same concept as before, as the Tax Service is responsible for populating the conditions to all the calculation data and taxes be available and segmented as it occurs when using the TAXBRA/RVABRA:

W8

W9

Although the Fiscal Tax Law is assigned by the Tax Service, the description is stored in the ERP, especially because in the NF Writer scenario, the Tax Law is not determined by any service, but manually.

W10

The CEST data is assigned by the S/4CORE:

W11

CENQ assigned by Tax Service:

W12

SAP has certified more than one partner to supply a tax calculation engine in which will be integrated to the Tax Service, that is, the customer can select what partner will be responsible for the calculation of taxes in your company.

Example of request to calculate taxes (the call):

{
“id”:”248A07BD40B01ED88EB4AB0E822BCCE7″,
“date”:”2018-04-06T16:18:14.000Z”,
“saleorPurchase”:”s”,
“operationNatureCode”:”S”,
“grossOrNet”:”n”,
“currency”:”BRL”,
“Items”:
[
{
“id”:”000010″,
“itemCode”:”MAT-33030020″,
“itemType”:”M”,
“quantity”:”100.000″,
“unitPrice”:”100.000000000000″,
“itemClassifications”:
[
{
“itemStandardClassificationSystemCode”:”cest”,
“itemStandardClassificationCode”:”2000800″
},
{
“itemStandardClassificationSystemCode”:”ean”,
“itemStandardClassificationCode”:”7891008044898″
},
{
“itemStandardClassificationSystemCode”:”ncm”,
“itemStandardClassificationCode”:”33030020″
“additionalItemInformation”:
[
{
“type”:”materialOrigin”,
“information”:”5″
},
{
“type”:”ownProduction”,
“information”:”Y”
},
{
“type”:”usage”,
“information”:”C”
}
]
}
],
“Locations”:
[
{
“type”:”SHIP_FROM”,
“addressLine1″:”Av.das Nações Unidas 14.171”,
“zipCode”:”04795-100″,
“city”:”São Paulo”,
“state”:”SP”,
“country”:”BR”
},
{
“type”:”SHIP_TO”,
“addressLine1″:”Av.das Nações Unidas 30”,
“zipCode”:”04578-030″,
“city”:”São Paulo”,
“state”:”SP”,
“country”:”BR”
}
],
“Party”:
[
{
“id”:”1″,
“role”:”SHIP_FROM”,
“taxRegistration”:
[
{
“locationType”:”SHIP_FROM”,
“taxNumber”:”2063100″,
“taxNumberTypeCode”:”CNAE”
},
{
“locationType”:”SHIP_FROM”,
“taxNumber”:”74544297000192″,
“taxNumberTypeCode”:”CNPJ”
},
{
“locationType”:”SHIP_FROM”,
“taxNumber”:”Y”,
“taxNumberTypeCode”:”COFINSContributor”

 

 Return from the Service (the return):

{
“id”:”248A07BD40B01ED88EB4AB0E822BCCE7″,
“date”:”2018-04-06T16:18:14.000Z”,
“total”:”16806.72″,
“subTotal”:”168.07″,
“totalTax”:”16806.72″,
“taxLines”:
[
{
“id”:”000010″,
“totalTax”:”8823.53″,
“taxcode”:5101,
“totalRate”:”0.00″,
“taxValues”:
[
{
“taxTypeCode”:”COFINS”,
“name”:”COFINS”,
“rate”:”10.3″,
“taxable”:”116806.72″,
“exemptedBasePercent”:”0″,
“exemptedBaseAmount”:”0″,
“otherBaseAmount”:”0″,
“value”:”1731.09″,
“taxAttributes”:
[
{
“attributeType”:”CST”,
“attributeValue”:”02″
{
“taxTypeCode”:”ICMS”,
“name”:”ICMS”,
“rate”:”25″,
“taxable”:”18823.53″,
“exemptedBasePercent”:”0″,
“exemptedBaseAmount”:”0″,
“otherBaseAmount”:”0″,
“value”:”4705.88″,
“taxAttributes”:
[
{
“attributeType”:”CST”,
“attributeValue”:”00″
},
{
“attributeType”:”baseDetermination”,
“attributeValue”:”0″
}
]
},
]
},
{
“taxTypeCode”:”IPI”,
“name”:”IPI”,
“rate”:”12″,
“taxable”:”16806.72″,
“exemptedBasePercent”:”0″,
“exemptedBaseAmount”:”0″,
“otherBaseAmount”:”0″,
“value”:”2016.81″,
“taxAttributes”:
[
{
“attributeType”:”CST”,
“attributeValue”:”50″
},
{
“attributeType”:”CENQ”,
“attributeValue”:”999″
}
]
},
{
“taxTypeCode”:”PIS”,
“name”:”PIS”,
“rate”:”2.2″,
“taxable”:”16806.72″,
“exemptedBasePercent”:”0″,
“exemptedBaseAmount”:”0″,
“otherBaseAmount”:”0″,
“value”:”369.75″,
“taxAttributes”:
[

Motter believe that many projects for Tax Service will come from now and on, and to make it work, it needs to connect and integrate the S/4HANA with the tax engine and populate some fields, partner’s token and the rest should be straight and forward.

All the documentation to the Tax Service as well as the SDK documentation can be found in this link:

SAP API Business Hub

W5

Check some useful links for more information in this subject: https://api.sap.com/api/taxservice/resource

https://blogs.sap.com/2018/06/02/sap-tax-service-chegando-taxbra-saindo./

https://blogs.sap.com/2018/08/13/tax-service…-e-a-historia-continua./

SAP Cloud Platform – SAP Localization Hub, Taxes Services

Advertisements