Enterprise Resource Planning Blogs by SAP
Get insights and updates about cloud ERP and RISE with SAP, SAP S/4HANA and SAP S/4HANA Cloud, and more enterprise management capabilities with SAP blog posts.
cancel
Showing results for 
Search instead for 
Did you mean: 
Alice_Ying
Product and Topic Expert
Product and Topic Expert

Welcome to this in-depth exploration of the SOAP Posting APIs: Journal Entry – Post (Synchronous) and Journal Entry – Post (Asynchronous). In this blog, we will try to bring your attention to the use of reference payloads for implementing the SOAP Posting APIs effectively.

The calculation of tax amounts and tax item parameters should be planned and carefully preserved in API nodes of ProductTaxItem and WithholdingTaxItem. For details about the service nodes, please refer to ProductTaxItem | SAP Help Portal and WithholdingTaxItem | SAP Help Portal. As the tax-relevant account is determined in the backend, you don't need to enter a G/L account in ProductTaxItem and WithholdingTaxItem. Tax items are generally consolidated at the journal entry level. However, you can configure and activate the passing of tax at the line-by-line level based on your business requirements. 

In this blog, we will concentrate on posting tax relevant journal entries via the SOAP Posting APIs. We will pivot around some primary use cases that correlate with posting a journal entry involving VAT tax, non-deductible tax, tax calculated on line items, and withholding tax. 

Posting Supplier Invoice with Input Tax 

Business Context 

A supplier invoice is a document from a supplier for materials that were delivered or services that were performed. The supplier invoice triggers the payment. For more information,  please refer to All About Supplier Invoices | SAP Help Portal.

Input tax is the Value Added Tax (VAT) that the client pays on purchases of goods and services, which can often be reclaimed from the government. For more information, please refer to Tax on Sales/Purchases, Sales Taxes, and Additional Taxes | SAP Help Portal. 

Key Points 

If you want to post a supplier invoice that includes input tax using a SOAP Posting API, please bear in mind the following key points while preparing your payloads: 

  • Tax information must be input in the ProductTaxItem node of the posting API. 
  • The API doesn’t calculate the tax amount from the Tax Based Amount. Instead, tax amount must be calculated in advance. 
  • Parameters of Tax Code, Tax Classification, Tax Amount, and Tax Base Amount are all required. Otherwise you may see error message 804(FF).  
  • In the CreditorItem node, include Supplier/Account Payable along with the related tax code. 
  • You must summarize tax items at the journal entry level. For instance, for multiple expenditure items with the same tax ccode, summarize them as one tax item in the ProductTaxItem node.  
  • If an invoice contains multiple tax codes, maintain various tax items. For example, if there are multiple expenditure items with different tax codes, provide several tax items based on the tax codes. 
  • If a tax code contains multiple tax items (varying tax classification and tax rate), you'll need multiple tax items and put them in the ProductTaxItem node. 
Journal Entry Samples 
  • For multiple expense items with the same tax code, the tax items will be consolidated into one with the total tax amount. In this example, you can see two expense line items with the same tax code V1, leading to a single combined tax item.
    Picture1.png
     
Reference Payload

 

 

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sfin="http://sap.com/xi/SAPSCORE/SFIN">
    <soapenv:Header/>
    <soapenv:Body>
        <sfin:JournalEntryBulkCreateRequest>
            <MessageHeader>
                <CreationDateTime>2024-03-11T10:29:20.230Z</CreationDateTime>
            </MessageHeader>
            <!--1 or more repetitions:-->
            <JournalEntryCreateRequest>
                <MessageHeader>
                    <CreationDateTime>2024-03-11T10:29:20.230Z</CreationDateTime>
                </MessageHeader>
                <JournalEntry>
                    <OriginalReferenceDocumentType>BKPFF</OriginalReferenceDocumentType>
                    <OriginalReferenceDocument/>
                    <OriginalReferenceDocumentLogicalSystem/>
                    <BusinessTransactionType>RFBU</BusinessTransactionType>
                    <AccountingDocumentType>KR</AccountingDocumentType>
                    <DocumentReferenceID>123</DocumentReferenceID>
                    <DocumentHeaderText>Tax</DocumentHeaderText>
                    <CreatedByUser>SAP</CreatedByUser>
                    <CompanyCode>1010</CompanyCode>
                    <DocumentDate>2024-03-11</DocumentDate>
                    <PostingDate>2024-03-11</PostingDate>
                    <TaxDeterminationDate>2024-03-11</TaxDeterminationDate>
                    <Item>
                        <GLAccount>0063001000</GLAccount>
                        <AmountInTransactionCurrency currencyCode="EUR">100</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <Tax>
                            <TaxCode>V1</TaxCode>
                        </Tax>
                        <AccountAssignment>
                            <!--Optional:-->
                            <CostCenter>0010101201</CostCenter>
                        </AccountAssignment>
                    </Item>
                    <Item>
                        <GLAccount>0063001000</GLAccount>
                        <AmountInTransactionCurrency currencyCode="EUR">100</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <Tax>
                            <TaxCode>V1</TaxCode>
                        </Tax>
                        <AccountAssignment>
                            <!--Optional:-->
                            <CostCenter>0010101201</CostCenter>
                        </AccountAssignment>
                    </Item>
                    <CreditorItem>
                        <ReferenceDocumentItem>2</ReferenceDocumentItem>
                        <Creditor>S1030001</Creditor>
                        <AmountInTransactionCurrency currencyCode="EUR">-238</AmountInTransactionCurrency>
                        <DebitCreditCode>H</DebitCreditCode>
                    </CreditorItem>
                    <ProductTaxItem>
                        <TaxCode>V1</TaxCode>
                        <TaxItemClassification>VST</TaxItemClassification>
                        <AmountInTransactionCurrency currencyCode="EUR">38</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode="EUR">200</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                </JournalEntry>
            </JournalEntryCreateRequest>
        </sfin:JournalEntryBulkCreateRequest>
    </soapenv:Body>
