diff --git a/api-docs/apiLive.htm b/api-docs/apiLive.htm index 1a5003e5a..9c589bf25 100644 --- a/api-docs/apiLive.htm +++ b/api-docs/apiLive.htm @@ -890,6 +890,22 @@
If you have the appropriate permissions, you can decide which types of products a given client or group can mix. In this way, you can restrict clients from having active loans accounts of different products at the same time.
+ +Field Descriptions |
+
| restrictedProducts | +
| List of productIds to create a product mix | +
Example Requests:
+
+GET https://DomainName/api/v1/loanproducts?associations=productMixes
+
+
+[
+ {
+ "productId": 1,
+ "productName": "Personal Loan",
+ "restrictedProducts": [
+ {
+ "id": 2,
+ "name": "Joint Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 5,
+ "name": "Primary Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 3,
+ "name": "Daily Loan",
+ "includeInBorrowerCycle": false
+ }
+ ],
+ "allowedProducts": [
+ {
+ "id": 1,
+ "name": "Personal Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 6,
+ "name": "Personal Loan -2",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 4,
+ "name": "Weekly Loan",
+ "includeInBorrowerCycle": false
+ }
+ ]
+ },
+ {
+ "productId": 2,
+ "productName": "Joint Loan",
+ "restrictedProducts": [
+ {
+ "id": 1,
+ "name": "Personal Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 6,
+ "name": "Personal Loan -2",
+ "includeInBorrowerCycle": false
+ }
+ ],
+ "allowedProducts": [
+ {
+ "id": 3,
+ "name": "Daily Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 2,
+ "name": "Joint Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 5,
+ "name": "Primary Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 4,
+ "name": "Weekly Loan",
+ "includeInBorrowerCycle": false
+ }
+ ]
+ }
+]
+
+ 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: +
Example Request:
+This request gets all the products details for which productmix is not defined.
+This request gets the productmix details for the specific loanproduct.
+
+GET https://DomainName/api/v1/loanproducts/template?isProductMixTemplate=true
+
+
+{
+ "productOptions": [
+ {
+ "id": 5,
+ "name": "Primary Loan"
+ },
+ {
+ "id": 4,
+ "name": "Weekly Loan"
+ }
+ ]
+}
+
+
+GET https://DomainName/api/v1/loanproducts/5/productmix
+
+
+{
+ "restrictedProducts": [
+ {
+ "id": 1,
+ "name": "Personal Loan",
+ "includeInBorrowerCycle": false
+ }
+ ],
+ "allowedProducts": [
+ {
+ "id": 3,
+ "name": "Daily Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 2,
+ "name": "Joint Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 6,
+ "name": "Personal Loan -2",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 5,
+ "name": "Primary Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 4,
+ "name": "Weekly Loan",
+ "includeInBorrowerCycle": false
+ }
+ ]
+}
+
+ Example Requests:
+
+GET https://DomainName/api/v1/loanproducts/5/productmix
+
+
+{
+ "restrictedProducts": [
+ {
+ "id": 1,
+ "name": "Personal Loan",
+ "includeInBorrowerCycle": false
+ }
+ ],
+ "allowedProducts": [
+ {
+ "id": 3,
+ "name": "Daily Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 2,
+ "name": "Joint Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 6,
+ "name": "Personal Loan -2",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 5,
+ "name": "Primary Loan",
+ "includeInBorrowerCycle": false
+ },
+ {
+ "id": 4,
+ "name": "Weekly Loan",
+ "includeInBorrowerCycle": false
+ }
+ ]
+}
+
+ Mandatory Fields |
+
| restrictedProducts | +
+POST https://DomainName/api/v1/loanproducts/5/productmix
+
+
+POST loanproducts/{productId}/productmix
+Content-Type: application/json
+Request Body:
+{"restrictedProducts":["1"]}
+
+
+{
+ "changes":{
+ "restrictedProductsForMix":[1],
+ "removedProductsForMix":[]
+ },
+ "productId":5
+}
+
+
+PUT https://DomainName/api/v1/loanproducts/{productId}/productmix
+
+
+PUT loanproducts/5/productmix
+Content-Type: application/json
+Request Body:
+{
+ "restrictedProducts":["3"]
+}
+
+
+{
+ "changes": {
+ "restrictedProductsForMix": [3],
+ "removedProductsForMix": [1]
+ },
+ "productId": 5
+}
+
+
+DELETE https://DomainName/api/v1/loanproducts/{productId}/productmix
+
+
+DELETE loanproducts/5/productmix
+
+
+{
+ "changes": {
+ "removedProductsForMix": [3]
+ },
+ "productId": 5
+}
+
+