Bye Banks receive send claim help contact

Notification URL help

For help you can also send us an email.

notification_url is the url on seller website whwere we send payment data, so seller can process the payment details and deliver the products or services.

We notify the url when an incoming payment is detected and again when the payment is confirmed.

Let's say you created the file script.php on your website, set http://yoursite.com/script.php as notification_url when creating the pay button, now when a payment is received, we will trigger your URL in background and send a code parameter to it, like this:

http://yoursite.com/script.php?code=e88c106v1b9

Your script should fetch that code value and load data from our website, from this Instant Payment Notification url:

https://byebanks.com/ipn/e88c106v1b9

And that will return the details of payment e88c106v1b9 in json format:

{
"variable_bitcoin_address":"123thisIstAnExampleNotaRealAddress45",
"receiver_bitcoin_address":"15H2aWQp7WGFoTYgnkVhQZg16d6SLKRDq2",
"receiver_email":"sales@example.com",
"receiver_phone":null,
"initial_amount":"10.00",
"initial_currency":"usd",
"receiver_name":"West Electronics Store",
"item_name":"Yellow Electric Box",
"invoice_date":"2147483647",
"btc_amount_requested":"0.00175400",
"btc_amount_pending":"0.00175400",
"btc_amount_received":"0.00175400",
"payment_id":"10104",
"payment_status":"completed",
"custom_data":"referral_id=120",
}

Here is a sample code for your ipn script by php

<?php

$payment_json_data = file_get_contents('https://byebanks.com/ipn/'.$_GET['code']);

// convert the json data to an array
$payment_array = json_decode($payment_json_data, true);

// now use any of the variables from the json string
echo $payment_array['payment_status'];

?>

In your IPN script we recommend that you verify these important things:

Payment data variables

btc_amount_requested is the amount the seller requested when pay button was created, when payment is completed the amount_confirmed should be equal to this.

btc_amount_pending is the amount of bitcoin that was not yet confirmed by network, it means a payment will be completed soon, sometimes minutes, sometimes hours, depending on current bitcoin network load.

btc_amount_received is the amount that was already confirmed, if the amount confirmed matches the amount requested then you can deliver the products/services to the buyer.

payment_status is a calculated value, can be "pending", or "completed" once the amount_received matches amount_requested.

variable_bitcoin_address is the address shown to the buyer in order to make the payment, this is not related to the seller's main address (receiver_bitcoin_address)

custom_data will contain any additional variables set by seller when creating the button link, for example it can contain an incoice id or a member id from seller website.