Extension Points
  • 09 Oct 2023
  • 4 Minutes To Read
  • Dark
    Light
  • PDF

Extension Points

  • Dark
    Light
  • PDF

Article Summary

Extension points are product areas that can be used by a Mambu Function to execute custom business logic. Each extension point has templates, which are ready-to-use implementations for that extension point. They allow you to start writing code immediately for common processes.

Warning!

For optimal performance and system responsiveness, we strongly recommend limiting yourself to a maximum of 50 to 100 custom field values per entity. The total size of the input payload to your custom function should not exceed 6mb. This is a hard limit, and any payload exceeding this size will not be processed.

For more information on other restrictions, see Restrictions and Security.

Fee Amount

The Fee Amount extension point works on the deposit fee amount and has the following templates.

DEPOSIT_FEE_AMOUNT

Input

NameTypeDescription
clientobjectClient (account holder) information.

Adheres to the Client schema from Mambu API v2, but with all hierarchical structures flattened to a single level.

Some fields have been intentionally omitted as they are not relevant for Mambu Functions.
client.statestringThe state of a client shows his workflow status, if he is waiting approval or is rejected or blacklisted
client.approvedDatestring(date-time)The date when client was approved
client.activationDatestring(date-time)The date when client was set as active for the first time
client.birthDatestring(date-time)The date when this client was born
client.genderstringGender of the person, male or female
clientCustomFieldsobjectValues from standard custom fields for the client, presented without being grouped into custom field sets.
groupobjectGroup (account holder) information.

Adheres to the Group schema from Mambu API v2, but with all hierarchical structures flattened to a single level.

Some fields have been intentionally omitted as they are not relevant for Mambu Functions.
group.creationDatestring(date-time)The date this group was created
group.lastModifiedDatestring(date-time)The last date the group was updated
group.groupNamestringThe name of the group
groupCustomFieldsobjectValues from standard custom fields for the group, presented without being grouped into custom field sets.
accountobjectAccount information.

Adheres to the DepositAccount schema from Mambu API v2, but with all hierarchical structures flattened to a single level.

Some fields have been intentionally omitted as they are not relevant for Mambu Functions.
account.creationDatestring(date-time)The date this deposit account was created
account.approvedDatestring(date-time)The date this deposit account was approved (as Organization Time)
account.activationDatestring(date-time)The date this deposit account was activated (as Organization Time)
account.lastModifiedDatestring(date-time)The last date the deposit account was updated
account.lastInterestCalculationDatestring(date-time)When/if the account had the interest last calculated (as Organization Time)
account.lastInterestStoredDatestring(date-time)When/if the account had last interest applied (stored to balance) (as Organization Time)
account.lastInterestReviewDatestring(date-time)When the regular interest was last time reviewed (as Organization Time)
account.lastOverdraftInterestReviewDatestring(date-time)When the overdraft interest was last time reviewed (as Organization Time)
account.lastAccountAppraisalDatestring(date-time)When/if the account had last been evaluated for interest calculations/maturity (as Organization Time)
account.accountTypestringIndicates the type of the deposit account and the product that it belongs to
account.accountStatestringThe state of the deposit account
account.recommendedDepositAmountstring(number)Recommended amount for a deposit
account.maxWithdrawalAmountstring(number)The maximum amount allowed for a withdrawal
account.targetAmountstring(number)The target amount (the monthly/weekly/daily deposits should/may lead towards a savings goal)
account.maturityDatestring(date-time)For fixed or compulsory savings plans, this is when the account matures (as Organization Time)
account.lockedDatestring(date-time)The date this deposit account was locked (as Organization Time)
account.totalBalancestring(number)The current balance of the account
account.accruedIntereststring(number)The amount of positive interest that has been accrued in the account
account.overdraftInterestAccruedstring(number)The amount of overdraft interest that has been accrued in the account
account.technicalOverdraftInterestAccruedstring(number)The amount of technical overdraft interest that has been accrued in the account
account.negativeInterestAccruedstring(number)The amount of negative interest that has been accrued in the account
account.overdraftAmountstring(number)How much money has been taken out in overdraft
account.technicalOverdraftAmountstring(number)How much money has been taken out as unplanned overdraft
account.overdraftExpiryDatestring(date-time)The expiration date of an overdraft (as Organization Time)
account.interestDuestring(number)The interest due. Indicates how much interest it's due for the account at this moment
account.technicalOverdraftInterestDuestring(number)How much interest is due to be paid on this account as a result of the technical overdraft
account.feesDuestring(number)How much fees is due to be paid on this account
account.overdraftLimitstring(number)How much may be taken out as overdraft, not defined means 0
account.allowOverdraftbooleanWhether this account supports overdraft or not
account.lockedBalancestring(number)No operation can modify the balance of the account and get it lower than this locked balance
account.holdBalancestring(number)The sum of all the authorization hold amounts that have DBIT as creditDebitIndicator from this account
account.blockedBalancestring(number)The sum of all the blocked amounts on this account
account.forwardAvailableBalancestring(number)The sum of all the authorization hold amounts that have CRDT as creditDebitIndicator from this account
account.maxDepositBalancestring(number)The maximum deposit balance of the account
account.interestPaymentPointstringThe interest payment point, specifies when the interest should be paid to the account
account.currencyCodestringThe currency code
account.lastSetToArrearsDatestring(date-time)Date when the deposit account was set to In Arrears state, or not defined if the account is not In Arrears state (as Organization Time)
accountCustomFieldsobjectValues from standard custom fields for the account, presented without being grouped into custom field sets

Example input payload

{
    "client": {
        "state": "ACTIVE",
        "birthDate": "1974-05-15T12:02:50+03:00",
        "gender": "MALE"
    },
    "clientCustomFields": {
        "customFieldDefinitionId1": "value",
        "customFieldDefinitionId2": "value",
        "customFieldDefinitionId3": "value"
    },
    "account": {
        "creationDate": "2023-06-19T12:07:30+03:00",
        "approvedDate": "2023-06-19T12:07:37+03:00",
        "activationDate": "2023-05-05T00:00:00+03:00",
        "lastModifiedDate": "2023-07-11T11:51:30+03:00",
        "lastInterestCalculationDate": "2023-07-05T00:00:00+03:00",
        "lastInterestStoredDate": "2023-07-01T00:00:00+03:00",
        "lastAccountAppraisalDate": "2023-07-05T10:47:12+03:00",
        "accountType": "REGULAR_SAVINGS",
        "accountState": "ACTIVE",
        "recommendedDepositAmount": "0",
        "maxWithdrawalAmount": "0",
        "totalBalance": "0",
        "accruedInterest": "0",
        "overdraftInterestAccrued": "0",
        "technicalOverdraftInterestAccrued": "0",
        "negativeInterestAccrued": "0",
        "overdraftAmount": "0",
        "technicalOverdraftAmount": "0",
        "interestDue": "0",
        "technicalOverdraftInterestDue": "0",
        "feesDue": "0",
        "overdraftLimit": "0",
        "allowOverdraft": false,
        "lockedBalance": "0",
        "holdBalance": "0",
        "blockedBalance": "0",
        "forwardAvailableBalance": "0",
        "interestPaymentPoint": "FIRST_DAY_OF_MONTH",
        "currencyCode": "USD"
    },
    "accountCustomFields": {
        "customFieldDefinitionId1": "value",
        "customFieldDefinitionId2": "value",
        "customFieldDefinitionId3": "value"
    }
}

Output

The only output for this extension point is the calculated fee amount created by the logic of your Mambu Function. The fee amount must be a string (number).

Example output

"9.99"

Was this article helpful?