</soapenv:Envelope>

 

 

  • For multiple expense items with different tax codes, they need to be handled individually. In this example, there are two expense items, each with a different tax code. You need to provide tax items for each separate tax code. In the ProductTaxItem node, both tax items must be maintained. 

Picture2.png

Reference Payload

 

 

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sfin="http://sap.com/xi/SAPSCORE/SFIN">
    <soapenv:Header/>
    <soapenv:Body>
        <sfin:JournalEntryBulkCreateRequest>
            <MessageHeader>
                <CreationDateTime>2024-03-11T10:29:20.230Z</CreationDateTime>
            </MessageHeader>
            <!--1 or more repetitions:-->
            <JournalEntryCreateRequest>
                <MessageHeader>
                    <CreationDateTime>2024-03-11T10:29:20.230Z</CreationDateTime>
                </MessageHeader>
                <JournalEntry>
                    <OriginalReferenceDocumentType>BKPFF</OriginalReferenceDocumentType>
                    <OriginalReferenceDocument/>
                    <OriginalReferenceDocumentLogicalSystem/>
                    <BusinessTransactionType>RFBU</BusinessTransactionType>
                    <AccountingDocumentType>KR</AccountingDocumentType>
                    <DocumentReferenceID>123</DocumentReferenceID>
                    <DocumentHeaderText>Tax</DocumentHeaderText>
                    <CreatedByUser>SAP</CreatedByUser>
                    <CompanyCode>1010</CompanyCode>
                    <DocumentDate>2024-03-11</DocumentDate>
                    <PostingDate>2024-03-11</PostingDate>
                    <TaxDeterminationDate>2024-03-11</TaxDeterminationDate>
                    <Item>
                        <GLAccount>0063001000</GLAccount>
                        <AmountInTransactionCurrency currencyCode="EUR">100</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <Tax>
                            <TaxCode>V1</TaxCode>
                        </Tax>
                        <AccountAssignment>
                            <!--Optional:-->
                            <CostCenter>0010101201</CostCenter>
                        </AccountAssignment>
                    </Item>
                    <Item>
                        <GLAccount>0063001000</GLAccount>
                        <AmountInTransactionCurrency currencyCode="EUR">100</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <Tax>
                            <TaxCode>V2</TaxCode>
                        </Tax>
                        <AccountAssignment>
                            <!--Optional:-->
                            <CostCenter>0010101201</CostCenter>
                        </AccountAssignment>
                    </Item>
                    <CreditorItem>
                        <ReferenceDocumentItem>2</ReferenceDocumentItem>
                        <Creditor>S1030001</Creditor>
                        <AmountInTransactionCurrency currencyCode="EUR">-226</AmountInTransactionCurrency>
                        <DebitCreditCode>H</DebitCreditCode>
                    </CreditorItem>
                    <ProductTaxItem>
                        <TaxCode>V1</TaxCode>
                        <TaxItemClassification>VST</TaxItemClassification>
                        <AmountInTransactionCurrency currencyCode="EUR">19</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode="EUR">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>V2</TaxCode>
                        <TaxItemClassification>VST</TaxItemClassification>
                        <AmountInTransactionCurrency currencyCode="EUR">7</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode="EUR">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                </JournalEntry>
            </JournalEntryCreateRequest>
        </sfin:JournalEntryBulkCreateRequest>
    </soapenv:Body>
</soapenv:Envelope>

 

 

  • For an expense item with a tax code that includes multiple tax items, each tax item must be addressed separately. Consider an example where there's just one expense item with tax code V8, but V8 includes two tax classifications - MWS and VST. In this situation, both of these tax items should be provided in the ProductTaxItem node. 

Picture3.png

Reference Payload

 

 

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sfin="http://sap.com/xi/SAPSCORE/SFIN">
    <soapenv:Header/>
    <soapenv:Body>
        <sfin:JournalEntryBulkCreateRequest>
            <MessageHeader>
                <CreationDateTime>2024-03-11T10:29:20.230Z</CreationDateTime>
            </MessageHeader>
            <!--1 or more repetitions:-->
            <JournalEntryCreateRequest>
                <MessageHeader>
                    <CreationDateTime>2024-03-11T10:29:20.230Z</CreationDateTime>
                </MessageHeader>
                <JournalEntry>
                    <OriginalReferenceDocumentType>BKPFF</OriginalReferenceDocumentType>
                    <OriginalReferenceDocument/>
                    <OriginalReferenceDocumentLogicalSystem/>
                    <BusinessTransactionType>RFBU</BusinessTransactionType>
                    <AccountingDocumentType>KR</AccountingDocumentType>
                    <DocumentReferenceID>123</DocumentReferenceID>
                    <DocumentHeaderText>Tax</DocumentHeaderText>
                    <CreatedByUser>SAP</CreatedByUser>
                    <CompanyCode>1010</CompanyCode>
                    <DocumentDate>2024-03-11</DocumentDate>
                    <PostingDate>2024-03-11</PostingDate>
                    <TaxDeterminationDate>2024-03-11</TaxDeterminationDate>
                    <Item>
                        <GLAccount>0063001000</GLAccount>
                        <AmountInTransactionCurrency currencyCode="EUR">100</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <Tax>
                            <TaxCode>V8</TaxCode>
                        </Tax>
                        <AccountAssignment>
                            <!--Optional:-->
                            <CostCenter>0010101201</CostCenter>
                        </AccountAssignment>
                    </Item>
                    <CreditorItem>
                        <ReferenceDocumentItem>2</ReferenceDocumentItem>
                        <Creditor>S1030001</Creditor>
                        <AmountInTransactionCurrency currencyCode="EUR">-100</AmountInTransactionCurrency>
                        <DebitCreditCode>H</DebitCreditCode>
                    </CreditorItem>
                    <ProductTaxItem>
                        <TaxCode>V8</TaxCode>
                        <TaxItemClassification>MWS</TaxItemClassification>
                        <AmountInTransactionCurrency currencyCode="EUR">-19</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode="EUR">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>V8</TaxCode>
                        <TaxItemClassification>VST</TaxItemClassification>
                        <AmountInTransactionCurrency currencyCode="EUR">19</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode="EUR">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                </JournalEntry>
            </JournalEntryCreateRequest>
        </sfin:JournalEntryBulkCreateRequest>
    </soapenv:Body>
