2016-08-14 91 views
-1

我正嘗試使用Express Checkout REST API在我的網站上銷售數字商品。使用REST API銷售數字商品

我面臨的主要問題是PayPal在訂單審覈中顯示「Ship To」。

使用REST API創建付款時,是否可以禁用或取消送貨?

我在這裏看到一個相關的問題:Selling Digital goods via REST API - 然而它已經很舊了,而且有一段時間沒有任何更新。基本上它說REST API不支持銷售數字商品。

謝謝。

回答

0

我設法創造一個體驗配置文件中禁用航運, https://developer.paypal.com/docs/api/payment-experience/

我曾經叫郵差應用程序發送POST請求到PayPal上https://api.sandbox.paypal.com/v1/payment-experience/web-profiles

有了這個JSON數據:

{ 
    "name": "AppName", 
    "presentation": { 
    "brand_name": "AppName Paypal", 
    "locale_code": "US" 
    }, 
    "input_fields": { 
    "no_shipping": 1, 
    "address_override": 1 
    }, 
    "flow_config": { 
    "landing_page_type": "login" 
    } 
} 

請注意,我使用no_shipping 1,禁用航運。我也向這個POST請求發送了Authorization Bearer令牌。

如果請求成功,那麼您將獲得新創建的體驗配置文件的標識。 創建快速結賬付款時使用該ID。

"experience_profile_id":"experience_profile_id",