【问题标题】:i am using paypal rest api of billing plans i need to know were will the api billing plans will affect我正在使用 paypal rest api 的计费计划,我需要知道 api 计费计划是否会影响
【发布时间】:2019-03-11 00:18:57
【问题描述】:
    ##Here i used rest api##
    curl -v -X POST https://api.sandbox.paypal.com/v1/payments/billing-plans/ \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer Access-Token" \
     -d '{
      "name": "Plan with Regular and Trial Payment Definitions",
     "description": "Plan with regular and trial payment definitions.",
      "type": "FIXED",
       "payment_definitions": [
     {
      "name": "Regular payment definition",
      "type": "REGULAR",
      "frequency": "MONTH",
      "frequency_interval": "2",
      "amount": {
        "value": "100",
        "currency": "USD"
      },
      "cycles": "12",
      "charge_models": [
        {
          "type": "SHIPPING",
          "amount": {
            "value": "10",
            "currency": "USD"
          }
        },
        {
          "type": "TAX",
          "amount": {
            "value": "12",
            "currency": "USD"
          }
        }
      ]
    },
    {
      "name": "Trial payment definition",
      "type": "TRIAL",
      "frequency": "WEEK",
      "frequency_interval": "5",
      "amount": {
        "value": "9.19",
        "currency": "USD"
      },
      "cycles": "2",
      "charge_models": [
        {
          "type": "SHIPPING",
          "amount": {
            "value": "1",
            "currency": "USD"
          }
        },
        {
          "type": "TAX",
          "amount": {
            "value": "2",
            "currency": "USD"
          }
        }
      ]
    }
  ],
  "merchant_preferences": {
    "setup_fee": {
      "value": "1",
      "currency": "USD"
    },
    "return_url": "https://example.com",
    "cancel_url": "https://example.com/cancel",
    "auto_bill_amount": "YES",
    "initial_fail_amount_action": "CONTINUE",
    "max_fail_attempts": "0"
  }
}"

我得到了状态创建的成功响应,...但是当我移动到贝宝开发者帐户并检查时,..我找不到任何新的付款, 你能告诉我具体的代码是否会反映,你能帮我找到是否会反映贝宝计费计划的请求。我在上面附上了以下 api 请求...

【问题讨论】:

    标签: paypal


    【解决方案1】:

    创建计费方案后,您必须执行以下操作。

    1. 激活该计划
    2. 创建协议
    3. 获得客户认可
    4. 执行协议

    https://developer.paypal.com/docs/subscriptions/

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2017-06-21
      • 2023-03-23
      • 2015-09-09
      • 2015-01-27
      • 2014-12-15
      • 2020-04-13
      • 2015-05-23
      • 2017-02-07
      相关资源
      最近更新 更多