</soapenv:Envelope>

 

 

Posting Customer Invoices with Output Tax 

Business Context 

Customer invoices are the documents you send to customers to invoice them for products or services that you have sold. Output tax is the VAT you collect from your customers when you sell goods or services, and this is generally to be remitted to the government. 

Key Points 

Please refer to the key points for posting supplier invoices. 

Journal Entry Sample 

For a customer invoice for a service or product with a 19% output tax, the tax amount should be 1,900 credited. You should enter the tax amount as -1,900. 

Picture4.png

Reference Payload

 

 

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sfin="http://sap.com/xi/SAPSCORE/SFIN">
    <soapenv:Header/>
    <soapenv:Body>
        <sfin:JournalEntryBulkCreateRequest>
            <MessageHeader>
                <CreationDateTime>2024-01-17T03:25:11.102Z</CreationDateTime>
            </MessageHeader>
            <!--1 or more repetitions:-->
            <JournalEntryCreateRequest>
                <MessageHeader>
                    <CreationDateTime>2024-01-17T03:25:11.102Z</CreationDateTime>
                </MessageHeader>
                <JournalEntry>
                    <OriginalReferenceDocumentType>BKPFF</OriginalReferenceDocumentType>
                    <BusinessTransactionType>RFBU</BusinessTransactionType>
                    <AccountingDocumentType>DR</AccountingDocumentType>
                    <DocumentHeaderText>AR With Tax</DocumentHeaderText>
                    <CreatedByUser>SAP</CreatedByUser>
                    <CompanyCode>1010</CompanyCode>
                    <DocumentDate>2024-01-17</DocumentDate>
                    <PostingDate>2024-01-17</PostingDate>
                    <TaxDeterminationDate>2024-01-17</TaxDeterminationDate>
                    <Item>
                        <GLAccount>41910000</GLAccount>
                        <AmountInTransactionCurrency currencyCode="EUR">-10000.00</AmountInTransactionCurrency>
                        <DebitCreditCode>H</DebitCreditCode>
                        <!-- With Date by Default in GL Item -->
                        <AssignmentReference>AR with Tax</AssignmentReference>
                        <Tax>
                            <TaxCode>A2</TaxCode>
                        </Tax>
                        <AccountAssignment>
                            <ProfitCenter>YB600</ProfitCenter>
                        </AccountAssignment>
                        <ProfitabilitySupplement>
                            <Customer>10100001</Customer>
                        </ProfitabilitySupplement>
                    </Item>
                    <DebtorItem>
                        <ReferenceDocumentItem>2</ReferenceDocumentItem>
                        <Debtor>10100001</Debtor>
                        <AmountInTransactionCurrency currencyCode="EUR">11900.00</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <DocumentItemText>Customer item</DocumentItemText>
                    </DebtorItem>
                    <ProductTaxItem>
                        <TaxCode>A2</TaxCode>
                        <TaxItemClassification>MWS</TaxItemClassification>
                        <AmountInTransactionCurrency currencyCode="EUR">-1900.00</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode="EUR">-10000.00</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                </JournalEntry>
            </JournalEntryCreateRequest>
        </sfin:JournalEntryBulkCreateRequest>
    </soapenv:Body>
</soapenv:Envelope>

 

 

Posting Non-deductible Input Tax 

Business Context 

Businesses not liable to tax on sales or purchases, such as businesses in the public sector or insurance companies, cannot or can partially claim sales tax from incoming invoices as input tax. In this case, the incoming invoice is posted with a tax code that contains a condition for non-deductible input tax.  

The non-deductible input tax can either be posted to a separate G/L account as a separate line item or be distributed to the expense items involved. For details please refer to Tax Type. 

Key Points 

Pay attention to the following points when posting non-deductible input tax: 

  • A non-deductible tax code consists of two tax types that input tax (VST) and non-deductible input tax. The input tax can be completely or partially non-deductible. Tax items should be provided separately in the ProductTaxItem node. 
  • The non-deductive tax amount can be posted to a separate expense account, or it can be distributed to the G/L account and asset line items. Non-deductible distributable tax should be added to relevant expense line item where it was determined. For this reason, no separate account is specified for the non-deductible distributable tax. 
Journal Entry Sample 

In this example where tax code N2 includes two tax items - input tax (VST) and non-deductible tax amount (NVV), both need to be maintained in the ProductTaxItem node. Since NVV is to be posted in the original expense account, the non-deductible tax amount should be added to the expense account. 

Picture5.png

