Class RefundRequest
Pagarme Refund Request
This route is used when you want to reverse a transaction performed by a charge via credit card. In case of reversal a transaction, only the id of the transaction is required to effect the reversal.
Example -- note this example assumes that the purchase has been successful and that the transaction ID returned from the purchase is held in $sale_id. See PurchaseRequest for the first part of this example transaction:
// Do a refund transaction on the gateway $transaction = $gateway->refund(array( 'transactionReference' => $sale_id, )); $response = $transaction->send(); if ($response->isSuccessful()) { echo "Refund transaction was successful!\n"; $refund_id = $response->getTransactionReference(); echo "Transaction reference = " . $refund_id . "\n"; }
- Omnipay\Common\Message\AbstractRequest
-
Omnipay\Pagarme\Message\AbstractRequest
-
Omnipay\Pagarme\Message\RefundRequest
Direct known subclasses
See:
Omnipay\Pagarme\Message\PurchaseRequestSee:
Omnipay\Pagarme\GatewayLink: https://docs.pagar.me/api/?shell#estorno-de-transao
Located at Message/RefundRequest.php
Methods summary
public
|
|
public
|
Methods inherited from Omnipay\Pagarme\Message\AbstractRequest
createResponse(),
extractAddress(),
extractDddPhone(),
getApiKey(),
getCard(),
getCardData(),
getCardHash(),
getCustomer(),
getCustomerData(),
getCustomerReference(),
getHttpMethod(),
getMetadata(),
insertApiKeyToData(),
sendData(),
setApiKey(),
setCard(),
setCardHash(),
setCustomer(),
setCustomerReference(),
setMetadata()