Update an existing partner-managed usage-based plan. Features + review sites are fully replaced each call (old PlanFeature/PlanReviewSite rows deleted and re-inserted).
Auth: Partner (usage-based only). Authentication group, no extra route-level route guard. updatePartnerPlan resolves the partner via getAuthPartner (403 if none); 403 unless billing_model === 'usage-based'; 404 if the plan id doesn't exist; 403 unless plan_type=usage-based AND is_admin_managed=0; 403 unless linked to the partner (planBelongsToCompany). overage_rate read-only (same as create).
Validation — identical rules as Create (same contract-model branching).
Rate limit: No rate limit.
Request
| Param | In | Type | Required | Notes |
|---|---|---|---|---|
id | path | integer | Yes | Plan ID (route [0-9]+); a usage-based plan owned by the partner. |
Body params are the same as Create plan (Usage-Based only) Create**. On update, omitted status/enforcement_mode fall back to the plan's existing values.
Response — data is the updated Plan with features + plan_review_sites.
Path params
| Parameter | Type | Required | Notes |
|---|---|---|---|
planId | integer | Required | Digits only. |
Errors: 422 on validation failure.
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
