Skip to main content

Rentiva v4.32.0 — Manage your subscription from the plugin

· 3 min read
MaxHandMade
Maintainer

The License page now has a Manage Subscription button that opens the Polar customer portal in a new tab. Cancel auto-renewal, update your card, switch plans, or resubscribe — all without leaving WordPress admin.

What changed

Inside the License Management section (visible when a license is active), you'll now see three buttons:

  1. Manage Subscription — opens Polar customer portal (this release)
  2. Re-validate Now (v4.31.2)
  3. Deactivate License

The new button reaches Polar through the same license server already in use. No new external services contacted from your site's perspective. Schema and signature integrity remain RSA-protected (v4.30.0+ pipeline).

State-driven emphasis

The button changes color based on how close your subscription is to renewal:

Days remainingColorIntent
> 30Standard primary blue"Plenty of runway"
≤ 30Yellow"Heads up — renewal is coming"
≤ 7Amber + glow"Decide now"
Expired (0)Amber + glow"Resubscribe to keep Pro"

Customers always see how close their renewal is at a glance, regardless of whether they read the email reminders.

Failure handling

If the portal session can't be minted (server error, network blip, license revoked between page load and click), the admin lands back on the License page with a customer-friendly translated warning:

ℹ️ Subscription management is not available right now (service unavailable). Please try again later or contact support@wpalemi.com.

Five reason codes are mapped to short Turkish labels via get_manage_unavailable_label() — no raw technical strings ever leak to end users.

Architecture

  • New public method LicenseManager::createCustomerPortalSession(string $return_url): array
  • New admin-post handler LicenseAdmin::handle_manage_subscription() — capability + nonce gated
  • New CSS file additions in assets/css/admin/license-admin.css, cache-busted via filemtime
  • 9 new translatable strings, all translated to Turkish

Compatibility

ComponentRequired version
mhm-license-serverv1.11.0+ (new /customer-portal-session endpoint)
mhm-polar-bridgev1.9.0+ (renewal reminder cron)
WordPress6.7+
PHP8.1+

Older license-server versions without the customer-portal endpoint return a graceful manage_unavailable notice instead of breaking — customers see a translated warning, not a broken redirect.

Out of scope (not in this release)

  • Past-due / dunning notifications — Polar handles these directly via email.
  • Yearly subscription renewal reminders — Polar sends these 7 days before renewal automatically.

Monthly subscribers receive an additional 7-day-out reminder email from mhm-polar-bridge v1.9.0+, since Polar doesn't generate these for short billing cycles.

Tests

  • 793 → 807 PHPUnit (+14 new across 3 test files)
  • PHPCS: 0 errors
  • i18n: 0 fuzzy on new strings, all 9 translated