- 30 Apr 2024
- 7 Minutes To Read
- Print
- DarkLight
- PDF
Deposit Fee Amount
- Updated On 30 Apr 2024
- 7 Minutes To Read
- Print
- DarkLight
- PDF
This extension point in deposits allows financial institutions to adjust account balances based on business rules using account data entities. For example, fees can be applied for low balances or bonuses for high balances. The function processes input data on savings accounts and client information to calculate a fee amount. Custom fields are supported, with a recommended limit of 50-100 per entity and a payload size limit of 6MB. The output is the calculated fee amount as a string, based on the logic of the Mambu Function. Various schemas like AccountInformation and AccountState define account and client details, with enumerated values for account types, client states, and interest payment points.
Description
This extension point in deposits allows FI to build use cases in which deposit accounts balances can be flexibly adjusted subject to business logics using data entities of the accounts. Example: applying a fee when account balance falls under a certain threshold or giving the account holder a bonus/incentive amount if the account balance is greater than a certain thresholds.
Your function will receive an input payload containing savings account data, along with associated client or group information and related custom field values. The result produced by your function will be interpreted as a fee amount. Both standard custom fields and grouped fields are supported.
While our system permits a large number of custom field values, for optimal performance and system responsiveness, we strongly recommend limiting yourself to a maximum of 50-100 custom field values per entity. Also, 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.
Technical contract specification
Extension point ID: DEPOSIT_FEE_AMOUNT
Input properties
DepositFeeAmountInput
Input payload defining all provided data fields
Name | Type | Availability | Description |
---|---|---|---|
account | AccountInformation | Always present | Account 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. |
accountCustomFields | object | Sometimes present | Values from standard custom fields for the account, presented without being grouped into custom field sets. Example: "accountCustomFields": { |
accountGroupedCustomFields | object | Sometimes present | Values from grouped custom fields for the account. Example: "accountGroupedCustomFields": { |
client | ClientInformation | Sometimes present | Client (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. |
clientCustomFields | object | Sometimes present | Values from standard custom fields for the client, presented without being grouped into custom field sets. Example: "clientCustomFields": { |
clientGroupedCustomFields | object | Sometimes present | Values from grouped custom fields for the client. Example: "clientGroupedCustomFields": { |
group | GroupInformation | Sometimes present | Group (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. |
groupCustomFields | object | Sometimes present | Values from standard custom fields for the group, presented without being grouped into custom field sets. Example: "groupCustomFields": { |
groupGroupedCustomFields | object | Sometimes present | Values from grouped custom fields for the group. Example: "groupGroupedCustomFields": { |
Output properties
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).
Constraint: amount can not be zero
string(number)
Schemas
AccountInformation
Account 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.
Name | Type | Availability | Description |
---|---|---|---|
accountState | AccountState | Sometimes present | The state of the deposit account |
accountType | AccountType | Sometimes present | Indicates the type of the deposit account and the product that it belongs to |
accruedInterest | string(number) | Sometimes present | The amount of positive interest that has been accrued in the account |
activationDate | string(date-time) | Sometimes present | The date this deposit account was activated (as Organization Time) |
allowOverdraft | boolean | Sometimes present | Whether this account supports overdraft or not |
approvedDate | string(date-time) | Sometimes present | The date this deposit account was approved (as Organization Time) |
blockedBalance | string(number) | Sometimes present | The sum of all the blocked amounts on this account |
creationDate | string(date-time) | Sometimes present | The date this deposit account was created |
currencyCode | string | Sometimes present | The currency code |
feesDue | string(number) | Sometimes present | How much fees is due to be paid on this account |
forwardAvailableBalance | string(number) | Sometimes present | The sum of all the authorization hold amounts that have CRDT as creditDebitIndicator from this account |
holdBalance | string(number) | Sometimes present | The sum of all the authorization hold amounts that have DBIT as creditDebitIndicator from this account |
interestDue | string(number) | Sometimes present | The interest due. Indicates how much interest it's due for the account at this moment |
interestPaymentPoint | InterestPaymentPoint | Sometimes present | The interest payment point, specifies when the interest should be paid to the account |
lastAccountAppraisalDate | string(date-time) | Sometimes present | When/if the account had last been evaluated for interest calculations/maturity (as Organization Time) |
lastInterestCalculationDate | string(date-time) | Sometimes present | When/if the account had the interest last calculated (as Organization Time) |
lastInterestReviewDate | string(date-time) | Sometimes present | When the regular interest was last time reviewed (as Organization Time) |
lastInterestStoredDate | string(date-time) | Sometimes present | When/if the account had last interest applied (stored to balance) (as Organization Time) |
lastModifiedDate | string(date-time) | Sometimes present | The last date the deposit account was updated |
lastOverdraftInterestReviewDate | string(date-time) | Sometimes present | When the overdraft interest was last time reviewed (as Organization Time) |
lastSetToArrearsDate | string(date-time) | Sometimes present | 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) |
lockedBalance | string(number) | Sometimes present | No operation can modify the balance of the account and get it lower than this locked balance |
lockedDate | string(date-time) | Sometimes present | The date this deposit account was locked (as Organization Time) |
maturityDate | string(date-time) | Sometimes present | For fixed or compulsory savings plans, this is when the account matures (as Organization Time) |
maxDepositBalance | string(number) | Sometimes present | The maximum deposit balance of the account |
maxWithdrawalAmount | string(number) | Sometimes present | The maximum amount allowed for a withdrawal |
negativeInterestAccrued | string(number) | Sometimes present | The amount of negative interest that has been accrued in the account |
overdraftAmount | string(number) | Sometimes present | How much money has been taken out in overdraft |
overdraftExpiryDate | string(date-time) | Sometimes present | The expiration date of an overdraft (as Organization Time) |
overdraftInterestAccrued | string(number) | Sometimes present | The amount of overdraft interest that has been accrued in the account |
overdraftLimit | string(number) | Sometimes present | How much may be taken out as overdraft, not defined means 0 |
recommendedDepositAmount | string(number) | Sometimes present | Recommended amount for a deposit |
targetAmount | string(number) | Sometimes present | The target amount (the monthly/weekly/daily deposits should/may lead towards a savings goal) |
technicalOverdraftAmount | string(number) | Sometimes present | How much money has been taken out as unplanned overdraft |
technicalOverdraftInterestAccrued | string(number) | Sometimes present | The amount of technical overdraft interest that has been accrued in the account |
technicalOverdraftInterestDue | string(number) | Sometimes present | How much interest is due to be paid on this account as a result of the technical overdraft |
totalBalance | string(number) | Always present | The current balance of the account |
AccountState
The state of the deposit account
Enumerated values: PARTIAL_APPLICATION
| PENDING_APPROVAL
| APPROVED
| PARTIALLY_DISBURSED
| REPAID
| REJECTED
| WRITTEN_OFF
| ACTIVE
| ACTIVE_IN_ARREARS
| MATURED
| LOCKED
| LOCKED_CAPPING
| DORMANT
| CLOSED
| CLOSED_RESCHEDULED
| REFINANCED
| RESCHEDULED
| CLOSED_WRITTEN_OFF
| CLOSED_WITHDRAWN
| WITHDRAWN
| CLOSED_REJECTED
| TERMINATED
AccountType
Indicates the type of the deposit account and the product that it belongs to
Enumerated values: CURRENT_ACCOUNT
| REGULAR_SAVINGS
| FIXED_DEPOSIT
| SAVINGS_PLAN
| INVESTOR_ACCOUNT
ClientInformation
Client (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.
Name | Type | Availability | Description |
---|---|---|---|
activationDate | string(date-time) | Sometimes present | The date when client was set as active for the first time |
approvedDate | string(date-time) | Sometimes present | The date when client was approved |
birthDate | string(date-time) | Sometimes present | The date when this client was born |
gender | Gender | Sometimes present | Gender of the person, male or female |
state | State | Sometimes present | The state of a client shows his workflow status, if he is waiting approval or is rejected or blacklisted |
Gender
Gender of the person, male or female
Enumerated values: MALE
| FEMALE
GroupInformation
Group (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.
Name | Type | Availability | Description |
---|---|---|---|
creationDate | string(date-time) | Sometimes present | The date this group was created |
groupName | string | Always present | The name of the group |
lastModifiedDate | string(date-time) | Sometimes present | The last date the group was updated |
InterestPaymentPoint
The interest payment point, specifies when the interest should be paid to the account
Enumerated values: FIRST_DAY_OF_MONTH
| DAILY
| EVERY_WEEK
| EVERY_OTHER_WEEK
| EVERY_MONTH
| EVERY_3_MONTHS
| BI_ANNUALLY
| ANNUALLY
| ON_FIXED_DATES
| ON_ACCOUNT_MATURITY
State
The state of a client shows his workflow status, if he is waiting approval or is rejected or blacklisted
Enumerated values: PENDING_APPROVAL
| INACTIVE
| ACTIVE
| EXITED
| BLACKLISTED
| REJECTED