clawsonm / cakephp-propay
CakePHP 2.x wrapper plugin for ProPay API services. Uses auto generated WSDL.
Installs: 442
Dependents: 0
Suggesters: 0
Security: 0
Stars: 3
Watchers: 2
Forks: 1
Open Issues: 1
Type:cakephp-plugin
Requires
- php: >=5.3.0
- composer/installers: ~1.0
- wsdl2phpgenerator/wsdl2phpgenerator: 2.3.0
This package is not auto-updated.
Last update: 2025-03-01 17:35:19 UTC
README
cakephp-propay
wrapper for propay SOAP service in cakephp. Source WSDL is located at http://protectpay.propay.com/API/SPS.svc?wsdl. However to test your implementation you must use their test service located at http://protectpaytest.propay.com/api/sps.svc?wsdl
Installation
Using Composer
Add the plugin to your project's composer.json
- something like this:
{
"require": {
"clawsonm/cakephp-propay": "dev-master"
}
}
Because this plugin has the type cakephp-plugin
set in its own composer.json
, Composer will install it inside your /Plugins
directory, rather than in the usual vendors file. It is recommended that you add /Plugins/ProPay
to your .gitignore file. (Why? read this.)
You must also generate the SOAP Client classes
path/to/plugin/setup.sh
or specify a path as the first parameter e.g.
Plugin/ProPay/setup.sh Plugin/ProPay/generated
NOTE: setup.sh uses the production WSDL URL. It assumes that you will specify the correct URL, test or production in your code, see below.
Non Composer
You must generate the SOAP client with wsdl2phpgenerator from http://github.com/wsdl2phpgenerator/wsdl2phpgenerator. If you use Composer it should already be downloaded by composer. Place the generated code in generated/.
e.g. Run:
./vender/bin/wsdl2php -i http://protectpay.propay.com/API/SPS.svc?wsdl -o generated/
./vender/bin/wsdl2php -i http://protectpaytest.propay.com/api/sps.svc?wsdl -o generated/
Configuration
Please bootstrap the plugin when you load it. e.g.:
CakePlugin::load('ProPay', array('bootstrap' => true));
ProPay.wsdlUrl
This is the WSDL URL used by the SOAP client to determine the correct URL to communicate with.
ProPay.generatedLib
This allows you to set a path to the generated SOAP client files for the autoloader (which is loaded in the plugin's bootstrap) to use.
ProPay.authenticationToken
This is your ProPay Authentication Token. If you use ProPay you know what this is. Please do not include this in your repo. Put it in a separate file that you exclude from your repo.
ProPay.billerAccountId
This is your ProPay BillerAccountId. If you use ProPay you know what this is. Please do not include this in your repo. Put it in a separate file that you exclude from your repo.
License
MIT License
See LICENSE file.