2

I am creating a website where I want to accept Monero as payment method. I want to create a monero wallet for my each signed up user. Like say for example, when a user logs in, his BTC, ETH, XMR and USDC all wallets are created and keys are encrypted and stored in database. Further,only these wallets will be used if user wants to do anything on my website. I have achieved this for BTC, ETH and USDC. Now I want to know how I can achieve this for XMR? Anyone please help.

1 Answer 1

2

Just using one wallet and a subaddress per customer is the simplest path (without knowing precisely what you're trying to achieve). You can create the new subaddresses with the wallet RPC method: create_address.

4
  • Yes... How can I make this one wallet? I can generate the addresses later on. Do I need to run a full node on my server? Commented Aug 30, 2021 at 10:31
  • You can use create_wallet to make the wallet. Both this and the answer refer to using the monero-wallet-rpc which also needs to use a node (which can be yours running on the same host or someone else's remotely).
    – jtgrassie
    Commented Aug 30, 2021 at 12:31
  • How can I access and connect a remote node? Right now I am using the documentation here [github.com/PsychicCat/monero-nodejs] and getting the following error: Error: connect ECONNREFUSED 127.0.0.1:18082 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1138:16) { errno: -111, code: 'ECONNREFUSED', syscall: 'connect', address: '127.0.0.1', port: 18082 } is this something related to my above issue??? Commented Aug 31, 2021 at 6:24
  • You have to connect to the host and port you are using for monero-wallet-rpc. Port 18082 is the default monerod zmq port, so if you want to use that port for the wallet RPC, you have to either disable zmq in monerod or tell monerod to use a different zmq port.
    – jtgrassie
    Commented Aug 31, 2021 at 13:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.