Reference Payload

 

 

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sfin="http://sap.com/xi/SAPSCORE/SFIN">
    <soapenv:Header/>
    <soapenv:Body>
        <sfin:JournalEntryBulkCreateRequest>
            <MessageHeader>
                <CreationDateTime>2024-03-11T10:29:20.230Z</CreationDateTime>
            </MessageHeader>
            <JournalEntryCreateRequest>
                <MessageHeader>
                    <CreationDateTime>2024-03-11T10:29:20.230Z</CreationDateTime>
                </MessageHeader>
                <JournalEntry>
                    <OriginalReferenceDocumentType>BKPFF</OriginalReferenceDocumentType>
                    <BusinessTransactionType>RFBU</BusinessTransactionType>
                    <DocumentReferenceID>123</DocumentReferenceID>
                    <AccountingDocumentType>KR</AccountingDocumentType>
                    <DocumentHeaderText>Tax Non Deductible</DocumentHeaderText>
                    <CreatedByUser>SAP</CreatedByUser>
                    <CompanyCode>1510</CompanyCode>
                    <DocumentDate>2024-03-11</DocumentDate>
                    <PostingDate>2024-03-11</PostingDate>
                    <TaxDeterminationDate>2024-03-11</TaxDeterminationDate>
                    <Item>
                        <GLAccount>65001000</GLAccount>
                        <AmountInTransactionCurrency currencyCode='JPY'>3672</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <DocumentItemText>GL Item</DocumentItemText>
                        <Tax>
                            <TaxCode>N2</TaxCode>
                        </Tax>
                        <AccountAssignment>
                            <CostCenter>15101101</CostCenter>
                        </AccountAssignment>
                    </Item>
                    <CreditorItem>
                        <ReferenceDocumentItem>2</ReferenceDocumentItem>
                        <Creditor>15300001</Creditor>
                        <AmountInTransactionCurrency currencyCode='JPY'>-3960</AmountInTransactionCurrency>
                        <DebitCreditCode>H</DebitCreditCode>
                        <DocumentItemText>Supplier Item</DocumentItemText>
                    </CreditorItem>
                    <ProductTaxItem>
                        <TaxCode>N2</TaxCode>
                        <TaxItemClassification>VST</TaxItemClassification>
                        <AmountInTransactionCurrency currencyCode='JPY'>288</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode='JPY'>3600</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>N2</TaxCode>
                        <TaxItemClassification>NVV</TaxItemClassification>
                        <AmountInTransactionCurrency currencyCode='JPY'>72</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode='JPY'>3600</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                </JournalEntry>
            </JournalEntryCreateRequest>
        </sfin:JournalEntryBulkCreateRequest>
    </soapenv:Body>
</soapenv:Envelope>

 

 

Tax Calculation by Line items (US Tax)  

Business Context  

If tax is calculated by line items, that means the tax is not determined for the entire document. Instead, it must be determined and posted individually for each expense item or revenue item. 

Generally, a line-by-line tax calculation is used only in company codes associated with the following countries: United States, Canada and, to some extent, India. If an external tax reporting system is used, the tax must be reported and posted on a line-by-line basis. 

You may encounter the following error messages when posting with line-by-line tax calculation: 

817(FF): Taxes by item is not activated and therefore not permitted in transfer. 
818(FF): Taxes by item is activated; consequently, transfer by item is mandatory. 

For tax at the line item level, Tax Jurisdiction Code is required in the ProductTaxItem node. Tax Item Group is also required and must be identical with the related items. G/L Item has the relevant Tax Item Group parameter in the Tax substructure. 

Now we will see three journal entry samples with reference payloads for line-by-line tax. 

  • Sample 1: From the screenshot, you see three line items with account 61004000 (travel expense meals) have different TaxItemGroup parameter (001, 002 and 003). Two of them have the identical Tax Code (U1) and Tax Jurisdiction Code (CA00000000) and the other has a different Tax Jurisdiction Code (FL00000000).  Therefore, the line items should have a tax item for each. 
  • Sample 2: You see three line Items with account 61004000 (travel expense meals). Because two of them have the same Tax Code (U1) and Tax Jurisdiction Code (CA00000000), these two items can share one tax item that has the summarized tax amount. 
  • Sample 3: Complicated tax calculation with multiple tax jurisdiction levels. Line-by-line tax is complicated normally because jurisdiction structure may have multiple levels. Each level has a sub-jurisdiction code. In this case, all relevant tax items must be arranged in the payload.  
Journal Entry Sample 1

Picture6.png

