Author

Topic: How accept bitcoin payments without bitpay, coinify, etc? (Read 1319 times)

legendary
Activity: 1442
Merit: 1186
If you are dealing with relatively low dollar amounts and able to sweep keys frequently here's a down and dirty way to do it.

1. Generate a new key pair on the fly with (https://blockchain.info/q/newkey)
2. You just generated a new address followed by the 64hex private key.
3. THAT KEY IS TRANSMITTED OPENLY AND NOT SECURE.  No biggie, as long as you are dealing with only a few orders a day and low dollar amounts your risk is minimal. Risk does exist to a MitM but again, if you are some small shop selling your homemade jelly for $20 a jar I'd say you're pretty unlikely to be a target. Now if your selling weed and cocaine, with a bunch of orders per hour, well then this would be the stupidest way to accept payment.  
4. Present the address to your customer, and tell them to send bitcoins to that address.
5. Use something like mail(); to email yourself the customer's contact/shipping info, the item they ordered, and the key pair your generated.
6. Once or a couple times a day when you receive an email that there was a new order, sweep the funds to your secure wallet on your phone/table/PC whatever.
7. If you don't know how to convert the 64 hex private key to wallet import format, head on over to bitaddress.org, click on wallet details and paste it in there.

Below are some very brief code examples for steps 1, 4 and 5

1.
Code:
$url "https://blockchain.info/q/newkey";
$fgc file_get_contents($url);
$keypair explode(" "$fgc);
$bitcoin_address $keypair[0];
$private_key $keypair[1];
//store in session
session_start();
$_SESSION["addy"] = $bitcoin_address;
$_SESSION["pk"] = $private_key;
?>


4.
Code:

Hello Mr Customer,

Please send $20 or //get exchange rate
$exc json_decode(file_get_contents("https://blockchain.info/stats?format=json"), true);
$btcusd $exc["market_price_usd"];
$usdamount 20;
$convert $usdamount $btcusd;
$convert number_format($convert4);
echo 
$convert."BTC to "$bitcoin_address;
?>




etc.. some form input



5.
Code:
//when user submits the form email yourself the details
if(isset($_POST['form_button'])){
$yourEmail "[email protected]";
$host $_SERVER['SERVER_NAME'];
$emailTitle "New Order";
$bodyEmail = <<   //include order details from your form
    Payment Address: 
$_SESSION["addy"] 

    Private Key to Sweep: 
$_SESSION["pk"] 

EOD;
 
        
$headers "From: noreply@".$host."\r\n";
        
$headers .= "Content-type: text/html\r\n";
        
$success mail("$yourEmail""$emailTitle""$bodyEmail""$headers");
}
?>

sr. member
Activity: 392
Merit: 251
You can use the blockchain.info API. It's pretty good and fast. Most bitcoin sites nowadays work on that. If you really want to be self sufficient, try using bitcoind.
full member
Activity: 140
Merit: 100
DEGEN Future Traders
Thanks for the info i will use it for further reference in my site.

; P
hero member
Activity: 586
Merit: 500
Here you go:

http://docs.electrum.org/en/latest/merchant.html

Did this with a small project I did last year, worked a treat.

Very easy to do.
member
Activity: 98
Merit: 10
Hello, All!

Is it possible to accepting bitcoin payments on site without bitpay?

Yes.

When your customer is ready to pay, you should:
  • Generate a bitcoin address.
  • Store the private key securely
  • Provide the bitcoin address to your customer
  • Tell your customer how much bitcoins you want them to send you
  • Watch for the transaction to be sent with the correct amount of bitcoins to the correct address
  • Determine if the transaction is likely to confirm (or wait for it to confirm)
  • Provide your product or service to the customer
Yes, providing a bitcoin address is really the only way you can get people to send bitcoins without a payment support such as bitpay.
sr. member
Activity: 265
Merit: 250
legendary
Activity: 1512
Merit: 1012
You can have Electrum accept Bitcoin payments on your website. Give a look on their documentation, they've got it all there.
newbie
Activity: 44
Merit: 0
Hello, All!

Is it possible to accepting bitcoin payments on site without bitpay?

Yes.

When your customer is ready to pay, you should:
  • Generate a bitcoin address.
  • Store the private key securely
  • Provide the bitcoin address to your customer
  • Tell your customer how much bitcoins you want them to send you
  • Watch for the transaction to be sent with the correct amount of bitcoins to the correct address
  • Determine if the transaction is likely to confirm (or wait for it to confirm)
  • Provide your product or service to the customer
Yes, that's definitely possible.  How to best do it depends a lot on your particular requirements and resources.  I think there are two main ways for you to do that:

1) If you have a server that is strong enough (and, importantly, actually your server and not just some web host), you can run Bitcoin Core on it and use the RPC interface to manage the wallet, check for incoming transactions and so on.  If you do this, be careful that you know what you are doing and are not keeping too many coins in the wallet on the server.

2) You can pregenerate a list of Bitcoin addresses from some wallet (where the private keys could even be totally offline) and then just have a simple script on the website hand out one address after the other from this list to customers.  You could use some API provider (blockchain explorer with programmatically accessible API) to check for incoming transactions.  This method is probably simpler for you, but you have to trust that API provider "somewhat".

In any case, note that this will let you accept Bitcoins directly - without converting them to fiat currency on the fly.

A lot of thanks, guys!
legendary
Activity: 1135
Merit: 1166
Yes, that's definitely possible.  How to best do it depends a lot on your particular requirements and resources.  I think there are two main ways for you to do that:

1) If you have a server that is strong enough (and, importantly, actually your server and not just some web host), you can run Bitcoin Core on it and use the RPC interface to manage the wallet, check for incoming transactions and so on.  If you do this, be careful that you know what you are doing and are not keeping too many coins in the wallet on the server.

2) You can pregenerate a list of Bitcoin addresses from some wallet (where the private keys could even be totally offline) and then just have a simple script on the website hand out one address after the other from this list to customers.  You could use some API provider (blockchain explorer with programmatically accessible API) to check for incoming transactions.  This method is probably simpler for you, but you have to trust that API provider "somewhat".

In any case, note that this will let you accept Bitcoins directly - without converting them to fiat currency on the fly.
legendary
Activity: 3472
Merit: 4801
Hello, All!

Is it possible to accepting bitcoin payments on site without bitpay?

Yes.

When your customer is ready to pay, you should:
  • Generate a bitcoin address.
  • Store the private key securely
  • Provide the bitcoin address to your customer
  • Tell your customer how much bitcoins you want them to send you
  • Watch for the transaction to be sent with the correct amount of bitcoins to the correct address
  • Determine if the transaction is likely to confirm (or wait for it to confirm)
  • Provide your product or service to the customer
newbie
Activity: 44
Merit: 0
Hello, All!

Is it possible to accepting bitcoin payments on site without bitpay? Because they ask to many information, documents and scans, and give a limits on monthly volume. Also I think it is more safety to accept payments straight on own bitcoin wallet without any 3rd party.

Thanks!
Jump to: