{"title":"Refund a transaction from the PED","category":"default","creationDate":1776961627,"content":"<p>Cancel or refund a transaction from the terminal transaction list, and receive a receipt on the POS or on the PED.<\/p>\n<div class=\"sc-notice note\"><div>\n<p>You can only use this cancel or refund method for transactions that:<\/p>\n<ul>\n<li>have been completed on the PED that is receiving the cancel or refund request.<\/li>\n<li>are still within the PED storage \u2013 this is currently limited to 100 tenders.<\/li>\n<\/ul>\n<\/div><\/div>\n<h2 id=\"peddevice-object\">PedDevice Object<\/h2>\n<table>\n<thead>\n<tr>\n<th>Name<\/th>\n<th>Description<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><code>PedDevice<\/code><\/td>\n<td>PED object that represents the terminal.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2 id=\"method\">Method<\/h2>\n<table style=\"width:100%;\"><colgroup><col style=\"width: 26%\"><col style=\"width: 73%\"><\/colgroup><thead><tr class=\"header\"><th><p>Name<\/p><\/th><th><p>Description<\/p><\/th><\/tr><\/thead><tbody><tr><td><p><code>CancelOrRefund<\/code><\/p><\/td><td><p>Cancel or refund a completed transaction from the terminal transaction list. The transaction must have been completed on the PED that is receiving the cancel or refund request, and must be still within the PED storage (this is currently limited to 100 tenders.)<\/p><\/td><\/tr><\/tbody><\/table>\n<h2 id=\"parameters\">Parameters<\/h2>\n<table style=\"width:100%;\"><colgroup><col style=\"width: 14%\"><col style=\"width: 9%\"><col style=\"width: 6%\"><col style=\"width: 69%\"><\/colgroup><thead><tr class=\"header\"><th><p>Name<\/p><\/th><th><p>Type<\/p><\/th><th><p>Required<\/p><\/th><th><p>Description<\/p><\/th><\/tr><\/thead><tbody><tr><td><p><code>merchantAccount<\/code><\/p><\/td><td><p>String<\/p><\/td><td><p><img title=\"-white_check_mark-\" alt=\"-white_check_mark-\" class=\"smileys\" src=\"\/user\/data\/smileys\/emoji\/white_check_mark.png\" \/><\/p><\/td><td><p>The merchant account that is canceling the transaction and refunding the money (if applicable).<\/p><\/td><\/tr><tr><td><code>tenderReference<\/code><\/td><td>String<\/td><td><img title=\"-white_check_mark-\" alt=\"-white_check_mark-\" class=\"smileys\" src=\"\/user\/data\/smileys\/emoji\/white_check_mark.png\" \/><\/td><td>A reference to the tender provided by the PED.<\/td><\/tr><tr><td><code>handleReceipt<\/code><\/td><td>Boolean<\/td><td><img title=\"-x-\" alt=\"-x-\" class=\"smileys\" src=\"\/user\/data\/smileys\/emoji\/x.png\" \/><\/td><td>Specifies that the POS handles and prints receipts. If omitted, it is required that the PED prints the receipt. If there is no printer unit, the transaction will fail.<\/td><\/tr><tr><td><p><code>additionalDataObject<\/code><\/p><\/td><td><p><a href=\"\/point-of-sale\/classic-library-deprecation\/classic-library-integrations\/com-extension-for-windows-integration\/com-extension-for-windows-objects\/additionaldata\">AdditionalData<\/a><\/p><\/td><td><img title=\"-x-\" alt=\"-x-\" class=\"smileys\" src=\"\/user\/data\/smileys\/emoji\/x.png\" \/><\/td><td>Contains key\/value pairs that can be used by the merchant to return specific additional data, in particular in the final transaction result.<\/td><\/tr><\/tbody><\/table>\n<h2 id=\"callback\">Callback<\/h2>\n<table style=\"width:100%;\"><colgroup><col style=\"width: 18%\"><col style=\"width: 81%\"><\/colgroup><thead><tr class=\"header\"><th>Name<\/th><th>Description<\/th><\/tr><\/thead><tbody><tr><td><code>CancelOrRefundOnPedCB<\/code><\/td><td><p>The Cancel or Refund Callback returns the result of a cancellation or refund, as well as any errors.<\/p><\/td><\/tr><\/tbody><\/table>\n<h2 id=\"parameters-1\">Parameters<\/h2>\n<table style=\"width:93%;\"><colgroup><col style=\"width: 14%\"><col style=\"width: 9%\"><col style=\"width: 69%\"><\/colgroup><thead><tr class=\"header\"><th><p>Name<\/p><\/th><th><p>Type<\/p><\/th><th><p>Description<\/p><\/th><\/tr><\/thead><tbody><tr><td><p><code>pedObj<\/code><\/p><\/td><td><p><a href=\"\/point-of-sale\/classic-library-deprecation\/classic-library-integrations\/com-extension-for-windows-integration\/com-extension-for-windows-objects\/peddevice\">PedDevice<\/a><\/p><\/td><td><p>PED object that represents the terminal.<\/p><\/td><\/tr><tr><td><p><code>receipts<\/code><\/p><\/td><td><a href=\"\/point-of-sale\/classic-library-deprecation\/classic-library-integrations\/com-extension-for-windows-integration\/com-extension-for-windows-objects\/receipts\">Receipts<\/a><\/td><td>Passes receipts to the cash register.\u00a0Its\u00a0structure is formatted for printing.<\/td><\/tr><tr><td><p><code>pedResult<\/code><\/p><\/td><td><p>int<\/p><\/td><td><p>Result denoting whether an error occurred on the PED.\u00a0A value of 0 means no error occurred.<\/p><div class=\"sc-notice warning\"><div><p>As this request is not processed on the PSP, check <code>pedResult<\/code> for errors instead of the <code>pspResult<\/code>.\u00a0<\/p><\/div><\/div><\/td><\/tr><tr><td><code>libResult<\/code><\/td><td>int<\/td><td><p>Result denoting whether an error occurred in the Library. A value of 0 means no error occurred.<\/p><div class=\"sc-notice warning\"><div><p>As this request is not processed on the PSP, check <code>libResult<\/code> for errors instead of the <code>pspResult<\/code>.<\/p><\/div><\/div><\/td><\/tr><tr><td><p><code>pspResult<\/code><\/p><\/td><td><p>int<\/p><\/td><td>Result denoting whether an error occurred on the PSP.\u00a0A value of 0 means no error occurred.<\/td><\/tr><tr><td><code>errorMessage<\/code><\/td><td>String<\/td><td>Reference for the transaction, used as the PSP reference is not available.<\/td><\/tr><\/tbody><\/table>","url":"https:\/\/docs.adyen.com\/pt\/point-of-sale\/classic-library-deprecation\/classic-library-integrations\/com-extension-for-windows-integration\/key-steps-com-extension\/cancel-or-refund-a-transaction-com-extension\/refund-a-transaction-from-the-ped-com","articleFields":{"id":"39944681","type":"page","_expandable":{"operations":""},"status":"current"},"algolia":{"url":"https:\/\/docs.adyen.com\/pt\/point-of-sale\/classic-library-deprecation\/classic-library-integrations\/com-extension-for-windows-integration\/key-steps-com-extension\/cancel-or-refund-a-transaction-com-extension\/refund-a-transaction-from-the-ped-com","title":"Refund a transaction from the PED","content":"Cancel or refund a transaction from the terminal transaction list, and receive a receipt on the POS or on the PED.\n\nYou can only use this cancel or refund method for transactions that:\n\nhave been completed on the PED that is receiving the cancel or refund request.\nare still within the PED storage \u2013 this is currently limited to 100 tenders.\n\n\nPedDevice Object\n\n\n\nName\nDescription\n\n\n\n\nPedDevice\nPED object that represents the terminal.\n\n\n\nMethod\nNameDescriptionCancelOrRefundCancel or refund a completed transaction from the terminal transaction list. The transaction must have been completed on the PED that is receiving the cancel or refund request, and must be still within the PED storage (this is currently limited to 100 tenders.)\nParameters\nNameTypeRequiredDescriptionmerchantAccountStringThe merchant account that is canceling the transaction and refunding the money (if applicable).tenderReferenceStringA reference to the tender provided by the PED.handleReceiptBooleanSpecifies that the POS handles and prints receipts. If omitted, it is required that the PED prints the receipt. If there is no printer unit, the transaction will fail.additionalDataObjectAdditionalDataContains key\/value pairs that can be used by the merchant to return specific additional data, in particular in the final transaction result.\nCallback\nNameDescriptionCancelOrRefundOnPedCBThe Cancel or Refund Callback returns the result of a cancellation or refund, as well as any errors.\nParameters\nNameTypeDescriptionpedObjPedDevicePED object that represents the terminal.receiptsReceiptsPasses receipts to the cash register.\u00a0Its\u00a0structure is formatted for printing.pedResultintResult denoting whether an error occurred on the PED.\u00a0A value of 0 means no error occurred.As this request is not processed on the PSP, check pedResult for errors instead of the pspResult.\u00a0libResultintResult denoting whether an error occurred in the Library. A value of 0 means no error occurred.As this request is not processed on the PSP, check libResult for errors instead of the pspResult.pspResultintResult denoting whether an error occurred on the PSP.\u00a0A value of 0 means no error occurred.errorMessageStringReference for the transaction, used as the PSP reference is not available.","type":"page","locale":"pt","boost":13,"hierarchy":{"lvl0":"Home","lvl1":"Terminais","lvl2":"Deprecation of classic libraries","lvl3":"Library integrations","lvl4":"COM extension for Windows integration","lvl5":"Key steps","lvl6":"Cancel or refund a transaction","lvl7":"Refund a transaction from the PED"},"hierarchy_url":{"lvl0":"https:\/\/docs.adyen.com\/pt","lvl1":"https:\/\/docs.adyen.com\/pt\/point-of-sale","lvl2":"https:\/\/docs.adyen.com\/pt\/point-of-sale\/classic-library-deprecation","lvl3":"https:\/\/docs.adyen.com\/pt\/point-of-sale\/classic-library-deprecation\/classic-library-integrations","lvl4":"https:\/\/docs.adyen.com\/pt\/point-of-sale\/classic-library-deprecation\/classic-library-integrations\/com-extension-for-windows-integration","lvl5":"https:\/\/docs.adyen.com\/pt\/point-of-sale\/classic-library-deprecation\/classic-library-integrations\/com-extension-for-windows-integration\/key-steps-com-extension","lvl6":"https:\/\/docs.adyen.com\/pt\/point-of-sale\/classic-library-deprecation\/classic-library-integrations\/com-extension-for-windows-integration\/key-steps-com-extension\/cancel-or-refund-a-transaction-com-extension","lvl7":"\/pt\/point-of-sale\/classic-library-deprecation\/classic-library-integrations\/com-extension-for-windows-integration\/key-steps-com-extension\/cancel-or-refund-a-transaction-com-extension\/refund-a-transaction-from-the-ped-com"},"levels":8,"category":"In-person payments","category_color":"green","tags":["Refund","transaction"]}}
