Loading...
To cancel a credit refund, send a PUT request to the relevant endpoint.
| Scenario | Merchant uses the POS to: |
|---|---|
| 1. The merchant refunds an item that customer returned. 2. The customer changes their mind about the return and wants to cancel it while the refund is still in the open batch. | 1. Find the original refund. 2. Cancel the refund. |
The endpoints you use depends on whether you identify the original refund using the creditreturn_id or the reference_id.
| Object | Parameter | Type | Size | Required? | Description |
|---|---|---|---|---|---|
| payment | amount | String | 1-9 | Optional | Total dollar amount you want to void. The value includes two decimal places, for example, 10.00. |
| transactions | processing_indicators | Object | N/A | Optional | Object that includes options for additional actions. For a list of parameters, see the processing_indicators object. |
processing_indicators object
| Parameter | Type | Size | Required? | Description |
|---|---|---|---|---|
| generate_receipt | Boolean | Explicit | Optional | If set to true, we generate a receipt and return it in the receipt object of the response. |
| Object | Field | Type | Description |
|---|---|---|---|
| N/A | creditreturn_id | String | Unique identifier that our gateway generated for the transaction. Note: This is the creditreturn_id that you can include in the endpoint URL for follow-on transactions |
| N/A | reference_id | String | Unique identifier for the transaction that the merchant created. Note: This is the reference_id that you can include in the endpoint URL for follow-on transactions. |
| N/A | status | String | Indicates the status of the request. For a list of possible values, see the Request status enumeration. |
| card | masked_card_number | String | Masked card number of the card that the customer used for the transaction. We mask all digits except the first six and the last four. |
| expiry_month | String | Month that the card expires in MM format. | |
| expiry_year | String | Year that the card expires in YY format. | |
| type | String | Name of the card brand that issued the card. For a list of possible values, see the Card type enumeration. | |
| payment | amount | String | Total dollar amount of the transaction that you voided. |
| type | String | Type of payment for the transaction. For a list of possible values, see the Payment type enumeration. | |
| transaction | batch_amount | String | Total dollar amount of the open batch. |
| batch_number | String | Unique identifier of the open batch. | |
| receipt | id | String | Unique alphanumeric value that our gateway assigns to the receipt. |
| text | Object | Object that contains text for the customer copy and merchant copy of the receipt. For a list of fields, see the text object. | |
| attributes | Object | Object that contains details of text that the receipt can include. For a list of fields, see the attributes object. | |
| labeled_attributes | Object | Object that contains details of the transaction. For a list of fields, see the labeled_attributes object. | |
| links | creditreturn_id |
text object
| Field | Type | Description |
|---|---|---|
| customer_receipt | String | Text for the customer’s receipt. Our gateway creates this text using the details of the transaction. |
| merchant_receipt | String | Text for the merchant’s receipt. Our gateway creates this text using the details of the transaction. |
attributes object
| Field | Type | Description |
|---|---|---|
| authorization_agreement | String | Text that describes the merchant's authorization agreement, for example, I agree to pay the total amount according to the card issuer agreement. |
| call_issuer | String | Text that displays if the merchant needs to call the issuing bank, for example, CALL ISSUER. |
| copy_label_customer | String | Text that identifies the receipt as the customer's copy. |
| copy_label_merchant | String | Text that identifies the receipt as the merchant's copy. |
| merchant_address | String | Address of the merchant's store. |
| merchant_footer | String | Text that appears on the footer of the receipt. |
| merchant_header | String | Text that appears on the header of the receipt. |
| merchant_name | String | Name of the merchant's store. |
| merchant_phone | String | Phone number of the merchant's store. |
| merchant_policy | String | Text that describes the merchant's policies, for example, a return policy. |
| verbiage | String | Additional text that the merchant can include on the receipt, for example, Approved - Thank You. |
labeled_attributes object
We return a label field and a value field for each object. For example, for amount, we return the following:
"amount":
{
"label": "Total Amount",
"value": "$99.45 USD"
}
| Object | Description |
|---|---|
| amount | Total dollar amount of the transaction. |
| approval_code | Approval code for the transaction from the processor. |
| authorization_response_code | Response code for an authorization. |
| avs_response_code | Response code that indicates the result of an AVS check. |
| batch_number | Unique identifier of the batch. |
| card_balance | Remaining balance of a prepaid card. |
| card_type | Type of card the customer used for the transaction. |
| cardsecurity_response_code | Indicates if the card security code (CSC) that the customer entered matches the CSC of the card. For a list of possible values, see the Card security response enumerations. |
| clerk_id | Clerk ID that the merchant wants to display on the receipt. This is an alphanumeric value that the merchant assigns to a clerk, for example, Al090-John Doe. |
| entry_legend | Indicates how the payment terminal read the card details. The value is one of the following: • CHIP READ• MAGSTRIPE• MANUAL |
| entry_method | Indicates how the customer or merchant entered the card details. The value is one of the following: • Contact• Contactless• Manual• Swipe |
| gratuity_amount | Dollar amount that was tip in the original transaction. |
| masked_card_number | Masked card number of the card that the customer used for the transaction. We mask all digits except the first six and the last four. |
| merchant_id | Unique identifier for the merchant. |
| original_auth_code | The authorization code of the original sale. |
| payment_type | Type of payment for the sale. For a list of possible values, see the Payment type enumeration. |
| number | Number of the receipt. |
| reference_id | Unique identifier that the merchant created for the sale. Note: You can include the reference_id in the endpoint URL for follow-on transactions. |
| subtotal_amount | Dollar amount for the subtotal of the sale. We return either a value or a blank line. |
| total_amount | Total dollar amount of the sale. We return either a value or a blank line. |
| transaction_datetime |
creditreturn_id object
| Field | Type | Description |
|---|---|---|
| href | String | Endpoint URL for the follow-on transaction using the creditreturn_id. |
| relation | String | Relationship between the endpoint you sent the original request to and the resource for the follow-on transaction. The value is one of the following: • return - The transaction uses a returns endpoint.• self - The transaction uses the same type of endpoint as the original request.• void - The transaction uses a voids endpoint. |
| method | String | HTTP method for sending the transaction. The value is one of the following: • GET• PATCH• POST• PUT |
| description | String | Text that describes the follow-on transaction, for example, get a refund transaction using sale id. |
reference_id object
| Field | Type | Description |
|---|---|---|
| href | String | Endpoint URL for the follow-on transaction using the reference_id. |
| relation | String | Relationship between the endpoint you sent the original request to and the resource for the follow-on transaction. The value is one of the following: • return - The transaction uses a returns endpoint.• self - The transaction uses the same type of endpoint as the original request.• void - The transaction uses a voids endpoint. |
| method | String | HTTP method for sending the transaction. The value is one of the following: • GET• PATCH• POST• PUT |
| description | String | Text that describes the follow-on transaction, for example, get a refund transaction using reference id. |
| Object |
| Object that includes HATEOAS links for follow-on transactions using the creditreturn_id. For a list of fields, see the creditreturn_id object. |
| reference_id | Object | Object that includes HATEOAS links for follow-on transactions using the reference_id. For a list of fields, see the reference_id object. |
Date and time of the transaction that the processor returns in YYYY-MM-DDThh:mm:ssZ format, for example, 2019-12-15T13:00:00Z. |
| transaction_id | Unique ID our gateway assigned to the original transaction. |
| transaction_type | Type of transaction you ran. |
| validation_code | Validation code from the issuing bank. |
| application_cryptogram | Application cryptogram (AC) for an EMV transaction. |
| application_identifier | Application identifier (AID) for an EMV transaction. |
| application_label | Application label for an EMV transaction. |
| application_preferred_name | Name of the application in the cardholder’s local language. |
| application_transaction_counter | Application transaction counter (ATC) for an EMV transaction. |