Account functions
Function definitions

Creating account holder

createAccountHolder(_name)
Function parameter
Description
_name
character string name for account system (eg, card account, securities account)

Creating ledger

function createLedger(_ledgerName, _ledgerGroup, _holderAddress)
Function parameter
Description
_ledgername
string name of ledger created in account system
_ledgerGroup
string name of group to which ledger belongs
_holderAddress
address of the account holder for this ledger

Creating account

createAccount(_accountName, _currency, _ledgerAddress)
Function parameter
Description
_accountName
string name of account created in accounting ledger
_currency
3 letter ISO code of currency denominating the account
_ledgerAddress
address of accounting ledger for this account

Posting an account entry

postEntry(_counterParty, _accountNumber, _txAmount, _txType, _txDate, _txDescription, _vchType, _accountAddress)
Function parameter
Description
_counterParty
address of client that represents the counter party in a transaction
_accountNumber
integer number representing an account
_txAmount
float number of a transaction amount
_txType
CREDIT or DEBIT string
_txDate
character string representing date of transaction in YYYY-MM-DD format
_txDescription
character string describing a transaction's purpose
_vchType
character string for a entry's voucher (eg, journal, cash, purchase, sales, etc)
_accountAddress
address of account to which the entry for the transaction should be posted

Getting an account entry

getEntry(_accountNumber, _txDate, _accountAddress)
Function parameter
Description
_accountNumber
integer number representing an account
_txDate
character string representing date of transaction in YYYY-MM-DD format
_accountAddress
address of account for which the entry of the transaction should be retrieved

Updating account statement

updateAccountStatement(_holderAddress)
Function parameter
Description
_holderAddress
address of the account holder for which the transaction account statement is to be updated

Getting account statement

getAccountStatement(_holderAddress, _index)
Function parameter
Description
_holderAddress
address of the account holder for which the transaction account statement is to retrieved
_index
integer number representing the entry that needs to be retrieved
Copy link
On this page
Creating account holder
Creating ledger
Creating account
Posting an account entry
Getting an account entry
Updating account statement
Getting account statement