Paypal IPN 交易 ID

发布于 2024-11-14 18:00:30 字数 385 浏览 4 评论 0原文

这可能是疲劳设置,但我对 IPN 事务中事务 ID 的使用有点困惑。

据我所知,PayPal 会分配一个交易 ID 并与所有其他 GUMF 一起返回 POST。然而,它还指出,单个交易可能会生成多个 IPN 消息(即,当支付状态从“待处理”变为“已确认”时)。在这种情况下,可能会收到多于一条具有相同事务 ID 的消息。

我对提供的所有示例感到困惑(由 PayPal 本身以及 PayPalTech 提供)。我见过的每个脚本都只处理通过 IPN 接收到的第一条消息 - 如果事务 ID 已经存在(特别是在将 IPN 事务写入数据库时​​),那么它实际上会被忽略。

如果是这种情况,他们是否可能会错过那些开始待处理然后变为已确认的交易?

我是否遗漏了一些东西,或者只是让事情变得比需要的更复杂?

This is probably fatigue setting in, but I am a little confused about the use of Transaction ID's in IPN transactions.

I understand that PayPal assigns a transaction ID and POSTs that back with all the other gumf. However, it also states that a single transaction may generate more than one IPN message (i.e. as the payment status moves from PENDING to CONFIRMED). In which case more then one message witht he same transaction ID may be received.

My confusion is around all the samples provided (by PayPal themselves as well as PayPalTech). Every script I have seen only processes the first message received via IPN - if the transaction ID already exists (especially when writing IPN transactions to a database), then it is effectively ignored.

If this is the case, are they not potentially missing out on those transactions which start PENDING and then become CONFIRMED?

Am I missing something or just making this more complicated than it needs to be?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

野稚 2024-11-21 18:00:31

例如,当您使用信用卡为购买提供资金时,会生成额外的交易 ID。因此,有一个 TransId 用于向 CC 收费,另一个 TransId 用于将钱发送给接收者。但接收者只看到“他的”TransId,而不是CC相关的。所以总会返回一个TransId。当交易状态更改(待处理/已确认等)时,交易 ID 不会更改。

The additional transaction ids are generated when for example you're funding the purchase using a credit card. So then there's one TransId for charging the CC, another TransId for sending the money to the receiver. But the receiver only sees "his" TransId, not the CC-related. So there will always be one TransId returned. The Transaction Id is not changed when the status of a transaction is changed (pending/confirmed, etc).

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文