【问题标题】:Hide shipping address in Paypal checkout REST API在 Paypal 结帐 REST API 中隐藏送货地址
【发布时间】:2019-04-01 05:45:59
【问题描述】:

我在我的页面上使用来自 Paypal 的当前 REST API。但我无法在 Paypal 上隐藏运输信息。我不想让我的客户选择更改 Paypal 中的地址。

    payment: function(data, actions) {
  return actions.payment.create({
    transactions: [{
      amount: {
        total: '<? print(number_format($got_daten["bestellwert"],2,".","")); ?>',
        currency: 'EUR',
        details: {
            subtotal: '<? print(number_format($got_daten["bestellwert_slim"],2,".","")); ?>',
            shipping: '<? print(number_format($got_daten["orderVersandkosten"],2,".","")); ?>'
        }
      },
    description: 'Krusenhof Etteln - Onlinebestellung',
    custom: 'Bestellung: <? print($got_daten["orderID"]); ?>',
    }],
note_to_payer: 'Rufen Sie uns an bei Fragen! Ihr Krusenhof Etteln'
  });
},

如何添加隐藏选项(不发货)?

所有文档都是旧版本的,不再有效。

谢谢 标记

【问题讨论】:

    标签: paypal checkout shipping


    【解决方案1】:

    您可以使用Payment Experience API 做到这一点。看看example here。它显示正在使用 no_shipping。

    curl -v -X \
      POST https://api.sandbox.paypal.com/v1/payment-experience/web-profiles/ \
      -H "Content-Type: application/json" \
      -H "Authorization: Bearer Access-Token" \
      -d '{
      "name": "ebayProfile",
      "presentation":
      {
        "logo_image": "https://www.paypal.com"
      },
      "input_fields":
      {
        "no_shipping": 1,
        "address_override": 1
      },
      "flow_config":
      {
        "landing_page_type": "billing",
        "bank_txn_pending_url": "https://www.paypal.com"
      }
    }'
    

    【讨论】:

      猜你喜欢
      • 2014-02-11
      • 1970-01-01
      • 2015-02-17
      • 2013-09-02
      • 2011-09-23
      • 2013-10-09
      • 2015-10-05
      • 2014-12-06
      • 2015-01-18
      相关资源
      最近更新 更多