Skip to main content

Retrieve Book Register By ID

Overview

The RetrieveBookRegisterByIdQuery retrieves detailed information for a specific book register by 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": "RetrieveBookRegisterByIdQuery",
"data": {
"id": 789
}
}

Request Fields

FieldTypeRequiredDescription
idlongYesThe unique identifier of the book register

Sample Request

{
"cmd": "RetrieveBookRegisterByIdQuery",
"data": {
"id": 789
}
}

Response Structure

Success Response

{
"isSuccessful": true,
"message": "Book register retrieved successfully.",
"statusCode": "00",
"data": {
"id": 789,
"bookType": 1,
"bookTypeDescription": "Cheque",
"bookReference": "CHQ-2024-001",
"depositAccountId": 12345,
"accountNumber": "1234567890",
"clientId": 67890,
"clientName": "John Doe",
"issuingBranchId": 5,
"branchName": "Main Branch",
"branchKey": "MB001",
"currencyCode": "NGN",
"currencyName": "Nigerian Naira",
"startSerialNumber": "0001001",
"endSerialNumber": "0001050",
"numberOfLeaves": 50,
"issuedDate": "2024-12-01T00:00:00Z",
"status": 1,
"statusDescription": "ACTIVE",
"isActive": true,
"remarks": "Initial cheque book issuance",
"createdAt": "2024-12-01T10:30:00Z",
"createdBy": "admin@bank.com",
"updatedAt": "2024-12-01T10:30:00Z",
"updatedBy": "admin@bank.com"
}
}

Error Response (Not Found)

{
"isSuccessful": false,
"message": "Book register not found.",
"statusCode": "99",
"data": null
}

Response Fields

FieldDescription
idUnique identifier of the book register
bookTypeNumeric book type (1=Cheque, 2=DepositSlip, 3=WithdrawalSlip)
bookTypeDescriptionHuman-readable book type
bookReferenceOptional reference number for the book
depositAccountIdID of the deposit account
accountNumberAccount number
clientIdID of the account holder
clientNameFull name of the account holder
issuingBranchIdID of the branch that issued the book
branchNameName of the issuing branch
branchKeyBranch code/key
currencyCodeISO currency code (e.g., NGN, USD)
currencyNameFull currency name
startSerialNumberFirst serial number in the book
endSerialNumberLast serial number in the book
numberOfLeavesTotal number of leaves/pages
issuedDateDate the book was issued
statusNumeric status (1=ACTIVE, 2=INACTIVE, 3=BLOCKED)
statusDescriptionHuman-readable status
isActiveBoolean indicating if status is ACTIVE
remarksNotes about the book register
createdAtTimestamp when record was created
createdByUser who created the record
updatedAtTimestamp of last update
updatedByUser who last updated the record

Notes

  • This command internally uses RetrieveBookRegistersListQuery with the ID filter
  • Returns 404 status if the book register does not exist
  • Includes full related data: deposit account, client details, branch information, and currency
  • Client names are automatically resolved based on client classification (individual/group)
  • Results are cached for improved performance