【问题标题】:How do I obtain an Access-Token for PayPal rest api - Live server如何获取 PayPal rest api 的访问令牌 - 实时服务器
【发布时间】:2017-02-07 14:53:08
【问题描述】:

根据PayPal Developer Documentation,在进行 REST 调用时,我需要提供“访问令牌”,我无法在我的 PayPal 帐户的 PayPal 控制面板中找到它。

curl -v https://api.sandbox.paypal.com/v1/payments/payment \
  -H "Content-Type:application/json" \
  -H "Authorization: Bearer Access-Token" \
  -d '{
  "intent": "sale",
  "payer":
  {
    "payment_method": "credit_card",
    "funding_instruments": [
    {
      "credit_card":
      {
        "number": "4012888888881881",
        "type": "mastercard",
        "expire_month": 12,
        "expire_year": 2018,
        "cvv2": 111,
        "first_name": "Betsy",
        "last_name": "Buyer"
      }
    }]
  },
  "transactions": [
  {
    "amount":
    {
      "total": "7.47",
      "currency": "USD"
    },
    "description": "This is the payment transaction description."
  }]
}'

如何获取实时(非沙盒)PayPal 帐户的“访问令牌”?

【问题讨论】:

    标签: php rest paypal


    【解决方案1】:

    经过一番谷歌搜索后,我来到了这里:Developer Paypal

    希望对你有帮助。

    【讨论】:

    • 这确实有帮助。您可能需要在此处添加该页面中的一些信息以保持此答案有效,因为编辑器非常注重仅链接解决方案。我确实在之后找到了这个:developer.paypal.com/docs/api/auth-headers,这似乎更具体地针对 REST api。
    • OP 的链接已损坏。
    猜你喜欢
    • 2015-09-06
    • 2015-04-06
    • 1970-01-01
    • 2012-10-27
    • 1970-01-01
    • 2020-01-06
    • 1970-01-01
    • 2021-12-02
    • 2015-04-06
    相关资源
    最近更新 更多