贝宝结帐-Platform_fee订单创建

问题描述

我按照本教程在我的市场上启用PayPal:https://developer.paypal.com/docs/business/checkout/set-up-standard-payments/

所以,我写这段代码:

<script src="https://www.paypal.com/sdk/js?client-id=xxxxxxxxxxx"></script>

createOrder: function(data,actions) {
      return actions.order.create({
        purchase_units: [{
          amount: {
            value: '{{ course.price / 100 }}',currency: 'EUR'
          },payee: {
            merchant_id: '3SBUTQHGTMHWS'
          },}],});
 },

这一项工作正常,但是当我要添加platform_fee时,PayPal返回422(不可处理实体):

createOrder: function(data,payment_instruction: {
            disbursement_mode: 'INSTANT',platform_fees: [{
              amount: {
                currency_code: 'EUR',value: '3'
              }
            }]
          },});
},

如何通过PayPal Checkout收取平台费? 谢谢您的帮助

解决方法

除非您是经过批准的PayPal合作伙伴,否则您不能使用platform_fee

相关问答

错误1:Request method ‘DELETE‘ not supported 错误还原:...
错误1:启动docker镜像时报错:Error response from daemon:...
错误1:private field ‘xxx‘ is never assigned 按Alt...
报错如下,通过源不能下载,最后警告pip需升级版本 Requirem...