我们可以通过手动转到https://business.paypal.com/merchantdata/reportHome?reportType=DLOG并执行以下操作来下载特定日期范围内的PayPal完成付款的CSV文件:
但是如何每月自动(使用API?)获得此信息,而不必手动访问网站?
是否有API可以触发与此https://business.paypal.com/merchantdata/reportHome?reportType=DLOG页几乎相同格式的交易CSV下载?
注意:
我已经看过https://developer.paypal.com/docs/reports/payflow-reports/和https://developer.paypal.com/docs/reports/#download-reports,但看起来很复杂,也没有完整的示例(只有XML samples,但不清楚如何使用它们)
我不想为此使用IPN(我确实将其用于其他任务,但是由于其他原因,它并不完全可靠)。
所需输出示例:
"Date","Time","TimeZone","Name","Type","Status","Currency","Gross","Fee","Net","From Email Address","To Email Address","Transaction ID","Shipping Address","Address Status","Item Title","Item ID","Shipping and Handling Amount","Insurance Amount","Sales Tax","Option 1 Name","Option 1 Value","Option 2 Name","Option 2 Value","Reference Txn ID","Invoice Number","Custom Number","Quantity","Receipt ID","Balance","Address Line 1","Address Line 2/District/Neighborhood","Town/City","State/Province/Region/County/Territory/Prefecture/Republic","Zip/Postal Code","Country","Contact Phone Number","Subject","Note","Country Code","Balance Impact"
"3/1/2018","04:52:07","CET","John Doe","Website Payment","Completed","EUR","100.00","0","100","johndoe@gmail.com","contact@example.com",...
"3/1/2018","16:29:30","CET","Mike Abcd","Website Payment","Completed","EUR","100.00","0","100","mikeabc@example.com","contact@example.com",...
答案 0 :(得分:-1)
您将必须通过XML api进行操作。基本上,您通过给定的链接中的示例XML进行发布请求,但其中包含数据。响应将采用XML格式,然后您使用返回的reportId
,然后调用get report api,它将以xml返回报告数据。