根据文档,我必须在 POST 请求中发送从 Google Pay 接收并以 Base64 编码的令牌。但是银行以错误“[paymentToken] 参数的值无效”作为响应。我如何获得这个令牌?
//if you try it like this, then the answer is the same error.
PaymentMethodToken token = paymentData.getPaymentMethodToken().getToken();
//the same error
byte[] data = token.getBytes();
String base64 = Base64.encodeToString(data, Base64.DEFAULT);