Closed maesitos closed 6 years ago
@maesitos I'm not a big fan of aggregating all notifications under a single name. A webhook contains many events which can be handled and updated in bulk.
I don't ever see a need for that and actually find it quite dangerous. If all hooks are created individually for each payment, it creates more separation which I feel can be good for many reasons. It can even allow us to create unique urls for better debugging.
POST /bitcoin_payable/notify_transaction/:payment_id
I have no particular preference and I was trying to follow the way Blocktrail, in my view, thought the users will use the API. Nonetheless I have tested and I was able to create almost 1200+ webhooks so the API can handle a decent amount of pending
payments with your proposal and by the way, the user interface does paginate.
I'd suggest to create new state for the payments canceled
so that if the paren app decides to cancel the order, effectively never expecting to receive any payments, the web-hook can be cleaned up.
Small changes on top pf https://github.com/Sailias/bitcoin_payable/pull/33