-
Notifications
You must be signed in to change notification settings - Fork 147
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How exactly to integrate web sockets ? #96
Comments
|
I have read it again and so far everything works fine except for the web socket part, which I don't understand what to do, there is not enough information on how to successfully implement the websockets. JSONRPC is working fine with curl, but I need a way to know whether or not the user has paid the invoice which can be done using sockets only. |
Maybe this guide will be helpful, then? http://yz.mit.edu/wp/web-sockets-tutorial-with-simple-python-server/ |
Well that just shows hosting a simple socket server. You mean I just need to run an empty web socket server with nothing coded inside it and electrum will take care of everything by itself ? |
If you followed electrum merchant docs, the simple socket server already works for you. The tutorial is useful to see how the javascript part is constructed. |
I am not sure if it is actually working or I am not doing something right. I see this message in browser console when I test a payment request:
I also noticed that it is using "wss", I did not configure https, perhaps this could be the issue ? But why is it automatically using wss (https) model, I don't need it, is there any way to let it use ws instead of wss ? |
You can't use electrum merchant without providing keys for SSL. It is clearly stated in requirements on the top of documentation chapter. |
merchant documentation was updated for 4.0 |
I have succeeded in installing electrum and running it as a daemon, it also accepts bitcoin in my website through electrum-merchant but one thing I do not understand is that how exactly to integrate web sockets ?
I did read the docs but the only information there is how to connect to a web socket server, lets suppose I make my own, then what procedure should I follow next ? Sockets, events, verifying, count of confirmations etc all this stuff would be done by me through custom coding or electrum can do it by itself ?
Secondly I would like to request for electrum-merchant to display the wallet address on the index.html page when viewed, not everyone use QR code or bitcoin core wallet, this can help a lot.
Thanks
The text was updated successfully, but these errors were encountered: