<p>Here's an example of an IPN that works with the Blockchain API:</p>

<p><a href="https://github.com/damonp/simplebtcpay/blob/master/www/callback.php" rel="nofollow">https://github.com/damonp/simplebtcpay/blob/master/www/callback.php</a></p>

CC BY-SA 3.0
2014-10-06T21:17:29.440Z
2014-10-06T21:17:29.440Z
siliconsys
<p>It <strong>is</strong> possible to test it offline. Check your <code>phpinfo()</code> to confirm, but I perform operations with the blockchain API from my XAMPP server all the time, as I am currently working on a site that uses the API. All you're doing is sending a request to a URL (like when you loaded this page) and getting the contents of that file. If you're interested, check out this class I wrote for using the blockchain API with PHP: <a href="https://github.com/lukesims/Blockchain-API-PHP-Class" rel="nofollow">https://github.com/lukesims/Blockchain-API-PHP-Class</a></p>

<p>With that, you could ad more functions or modify it to interact with your database simultaneously.</p>

CC BY-SA 3.0
2014-05-09T13:27:37.060Z
2014-05-09T13:27:37.060Z
Luke
<p>Its not possible to test it offline (probably because of file_get_contents() function which is present in create.php )</p>

<p>Second, as far as I know, you would have to write your update queries or whatever you want to do, inside the callback.php file, which is called by Blockchain itself once a transaction has been done.</p>

CC BY-SA 3.0
2014-04-09T10:43:22.553Z
2014-04-09T10:43:22.553Z
Salmaan Ahmed Khan
<p>I'm having some real trouble setting up the Blockchain API on my server</p>

<p>First off is it possible to test it offline with local host?</p>

<p>Secondly, how do I set it up so when a tx is made through my site, it runs a php function to update a database with certain values </p>

<p>Has anyone successfully set up the API before and if so could they please walk me through how I would do it</p>

<p>Thanks </p>

<api><blockchain.info>
Blockchain API support - receive payment IPN
Coderrrr
# Blockchain API support - receive payment IPN

(Asked by: username_0 on 2013-08-09)

I'm having some real trouble setting up the Blockchain API on my server

First off is it possible to test it offline with local host?

Secondly, how do I set it up so when a tx is made through my site, it runs a php function to update a database with certain values

Has anyone successfully set up the API before and if so could they please walk me through how I would do it

Thanks

**Tags:** api, blockchain.info


---

## 3 answers

### Answer by username_1 on 2014-10-06. Score: 1

Here's an example of an IPN that works with the Blockchain API:

<https://github.com/damonp/simplebtcpay/blob/master/www/callback.php>


---

### Answer by username_2 on 2014-05-09. Score: 1

It **is** possible to test it offline. Check your `phpinfo()` to confirm, but I perform operations with the blockchain API from my XAMPP server all the time, as I am currently working on a site that uses the API. All you're doing is sending a request to a URL (like when you loaded this page) and getting the contents of that file. If you're interested, check out this class I wrote for using the blockchain API with PHP: <https://github.com/lukesims/Blockchain-API-PHP-Class>

With that, you could ad more functions or modify it to interact with your database simultaneously.


---

### Answer by username_3 on 2014-04-09. Score: 0

Its not possible to test it offline (probably because of file\_get\_contents() function which is present in create.php )

Second, as far as I know, you would have to write your update queries or whatever you want to do, inside the callback.php file, which is called by Blockchain itself once a transaction has been done.


---