Reference Payload 1

 

 

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sfin="http://sap.com/xi/SAPSCORE/SFIN">
   <soapenv:Header/>
   <soapenv:Body>
      <sfin:JournalEntryBulkCreateRequest>
         <MessageHeader>
            <CreationDateTime>{{$isoTimestamp}}</CreationDateTime>
         </MessageHeader>
         <JournalEntryCreateRequest>
            <MessageHeader>
               <CreationDateTime>{{$isoTimestamp}}</CreationDateTime>
            </MessageHeader>
            <JournalEntry>
               <OriginalReferenceDocumentType>BKPFF</OriginalReferenceDocumentType>
               <BusinessTransactionType>RFBU</BusinessTransactionType>
               <AccountingDocumentType>SA</AccountingDocumentType>
               <DocumentReferenceID>TAX_001</DocumentReferenceID>
               <DocumentHeaderText>{{documentHeaderText_Header}}</DocumentHeaderText>
               <CreatedByUser>SAP</CreatedByUser>
               <CompanyCode>1710</CompanyCode>
               <DocumentDate>{{currentDate}}</DocumentDate>
               <PostingDate>{{currentDate}}</PostingDate>
               <Item>
                  <GLAccount>61004000</GLAccount>
                  <AmountInTransactionCurrency currencyCode="USD">107.25</AmountInTransactionCurrency>
                  <DebitCreditCode>S</DebitCreditCode>
                  <Tax>
                     <TaxCode>U1</TaxCode>
                     <TaxJurisdiction>CA00000000</TaxJurisdiction>
                     <TaxItemGroup>001</TaxItemGroup>
                  </Tax>
                  <AccountAssignment>
                     <CostCenter>17101101</CostCenter>
                  </AccountAssignment>
               </Item>
               <Item>
                  <GLAccount>61004000</GLAccount>
                  <AmountInTransactionCurrency currencyCode="USD">107.25</AmountInTransactionCurrency>
                  <DebitCreditCode>S</DebitCreditCode>
                  <Tax>
                     <TaxCode>U1</TaxCode>
                     <TaxJurisdiction>CA00000000</TaxJurisdiction>
                     <TaxItemGroup>002</TaxItemGroup>
                  </Tax>
                  <AccountAssignment>
                     <CostCenter>17101101</CostCenter>
                  </AccountAssignment>
               </Item>
               <Item>
                  <GLAccount>61004000</GLAccount>
                  <AmountInTransactionCurrency currencyCode="USD">106</AmountInTransactionCurrency>
                  <DebitCreditCode>S</DebitCreditCode>
                  <Tax>
                     <TaxCode>U1</TaxCode>
                     <TaxJurisdiction>FL00000000</TaxJurisdiction>
                     <TaxItemGroup>003</TaxItemGroup>
                  </Tax>
                  <AccountAssignment>
                     <CostCenter>17101101</CostCenter>
                  </AccountAssignment>
               </Item>
               <Item>
                  <GLAccount>11001000</GLAccount>
                  <AmountInTransactionCurrency currencyCode="USD">-300.00</AmountInTransactionCurrency>
                  <DebitCreditCode>H</DebitCreditCode>
                  <HouseBank>USBK2</HouseBank>
                  <HouseBankAccount>USAC2</HouseBankAccount>
               </Item>
               <ProductTaxItem>
                  <TaxCode>U1</TaxCode>
                  <TaxItemGroup>001</TaxItemGroup>
                  <TaxItemClassification>MW1</TaxItemClassification>
                  <DebitCreditCode>H</DebitCreditCode>
                  <TaxJurisdiction>CA00000000</TaxJurisdiction>
                  <AmountInTransactionCurrency currencyCode="USD">-7.25</AmountInTransactionCurrency>
                  <TaxBaseAmountInTransCrcy currencyCode="USD">-100</TaxBaseAmountInTransCrcy>
               </ProductTaxItem>
               <ProductTaxItem>
                  <TaxCode>U1</TaxCode>
                  <TaxItemGroup>001</TaxItemGroup>
                  <TaxItemClassification>NVV</TaxItemClassification>
                  <DebitCreditCode>S</DebitCreditCode>
                  <TaxJurisdiction>CA00000000</TaxJurisdiction>
                  <AmountInTransactionCurrency currencyCode="USD">7.25</AmountInTransactionCurrency>
                  <TaxBaseAmountInTransCrcy currencyCode="USD">100</TaxBaseAmountInTransCrcy>
               </ProductTaxItem>
               <ProductTaxItem>
                  <TaxCode>U1</TaxCode>
                  <TaxItemGroup>002</TaxItemGroup>
                  <TaxItemClassification>MW1</TaxItemClassification>
                  <DebitCreditCode>H</DebitCreditCode>
                  <TaxJurisdiction>CA00000000</TaxJurisdiction>
                  <AmountInTransactionCurrency currencyCode="USD">-7.25</AmountInTransactionCurrency>
                  <TaxBaseAmountInTransCrcy currencyCode="USD">-100</TaxBaseAmountInTransCrcy>
               </ProductTaxItem>
               <ProductTaxItem>
                  <TaxCode>U1</TaxCode>
                  <TaxItemGroup>002</TaxItemGroup>
                  <TaxItemClassification>NVV</TaxItemClassification>
                  <DebitCreditCode>S</DebitCreditCode>
                  <TaxJurisdiction>CA00000000</TaxJurisdiction>
                  <AmountInTransactionCurrency currencyCode="USD">7.25</AmountInTransactionCurrency>
                  <TaxBaseAmountInTransCrcy currencyCode="USD">100</TaxBaseAmountInTransCrcy>
               </ProductTaxItem>
               <ProductTaxItem>
                  <TaxCode>U1</TaxCode>
                  <TaxItemGroup>003</TaxItemGroup>
                  <TaxItemClassification>MW1</TaxItemClassification>
                  <DebitCreditCode>H</DebitCreditCode>
                  <TaxJurisdiction>FL00000000</TaxJurisdiction>
                  <AmountInTransactionCurrency currencyCode="USD">-6</AmountInTransactionCurrency>
                  <TaxBaseAmountInTransCrcy currencyCode="USD">-100</TaxBaseAmountInTransCrcy>
               </ProductTaxItem>
               <ProductTaxItem>
                  <TaxCode>U1</TaxCode>
                  <TaxItemGroup>003</TaxItemGroup>
                  <TaxItemClassification>NVV</TaxItemClassification>
                  <DebitCreditCode>S</DebitCreditCode>
                  <TaxJurisdiction>FL00000000</TaxJurisdiction>
                  <AmountInTransactionCurrency currencyCode="USD">6</AmountInTransactionCurrency>
                  <TaxBaseAmountInTransCrcy currencyCode="USD">100</TaxBaseAmountInTransCrcy>
               </ProductTaxItem>
            </JournalEntry>
         </JournalEntryCreateRequest>
      </sfin:JournalEntryBulkCreateRequest>
   </soapenv:Body>
</soapenv:Envelope>

 

 

Journal Entry Sample 2

Picture7.png

Reference Payload 2

 

 

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sfin="http://sap.com/xi/SAPSCORE/SFIN">
   <soapenv:Header/>
   <soapenv:Body>
      <sfin:JournalEntryBulkCreateRequest>
         <MessageHeader>
            <CreationDateTime>{{$isoTimestamp}}</CreationDateTime>
         </MessageHeader>
         <JournalEntryCreateRequest>
            <MessageHeader>
               <CreationDateTime>{{$isoTimestamp}}</CreationDateTime>
            </MessageHeader>
            <JournalEntry>
               <OriginalReferenceDocumentType>BKPFF</OriginalReferenceDocumentType>
               <BusinessTransactionType>RFBU</BusinessTransactionType>
               <AccountingDocumentType>SA</AccountingDocumentType>
               <DocumentReferenceID>TAX_001</DocumentReferenceID>
               <DocumentHeaderText>{{documentHeaderText_Header}}</DocumentHeaderText>
               <CreatedByUser>SAP</CreatedByUser>
               <CompanyCode>1710</CompanyCode>
               <DocumentDate>{{currentDate}}</DocumentDate>
               <PostingDate>{{currentDate}}</PostingDate>
               <Item>
                  <GLAccount>61004000</GLAccount>
                  <AmountInTransactionCurrency currencyCode="USD">107.25</AmountInTransactionCurrency>
                  <DebitCreditCode>S</DebitCreditCode>
                  <Tax>
                     <TaxCode>U1</TaxCode>
                     <TaxJurisdiction>CA00000000</TaxJurisdiction>
                     <TaxItemGroup>001</TaxItemGroup>
                  </Tax>
                  <AccountAssignment>
                     <CostCenter>17101101</CostCenter>
                  </AccountAssignment>
               </Item>
               <Item>
                  <GLAccount>61004000</GLAccount>
                  <AmountInTransactionCurrency currencyCode="USD">107.25</AmountInTransactionCurrency>
                  <DebitCreditCode>S</DebitCreditCode>
                  <Tax>
                     <TaxCode>U1</TaxCode>
                     <TaxJurisdiction>CA00000000</TaxJurisdiction>
                     <TaxItemGroup>001</TaxItemGroup>
                  </Tax>
                  <AccountAssignment>
                     <CostCenter>17101101</CostCenter>
                  </AccountAssignment>
               </Item>
               <Item>
                  <GLAccount>61004000</GLAccount>
                  <AmountInTransactionCurrency currencyCode="USD">106</AmountInTransactionCurrency>
                  <DebitCreditCode>S</DebitCreditCode>
                  <Tax>
                     <TaxCode>U1</TaxCode>
                     <TaxJurisdiction>FL00000000</TaxJurisdiction>
                     <TaxItemGroup>002</TaxItemGroup>
                  </Tax>
                  <AccountAssignment>
                     <CostCenter>17101101</CostCenter>
                  </AccountAssignment>
               </Item>
               <Item>
                  <GLAccount>11001000</GLAccount>
                  <AmountInTransactionCurrency currencyCode="USD">-300.00</AmountInTransactionCurrency>
                  <DebitCreditCode>H</DebitCreditCode>
                  <HouseBank>USBK2</HouseBank>
                  <HouseBankAccount>USAC2</HouseBankAccount>
               </Item>
               <ProductTaxItem>
                  <TaxCode>U1</TaxCode>
                  <TaxItemGroup>001</TaxItemGroup>
                  <TaxItemClassification>MW1</TaxItemClassification>
                  <DebitCreditCode>H</DebitCreditCode>
                  <TaxJurisdiction>CA00000000</TaxJurisdiction>
                  <AmountInTransactionCurrency currencyCode="USD">-14.5</AmountInTransactionCurrency>
                  <TaxBaseAmountInTransCrcy currencyCode="USD">-200</TaxBaseAmountInTransCrcy>
               </ProductTaxItem>
               <ProductTaxItem>
                  <TaxCode>U1</TaxCode>
                  <TaxItemGroup>001</TaxItemGroup>
                  <TaxItemClassification>NVV</TaxItemClassification>
                  <DebitCreditCode>S</DebitCreditCode>
                  <TaxJurisdiction>CA00000000</TaxJurisdiction>
                  <AmountInTransactionCurrency currencyCode="USD">14.5</AmountInTransactionCurrency>
                  <TaxBaseAmountInTransCrcy currencyCode="USD">200</TaxBaseAmountInTransCrcy>
               </ProductTaxItem>
               <ProductTaxItem>
                  <TaxCode>U1</TaxCode>
                  <TaxItemGroup>002</TaxItemGroup>
                  <TaxItemClassification>MW1</TaxItemClassification>
                  <DebitCreditCode>H</DebitCreditCode>
                  <TaxJurisdiction>FL00000000</TaxJurisdiction>
                  <AmountInTransactionCurrency currencyCode="USD">-6</AmountInTransactionCurrency>
                  <TaxBaseAmountInTransCrcy currencyCode="USD">-100</TaxBaseAmountInTransCrcy>
               </ProductTaxItem>
               <ProductTaxItem>
                  <TaxCode>U1</TaxCode>
                  <TaxItemGroup>002</TaxItemGroup>
                  <TaxItemClassification>NVV</TaxItemClassification>
                  <DebitCreditCode>S</DebitCreditCode>
                  <TaxJurisdiction>FL00000000</TaxJurisdiction>
                  <AmountInTransactionCurrency currencyCode="USD">6</AmountInTransactionCurrency>
                  <TaxBaseAmountInTransCrcy currencyCode="USD">100</TaxBaseAmountInTransCrcy>
               </ProductTaxItem>
            </JournalEntry>
         </JournalEntryCreateRequest>
      </sfin:JournalEntryBulkCreateRequest>
   </soapenv:Body>
