Author

Topic: Blockchain API Payment Processing (Read 146 times)

newbie
Activity: 6
Merit: 0
December 29, 2017, 08:52:17 AM
#9
5 minutes is a really short time imho. People might need to move funds, sweep paper wallets, search the key for the old ledger HW.1 in order to sign a transaction.
Bitpay waits 15 minutes, i think that's reasonable...

Ok I'll up the time limit. I was just thinking of the volatility.

As for you choice of using the blockchain api, i agree to one of the previous posters: why don't you use an established payment provider like bitpay or coinpayments? If you're set on doing things yourself (to have full controll, or because you don't like to pay a fee), i'd suggest running your own node and using json-rpc query's, or using an xpub from an offline electrum wallet to derive new payment addresses for each customer without exposing your private key or xprv on an online server...

I tried setting up my own node but go nowhere. I know some PHP and that's about it.

It's doable using php...
Just use easybitcoin:
https://github.com/aceat64/EasyBitcoin-PHP

then build a connection
Code:
require_once('easybitcoin.php');
$bitcoin = new Bitcoin('[your rcp username here]','[your rcp password here]','[bitcoind\'s ip address here]','8332');

then you can just send requests
for example, to decode a raw transaction stored in the variable $raw
Code:
$decoded = decoderaw($raw, $bitcoin)

Thanks but that's all still over my head. I'm just about finished integrating the Blockchain API. It's looking good thus far.
legendary
Activity: 3584
Merit: 5248
https://merel.mobi => buy facemasks with BTC/LTC
December 27, 2017, 08:25:26 PM
#8
5 minutes is a really short time imho. People might need to move funds, sweep paper wallets, search the key for the old ledger HW.1 in order to sign a transaction.
Bitpay waits 15 minutes, i think that's reasonable...

Ok I'll up the time limit. I was just thinking of the volatility.

As for you choice of using the blockchain api, i agree to one of the previous posters: why don't you use an established payment provider like bitpay or coinpayments? If you're set on doing things yourself (to have full controll, or because you don't like to pay a fee), i'd suggest running your own node and using json-rpc query's, or using an xpub from an offline electrum wallet to derive new payment addresses for each customer without exposing your private key or xprv on an online server...

I tried setting up my own node but go nowhere. I know some PHP and that's about it.

It's doable using php...
Just use easybitcoin:
https://github.com/aceat64/EasyBitcoin-PHP

then build a connection
Code:
require_once('easybitcoin.php');
$bitcoin = new Bitcoin('[your rcp username here]','[your rcp password here]','[bitcoind\'s ip address here]','8332');

then you can just send requests
for example, to decode a raw transaction stored in the variable $raw
Code:
$decoded = decoderaw($raw, $bitcoin)
newbie
Activity: 6
Merit: 0
December 27, 2017, 04:04:48 PM
#7
5 minutes is a really short time imho. People might need to move funds, sweep paper wallets, search the key for the old ledger HW.1 in order to sign a transaction.
Bitpay waits 15 minutes, i think that's reasonable...

Ok I'll up the time limit. I was just thinking of the volatility.

As for you choice of using the blockchain api, i agree to one of the previous posters: why don't you use an established payment provider like bitpay or coinpayments? If you're set on doing things yourself (to have full controll, or because you don't like to pay a fee), i'd suggest running your own node and using json-rpc query's, or using an xpub from an offline electrum wallet to derive new payment addresses for each customer without exposing your private key or xprv on an online server...

I tried setting up my own node but go nowhere. I know some PHP and that's about it.
newbie
Activity: 6
Merit: 0
December 27, 2017, 03:43:43 PM
#6
You can clearly state that if they send less than the required amount, that is considered a donation. Keep it simple.

It would be nice if I could get away with this.  Grin
newbie
Activity: 6
Merit: 0
December 27, 2017, 03:27:06 PM
#5
Hi and welcome.
I don't have much experience with blockchain API just wanted to let you know you can use some established payment processor like bipay or myceliumgear ... these should take care of similar issues.


BTW for testing purposes you can try using bitcoin testnet (these coins are very same to BTC but you can get them for free)



I'm trying to avoid the up to 1% fee. I'll check out bitcoin testnet. Thanks
legendary
Activity: 3584
Merit: 5248
https://merel.mobi => buy facemasks with BTC/LTC
December 27, 2017, 12:39:15 PM
#4
5 minutes is a really short time imho. People might need to move funds, sweep paper wallets, search the key for the old ledger HW.1 in order to sign a transaction.
Bitpay waits 15 minutes, i think that's reasonable...

As for you choice of using the blockchain api, i agree to one of the previous posters: why don't you use an established payment provider like bitpay or coinpayments? If you're set on doing things yourself (to have full controll, or because you don't like to pay a fee), i'd suggest running your own node and using json-rpc query's, or using an xpub from an offline electrum wallet to derive new payment addresses for each customer without exposing your private key or xprv on an online server...
legendary
Activity: 3668
Merit: 6382
Looking for campaign manager? Contact icopress!
December 27, 2017, 12:37:02 PM
#3
This is my first post. I'm adding Bitcoin as a payment option to one of my websites and have some questions about functionality. Since the buyer controls how much they pay, how do you handle underpayments? Since the buyer has the payment address, how do you handle later payments since the buyer would likely only do this if the conversion rate is in his favor? I put a 5-minute timer on my payment page so I could make it where any payments after the 5 minutes would not result in shipment but that would create a headache. Will the API callback occur multiple times for multiple payments to the same address? I would check this out for myself if not for the current high transaction fees.

Thanks in advance.

Greg

One of the websites I am buying from has a payment processor that accepts Bitcoin.
In order to have the payment automatically processed, I have to make the transfer within 20 minutes and I think that it has to be one transfer with the correct (displayed) amount.
If the tx is relayed within the 20 minutes, "I am good" and when 1 or 3 confirmations passed the seller sends the "payment received" e-mail.

So the 1st check is (afaik) by time and amount and a second check is done to make sure the tx gets confirmed.


You can clearly state that if they send less than the required amount, that is considered a donation. Keep it simple.
sr. member
Activity: 952
Merit: 339
invest trade and gamble wisely
December 27, 2017, 12:27:24 PM
#2
Hi and welcome.
I don't have much experience with blockchain API just wanted to let you know you can use some established payment processor like bipay or myceliumgear ... these should take care of similar issues.


BTW for testing purposes you can try using bitcoin testnet (these coins are very same to BTC but you can get them for free)
newbie
Activity: 6
Merit: 0
December 27, 2017, 10:02:28 AM
#1
This is my first post. I'm adding Bitcoin as a payment option to one of my websites and have some questions about functionality. Since the buyer controls how much they pay, how do you handle underpayments? Since the buyer has the payment address, how do you handle later payments since the buyer would likely only do this if the conversion rate is in his favor? I put a 5-minute timer on my payment page so I could make it where any payments after the 5 minutes would not result in shipment but that would create a headache. Will the API callback occur multiple times for multiple payments to the same address? I would check this out for myself if not for the current high transaction fees.

Thanks in advance.

Greg
Jump to: