Batch-edit a draft's prices
Apply a batch add/remove/replace price diff to a draft version’s own current slots. The version must be a draft. An empty diff is a no-op.
Authorizations
API key authentication
Headers
Optional optimistic-concurrency precondition — the draft version's updatedAt timestamp as read from a prior GET. If present and it no longer matches the version's current updatedAt, the request is rejected with 412 (draft_modified). Omit to skip the check.
Path Parameters
Unique identifier for a plan
^plan_[a-zA-Z0-9]+$The version number within the plan (1-based).
x >= 1Body
A batch reference-by-id price diff applied to a draft version's own current slots. Every id references an existing price created via POST /prices; inline price definitions are not accepted. An empty diff is a no-op.
Prices to add to the draft. Each must not already be on the draft's current slots.
Unique identifier for a price
^price_[a-zA-Z0-9]+$Prices to remove. Each must be on the draft's current slots.
Unique identifier for a price
^price_[a-zA-Z0-9]+$Prices to swap in place, preserving the slot's lineage. replacesPriceId must be on the draft's current slots; withPriceId is the new price.
Response
The updated draft version
A single plan version, including its price slots. Extends the list summary with the version's prices for draft review.
Unique identifier for a plan version
^pver_[a-zA-Z0-9]+$plan_version Monotonic version number within the plan, starting at 1.
x >= 1Lifecycle status of the version.
draft, published, archived Whether this version is the plan's current default (live) version.
Number of committed-status subscriptions pinned to this version at creation time. Not a live-billing cohort.
x >= 0When this version was last modified. Optimistic-concurrency token: read this value and echo it back as an If-Match header on a draft-price-mutation request to reject the write (412) if the draft changed since this read.
The price slots that make up this version.
When this version was published. Absent for draft versions.
The version this one was cloned from at mint time. Absent for versions minted before this field existed or through the legacy fused write path. Used to detect a superseded base when moving the default.
^pver_[a-zA-Z0-9]+$