</soapenv:Envelope>

 

 

Journal Entry Sample 3

Picture8.png

Reference Payload 3

 

 

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sfin="http://sap.com/xi/SAPSCORE/SFIN">
    <soap:Header/>
    <soap:Body>
        <sfin:JournalEntryBulkCreateRequest>
            <MessageHeader>
                <CreationDateTime>2024-01-17T07:05:19.212Z</CreationDateTime>
            </MessageHeader>
            <JournalEntryCreateRequest>
                <MessageHeader>
                    <CreationDateTime>2024-01-17T07:05:19.212Z</CreationDateTime>
                </MessageHeader>
                <JournalEntry>
                    <OriginalReferenceDocumentType>BKPFF</OriginalReferenceDocumentType>
                    <BusinessTransactionType>RFBU</BusinessTransactionType>
                    <AccountingDocumentType>SA</AccountingDocumentType>
                    <!-- If no this field, Message: For document type KR, an entry is required in field Reference -->
                    <DocumentReferenceID>TAX_001</DocumentReferenceID>
                    <DocumentHeaderText>Line By Line</DocumentHeaderText>
                    <CreatedByUser>SAP</CreatedByUser>
                    <CompanyCode>1710</CompanyCode>
                    <DocumentDate>2024-01-17</DocumentDate>
                    <PostingDate>2024-01-17</PostingDate>
                    <Item>
                        <ReferenceDocumentItem>1</ReferenceDocumentItem>
                        <GLAccount>61004000</GLAccount>
                        <AmountInTransactionCurrency currencyCode="USD">105</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <DocumentItemText>Test Tax</DocumentItemText>
                        <Tax>
                            <TaxCode>U1</TaxCode>
                            <TaxJurisdiction>4712100900</TaxJurisdiction>
                            <TaxItemGroup>1</TaxItemGroup>
                        </Tax>
                        <AccountAssignment>
                            <CostCenter>17101101</CostCenter>
                        </AccountAssignment>
                    </Item>
                    <Item>
                        <ReferenceDocumentItem>2</ReferenceDocumentItem>
                        <GLAccount>11001000</GLAccount>
                        <AmountInTransactionCurrency currencyCode="USD">-100</AmountInTransactionCurrency>
                        <DebitCreditCode>H</DebitCreditCode>
                        <DocumentItemText>Test Bank</DocumentItemText>
                        <HouseBank>USBK1</HouseBank>
                        <HouseBankAccount>USAC1</HouseBankAccount>
                        <ValueDate>2024-01-17</ValueDate>
                    </Item>
                    <!-- NVV Tax lines -->
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>NVV</TaxItemClassification>
                        <TaxJurisdiction>4700000000</TaxJurisdiction>
                        <TaxJurisdictionLevel>1</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>3.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">3</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>NVV</TaxItemClassification>
                        <TaxJurisdiction>4712100000</TaxJurisdiction>
                        <TaxJurisdictionLevel>2</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>2.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">2</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>NVV</TaxItemClassification>
                        <TaxJurisdiction>4712100900</TaxJurisdiction>
                        <TaxJurisdictionLevel>3</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>0.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">0</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>NVV</TaxItemClassification>
                        <TaxJurisdiction>4712100900</TaxJurisdiction>
                        <TaxJurisdictionLevel>4</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>0.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">0</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>NVV</TaxItemClassification>
                        <TaxJurisdiction>4712100900</TaxJurisdiction>
                        <TaxJurisdictionLevel>5</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>0.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">0</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>NVV</TaxItemClassification>
                        <TaxJurisdiction>4712100900</TaxJurisdiction>
                        <TaxJurisdictionLevel>6</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>0.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">0</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>MW1</TaxItemClassification>
                        <TaxJurisdiction>4700000000</TaxJurisdiction>
                        <TaxJurisdictionLevel>1</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>3.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">-3</AmountInTransactionCurrency>
                        <DebitCreditCode>H</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">-100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>MW2</TaxItemClassification>
                        <TaxJurisdiction>4712100000</TaxJurisdiction>
                        <TaxJurisdictionLevel>2</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>2.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">-2</AmountInTransactionCurrency>
                        <DebitCreditCode>H</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">-100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>MW3</TaxItemClassification>
                        <TaxJurisdiction>4712100900</TaxJurisdiction>
                        <TaxJurisdictionLevel>3</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>0.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">0</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">-100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>MW4</TaxItemClassification>
                        <TaxJurisdiction>4712100900</TaxJurisdiction>
                        <TaxJurisdictionLevel>4</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>0.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">0</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">-100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>MW4</TaxItemClassification>
                        <TaxJurisdiction>4712100900</TaxJurisdiction>
                        <TaxJurisdictionLevel>5</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>0.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">0</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">-100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <ProductTaxItem>
                        <TaxCode>U1</TaxCode>
                        <TaxItemClassification>MW4</TaxItemClassification>
                        <TaxJurisdiction>4712100900</TaxJurisdiction>
                        <TaxJurisdictionLevel>6</TaxJurisdictionLevel>
                        <LowestLevelTaxJurisdiction>4712100900</LowestLevelTaxJurisdiction>
                        <TaxItemGroup>1</TaxItemGroup>
                        <TaxRate>0.00</TaxRate>
                        <AmountInTransactionCurrency currencyCode="USD">0</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <TaxBaseAmountInTransCrcy currencyCode="USD">-100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                </JournalEntry>
            </JournalEntryCreateRequest>
        </sfin:JournalEntryBulkCreateRequest>
    </soap:Body>
