我创建了测试帐户和 API 密钥。但我无法在这个 java 代码中匹配它们:
public void testProductsList() throws Exception
{
Twocheckout.apiusername = "901328163";
Twocheckout.apipassword = "B1536FC3-18AB-4289-BD25-2C84906345A8";
Twocheckout.privatekey = "81DBF3E3-04B3-47DB-8068-ED7DAB20BC5A";
Twocheckout.mode = "sandbox";
HashMap<String, String> params = new HashMap<String, String>();
ProductList result = TwocheckoutProduct.list(params);
Product[] products = result.getProducts();
System.out.println(Arrays.toString(products));
}
我总是得到 com.twocheckout.TwocheckoutException: Authentication failed
你能给点建议吗?