Long time back , I had a post discussing AR Receipting , API's avaiability and integration with POS based system. This post is sort of tutorial outlines the specifications and the methodology for using the various Receipt APIs.
Functional Importance of Receipt API's
Oracle receipt APIs provide an extension to existing functionality of creating and manipulating receipts through standard AR Receipts forms and lockboxes.
Most of the public receipt API caters to the following basic functionality via different API calls:
- Creating a cash receipt.
- Applying a cash receipt to a debit item.
- Creating a cash receipt and applying it to a debit item in one pass.
- On-account application.
- Unapplying the on-account application.
- Unapplying the receipt application to a particular transaction.
- Reversing the receipt.
- Activity application, such as Receipt Write-off.
- Creating a miscellaneous receipt.
- Other account application, such as Claim Investigation.
- Receipt-to-receipt application.
- Creating a cash receipt and an on-account application in one pass.
These API potentially used when you are using two major products like AR and Trade managment.
Which API's is not supported
- Creating a Batch Receipt
Why Receipts API are in demand
- For Migration in Transformation/re-implemenation project , company want to bring old receipts to newer system. Except Lockbox, there is no other way other than API.
- Integration :Some sectors like retail, healthcare , Telco need direct Integration with third party POS based system like (WINCOR etc)
- Need for excel based upload interface : Majority of collection for companies are in third and fourth week of the month , and all entry should go into system thus need for excel based receipt upload cann't be denied. The business need for having receipt WEBADI is still not supported by Oracle.
What is senarios
The senario which going to discuss here is "Create Cash Receipt "
In Reality a cash receipts may be created as identified (with a customer/Transaction) or as unidentified (without a customer).This routine is called to create cash receipts for the payment received in the form of a check or cash.
The key is
- When you tag customer/transaction it is identified
- Where there is no customer attached to receipt it is unidentified.
Moreover Receipt that you are going to create must have a Payment method , which have underline account details for identified and unidentified account.
Which API is being used
By using the following procedure Ar_receipt_api_pub.Create_cash you can create a single cash receipt, as in the case of manually created cash receipts.
Step to use the API
You have to perform these steps in order to get API executed
Step 1 : Identification of some mandatory and key column of APIOnce you identify the key and mandatory column , you have 50% done. What is recomended for you to check the API version in irep with your EBS version.Here is the example.Step 2 : Idetify and the mandatory column and must do pre-requsite setup for receipt.Your Payment method , underline bank, respective accounting details must be pre-requiste step up for creating a receipt in Oracle.The mandatory requirement is Customer master with valid bill to and a valid transaction that must be open.Step 3: You need to initialize the apps_initialize pacakgeFor this you have to follow these steps:Run the query 1
- SELECT USER_ID FROM FND_USER
- WHERE USER_NAME='USER_NAME';
Run the query 2
- SELECT application_id FROM fnd_application
- WHERE application_short_name LIKE 'APPL_SHRT_NAME'; --'AR';
Run the query 3
- SELECT RESPONSIBILITY_ID
- FROM FND_RESPONSIBILITY
- WHERE APPLICATION_ID=222;
Run the query 4Run thisscript , this will set the apps environment.Alternatively you can use fnd_global.apps_initialize(1290,51118,222) before calling API.Step 4: run thescript in Toad or sql*plus and once the procedure executed correctly Oracle will issue a receipt id.This is been tested in 11i . With little modification you can use in R12. Here is api code in text file.
Finally Verification
Make sure you API executed correctly , once done you can check the receipt creation from Receipt workbench screen. What you have to do, just search the Receipt number and verify the details are correctly been populated or not.Navigate to ReceivablesReceipts : Receipts.Query for Receipt Number 'HUB-TEST1'(As Example discussed above). The below screen shows the created cash receipt
We will some other API usage in another post