Tutorial: Block, Unblock, Hold, Release Amount for Accounts

📘

API References for Endpoints in this tutorial:

Tutorial: Blocking an Account

In this scenario, we will explore how to block a deposit account using the MBanq Cloud API. Blocking an account involves locking or putting a hold on the account, preventing various types of credit and debit transactions. It is a useful feature for client management, risk monitoring, fraud prevention, and regulatory compliance.

There are situations where it becomes necessary to flag or put a hold on an account. This feature provides the ability to lock or hold an account for informational/notification purposes, blocking transactions, or restricting account activities. It is essential for general client management, risk monitoring, fraud prevention, and compliance with accounting, KYC/AML, and regulatory requirements.

Blocking an account serves various purposes, such as blacklisting a client, flagging dormant or inactive accounts, identifying suspicious activities like illegal entries or fraud, guaranteeing loans, enforcing compulsory savings, holding an account for passbook loss, handling the death of an account holder, managing inactive/dormant accounts and escheatment rules, responding to emergencies or natural disasters, facilitating the transfer or acquisition of portfolios, and locking accounts in case of arrears or financial distress.

The ability to flag or block an account can have different intended results. It can be used for informational and notification purposes, or it can restrict transactions and place funds on hold.

Now, let's proceed with the step-by-step tutorial on how to block a deposit account using the MBanq Cloud API.

Step 1: Make the API Request

To block a deposit account, send a POST request to the following endpoint:

POST https://api.cloud.mbanq.com/v1/savingsaccounts/{savingsId}?command=block

Replace {savingsId} with the ID of the savings account you want to block. Here is an example request using cURL:

curl -X POST https://api.cloud.mbanq.com/v1/savingsaccounts/1?command=block \
-H 'Content-Type: application/json' \
-d '{
  "reason": "block reason"
}'
ParameterValue TypeExample ValueExplanation
savingsIdNumber1The ID of the savings account to be blocked
reasonString"block reason"The reason for blocking the account

Step 2: Receive the API Response

If the request was successful, you will receive a JSON response with the updated account information. Here is an example response:

{
  "officeId": 1,
  "clientId": 1,
  "savingsId": 1,
  "resourceId": 1,
  "changes": {
    "subStatus": {
      "id": 400,
      "code": "SavingsAccountSubStatusEnum.block",
      "value": "Block",
      "none": false,
      "inactive": false,
      "dormant": false,
      "escheat": false,
      "block": true,
      "blockCredit": false,
      "blockDebit": false
    }
  }
}
ParameterValue TypeExample ValueExplanation
officeIdNumber1The ID of the office where the account belongs
clientIdNumber1The ID of the client associated with the account
savingsIdNumber1The ID of the blocked savings account
resourceIdNumber1The resource ID of the blocked savings account
changesObjectSee below exampleInformation about the changes made to the account
subStatusObjectSee below exampleSubstatus details of the savings account after being blocked
idNumber400The ID of the substatus indicating the account is blocked
codeString"SavingsAccountSubStatusEnum.block"The code representing the substatus of a blocked account
valueString"Block"The value representing the substatus of a blocked account
noneBooleanfalseIndicates if the substatus is "none"
inactiveBooleanfalseIndicates if the substatus is "inactive"
dormantBooleanfalseIndicates if the substatus is "dormant"
escheatBooleanfalseIndicates if the substatus is "escheat"
blockBooleantrueIndicates if the substatus is "block"
blockCreditBooleanfalseIndicates if the account is blocked for credit transactions (true or false)
blockDebitBooleanfalseIndicates if the account is blocked for debit transactions (true or false