I am using the bitcoind account system for my web app, but it doesn't work the way I want it to work. So I want to make my own account system in Laravel(probably opensource).
The main reason for the account system is that I can't know the fee when I send a transaction. With my own account system I can check if the fee is correct and then send the transaction.
But how can I setup a safe account system?
I was thinking about a table with all the bitcoin accounts(I am not using the users table so I can create accounts for an order for example).
Then an address table with all the addresses linked to an account.
But how do I handle incomming transactions? And outgoing transactions? If I for some reason change something outside my account system, it will probably will break pretty easy.
Do I have to import all the transactions to calculate the right account balances?
And I want to make the system in a way that I can make transactions between accounts, without making a "real" transaction, just like it works now.
I think it isn't that hard without the account-to-account transactions and moving bitcoin addresses to other accounts features, just import all the transactions in the database and calculate the balance for every address. And than sum the address balance for every account, but I need it.
Does this kind of system already exists. If not can someone help me with thinking this out.