Also what about cash payment, can we refund cash payment to our custom tender as well
Cash is simply another tender type, so no you won't be able to invoke another tender type to refund other than the original payment tender type. A workaround would be to refund using our tender type but within your implementation, note that cash was returned rather than credit being remitted. The issue here would be that in Reporting and Order app, the refund will still indicate your tender as the refund, regardless of whether cash or credit was given.
Handling refunds You will also need to account for all refunds on partial payments made by custom tenders. Note that the merchant can issue a LineItem-level refund using Custom tenders. First, ensure your custom tender’s Refund Activity can handle refund intents: <intent-filter> <action android:name="clover.intent.action.REFUND" /> <category android:name="android.intent.category.DEFAULT" />From your Refund Activity, capture some Extras from the Refund Intent:final long amount = getIntent().getLongExtra(Intents.EXTRA_AMOUNT, 0); final String orderId = getIntent().getStringExtra(Intents.EXTRA_ORDER_ID); final String paymentId = getIntent().getStringExtra(Intents.EXTRA_PAYMENT_ID); final ArrayList lineItemIds = getIntent().getStringArrayListExtra(Intents.EXTRA_LINE_ITEM_IDS);If the Refund POSTs successfully on your end, tell Clover everything went as planned: Intent data = new Intent(); data.putExtra(Intents.EXTRA_ORDER_ID, orderId); data.putExtra(Intents.EXTRA_PAYMENT_ID, paymentId); data.putExtra(Intents.EXTRA_LINE_ITEM_IDS, lineItemIds); data.putExtra(Intents.EXTRA_AMOUNT, amount); data.putExtra(Intents.EXTRA_CLIENT_ID, "Your_external_payment_ID"); setResult(RESULT_OK, data); finish();Else: setResult(RESULT_CANCELED, data); finish();
No one has followed this question yet.
Order Total is not updating when I created custom item with negative price from clover sdk
Ecommerce v1/refunds API returns processing_error in Sandbox
Refund of Secure Payment transaction
how to generate a customized report and make it get reflected in reporting Application?
Call custom tender directly from the app without open ACTION_SECURE_PAY