Send logs request

The client app must implement a mechanism to send messages using Android intents and URI calls and to receive the result in a custom URI callback.

Send logs request

With the send logs action the user can trigger the application to upload the application logs.

Field Description Example Card terminal support
scheme The Viva's custom URL scheme, the host and the version. 'vivapayclient://pay/v1' Viva Wallet POS app for AndroidViva Wallet POS app for Android
merchantKey The merchant's key. For successful validation, should not be empty.
Deprecated: you may pass any value
'SG23323424EXS3' Viva Wallet POS app for AndroidViva Wallet POS app for Android
appId The client app ID. For successful validation, should not be empty. 'com.example.myapp' Viva Wallet POS app for AndroidViva Wallet POS app for Android
action Cancel transaction. For successful validation, should not be empty. 'sendLogs' Viva Wallet POS app for AndroidViva Wallet POS app for Android
callback The URI callback that will handle the result. For successful validation, should not be empty. 'mycallbackscheme://result' Viva Wallet POS app for AndroidViva Wallet POS app for Android

The above information elements must create a URI call, i.e.

Intent payIntent = new Intent(Intent.ACTION_VIEW, Uri.parse( "vivapayclient://pay/v1"
			+ "?merchantKey=MY_MERCHANT_KEY"
			+ "&appId=com.example.myapp"
			+ "&action=sendLogs"
			+ "&referenceNumber=123456"
			+ "&callback=mycallbackscheme://result"));


payIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
payIntent.addFlags(Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS);
startActivity(payIntent);

Send logs response

After executing an abort transaction, the Card Terminal App responds with an abort response result to indicate if the abort request has been successful or not. It should be noted that the response from the abort action is actually the response of a failed transaction.

The result is received as a URI in the callback activity intent:

Uri result = getIntent().getData();

The table below summarizes the contents of a successful response:

Field Description Example Card terminal support
callback The URI callback that will handle the result. 'mycallbackscheme://result' Viva Wallet POS app for AndroidViva Wallet POS app for Android
status The status of the transaction. 'success' Viva Wallet POS app for AndroidViva Wallet POS app for Android
message A string containing information about the transaction status. 'Send Logs completed' Viva Wallet POS app for AndroidViva Wallet POS app for Android
action Cancel transaction. 'sendLogs' Viva Wallet POS app for AndroidViva Wallet POS app for Android

A send logs response result looks as follows:

mycallbackscheme://result?status=success&message=Send Logs completed&action=sendLogs

Get Support

If you have any questions about our solutions, or questions about how to integrate with our solutions, please refer to our Get Support page.