调用Paypal Create agreement API如何隐藏结算页收货地址区块
要隐藏Paypal结算页的收货地址区块,你只需要将no_shipping: 1参数添加到请求体的override_merchant_preferences对象中即可。
修改后的完整请求体如下:
{ "name": "user@user.com Agreement", "description": "Essential 1 Plan - 19$ trial 7 days - 1$", "start_date": "2021-11-11T00:52:01Z", "payer": { "payment_method": "paypal" }, "plan": { "id": "P-XXXXXXXXXXXXXXXXXXXXXXXX" }, "override_merchant_preferences": { "setup_fee": { "value": 0, "currency": "USD" }, "return_url": "http://domain.local/membership/checkout/success", "cancel_url": "http://domain.local/membership/checkout/cancel", "auto_bill_amount": "YES", "initial_fail_amount_action": "CONTINUE", "max_fail_attempts": 2, "no_shipping": 1 } }
no_shipping参数支持三个取值:
0:默认值,允许买家填写收货地址1:完全隐藏收货地址区块,适配数字产品售卖场景2:显示收货地址字段,但不强制买家填写
如果配置后依旧不生效,可以检查你关联的订阅Plan本身的全局商户偏好配置,避免全局配置覆盖了本次请求的覆盖参数。

内容的提问来源于stack exchange,提问作者Vanya Avchyan
相关产品推荐
相关产品推荐

