Is there a way where we can add a callback link to the transaction and when it is done, it gives a call back to the system.
Thanks in advance.
Is there a way where we can add a callback link to the transaction and when it is done, it gives a call back to the system.
Thanks in advance.
I’m not aware of any way to do that easily. One way to accomplish that would be as follows -
I have not tried to implement the above, but I believe that it should be doable.
I am looking for a solution similar to this:
Blockchain Receive Payments API: Accept Bitcoin Payments - Blockchain
So, just to make sure I understand what you’re looking for -
You’re wondering if there is a way for your local node to issue a http callback once a transaction was successfully included in a block.
Is that the case ?
Yes you are right, like in btc if there is a transaction against a product or service, it will give a callback to the system on transaction confirmation.
Currently, neither the REST API, nor the goal client provides that functionality.
If the transaction is sent from the local host, once the transaction is sent ( and before its being included in a block ), you can spin a separate process that would monitor the transaction state using pending-transaction-information
, and implement the callback as needed yourself.
I’m not a big fan of the above solution since
I wish I had a better answer here… please let me know if that helps.
Thanks tsachi, I will look into it and if i found a solution, i will let you know too.
Ever find anything? You would think this is a standard option to have out of the box.
The cleanest solution is to query the indexer every new round and check if the transaction is recorded.
There is currently no push API on Algorand that I am aware of.