0

I want to create a website where people can submit their altcoin address and they receive some for free.

The addresses are saved in a MySQL database and the transactions are send from just one address.

How do I have to connect the database with the altcoin client so the transactions to the user addresses are processed automatically?

Thank you in advance!

  • Most altcoin clients provide an API. So the short answer to your question is "write some code that fetches the addresses from the database and calls the altcoin client API to send the coins". – Nate Eldredge Apr 8 '14 at 15:36
1

You need to speak with each wallet through it's JSON RPC API. To speak with the wallet you need to write some code.

If you want to test this api go to your wallet in the menu Help->Debug->Console and write the 'help' command, it will give you the list of all the available commands.

To enable this RPC for external applications you need to create a .conf file. Try to run the wallet from the command line and it should complain that you must create this file. This file contains the credentials that external applications use to access the json-rpc api of the wallet. This is different than the password that you need in order to send the coins.

There are some security considerations that you need to keep in mind:

  • by default the JSON RPC calls are transmitted in plain text so you need to enable encryption explicitly

  • minimize the amount of coins you have in the server hot wallet. Instead use one external script to replenish the wallet as needed (also it could compare the addresses in the database with the amount spent)

  • set the credentials for the wallet access in a secure way

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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