Retrieving the Investor's Statement
Description
This web service provides the statement of investor account. It categorizes each deposit and withdrawal transaction, for example, a deposit may occur due to repayment from loan, or when the investor exits from a loan. Similarly, any deposit or withdrawal transactions by the investors are reflected in the statement.
Definition
https://<domain>/services/apexrest/peer/v1/accounts/getLenderStatement/<accountId>*
Parameters
The table given below provides details of the request parameters used by this web service:
Fields | Type | Description |
---|---|---|
startDate* | Date | This is the start date for the Lender Statement |
endDate | Date | This is the end date for the Lender Statement |
skipInvestmentBooking | Boolean |
If this is true, Investment Booking will not be considered in the Lender Statement. |
accountId | String |
The accountId in the url should be of an Investor |
Error messages
When you post a web service, you can receive the possible error messages as shown in the table below:
Error Code |
Reason |
HTTP Status Code |
---|---|---|
INVALID_INPUT |
You will receive this error if the Request body is not according to the specifications |
400 |
EXCEPTION_WHILE_PROCESSING |
You will receive this error if any unexpected error occurs during the processing of the request, the system will raise the exception |
500 |
ACCOUNT_NOT_FOUND | You will receive this error if the account of the required lender is not found | 404 |
Sample Request
The sample request to be sent is as shown below:
https://na11.salesforce.com/services/apexrest/peer/v1/accounts/getLenderStatement/001G000001eGqcV?startDate=2012-1-1&endDate=2015-1-1&skipInvestmentBooking=true
Sample Response
The sample response that you will receive is as shown below:
{
"status": "SUCCESS",
"rowNumber": -1,
"response": [
{
"txnObj": {
"attributes": {
"type": "loan__Investor_Fund_Transaction__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Fund_Transaction__c/a3037000000aDTgAAM" },
"Id": "a3037000000aDTgAAM",
"Name": "IFT-000000124",
"loan__Transaction_Amount__c": 10000,
"loan__Transaction_Type__c": "DEPOSIT",
"loan__Transaction_Date__c": "2016-03-26",
"loan__Balance_After__c": 10000,
"loan__Cleared__c": true,
"loan__Reversed__c": false,
"CreatedDate": "2016-11-15T10:04:50.000+0000",
"loan__Rejected__c": false
},
"transactionType": "DEPOSIT",
"transactionId": "IFT-000000124",
"transactionDatetime": null,
"transactionDate": "2016-03-26",
"transactionAmount": 10000,
"sharePercent": null,
"reversed": false,
"relatedLoan": null,
"rejected": false,
"principal": null,
"lateFee": null,
"interest": null,
"fee": null,
"cleared": true,
"availableFunds": 10000,
"amountInFunding": 0
},
{
"txnObj": {
"attributes": {
"type": "loan__Investor_Loan_Account_Txns__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan_Account_Txns__c/a3137000000LpVhAAK" },
"Id": "a3137000000LpVhAAK",
"Name": "ILTID-0000251395",
"loan__Txn_Amount__c": 1000,
"CreatedDate": "2016-11-15T10:18:10.000+0000",
"loan__Interest_Service_Charge__c": 0,
"loan__Late_Fee_Service_Charge__c": 0,
"loan__Interest_Paid__c": 0,
"loan__Late_Fees_Paid__c": 0,
"loan__Principal_Paid__c": 0,
"loan__Post_Date__c": "2016-03-26",
"loan__Transaction_Date__c": "2016-03-26",
"loan__Vat__c": 0,
"loan__Tax__c": 0,
"loan__Charged_Off_Principal__c": 0,
"loan__Charged_Off_Interest__c": 0,
"loan__Charged_Off_Fees__c": 0,
"loan__Investor_Loan__c": "a32370000004nRoAAI",
"loan__Total_Service_Charge__c": 0,
"loan__Txn_Code__c": "ACTIVE",
"loan__Txn_Description__c": "Investment Activated",
"loan__Investor_Loan__r": {
"attributes": {
"type": "loan__Investor_Loan__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan__c/a32370000004nRoAAI" },
"Id": "a32370000004nRoAAI",
"loan__Status__c": "Closed - Written Off",
"loan__Share_rounded__c": 9.9,
"loan__Loan__c": "a3G37000000LdxoEAC",
"loan__Loan__r": {
"attributes": {
"type": "loan__Loan_Account__c",
"url": "/services/data/v32.0/sobjects/loan__Loan_Account__c/a3G37000000LdxoEAC" },
"Id": "a3G37000000LdxoEAC",
"Name": "LAI-00003665" }
}
},
"transactionType": "WITHDRAWAL - Invested in Loan",
"transactionId": "ILTID-0000251395",
"transactionDatetime": null,
"transactionDate": "2016-03-26",
"transactionAmount": 1000,
"sharePercent": 9.9,
"reversed": null,
"relatedLoan": "LAI-00003665",
"rejected": null,
"principal": null,
"lateFee": null,
"interest": null,
"fee": null,
"cleared": null,
"availableFunds": 10000,
"amountInFunding": 0
},
{
"txnObj": {
"attributes": {
"type": "loan__Investor_Loan_Account_Txns__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan_Account_Txns__c/a3137000000LpVuAAK" },
"Id": "a3137000000LpVuAAK",
"Name": "ILTID-0000251404",
"loan__Txn_Amount__c": 1337.96336633663366336633663366336647043,
"CreatedDate": "2016-11-15T10:30:08.000+0000",
"loan__Interest_Service_Charge__c": 0,
"loan__Late_Fee_Service_Charge__c": 0,
"loan__Interest_Paid__c": 0,
"loan__Late_Fees_Paid__c": 380.0099009900990099009900990099010281,
"loan__Principal_Paid__c": 957.95346534653465346534653465346544233,
"loan__Post_Date__c": "2016-03-26",
"loan__Transaction_Date__c": "2016-03-26",
"loan__Loan_Payment_Transaction_Time__c": "2016-03-26T10:29:19.000+0000",
"loan__Loan_Payment_Transaction__c": "a3N37000000LSUaEAO",
"loan__Vat__c": 0,
"loan__Tax__c": 0,
"loan__Charged_Off_Principal__c": 0,
"loan__Charged_Off_Interest__c": 0,
"loan__Charged_Off_Fees__c": 0,
"loan__Investor_Loan__c": "a32370000004nRoAAI",
"loan__Total_Service_Charge__c": 53.5185346534653465346534653465346588172,
"loan__Txn_Code__c": "PAYMENT APPROVAL",
"loan__Txn_Description__c": "Payment Approved",
"loan__Balance_After__c": 10284.4448316831683168316831683168318116,
"loan__Investor_Loan__r": {
"attributes": {
"type": "loan__Investor_Loan__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan__c/a32370000004nRoAAI" },
"Id": "a32370000004nRoAAI",
"loan__Status__c": "Closed - Written Off",
"loan__Share_rounded__c": 9.9,
"loan__Loan__c": "a3G37000000LdxoEAC",
"loan__Loan__r": {
"attributes": {
"type": "loan__Loan_Account__c",
"url": "/services/data/v32.0/sobjects/loan__Loan_Account__c/a3G37000000LdxoEAC" },
"Id": "a3G37000000LdxoEAC",
"Name": "LAI-00003665" }
}
},
"transactionType": "DEPOSIT - Repayment From Loan",
"transactionId": "ILTID-0000251404",
"transactionDatetime": null,
"transactionDate": "2016-03-26",
"transactionAmount": 1284.4448316831683168316831683168318116128,
"sharePercent": 9.9,
"reversed": null,
"relatedLoan": "LAI-00003665",
"rejected": null,
"principal": 957.95346534653465346534653465346544233,
"lateFee": 380.0099009900990099009900990099010281,
"interest": 0,
"fee": -53.5185346534653465346534653465346588172,
"cleared": null,
"availableFunds": 10284.4448316831683168316831683168318116,
"amountInFunding": 0
},
{
"txnObj": {
"attributes": {
"type": "loan__Investor_Loan_Account_Txns__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan_Account_Txns__c/a3137000000LpVwAAK" },
"Id": "a3137000000LpVwAAK",
"Name": "ILTID-0000251406",
"loan__Txn_Amount__c": 1000,
"CreatedDate": "2016-11-15T10:46:29.000+0000",
"loan__Interest_Service_Charge__c": 0,
"loan__Late_Fee_Service_Charge__c": 0,
"loan__Interest_Paid__c": 0,
"loan__Late_Fees_Paid__c": 0,
"loan__Principal_Paid__c": 0,
"loan__Post_Date__c": "2016-03-26",
"loan__Transaction_Date__c": "2016-03-26",
"loan__Vat__c": 0,
"loan__Tax__c": 0,
"loan__Charged_Off_Principal__c": 0,
"loan__Charged_Off_Interest__c": 0,
"loan__Charged_Off_Fees__c": 0,
"loan__Investor_Loan__c": "a32370000004nRoAAI",
"loan__Total_Service_Charge__c": 0,
"loan__Txn_Code__c": "DE-ACTIVE",
"loan__Txn_Description__c": "Investment Deactivated",
"loan__Balance_After__c": 10304.4448316831683168316831683168318116,
"loan__Investor_Loan__r": {
"attributes": {
"type": "loan__Investor_Loan__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan__c/a32370000004nRoAAI" },
"Id": "a32370000004nRoAAI",
"loan__Status__c": "Closed - Written Off",
"loan__Share_rounded__c": 9.9,
"loan__Loan__c": "a3G37000000LdxoEAC",
"loan__Loan__r": {
"attributes": {
"type": "loan__Loan_Account__c",
"url": "/services/data/v32.0/sobjects/loan__Loan_Account__c/a3G37000000LdxoEAC" },
"Id": "a3G37000000LdxoEAC",
"Name": "LAI-00003665" }
}
},
"transactionType": "DEPOSIT - Exited from Loan",
"transactionId": "ILTID-0000251406",
"transactionDatetime": null,
"transactionDate": "2016-03-26",
"transactionAmount": 1000,
"sharePercent": 9.9,
"reversed": null,
"relatedLoan": "LAI-00003665",
"rejected": null,
"principal": null,
"lateFee": null,
"interest": null,
"fee": null,
"cleared": null,
"availableFunds": 10304.4448316831683168316831683168318116,
"amountInFunding": 0
},
{
"txnObj": {
"attributes": {
"type": "loan__Investor_Loan_Account_Txns__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan_Account_Txns__c/a3137000000LpVyAAK" },
"Id": "a3137000000LpVyAAK",
"Name": "ILTID-0000251408",
"loan__Txn_Amount__c": 17.04653465346534653465346534653455767,
"CreatedDate": "2016-11-15T10:46:29.000+0000",
"loan__Interest_Service_Charge__c": 0,
"loan__Late_Fee_Service_Charge__c": 0,
"loan__Interest_Paid__c": 0,
"loan__Late_Fees_Paid__c": 0,
"loan__Principal_Paid__c": 0,
"loan__Post_Date__c": "2016-03-26",
"loan__Transaction_Date__c": "2016-03-26",
"loan__Vat__c": 0,
"loan__Tax__c": 0,
"loan__Charged_Off_Principal__c": 0,
"loan__Charged_Off_Interest__c": 0,
"loan__Charged_Off_Fees__c": 0,
"loan__Investor_Loan__c": "a32370000004nRtAAI",
"loan__Total_Service_Charge__c": 0,
"loan__Txn_Code__c": "ACTIVE",
"loan__Txn_Description__c": "Investment Activated",
"loan__Balance_After__c": 10304.4448316831683168316831683168318116,
"loan__Investor_Loan__r": {
"attributes": {
"type": "loan__Investor_Loan__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan__c/a32370000004nRtAAI" },
"Id": "a32370000004nRtAAI",
"loan__Status__c": "Closed - Written Off",
"loan__Share_rounded__c": 4.01,
"loan__Loan__c": "a3G37000000LdxoEAC",
"loan__Loan__r": {
"attributes": {
"type": "loan__Loan_Account__c",
"url": "/services/data/v32.0/sobjects/loan__Loan_Account__c/a3G37000000LdxoEAC" },
"Id": "a3G37000000LdxoEAC",
"Name": "LAI-00003665" }
}
},
"transactionType": "WITHDRAWAL - Invested in Loan",
"transactionId": "ILTID-0000251408",
"transactionDatetime": null,
"transactionDate": "2016-03-26",
"transactionAmount": 17.04653465346534653465346534653455767,
"sharePercent": 4.01,
"reversed": null,
"relatedLoan": "LAI-00003665",
"rejected": null,
"principal": null,
"lateFee": null,
"interest": null,
"fee": null,
"cleared": null,
"availableFunds": 10304.4448316831683168316831683168318116,
"amountInFunding": 0
},
{
"txnObj": {
"attributes": {
"type": "loan__Investor_Loan_Account_Txns__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan_Account_Txns__c/a3137000000LpW0AAK" },
"Id": "a3137000000LpW0AAK",
"Name": "ILTID-0000251409",
"loan__Txn_Amount__c": 42.04653465346534653465346534653455767,
"CreatedDate": "2016-11-15T10:54:42.000+0000",
"loan__Interest_Service_Charge__c": 0,
"loan__Late_Fee_Service_Charge__c": 0,
"loan__Interest_Paid__c": 0,
"loan__Late_Fees_Paid__c": 0,
"loan__Principal_Paid__c": 0,
"loan__Post_Date__c": "2016-03-26",
"loan__Transaction_Date__c": "2016-03-26",
"loan__Vat__c": 0,
"loan__Tax__c": 0,
"loan__Charged_Off_Principal__c": 42.04653465346534653465346534653455767,
"loan__Charged_Off_Interest__c": 0,
"loan__Charged_Off_Fees__c": 0,
"loan__Investor_Loan__c": "a32370000004nRoAAI",
"loan__Total_Service_Charge__c": 0,
"loan__Txn_Code__c": "CHARGE OFF",
"loan__Txn_Description__c": "write off transaction for an IO.ILID-0000000208",
"loan__Investor_Loan__r": {
"attributes": {
"type": "loan__Investor_Loan__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan__c/a32370000004nRoAAI" },
"Id": "a32370000004nRoAAI",
"loan__Status__c": "Closed - Written Off",
"loan__Share_rounded__c": 9.9,
"loan__Loan__c": "a3G37000000LdxoEAC",
"loan__Loan__r": {
"attributes": {
"type": "loan__Loan_Account__c",
"url": "/services/data/v32.0/sobjects/loan__Loan_Account__c/a3G37000000LdxoEAC" },
"Id": "a3G37000000LdxoEAC",
"Name": "LAI-00003665" }
}
},
"transactionType": "Written Off Investment",
"transactionId": "ILTID-0000251409",
"transactionDatetime": null,
"transactionDate": "2016-03-26",
"transactionAmount": 42.04653465346534653465346534653455767,
"sharePercent": 9.9,
"reversed": null,
"relatedLoan": "LAI-00003665",
"rejected": null,
"principal": 42.04653465346534653465346534653455767,
"lateFee": null,
"interest": 0,
"fee": null,
"cleared": null,
"availableFunds": 10304.4448316831683168316831683168318116,
"amountInFunding": 0
},
{
"txnObj": {
"attributes": {
"type": "loan__Investor_Loan_Account_Txns__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan_Account_Txns__c/a3137000000LpW1AAK" },
"Id": "a3137000000LpW1AAK",
"Name": "ILTID-0000251410",
"loan__Txn_Amount__c": 17.04653465346534653465346534653455767,
"CreatedDate": "2016-11-15T10:54:42.000+0000",
"loan__Interest_Service_Charge__c": 0,
"loan__Late_Fee_Service_Charge__c": 0,
"loan__Interest_Paid__c": 0,
"loan__Late_Fees_Paid__c": 0,
"loan__Principal_Paid__c": 0,
"loan__Post_Date__c": "2016-03-26",
"loan__Transaction_Date__c": "2016-03-26",
"loan__Vat__c": 0,
"loan__Tax__c": 0,
"loan__Charged_Off_Principal__c": 17.04653465346534653465346534653455767,
"loan__Charged_Off_Interest__c": 0,
"loan__Charged_Off_Fees__c": 0,
"loan__Investor_Loan__c": "a32370000004nRtAAI",
"loan__Total_Service_Charge__c": 0,
"loan__Txn_Code__c": "CHARGE OFF",
"loan__Txn_Description__c": "write off transaction for an IO.ILID-0000000209",
"loan__Investor_Loan__r": {
"attributes": {
"type": "loan__Investor_Loan__c",
"url": "/services/data/v32.0/sobjects/loan__Investor_Loan__c/a32370000004nRtAAI" },
"Id": "a32370000004nRtAAI",
"loan__Status__c": "Closed - Written Off",
"loan__Share_rounded__c": 4.01,
"loan__Loan__c": "a3G37000000LdxoEAC",
"loan__Loan__r": {
"attributes": {
"type": "loan__Loan_Account__c",
"url": "/services/data/v32.0/sobjects/loan__Loan_Account__c/a3G37000000LdxoEAC" },
"Id": "a3G37000000LdxoEAC",
"Name": "LAI-00003665" }
}
},
"transactionType": "Written Off Investment",
"transactionId": "ILTID-0000251410",
"transactionDatetime": null,
"transactionDate": "2016-03-26",
"transactionAmount": 17.04653465346534653465346534653455767,
"sharePercent": 4.01,
"reversed": null,
"relatedLoan": "LAI-00003665",
"rejected": null,
"principal": 17.04653465346534653465346534653455767,
"lateFee": null,
"interest": 0,
"fee": null,
"cleared": null,
"availableFunds": 10304.4448316831683168316831683168318116,
"amountInFunding": 0
}
],
"errorNumber": 0,
"errorMessage": null,
"errorCode": "NO_ERROR",
"content": []
}