The abstract MPay24Shop class provides abstract functions, which are used from the other functions in order to make a payment or a request to mPAY24
TYPE: PARAMETER - VALUE(s), description
| author | mPAY24 GmbH <support@mpay24.com> |
|---|---|
| version | $Id: MPay24Shop.php 5522 2013-06-24 13:08:35Z anna $ |
| filesource | MPay24Shop.php |
| license | http://ec.europa.eu/idabc/eupl.html EUPL, Version 1.1 |
MPay24Shop(int $merchantID, string $soapPassword, bool $test, string $proxyHost = null, int $proxyPort = null, bool $debug = false)
int5-digit account number, supported by mPAY24: TEST accounts - starting with 9 LIVE account - starting with 7
stringThe webservice's password, supported by mPAY24
boolTRUE - when you want to use the TEST system, FALSE - when you want to use the LIVE system
stringThe host name in case you are behind a proxy server ("" when not)
int4-digit port number in case you are behind a proxy server ("" when not)
boolTRUE - when you want to write log files, FALSE - when you don't want write log files
createTransaction()
updateTransaction(string $tid, array $args, bool $shippingConfirmed)
stringThe transaction ID you want to update with the confirmation
arrayArrguments with them the transaction is to be updated
boolTRUE if the shipping address is confirmed, FALSE - otherwise (in case of PayPal Express Checkout)
getTransaction(string $tid)
stringThe transaction ID of the transaction you want get
createMDXI(\Transaction $transaction)
\TransactionThe transaction you want to make a MDXI XML file for
createProfileOrder(string $tid)
stringThe transaction ID of the transaction you want to make an order transaction XML file for
createExpressCheckoutOrder(string $tid)
stringThe transaction ID of the transaction you want to make an order transaction XML file for
createFinishExpressCheckoutOrder(string $tid, string $shippingCosts, string $amount, bool $cancel)
stringThe transaction ID of the transaction you want to make an order transaction XML file for
stringThe shipping costs amount for the transaction, provided by PayPal, after changing the shipping address
stringThe new amount for the transaction, provided by PayPal, after changing the shipping address
boolTRUE if the a cancelation is wanted after renewing the amounts and FALSE otherwise
write_log(string $operation, string $info_to_log)
stringThe operation, which is to log: GetPaymentMethods, Pay, PayWithProfile, Confirmation, UpdateTransactionStatus, ClearAmount, CreditAmount, CancelTransaction, etc.
stringThe information, which is to log: request, response, etc.
createSecret(string $tid, string $amount, string $currency, string $timeStamp)
It should build a hash from the transaction ID of your shop, the amount of the transaction, the currency and the timeStamp of the transaction. The mPAY24 confirmation interface will be called with this hash (parameter name 'token'), so you would be able to check whether the confirmation is really coming from mPAY24 or not. The hash should be then saved in the transaction object, so that every transaction has an unique secret token.
stringThe transaction ID you want to make a secret key for
stringThe amount, reserved for this transaction
stringThe timeStamp at the moment the transaction is created
stringThe timeStamp at the moment the transaction is created
getSecret(string $tid)
stringThe transaction ID you want to get the secret key for
getPaymentMethods()
pay()
payWithProfile()
payWithExpressCheckout()
finishExpressCheckoutPayment(string $tid, int $shippingCosts, int $amount, string $cancel)
stringThe transaction ID in the shop
intThe shippingcosts for the transaction multiply by 100
intThe amount you want to reserve/bill multiply by 100
stringALLOWED: "true" or "false" - in case of 'true' the transaction will be canceled, otherwise reserved/billed
confirm(string $tid, array $args)
stringThe transaction ID in the shop
arrayA list with the arguments, provided with the confirmation
updateTransactionStatus(string $tid)
An array with all the data (by mPAY24) for this transaction (STATUS, CURRENCY, PRICE, APPR_CODE, etc) will be returned. Possible values for the STATUS attribute:
stringThe transaction ID (in your shop), for the transaction you are asking for
clearAmount(string $tid, int $amount)
stringThe transaction ID, for the transaction you want to clear
intThe amount you want to clear multiply by 100
creditAmount(string $tid, int $amount)
stringThe transaction ID, for the transaction you want to credit
intThe amount you want to credit multiply by 100
cancelTransaction(string $tid)
stringThe transaction ID, for the transaction you want to cancel
checkTransaction($transaction)
mPay24Api