简体   繁体   English

使用Paypal定期付款的IPN

[英]IPN with Paypal recurring payments

我正在尝试设置带有定期付款和IPN通知的订阅系统,但我读到无法通过API设置notify_url。

The CreateRecurringPaymentsProfile request doesn't by itself seem to do the actual recurring transactions,except for the "INITAMT" which you may set (any amount to be charged immediately upon profile creation, say a "set up fee" or something). CreateRecurringPaymentsProfile请求本身似乎并不执行实际的重复交易,但您可以设置“ INITAMT”(在配置文件创建后立即收取的任何金额,例如“设置费用”之类的东西)除外。 If it does I think there should not be something like this Recurring Payments With Direct Payment for instance. 如果确实如此,我认为就不应该有这种直接付款的定期付款方式

The DoDirectPayment request allows a RECURRING parameter and this requires the "recurring payment profile be already created" (using the CreateRecurringPaymentsProfile request) . DoDirectPayment请求允许使用RECURRING参数,这需要“已创建重复付款配置文件”(使用CreateRecurringPaymentsProfile请求)。 DoDirectPayment also allows NOTIFYURL parameter . DoDirectPayment还允许使用NOTIFYURL参数。

So the IPN should be returning all that is applicable for recurring payments. 因此,IPN应该退还所有适用于定期付款的内容。 See IPN recurring payment variables - ones that are related to "recurring payment profile creation". 请参阅IPN定期付款变量 -与“定期付款资料创建”相关的变量 You could identify this matching the "PROFILEREFERENCE" param you set with CreateRecurringPaymentsProfile against "rp_invoice_id" in the IPN . 您可以针对IPN中的“ rp_invoice_id”,将与CreateRecurringPaymentsProfile设置的“ PROFILEREFERENCE”参数相匹配。

IPN subscription variables - ones that are related to the first and following subscription payments. IPN订阅变量 -与第一次和之后的订阅付款相关的变量 You could identify this matching the "INVNUM" you set with DoDirectPayment against the "invoice" in the IPN . 您可以根据IPN中的“发票”来识别与通过DoDirectPayment设置的“ INVNUM”相匹配的内容。 It also returns "payment_date" and "payment_status" . 它还返回“ payment_date”和“ payment_status”。

I haven't tested this though. 我还没有测试过。

Unfortunately you are right. 不幸的是你是对的。 There is no way to send notify url with CreateRecurringPaymentsProfile. 无法使用CreateRecurringPaymentsProfile发送通知URL。 The only way to set it is to set it in IPN settings in paypal, but of course you won't be able to make different urls for different subscriptions. 设置它的唯一方法是在Paypal的IPN设置中进行设置,但是您当然无法为不同的订阅创建不同的url。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM