Skip to main content

Retrieve Deposit By ID

Overview

The RetrieveDepositByIdQuery allows you to retrieve detailed information about a specific deposit account using its unique identifier.

API Endpoint

POST /api/bpm/cmd

Headers

Content-Type: application/json
Authorization: Bearer {access_token}
X-Tenant-ID: {tenant_id}

Request Structure

{
"cmd": "RetrieveDepositByIdQuery",
"data": {
"id": 12345
}
}

Request Fields

FieldTypeRequiredDescription
idlongYesUnique ID of the deposit account

Sample Request

{
"cmd": "RetrieveDepositByIdQuery",
"data": {
"id": 12345
}
}

Response Structure

Success Response

{
"isSuccessful": true,
"message": "Deposit with ID 12345 found.",
"statusCode": "00",
"data": {
"id": 12345,
"accountNumber": "1234567890",
"accountName": "John Doe Savings Account",
"clientId": 67890,
"clientName": "John Doe",
"productId": 101,
"productName": "Regular Savings",
"currency": "NGN",
"balance": 250000.00,
"availableBalance": 245000.00,
"depositState": 1,
"branchId": 5,
"branchName": "Main Branch",
"interestRate": 5.5,
"minimumBalance": 10000.00,
"dateCreated": "2024-01-15T10:30:00Z",
"createdBy": "user@bank.com",
"lastModifiedDate": "2024-02-20T09:15:00Z"
}
}

Error Response

{
"isSuccessful": false,
"message": "Deposit with ID 12345 not found.",
"statusCode": "04",
"data": null
}

Notes

  • This command internally uses RetrieveDepositListQuery with the specified ID filter
  • The id parameter is mandatory and must be a valid long integer
  • If the deposit account is not found, the response will have isSuccessful: false with status code "04"
  • The command removes pagination and filter parameters before processing
  • Returns the first matching item from the filtered list