Integrate our products into your software. Let's make payment happen together!
Look at all the possibilitiesThis guide will show you how to receive a CardToken with the following methods payment, token, reservation, cardValidation and repeatLastMessage
The following code snippet demonstrates how you can receive a CardToken.
ExternalTerminal externalTerminal = ExternalTerminal.builder() .. // other ExternalTerminal properties .requestToken(true/false) // true if you want to receive a CardToken (Default is false) .build();
PaymentDelegate paymentDelegate = new PaymentDelegate() { @Override public void onPaymentSuccess(PaymentResult result) { String cardToken = result.cardToken(); } .. // other PaymentDelegate methods };
TokenApi tokenService = new TokenService(); ExternalTerminal terminal = createExternalTerminal(); TokenDelegate tokenDelegate = new TokenDelegate() { @Override public void onTokenSuccess(TokenResult tokenResult) { String cardToken = tokenResult..authorisationResponse().cardToken(); } .. // other TokenDelegate methods }; tokenService.token(terminal, TokenPurpose.TRACKING, tokenDelegate);
TerminalDelegate terminalDelegate = new TerminalDelegate() { @Override public void onPaymentAdministrationSuccess(PaymentAdministrationResult result) { String cardToken = ((PaymentResult) result.result).cardToken(); } .. // other PaymentDelegate methods };