Scope:
This post will help you to know how to create an AR Invoice using the REST service. This invoice will have a Tax line and Distribution Line for the Invoice lines
Requirement:
The requirement here is to create an AR Invoice using the REST service.
How To Do:
We can use the REST URL and Payload as below.
REST action: POST
https://<<hostname>>/fscmRestApi/resources/11.13.18.05/receivablesInvoices
Payload:
The values in the payload are samples and please change them accordingly as per your instances
Note: When Tax distribution is passed in the payload, you'll have to pass "DetailedTaxLineNumber".
SAMPLE PAYLOAD :
================
{
"BillingDate" : "2021-07-27",
"BillToCustomerNumber" : "1577300",
"BillToSite":"TCA",
"DueDate":"2021-03-20",
"BusinessUnit" : "Vision Operations",
"PaymentTerms" : "30 Net",
"InvoiceCurrencyCode" : "USD",
"TransactionDate" : "2021-03-03",
"AccountingDate" : "2021-03-03",
"TransactionSource" : "Manual",
"TransactionType" : "Invoice",
"receivablesInvoiceLines":[
{
"Description":"AM REST API TEST",
"LineNumber":1,
"Quantity":10,
"UnitSellingPrice":1,
"LineAmount" : "10.0",
"TaxClassificationCode":"VAT20",
"receivablesInvoiceLineTaxLines": [
{
"TaxAmount":"2",
"TaxRegimeCode":"FUS_STCC_REGIME-UES",
"TaxRateCode":"VAT20"
}
]
}
],
"receivablesInvoiceDistributions" : [
{
"InvoiceLineNumber" : 1,
"AccountClass" : "Receivable",
"AccountCombination" : "01-000-1212-0000-000",
"Percent" : 100
},
{
"InvoiceLineNumber" : 1,
"AccountClass" : "Revenue",
"AccountCombination" : "01-000-4110-0000-000",
"Percent" : 100
},
{
"InvoiceLineNumber" : 1,
"AccountClass" : "Tax",
"AccountCombination" : "01-000-7610-0000-000",
"DetailedTaxLineNumber": 1,
"Percent" : 100
}
]
}
I hope this helps.
No comments:
Post a Comment