diff --git a/api-docs/apiLive.htm b/api-docs/apiLive.htm index 3139b1a5b..a6320c815 100644 --- a/api-docs/apiLive.htm +++ b/api-docs/apiLive.htm @@ -10,7 +10,7 @@ QueryParameters = (function() { var result = {}; if (window.location.search) { - // split up the query string and store in an associative array + // split up the query string and store in an associaative array var params = window.location.search.slice(1).split("&"); for ( var i = 0; i < params.length; i++) { var tmp = params[i].split("="); @@ -938,6 +938,149 @@ +
+

Shares

+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + +
RESOURCES
+
+ + + + + + +
POST
create/complex + update
+ + + + + + +
GET
read
+ + + + + + +
PUT
update
+ + + + + + +
DELETE
delete
Share AccountsshareaccountsSubmit new share applicationList share application/accounts
accounts/share/{accountId}Retrieve a share application/accountModify a share application
accounts/share/{accountId}?command=approveApprove a share application
accounts/share/{accountId}?command=undoApprovalUndo share application approval
accounts/share/{accountId}?command=rejectReject a share application
accounts/share/{accountId}?command=activateActivate a share account
accounts/share/{accountId}?command=closeClose a share account
accounts/share/{accountId}?command=applyadditionalsharesApply additional shares on a share account
accounts/share/{accountId}?command=approveadditionalsharesApprove additional shares request on a share account
accounts/share/{accountId}?command=rejectadditionalsharesReject additional shares request on a share account
accounts/share/{accountId}?command=redeemsharesRedeem shares on a share account
+
+
+
+

Loan

@@ -1825,6 +1968,7 @@ + savingsproducts/{productId} @@ -1865,6 +2009,22 @@ Update a Recurring Deposit product Delete a Recurring Deposit product + + Share Product + shareproducts + Create a Share product + List Share products + + + + + + shareproducts/{productId} + + Retrieve a Share product + Update a Share product + + Currency currencies @@ -20088,6 +20248,499 @@ Content-Type: application/json
+   +
+
+

Create a Share Product

+ + + + + +
Mandatory Fields
name, shortName, description, currencyCode, digitsAfterDecimal,inMultiplesOf, locale, + totalShares, unitPrice, nominalShares,allowDividendCalculationForInactiveClients,accountingRule
+
+ + + + + +
Mandatory Fields for Cash based accounting (accountingRule = 2)
shareReferenceId, shareSuspenseId, shareEquityId, incomeFromFeeAccountId
+
+ + + +
Optional Fields
sharesIssued, minimumShares, maximumShares, minimumActivePeriodForDividends, minimumactiveperiodFrequencyType, + lockinPeriodFrequency, lockinPeriodFrequencyType, marketPricePeriods, chargesSelected
+
+
+ + POST https://Domain Name/api/v1/products/share + POST shareproducts +Content-Type: application/json +Request Body: +{ +"name": "Share Product", +"shortName": "SP", +"description": "Description", +"currencyCode": "USD", +"digitsAfterDecimal": 2, +"inMultiplesOf": "1", +"locale": "en", +"totalShares": "1000", +"sharesIssued": "1000", +"unitPrice": "1", +"minimumShares": "10", +"nominalShares": "20", +"maximumShares": "30", +"minimumActivePeriodForDividends": "1", +"minimumactiveperiodFrequencyType": 0, +"lockinPeriodFrequency": "1", +"lockinPeriodFrequencyType": 1, +"allowDividendCalculationForInactiveClients": "true", +"marketPricePeriods": [{ + "locale": "en", + "dateFormat": "dd MMMM yyyy", + "fromDate": "04 May 2016", + "shareValue": "2" +}], +"chargesSelected": [{ + "id": 20 +}], +"accountingRule": "1" +} + + + +{ + "resourceId": 1 +} + + POST shareproducts +Content-Type: application/json +Request Body: +{ +"name": "Share Product", +"shortName": "SP", +"description": "Description", +"currencyCode": "USD", +"digitsAfterDecimal": 2, +"inMultiplesOf": "1", +"locale": "en", +"totalShares": "100000", +"sharesIssued": "100000", +"unitPrice": "1", +"minimumShares": "1000", +"nominalShares": "2000", +"maximumShares": "5000", +"minimumActivePeriodForDividends": "1", +"minimumactiveperiodFrequencyType": 0, +"lockinPeriodFrequency": "1", +"lockinPeriodFrequencyType": 1, +"allowDividendCalculationForInactiveClients": "true", +"marketPricePeriods": [{ + "locale": "en", + "dateFormat": "dd MMMM yyyy", + "fromDate": "04 May 2016", + "shareValue": "2" +}], +"chargesSelected": [{ + "id": 20 +}], +"accountingRule": "2", +"shareReferenceId": 5, +"shareSuspenseId": 8, +"shareEquityId": 66, +"incomeFromFeeAccountId": 2 +} + + +{ + "resourceId": 1 +} + +
+
+ +  +
+
+

Retrieve a Share Product

+

Example Requests:

+
products/share/1
+

+
products/share/1?template=true
+
+
+ GET https://Domain Name/api/v1/products/share/1 + +{ + "id": 1, + "name": "Share Product", + "shortName": "SP", + "description": "SP", + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "inMultiplesOf": 100, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "totalShares": 100, + "totalSharesIssued": 50, + "unitPrice": 1.00, + "shareCapital": 50.00, + "minimumShares": 1, + "nominalShares": 10, + "maximumShares": 50, + "marketPrice": [ + { + "id": 4, + "fromDate": "Feb 1, 2016", + "shareValue": 1.00 + }, + { + "id": 5, + "fromDate": "May 3, 2016", + "shareValue": 5.00 + }], + "charges": [{ + "id": 20, + "name": "Share Account Activation Flat", + "active": true, + "penalty": false, + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "amount": 1.000000, + "chargeTimeType": { + "id": 13, + "code": "chargeTimeType.activation", + "value": "Share Account Activate" + }, + "chargeAppliesTo": { + "id": 4, + "code": "chargeAppliesTo.shares", + "value": "Shares" + }, + "chargeCalculationType": { + "id": 1, + "code": "chargeCalculationType.flat", + "value": "Flat" + }, + "chargePaymentMode": { + "id": 0, + "code": "chargepaymentmode.regular", + "value": "Regular" + } + }], + "allowDividendCalculationForInactiveClients": true, + "lockinPeriod": 1, + "lockPeriodTypeEnum": { + "id": 0, + "value": "Days" + }, + "minimumActivePeriod": 1, + "minimumActivePeriodForDividendsTypeEnum": { + "id": 0, + "value": "Days" + }, + "accountingRule": { + "id": 2, + "code": "accountingRuleType.cash", + "value": "CASH BASED" + }, + "accountingMappings": { + "shareReferenceId": { + "id": 1, + "name": "ACCOUNT_NAME_1FJBQ", + "glCode": "ASSET_ED1461237837829" + }, + "incomeFromFeeAccountId": { + "id": 14, + "name": "ACCOUNT_NAME_1FJBQ", + "glCode": "INCOME_OY1461237869836" + }, + "shareEquityId": { + "id": 66, + "name": "Equity Account", + "glCode": "EQUITY1" + }, + "shareSuspenseId": { + "id": 8, + "name": "ACCOUNT_NAME_1FJBQ", + "glCode": "LIABILITY_MA1461237860198" + } + }, + "currencyOptions": [{ + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }], + "chargeOptions": [{ + "id": 20, + "name": "Share Account Activation Flat", + "active": true, + "penalty": false, + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "amount": 1.000000, + "chargeTimeType": { + "id": 13, + "code": "chargeTimeType.activation", + "value": "Share Account Activate" + }, + "chargeAppliesTo": { + "id": 4, + "code": "chargeAppliesTo.shares", + "value": "Shares" + }, + "chargeCalculationType": { + "id": 1, + "code": "chargeCalculationType.flat", + "value": "Flat" + }, + "chargePaymentMode": { + "id": 0, + "code": "chargepaymentmode.regular", + "value": "Regular" + } + }, + { + "id": 21, + "name": "Share Purchase %", + "active": true, + "penalty": false, + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "amount": 0.500000, + "chargeTimeType": { + "id": 14, + "code": "chargeTimeType.sharespurchase", + "value": "Share Purchase" + }, + "chargeAppliesTo": { + "id": 4, + "code": "chargeAppliesTo.shares", + "value": "Shares" + }, + "chargeCalculationType": { + "id": 2, + "code": "chargeCalculationType.percent.of.amount", + "value": "% Amount" + }, + "chargePaymentMode": { + "id": 0, + "code": "chargepaymentmode.regular", + "value": "Regular" + } + } + ], + "minimumActivePeriodFrequencyTypeOptions": [{ + "id": 0, + "code": "savings.lockin.sharePeriodFrequencyType.days", + "value": "Days" + }], + "lockinPeriodFrequencyTypeOptions": [{ + "id": 0, + "code": "savings.lockin.sharePeriodFrequencyType.days", + "value": "Days" + }, + { + "id": 1, + "code": "savings.lockin.sharePeriodFrequencyType.weeks", + "value": "Weeks" + }, + { + "id": 2, + "code": "savings.lockin.sharePeriodFrequencyType.months", + "value": "Months" + }, + { + "id": 3, + "code": "savings.lockin.sharePeriodFrequencyType.years", + "value": "Years" + }], + "accountingMappingOptions": { + "liabilityAccountOptions": [{ + "id": 4, + "name": "ACCOUNT_NAME_1FJBQ", + "glCode": "LIABILITY_2T1461237838897", + "disabled": false, + "manualEntriesAllowed": true, + "type": { + "id": 2, + "code": "accountType.liability", + "value": "LIABILITY" + }, + "usage": { + "id": 1, + "code": "accountUsage.detail", + "value": "DETAIL" + }, + "description": "DEFAULT_DESCRIPTION", + "nameDecorated": "ACCOUNT_NAME_1FJBQ", + "tagId": { + "id": 0, + "isActive": false + } + }], + "assetAccountOptions": [{ + "id": 1, + "name": "ACCOUNT_NAME_1FJBQ", + "glCode": "ASSET_ED1461237837829", + "disabled": false, + "manualEntriesAllowed": true, + "type": { + "id": 1, + "code": "accountType.asset", + "value": "ASSET" + }, + "usage": { + "id": 1, + "code": "accountUsage.detail", + "value": "DETAIL" + }, + "description": "DEFAULT_DESCRIPTION", + "nameDecorated": "ACCOUNT_NAME_1FJBQ", + "tagId": { + "id": 0, + "isActive": false + } + }], + "incomeAccountOptions": [{ + "id": 2, + "name": "ACCOUNT_NAME_1FJBQ", + "glCode": "INCOME_9O1461237838422", + "disabled": false, + "manualEntriesAllowed": true, + "type": { + "id": 4, + "code": "accountType.income", + "value": "INCOME" + }, + "usage": { + "id": 1, + "code": "accountUsage.detail", + "value": "DETAIL" + }, + "description": "DEFAULT_DESCRIPTION", + "nameDecorated": "ACCOUNT_NAME_1FJBQ", + "tagId": { + "id": 0, + "isActive": false + } + }], + "equityAccountOptions": [{ + "id": 66, + "name": "Equity Account", + "glCode": "EQUITY1", + "disabled": false, + "manualEntriesAllowed": true, + "type": { + "id": 3, + "code": "accountType.equity", + "value": "EQUITY" + }, + "usage": { + "id": 1, + "code": "accountUsage.detail", + "value": "DETAIL" + }, + "nameDecorated": "Equity Account", + "tagId": { + "id": 0, + "isActive": false + } + }] + } +} + +
+
+ +  +
+
+

Update a Share Product

+
+
+ PUT https://Domain Name/api/v1/products/share/{productId} + POST shareproducts/1 +Content-Type: application/json +Request Body: +{ + "description": "Share Product Description.", + "locale": "en", + "unitPrice": "5.0" +} + + +{ + "resourceId": 1, + "changes": { + "description": "Share Product Description.", + "unitPrice": 5.0, + "locale": "en" + } +} + +
+
+ +  +
+
+

List Share Products

+ + + + + +
Mandatory Fields
limit, offset
+

Example Requests:

+
shareproducts
+
+
+ + GET https://Domain Name/api/v1/products/share?limit=10&offset=0 + + +{ + "totalFilteredRecords": 1, + "pageItems": [{ + "id": 1, + "name": "Share Product", + "shortName": "Share Product Description", + "totalShares": 100 + }] +} + +
+
+  
@@ -21468,7 +22121,1119 @@ Content-Type: application/json
+ +  +
+
+

Share Account:

+

Share accounts are instances of a praticular share product created for an individual. + An application process around the creation of accounts is also supported.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Starting StateActionResultant State
-SubmitSubmitted and pending approval
Submitted and pending approvalRejectClosed - Rejected
Submitted and pending approvalApproveApproved
ApprovedUndo ApprovalSubmitted and pending approval
ApprovedActivateActive
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Field Descriptions
clientId
The client you are creating the share account for. clientId must be provided.
productId
The id of the product used for this share account. The share account inherits the selected currency of the product and possibly other details if not overridden in the share account creation request.
accountNo
The account no. associated with this account. Is auto generated if not provided at creation time.
externalId
A place to put an external reference for this share account useful in migrations e.g. The ID another system uses. If provided, it must be unique.
submittedOnDate
submittedOnDate must be provided when initially creating share account application. locale and dateFormat parameters must be provided with this.
savingsAccountId
The saving account id in which dividend amount should be posted.
minimumActivePeriod
Optional: If provided, used along with minimumActivePeriodFrequencyType to indicate the length of time that the share account for considering dividends. e.g. 60 Days
minimumActivePeriodFrequencyType
Optional: If provided, used along with minimumActivePeriod to indicate the length of time that the share account for considering dividends. 0=Days + e.g. 60 Days
lockinPeriodFrequency
Optional: If provided, used along with lockinPeriodFrequencyType to indicate the length of time that the shares is 'locked in' and redeems are not allowed. e.g. 6 Months
lockinPeriodFrequencyType
Optional: If provided, used along with lockinPeriodFrequency to indicate the length of time that the shares is 'locked in' and redeems are not allowed. 0=Days, 1=Weeks, 2=Months, 3=Years + e.g. 6 Months
applicationDate
Application date on which the first shares purchase should be considerd.
requestedShares
+
+
+ +  +
+
+

Retrieve Share Account Template:

+

This is a convenience resource. It can be useful when building maintenance user interface screens for client applications. The template data returned consists of any or all of: +

+

+

Arguments

+
+
clientId
+
Integer mandatory
+
productId
+
Integer optional
+
If entered, productId, productName and selectedProduct fields are returned.
+
+

Example Requests:

+
accounts/share/template?clientId=1
+

+
accounts/share/template?clientId=1&productId=1
+
+
+ GET https://Domain Name/api/v1/accounts/share/template?clientId={clientId} + +{ + "clientId": 7, + "clientName": "Client Name", + "productOptions": [{ + "id": 1, + "name": "Share Product", + "shortName": "SP", + "totalShares": 100 + }] +} + +
+ +
+ GET https://Domain Name/api/v1/accounts/share/template?clientId={clientId}&productId={productId} + +{ + "clientId": 7, + "clientName": "Client Name", + "defaultShares": 100, + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "inMultiplesOf": 100, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "currentMarketPrice": 5.00, + "charges": [{ + "chargeId": 20, + "name": "Share Account Activation Flat", + "chargeTimeType": { + "id": 13, + "code": "chargeTimeType.activation", + "value": "Share Account Activate" + }, + "chargeCalculationType": { + "id": 1, + "code": "chargeCalculationType.flat", + "value": "Flat" + }, + "amount": 1.000000, + + }], + "lockinPeriodFrequencyTypeOptions": [{ + "id": 0, + "code": "savings.lockin.sharePeriodFrequencyType.days", + "value": "Days" + }, + { + "id": 1, + "code": "savings.lockin.sharePeriodFrequencyType.weeks", + "value": "Weeks" + }, + { + "id": 2, + "code": "savings.lockin.sharePeriodFrequencyType.months", + "value": "Months" + }, + { + "id": 3, + "code": "savings.lockin.sharePeriodFrequencyType.years", + "value": "Years" + }], + "minimumActivePeriodFrequencyTypeOptions": [{ + "id": 0, + "code": "savings.lockin.sharePeriodFrequencyType.days", + "value": "Days" + }], + "clientSavingsAccounts": [{ + "id": 13, + "accountNo": "000000013", + "depositType": { + "id": 100, + "code": "depositAccountType.savingsDeposit", + "value": "Savings" + } + }] +} + +
+
+ +  +
+
+

Submit new share application

+
+ + + +
Mandatory Fields
clientId, productId, submittedDate, savingsAccountId, requestedShares, applicationDate
+
+ + + +
Optional Fields
accountNo, externalId
+
+ + + + +
Inherited from Product (if not provided)
minimumActivePeriod, minimumActivePeriodFrequencyType, lockinPeriodFrequency, lockinPeriodFrequencyType
+
+
+

Minimal request: accountNo auto generated, remaining details inherited from savings product.

+ POST https://Domain Name/api/v1/accounts/share + POST savingsaccount +Content-Type: application/json +Request Body: +{ + "clientId": "7", + "productId": 1, + + "requestedShares": 100, + "externalId": "1", + "submittedDate": "01 May 2016", + "minimumActivePeriod": "1", + "minimumActivePeriodFrequencyType": 0, + "lockinPeriodFrequency": "1", + "lockinPeriodFrequencyType": 0, + "applicationDate": "01 May 2016", + "allowDividendCalculationForInactiveClients": true, + "locale": "en", + "dateFormat": "dd MMMM yyyy", + "charges": [{ + "chargeId": 20, + "amount": 1 + }, + { + "chargeId": 21, + "amount": 0.5 + }, + { + "chargeId": 23, + "amount": 2 + }], + + "savingsAccountId": 13 +} + + +{ + "resourceId": 1 +} + +
+
+ +  +
+
+

Approve share application

+

Approves share application so long as its in 'Submitted and pending approval' state.

+
+
+ POST https://Domain Name/api/v1/accounts/share/{shareAccountId}?command=approve + POST shareaccount/1?command=approve +Content-Type: application/json +Request Body: +{ +"note":"notes", +"approvedDate":"01 May 2016", +"locale":"en", +"dateFormat":"dd MMMM yyyy" +} + + +{ + + "resourceId": 1, + "changes": { + "status": { + "id": 200, + "code": "shareAccountStatusType.approved", + "value": "Approved", + "submittedAndPendingApproval": false, + "approved": true, + "rejected": false, + "active": false, + "closed": false + }, + "locale": "en", + "dateFormat": "dd MMMM yyyy", + "approvedDate": "01 May 2016" + } +} + +
+
+ +  +
+
+

Undo approval share application

+

Will move 'approved' share application back to 'Submitted and pending approval' state.

+
+
+ POST https://Domain Name/api/v1/accounts/share/{shareAccountId}?command=undoApproval + POST shareaccount/1?command=undoApproval +Content-Type: application/json +Request Body: +{ +} + + +{ + + "resourceId": 1, + "changes": { + "status": { + "id": 100, + "code": "shareAccountStatusType.submitted.and.pending.approval", + "value": "Submitted and pending approval", + "submittedAndPendingApproval": true, + "approved": false, + "rejected": false, + "active": false, + "closed": false + }, + "approvedOnDate": "" + } +} + +
+
+ +  +
+
+

Reject share application

+

Rejects share application so long as its in 'Submitted and pending approval' state.

+
+
+ POST https://Domain Name/api/v1/accounts/share/{shareAccountId}?command=reject + POST shareaccount/1?command=reject +Content-Type: application/json +Request Body: +{ + "locale": "en", + "dateFormat": "dd MMMM yyyy", + "rejectedDate": "03 March 2013" +} + + +{ + + "resourceId": 1, + "changes": { + "status": { + "id": 500, + "code": "shareAccountStatusType.rejected", + "value": "Rejected", + "submittedAndPendingApproval": false, + "approved": false, + "rejected": true, + "active": false, + "closed": true + }, + "locale": "en", + "dateFormat": "dd MMMM yyyy", + "rejectedDate": "03 March 2013", + "closedDate": "03 March 2013" + } +} + +
+
+ +  +
+
+

Activate a share account

+

Results in an approved share application being converted into an 'active' share account.

+
+
+ POST https://Domain Name/api/v1/accounts/share/{shareAccountId}?command=activate + POST shareaccount/1?command=activate +Content-Type: application/json +Request Body: +{ + "locale": "en", + "dateFormat": "dd MMMM yyyy", + "activatedDate": "01 March 2013" +} + + +{ + "resourceId": 1, + "changes": { + "status": { + "id": 300, + "code": "shareAccountStatusType.active", + "value": "Active", + "submittedAndPendingApproval": false, + "approved": false, + "rejected": false, + "active": true, + "closed": false + }, + "locale": "en", + "dateFormat": "dd MMMM yyyy", + "activatedDate": "01 March 2013" + } +} + +
+
+ +  +
+
+

Close a share account

+

Results in an Activated share application being converted into an 'closed' share account.

+

closedDate is closure date of share account

+ + + + + + + +
Mandatory Fields
dateFormat,locale,closedDate
+
+ +
+
+ POST https://Domain Name/api/v1/accounts/share/{shareAccountId}?command=close + POST shareaccount/5?command=close +Content-Type: application/json +Request Body: +{ + "dateFormat":"dd MMMM yyyy", + "locale":"en", + "closedDate":"26 August 2013", + "note":"close note" +} + + +{ + + "resourceId":5, + "changes":{ + "status":{ + "id":600, + "code":"shareAccountStatusType.closed", + "value":"Closed", + "submittedAndPendingApproval":false, + "approved":false, + "rejected":false, + "active":false, + "closed":true + }, + "locale":"en", + "dateFormat":"dd MMMM yyyy", + "closedOnDate":"26 August 2013", + "note":"close note" + } +} + + +
+
+ +  +
+
+

Apply additional shares on a share account

+

requestedDate is requsted date of share purchase

+

requestedShares is number of shares to be purchase

+ + + + + + + + +
Mandatory Fields
dateFormat,locale,requestedDate, requestedShares
+
+ +
+
+ POST https://Domain Name/api/v1/accounts/share/{shareAccountId}?command=applyadditionalshares + POST shareaccount/5?command=applyadditionalshares +Content-Type: application/json +Request Body: +{ + "requestedDate": "04 May 2016", + "requestedShares": "10", + "locale": "en", + "dateFormat": "dd MMMM yyyy" +} + + +{ + + "resourceId":5, +} + + +
+
+ +  +
+
+

Approve additional shares request on a share account

+

requestedShares is Share purchase transaction ids

+ + + + + + + + +
Mandatory Fields
requestedShares
+
+ +
+
+ POST https://Domain Name/api/v1/accounts/share/{shareAccountId}?command=approveadditionalshares + POST shareaccount/5?command=approveadditionalshares +Content-Type: application/json +Request Body: +{ + "requestedShares": [{ + "id": 34 + }] +} + + +{ + + "resourceId":5, +} + + +
+
+ +  +
+
+

Reject additional shares request on a share account

+

requestedShares is Share purchase transaction ids

+ + + + + + + + +
Mandatory Fields
requestedShares
+
+ +
+
+ POST https://Domain Name/api/v1/accounts/share/{shareAccountId}?command=rejectadditionalshares + POST shareaccount/5?command=rejectadditionalshares +Content-Type: application/json +Request Body: +{ + "requestedShares":[{"id":35}] +} + + +{ + + "resourceId":5, +} + + +
+
+ +  +
+
+

Redeem shares on a share account

+

Results redeem some/all shares from share account.

+

requestedDate is requsted date of shares redeem

+

requestedShares is number of shares to be redeemed

+ + + + + + + + +
Mandatory Fields
dateFormat,locale,requestedDate,requestedShares
+
+ +
+
+ POST https://Domain Name/api/v1/accounts/share/{shareAccountId}?command=redeemshares + POST shareaccount/5?command=redeemshares +Content-Type: application/json +Request Body: +{ + "requestedDate": "04 May 2016", + "requestedShares": "4", + "locale": "en", + "dateFormat": "dd MMMM yyyy" +} + + +{ + + "resourceId":5, +} + + +
+
+ +  +
+
+

List share applications/accounts

+

Example Requests:

+
shareaccount
+ +
+
+ GET https://Domain Name/api/v1/accounts/share + +{ + "totalFilteredRecords": 1, + "pageItems": [ + { + "id": 1, + "accountNo": "000000001", + "clientId": 1, + "clientName": "Client Name", + "productId": 1, + "productName": "Share Product Name", + + "status": { + "id": 100, + "code": "shareAccountStatusType.submitted.and.pending.approval", + "value": "Submitted and pending approval", + "submittedAndPendingApproval": true, + "approved": false, + "rejected": false, + "active": false, + "closed": false + }, + "timeline": { + "submittedOnDate": [ + 2013, + 3, + 1 + ] + }, + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "purchasedShares" : [ + {"id":1, + "purchasedDate":"01 May 2013", + "numberOfShares": 10, + "purchasedPrice": 5 + } + ], + + "summary": { + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + } + } + ] +} + +
+
+ +  +
+
+

Retrieve a share application/account:

+ +

Example Requests :

+
shareaccount/1
+
+
+ GET https://DomainName/api/v1/accounts/share/{accountId} + +{ + "id": 2, + "accountNo": "000000002", + "savingsAccountNumber": "000000013", + "clientId": 7, + "clientName": "Client_FirstName_2KX8C Client_LastName_NWNG", + "productId": 1, + "productName": "Share Product", + "status": { + "id": 300, + "code": "shareAccountStatusType.active", + "value": "Active", + "submittedAndPendingApproval": false, + "approved": false, + "rejected": false, + "active": true, + "closed": false + }, + "timeline": { + "submittedOnDate": [2016, + 4, + 1], + "submittedByUsername": "mifos", + "submittedByFirstname": "App", + "submittedByLastname": "Administrator", + "approvedDate": [2016, + 4, + 1], + "approvedByUsername": "mifos", + "approvedByFirstname": "App", + "approvedByLastname": "Administrator", + "activatedDate": [2016, + 4, + 1] + }, + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "inMultiplesOf": 100, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "summary": { + "id": 2, + "accountNo": "000000002", + "totalApprovedShares": 1, + "totalPendingForApprovalShares": 0, + "productId": 1, + "productName": "Conflux Share Product", + "status": { + "id": 300, + "code": "shareAccountStatusType.active", + "value": "Active", + "submittedAndPendingApproval": false, + "approved": false, + "rejected": false, + "active": true, + "closed": false + }, + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "inMultiplesOf": 100, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "timeline": { + "submittedOnDate": [2016, + 4, + 1], + "submittedByUsername": "mifos", + "submittedByFirstname": "App", + "submittedByLastname": "Administrator", + "approvedDate": [2016, + 4, + 1], + "approvedByUsername": "mifos", + "approvedByFirstname": "App", + "approvedByLastname": "Administrator", + "activatedDate": [2016, + 4, + 1] + } + }, + "purchasedShares": [{ + "id": 6, + "accountId": 2, + "purchasedDate": [2016, + 4, + 1], + "numberOfShares": 10, + "purchasedPrice": 0.50, + "status": { + "id": 300, + "code": "purchasedSharesStatusType.approved", + "value": "Approved" + }, + "type": { + "id": 500, + "code": "purchasedSharesType.purchased", + "value": "Purchase" + }, + "amount": 5.05, + "chargeAmount": 0.05, + "amountPaid": 5.05 + }, + { + "id": 7, + "accountId": 2, + "purchasedDate": [2016, + 4, + 21], + "status": { + "id": 300, + "code": "purchasedSharesStatusType.approved", + "value": "Approved" + }, + "type": { + "id": 700, + "code": "charge.payment", + "value": "Charge Payment" + }, + "amount": 1.00, + "chargeAmount": 0, + "amountPaid": 1.00 + }, + { + "id": 8, + "accountId": 2, + "purchasedDate": [2016, + 4, + 2], + "numberOfShares": 5, + "purchasedPrice": 0.50, + "status": { + "id": 300, + "code": "purchasedSharesStatusType.approved", + "value": "Approved" + }, + "type": { + "id": 600, + "code": "purchasedSharesType.redeemed", + "value": "Redeem" + }, + "amount": 2.45, + "chargeAmount": 0.05, + "amountPaid": 2.45 + }, + { + "id": 9, + "accountId": 2, + "purchasedDate": [2016, + 4, + 3], + "numberOfShares": 10, + "purchasedPrice": 0.50, + "status": { + "id": 300, + "code": "purchasedSharesStatusType.approved", + "value": "Approved" + }, + "type": { + "id": 500, + "code": "purchasedSharesType.purchased", + "value": "Purchase" + }, + "amount": 5.05, + "chargeAmount": 0.05, + "amountPaid": 5.05 + }, + { + "id": 10, + "accountId": 2, + "purchasedDate": [2016, + 4, + 4], + "numberOfShares": 5, + "purchasedPrice": 0.50, + "status": { + "id": 300, + "code": "purchasedSharesStatusType.approved", + "value": "Approved" + }, + "type": { + "id": 500, + "code": "purchasedSharesType.purchased", + "value": "Purchase" + }, + "amount": 2.52, + "chargeAmount": 0.02, + "amountPaid": 2.52 + }, + { + "id": 11, + "accountId": 2, + "purchasedDate": [2016, + 4, + 5], + "numberOfShares": 15, + "purchasedPrice": 0.50, + "status": { + "id": 300, + "code": "purchasedSharesStatusType.approved", + "value": "Approved" + }, + "type": { + "id": 600, + "code": "purchasedSharesType.redeemed", + "value": "Redeem" + }, + "amount": 7.35, + "chargeAmount": 0.15, + "amountPaid": 7.35 + }, + { + "id": 31, + "accountId": 2, + "purchasedDate": [2016, + 5, + 4], + "numberOfShares": 4, + "purchasedPrice": 5.00, + "status": { + "id": 300, + "code": "purchasedSharesStatusType.approved", + "value": "Approved" + }, + "type": { + "id": 600, + "code": "purchasedSharesType.redeemed", + "value": "Redeem" + }, + "amount": 19.60, + "chargeAmount": 0.40, + "amountPaid": 19.60 + }], + "savingsAccountId": 13, + "currentMarketPrice": 5.00, + "lockinPeriod": 1, + "lockPeriodTypeEnum": { + "id": 0, + "code": "savings.lockin.sharePeriodFrequencyType.days", + "value": "Days" + }, + "minimumActivePeriod": 1, + "minimumActivePeriodTypeEnum": { + "id": 0, + "code": "savings.lockin.sharePeriodFrequencyType.days", + "value": "Days" + }, + "allowDividendCalculationForInactiveClients": true, + "charges": [{ + "id": 9, + "chargeId": 20, + "accountId": 2, + "name": "Share Account Activation Flat", + "chargeTimeType": { + "id": 13, + "code": "chargeTimeType.activation", + "value": "Share Account Activate" + }, + "chargeCalculationType": { + "id": 1, + "code": "chargeCalculationType.flat", + "value": "Flat" + }, + "percentage": 0, + "amountPercentageAppliedTo": 0, + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "amount": 1.000000, + "amountPaid": 1.000000, + "amountWaived": 0, + "amountWrittenOff": 0, + "amountOutstanding": 0.000000, + "amountOrPercentage": 1.000000, + "isActive": true + }, + { + "id": 7, + "chargeId": 21, + "accountId": 2, + "name": "Share Purchase %", + "chargeTimeType": { + "id": 14, + "code": "chargeTimeType.sharespurchase", + "value": "Share Purchase" + }, + "chargeCalculationType": { + "id": 2, + "code": "chargeCalculationType.percent.of.amount", + "value": "% Amount" + }, + "percentage": 1.000000, + "amountPercentageAppliedTo": 12.500000, + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "amount": 0.120000, + "amountPaid": 0.120000, + "amountWaived": 0, + "amountWrittenOff": 0, + "amountOutstanding": 0.000000, + "amountOrPercentage": 1.000000, + "isActive": true + }, + { + "id": 8, + "chargeId": 23, + "accountId": 2, + "name": "Share Redeem %", + "chargeTimeType": { + "id": 15, + "code": "chargeTimeType.sharesredeem", + "value": "Share Redeem" + }, + "chargeCalculationType": { + "id": 2, + "code": "chargeCalculationType.percent.of.amount", + "value": "% Amount" + }, + "percentage": 2.000000, + "amountPercentageAppliedTo": 30.000000, + "currency": { + "code": "USD", + "name": "US Dollar", + "decimalPlaces": 2, + "displaySymbol": "$", + "nameCode": "currency.USD", + "displayLabel": "US Dollar ($)" + }, + "amount": 0.600000, + "amountPaid": 0.600000, + "amountWaived": 0, + "amountWrittenOff": 0, + "amountOutstanding": 0.000000, + "amountOrPercentage": 2.000000, + "isActive": true + }], + "dividends": [] +} + +
+
+ +  +
+
+

Modify a share application

+

Share application can only be modified when in 'Submitted and pending approval' state. Once the application is approved, the details cannot be changed using this method. Specific api endpoints will be created to allow change of interest detail such as rate, compounding period, posting period etc

+
+
+ PUT https://Domain Name/api/v1/accounts/share/{accountsId} + PUT shareaccount/1 +Content-Type: application/json +No Request Body: +{ + "locale": "en", + "dateFormat": "dd MMMM yyyy", + "applicationDate": "01 April 2016", + "requestedShares": "20", +} + + +{ + + "resourceId": 1, + "changes": { + "dateFormat": "dd MMMM yyyy", + "applicationDate": "01 April 2016", + "requestedShares": "20", + "locale": "en" + } +} + +
+
+ +  
@@ -22009,7 +23774,7 @@ Request Body:
-   + 

Approve savings application

@@ -44474,6 +46239,30 @@ No Request Body: + + Share Product + shareproducts + Create a Share product + List Share products + + + + + + + shareproducts/template + + Retrieve Share Product Template + + + + + + shareproducts/{productId} + + Retrieve a share product + Update a share product +
diff --git a/api-docs/apidocs.css b/api-docs/apidocs.css index 38b8b9f96..f8816a7de 100644 --- a/api-docs/apidocs.css +++ b/api-docs/apidocs.css @@ -192,7 +192,7 @@ body { .flybar-nav { display: block; float: left; - min-width: 80px; + min-width: 60px; position: relative; }