Modifying billing plans

PATCHing billing plans

Use the following endpoint to PATCH an existing billing plan:

  • PATCH /admin/v1/billing-plans/{billingPlanId}

When a billing plan is assigned to at least one account, BillingCenter considers the plan to be in use.

When a plan is not in use:

  • Its inUse field is set to false.
  • The entire plan can be modified.

When a plan is in use:

  • Its inUse field is set to true.
  • Through Cloud API, only expirationDate and planOrder can be modified.

For example, the following changes billing plan bc:101 so that lead time is calculated in business days and the plan expires on June 6, 2025.

  • If the plan is not in use, the PATCH is successful.
  • If the plan is in use, the PATCH fails because it specifies a value that is not expirationDate.
PATCH /admin/v1/billing-plans/bc:101

{
  "data": {
    "attributes": {
        "expirationDate": "2025-06-06",
        "leadTimeDayUnit": {
            "code": "business"
        }
    }
  }
}

DELETEing billing plans

Use the following endpoint to DELETE an existing billing plan:

  • DELETE /admin/v1/billing-plans/{billingPlanId}

When a billing plan is assigned to at least one account, BillingCenter considers the plan to be in use. When a plan is in use, it cannot be deleted.

For example, the following deletes billing plan bc:101 (assuming that it is not in use).

DELETE /admin/v1/billing-plans/bc:101

<no request body>