Update plan pricing

Update pricing for the subscription plan

DocsCurrentLast updated: August 19th 2021, @ 12:09:28 pm


You can modify subscription pricing for all subscribers at once by changing the pricing at the plan level, without needing to migrate subscriptions individually.

Use case

Merchant providing video streaming service offering a basic plan priced at $5 per month needs to update it to $7 per month for future payment cycles for all existing subscribers enrolled on the plan.

How it works

When you update the plan price, here's how the changes affect subscribers:

  • Future subscribers see the latest price.

  • Existing subscribers are billed the new price only after a 10-day prior email pre-notification. Billing cycles within ten days of the price change are not changed until the next billing cycle.

    For example, you update the plan price from $20 to $25 on the 10th of the month. An existing subscriber is enrolled on this plan with the next billing cycle starting on the 15th of the month. This subscriber pays $20 for their subscription on the 15th of the month, and on the following month pays $25.

Update pricing

API endpoint used: Update pricing schemes endpoint

Sample request

curl -v -X POST https://api-m.sandbox.paypal.com/v1/billing/plans/P-7GL4271244454362WXNWU5NQ/update-pricing-schemes \
-H "Content-Type: application/json" \
-H "Authorization: Bearer Access-Token" \
-d '{
  "pricing_schemes": [
    {
      "billing_cycle_sequence": 1,
      "pricing_scheme": {
        "fixed_price": {
          "value": "50",
          "currency_code": "USD"
        },
        "roll_out_strategy": {
          "effective_time": "2019-02-10T21:20:49Z",
          "process_change_from": "NEXT_PAYMENT"
        }
      }
    },
    {
      "billing_cycle_sequence": 2,
      "pricing_scheme": {
        "fixed_price": {
          "value": "100",
          "currency_code": "USD"
        },
        "pricing_model": "VOLUME",
        "tiers": [
          {
            "starting_quantity": "1",
            "ending_quantity": "1000",
            "amount": {
              "value": "150",
              "currency_code": "USD"
            }
          },
          {
            "starting_quantity": "1001",
            "amount": {
              "value": "250",
              "currency_code": "USD"
            }
          }
        ],
        "roll_out_strategy": {
          "effective_time": "2019-02-10T21:20:49Z",
          "process_change_from": "NEXT_PAYMENT"
        }
      }
    }
  ]
}'

Modify the code

  • Access-Token - replace <Access-Token> with your access token.
  • Subscription ID - In the URI for the API call, replace the sample ID with the ID for the subscription you want to update. In this example, the subscription ID is I-BW452GLLEP1G.