Download the PHP package wikp/payment-mtgox-bundle without Composer
On this page you can find all versions of the php package wikp/payment-mtgox-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download wikp/payment-mtgox-bundle
More information about wikp/payment-mtgox-bundle
Files in wikp/payment-mtgox-bundle
Package payment-mtgox-bundle
Short Description Bundle for creating payment system based on MtGox.com (Bitcoin cryptocurrency
License MIT
Homepage http://github.com/wikp/PaymentMtgoxBundle
Informations about the package payment-mtgox-bundle
PaymentMtgoxBundle
This bundle utilizes MtGox's IPN (Instant Payment Notification)
providing ability to create for example donation system, or simple shop.
The only thing you are forced to do is to create Order
class
implementing OrderInterface
and its doctrine repository (implementing
OrderRepositoryInterface
) and redirect user to MtGox Payment Page
(implementation of obtaining address to redirect is also included in
this bundle).
Full documentation and big refactor soon, so use only for testing purposes (I'm using this on production and everything works well, but my refactor implies your refactor ;) ).
Documentation
Installation
PaymentMtgoxBundle
is installed as every symfony bundle (composer require
, change in app/AppKernel.php
)
Configuration
You should first configure JMSPaymentCoreBundle (so only put payments_secret
in `app/config/parameters.yml').
Next get your api key and secret and also put them there. Something like that:
mtgox_api_key: your-mtgox-api-key
mtgox_api_secret: "+your-mtgox-api-secret=="
You should also add IpnController to your app/config/routing.yml
:
wikp_payment_mtgox:
resource: "@WikpPaymentMtgoxBundle/Resources/config/routing.yml"
prefix: /mtgox
Next, write your Order entity and its Repository:
Obtaining payment URL
You could obtain payment URL where you next should redirect a user in this way:
IpnController
When you configure bundle and do the payment, IpnController
should mark it as finished when all the money will be
transfered to your MtGox account.
Remember that you CANNOT debug this on your local machine, because MtGox probably won't be able to access it.