在 Paypal 中,什么可以保护买家在结账时从他们的账户中扣除正确的金额?

In Paypal, what protects the buyer that the correct amount will be charged to their account during checkout?

我正在使用 Braintree SDK 在 PayPal 沙箱中测试我的代码。 我可以在客户端设置一个数量,例如10 美元,客户可以继续结帐流程。

但是在服务器端,收到"nonce"代码后,我可以向客户端收取200美元并且没有错误或验证。

如果开发商决定收取比结账时所说的多的费用,如何保护买家免于多付?

在客户端,我将意向选项发送给 "authorize",但如果我愿意,我仍然可以向买家多收钱。

客户端代码

 paypal.Button.render({
     braintree: braintree,
                  client: {

                    sandbox: '{{$btClientToken}}'
                  },
                  env: 'sandbox',
                  commit: true, 

                  payment: function (data, actions) {
                    return actions.braintree.create({
                      flow: 'checkout', // Required
                      intent:'authorize',
                      amount: '10', // Required
                      currency: 'USD', // Required
                      displayName: 'test dispaly name',
                      description: 'test description',
                      lineItems:[
                        {
                            quantity:'1',
                            unitAmount:'10',
                            totalAmount: '10',
                            name:'line item test',
                            description:'test description',
                            kind:'debit'
                        }

                      ]
                    });

                  },
                   onAuthorize: function (payload) {

                    console.log(payload);

                    $.ajax({
                        method:'POST',
                        data:{
                            _token: '{{ csrf_token() }}',
                            payment_method_nonce: payload.nonce,
                            uid: '{{$uid}}',
                            order_id:payload.orderID,
                            payer_id:payload.payerID,
                            payment_token: payload.paymentToken
                        },
                        url:'{{url("cart/order/nonce")}}'

                    }).done((reply)=>{

                        console.log(reply);
                    });
                  },

                }, '#paypal-pay');

服务器端代码

$result = $gateway->transaction()->sale([
   'amount' => '200.00',
   'paymentMethodNonce' => $nonce,
       'descriptor' => [
          'name' => 'company name*myurl.com'
      ],
      'options' => [
        'submitForSettlement' => True,
        "paypal" => [
            "description" => $order->title
        ],
      ],
      'lineItems' => [
            [
                  'description' => 'TEST DESCRIPTION',
                  'name'        => 'TEST NAME',
                  'quantity'    => '1',
                  'unitAmount'  => '200.00',
                  'totalAmount' => '200.00',
                  'kind'        => 'debit'
            ]

      ]
    ]);

我在卖家控制面板中收到了一笔成功的交易,金额为 200 美元。

如果您错误地向消费者收费,大多数消费者保护法都允许消费者向您追回他们的钱,如果您系统地这样做,贸易标准机构可以对您采取行动。

PayPal 本身也会通过买家保护保证提供保护,这意味着如果商家不自行退款,消费者可以直接从 PayPal 取回他们的钱。

编辑

@Grumpy 提出了一个很好的观点,PayPal 很可能会在几次交易后阻止或禁止您的帐户。