</soap:Envelope>

 

 

Posting Supplier Invoices with Withholding Tax 

Business Context  

For the business context of withholding tax, please refer to Withholding Tax | SAP Help Portal. Generally withholding tax is tax that is charged from payment in some countries/regions. Instead of the responsible party paying it directly to the authorities, it's deducted by the customer from the payment for a taxed supplier and then sent straight to the tax authorities.

Withholding tax can be posted either during payment or invoicing, depending on the legal requirements of each region. For example, withholding tax is posted when the supplier invoice is posted, the tax is deducted and paid to tax authorities on behalf of the supplier.

Key Points 

If you want to post withholding tax via API, please kindly check parameters in withholding tax section. Please refer to WithholdingTaxItem | SAP Help Portal  in details.

  • ReferenceDocumentItem 

ReferenceDocumentItem is mandatory in Withholding Tax section and must have the reference with accounting document items. It doesn’t determine the sequence of the journal entry items. 

  • TaxIsToBeCalculated 

Withholding Tax amount can be calculated automatically once TaxIsToBeCalculated is set with true and AmountInTransactionCurrency is set with 0. 

Journal Entry Sample 

For this client, withholding tax is required to post when invoice. A Supplier invoice should be posted with expense 100 together with 1% VAT and deducting 2% withholding tax. VAT tax code is V1 and withholding tax code is 02 with withholding tax type I1 and I2. 

For the journal entry in the screenshot below, the account payable is 96, 4 withhold tax deducted from 100. 

Picture9.png

Picture10.png

Reference Payload

 

 

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sfin="http://sap.com/xi/SAPSCORE/SFIN">
    <soapenv:Header/>
    <soapenv:Body>
        <sfin:JournalEntryBulkCreateRequest>
            <MessageHeader>
                <TestDataIndicator/>
                <CreationDateTime>{{$isoTimestamp}}</CreationDateTime>
            </MessageHeader>
            <JournalEntryCreateRequest>
                <MessageHeader>
                    <TestDataIndicator/>
                    <CreationDateTime>{{$isoTimestamp}}</CreationDateTime>
                </MessageHeader>
                <JournalEntry>
                    <OriginalReferenceDocumentType>BKPFF</OriginalReferenceDocumentType>
                    <BusinessTransactionType>RFBU</BusinessTransactionType>
                    <AccountingDocumentType>KZ</AccountingDocumentType>
                    <DocumentReferenceID>123</DocumentReferenceID>
                    <DocumentHeaderText>Supplier_WithHolding_Tax</DocumentHeaderText>
                    <CreatedByUser>SAP</CreatedByUser>
                    <CompanyCode>5110</CompanyCode>
                    <DocumentDate>{{currentDate}}</DocumentDate>
                    <PostingDate>{{currentDate}}</PostingDate>
                    <TaxDeterminationDate>{{currentDate}}</TaxDeterminationDate>
                    <TaxReportingDate>{{currentDate}}</TaxReportingDate>
                    <Item>
                        <GLAccount>	61008000</GLAccount>
                        <AmountInTransactionCurrency currencyCode="IDR">99</AmountInTransactionCurrency>
                        <DebitCreditCode>S</DebitCreditCode>
                        <Tax>
                            <TaxCode>V1</TaxCode>
                        </Tax>
                        <AccountAssignment>
                            <CostCenter>51101101</CostCenter>
                        </AccountAssignment>
                        <BusinessPlace>5110</BusinessPlace>
                    </Item>
                    <CreditorItem>
                        <ReferenceDocumentItem>1</ReferenceDocumentItem>
                        <Creditor>51405110</Creditor>
                        <AmountInTransactionCurrency currencyCode="IDR">-100</AmountInTransactionCurrency>
                        <DebitCreditCode>H</DebitCreditCode>
                        <DocumentItemText>Vender item</DocumentItemText>
                    </CreditorItem>
                    <ProductTaxItem>
                        <TaxCode>V1</TaxCode>
                        <TaxItemClassification>VST</TaxItemClassification>
                        <AmountInTransactionCurrency currencyCode="IDR">1</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode="IDR">100</TaxBaseAmountInTransCrcy>
                    </ProductTaxItem>
                    <WithholdingTaxItem>
                        <ReferenceDocumentItem>1</ReferenceDocumentItem>
                        <WithholdingTaxType>I1</WithholdingTaxType>
                        <WithholdingTaxCode>02</WithholdingTaxCode>
                        <TaxIsToBeCalculated>true</TaxIsToBeCalculated>
                        <AmountInTransactionCurrency currencyCode="IDR">0</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode="IDR">100</TaxBaseAmountInTransCrcy>
                    </WithholdingTaxItem>
                    <WithholdingTaxItem>
                        <ReferenceDocumentItem>1</ReferenceDocumentItem>
                        <WithholdingTaxType>I2</WithholdingTaxType>
                        <WithholdingTaxCode>02</WithholdingTaxCode>
                        <TaxIsToBeCalculated>true</TaxIsToBeCalculated>
                        <AmountInTransactionCurrency currencyCode="IDR">0</AmountInTransactionCurrency>
                        <TaxBaseAmountInTransCrcy currencyCode="IDR">100</TaxBaseAmountInTransCrcy>
                    </WithholdingTaxItem>
                </JournalEntry>
            </JournalEntryCreateRequest>
        </sfin:JournalEntryBulkCreateRequest>
    </soapenv:Body>
</soapenv:Envelope>

 

 

If you'd like to explore more on the posting APIs, please refer to the following links on SAP Help Portal: