duannaoben8011 2015-08-11 23:01 采纳率: 0%
浏览 111
已采纳

如何使用相同的交易在稍后阶段向paypal信用卡付款收取小费?

I'm developing an e-commerce website using PHP and integrating paypal for processing the credit card payments. I found APIs in PHP that are used to make payments and capture transaction id but none of these discussed about adding adjustments to the amount that is captured. My use cases include: Adding tip later Adding time extension adjustments Returning only portion of the amount if order gets cancelled and few more of similar kind

May anyone tell me how this kind of a task is handled with paypal and also is there any API that will provide this functionality as well?

  • 写回答

2条回答 默认 最新

  • dongpigui8898 2015-08-12 01:16
    关注

    References Transactions would work fine to charge a separate transaction for the tip, but then the customers would see two separate charges on their credit card and you'll probably get lots of questions and confused people wondering why their card was hit twice. As obvious as it seems, I've been there.

    The best way to handle it would be to run an Authorization when you first run the card. Authorize it for something like 50% above the ticket total, or whatever you think it would take to cover the final total including a tip for that order.

    If the order is canceled for any reason you simply Void the authorization. If you're ready to actually process the funds with a final total including tip, then you can Capture the amount that you need up to the amount that you originally authorized. I believe you may even be able to capture up to 10% more than the original authorization, but I'm not 100% sure on that.

    The thing you would need to be careful about is authorizing a card for some large amount and then not voiding or capturing shortly after. The authorization is only guaranteed for 3 days. You can run a re-authorization and get an additional 3 days if you need to.

    If the order gets canceled and you don't void it then you'll get complaints that a large amount is "charged" on their account. It looks like a charge until it clears back or is voided. If you don't void it then it can take up to 29 days for them to get access to those funds on their account again, so you want to avoid those types of complaints too.

    You would need Payments Pro to handle credit cards directly for that sort of a system. Depending on which version of Pro they put you on you'll use either the PayFlow API, or you'll use variations of DoDirectPayment, DoVoid, DoCapture, DoReauthorization.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 用土力学知识进行土坡稳定性分析与挡土墙设计
  • ¥70 PlayWright在Java上连接CDP关联本地Chrome启动失败,貌似是Windows端口转发问题
  • ¥15 帮我写一个c++工程
  • ¥30 Eclipse官网打不开,官网首页进不去,显示无法访问此页面,求解决方法
  • ¥15 关于smbclient 库的使用
  • ¥15 微信小程序协议怎么写
  • ¥15 c语言怎么用printf(“\b \b”)与getch()实现黑框里写入与删除?
  • ¥20 怎么用dlib库的算法识别小麦病虫害
  • ¥15 华为ensp模拟器中S5700交换机在配置过程中老是反复重启
  • ¥15 uniapp uview http 如何实现统一的请求异常信息提示?