What malleability means is that you can't store the transaction ID that bitcoind
returns from its sendtoaddress
API call and expect that number to mean anything at all later.
Instead, if you want to keep track of a high volume of outgoing transactions, you have to wait for the transactions to be fully confirmed and immune to blockchain reorganizations, and then guess at which blockchain transactions correspond to which withdrawal or automatic payment events by matching the amount and destination address.
Some famous guy recommended using a combination of amount, address, and timestamp, but apparently transaction timestamps are not reliable either, so there really isn't a good, reliable way for Bitcoin apps to keep track of which transactions they sent out and why.
bitcoind
itself tracks outputs, not transaction IDs, but it doesn't expose this information to API users. So if you want to send transactions and track them by the outputs, which is considered to be reliable, you need to write your own Bitcoin client, which is a lot like writing your own SQL server, except it's not as simple.