Open nickjuntilla opened 3 years ago
Currently, one workaround is to listen to to the event Match
of the exchange smart contract end send an email or whatever job you need when the event is received.
That's not ideal as this requires your backend to maintain a connection to the blockchain but at least there is a way to do that.
One question: do you prefer to get a webhook for this or for example to use websocket for event streaming?
Webhook would definitely be better as it can be connected to a stateless/serverless endpoint. Websocket is interesting but maintaining an open connection is always tricky. I don't see much value in that, as it can already be done by directly listening to the events in the smart contract.
I agree with @antho1404 we use stateless google cloud functions and the webhook is great.
Ok, thanks for the information @antho1404 @nickjuntilla
Also, if you have capacity to contribute, will guide you to how this can be implemented and what should be changed. Let me know if you are ready to contribute
Depending on the time required, I might be able to contribute to that.
@sanufriev could you guide @antho1404 and anyone interested what's needed to be done to add a webhook for order state change
This issue has been closed. What's the status? Is this something possible to do now? If so, how? Or is this something that will not be done because it can be done directly by listening to the chain?
This issue has been closed. What's the status? Is this something possible to do now? If so, how? Or is this something that will not be done because it can be done directly by listening to the chain?
Hey Antho, I was under the mistaken idea that you were reached by @sanufriev already. Then this issue should not be closed, let me try to get ahold of him again to look over this issue.
We would like to alert our users when an NFT is sold. This way we could send them a congratulatory email or something of that nature. This could be possible by having a webhook callback parameter in the sell order.