/revenuecat-play-billing:rc-payment-recoveryfrom revenuecat-play-billing
Handles failed subscription renewals on Android with RevenueCat. Covers grace period and account hold states, CustomerInfo signals, and triggering Google's in-app messaging.
Ships in revenuecat-play-billing. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Failed renewals on Google Play move a subscription through two states: grace period (user keeps access while Google retries the card) and account hold (access revoked until the user fixes the payment method). With RevenueCat, both states land in CustomerInfo automatically, and Google's in app message shows by default.
A failed renewal leads to one of these states:
| State | Access | How RevenueCat surfaces it | User sees |
|---|---|---|---|
| Grace period | Retained | entitlement.isActive == true and billingIssueDetectedAt != null | Google in app snackbar by default |
| Account hold | Revoked | entitlement.isActive == false and billingIssueDetectedAt != null | Google in app snackbar by default |
| Expired without recovery | Revoked | Can look like account hold: the SDK documents billingIssueDetectedAt as null when there is no issue or it was resolved, so it can stay set after the subscription ends | Your account hold screen and its paywall path |
| Recovered | Retained | billingIssueDetectedAt == null | Nothing |
Two signals matter in the SDK:
EntitlementInfo.billingIssueDetectedAt is non null from the moment Google reports a billing problem until the user resolves it.EntitlementInfo.isActive tells you whether they still have access.On the backend, one BILLING_ISSUE webhook (plus a CANCELLATION with cancel_reason BILLING_ERROR) fires when the failure is first detected; account hold does not send another BILLING_ISSUE. When the grace period ends without recovery and the subscription enters account hold, RevenueCat sends EXPIRATION (expiration_reason BILLING_ERROR); a later recovery, during grace or hold, sends RENEWAL. You do not decode RTDNs.
Before you write app code, decide what you actually need. Most apps need none.
Ask:
showInAppMessagesIfNeeded (for InAppMessageType.BILLING_ISSUES) each time an Activity starts.billingIssueDetectedAt from CustomerInfo and branch on isActive.showInAppMessagesIfNeeded(activity) yourself.BILLING_ISSUE webhook. No app code required.If you only want the default behavior, stop here.
Leave automatic in app messages on. This is the default:
PurchasesConfiguration.Builder(context, apiKey)
.showInAppMessagesAutomatically(true)
.build()
Disable the automatic call and show the message from your chosen activity:
PurchasesConfiguration.Builder(context, apiKey)
.showInAppMessagesAutomatically(false)
.build()
Purchases.sharedInstance.showInAppMessagesIfNeeded(activity)
Read the entitlement and branch on both flags:
val entitlement = customerInfo.entitlements["pro_access"]
when {
entitlement == null -> showSubscribeScreen()
entitlement.billingIssueDetectedAt != null && entitlement.isActive -> showGracePeriodWarning()
entitlement.billingIssueDetectedAt != null -> showAccountHoldScreen()
!entitlement.isActive -> showSubscribeScreen()
else -> showPremiumContent()
}
The showAccountHoldScreen() branch also catches a subscription that expired without recovery, because billingIssueDetectedAt can stay set after it ends. The screen cannot tell the two apart, so offer both actions: fixing the payment method, which restores a subscription on hold, and a path to the paywall, the only way back after that expiry.
Send the user to Google Play's subscription page with Purchases.sharedInstance.showManageSubscriptions(activity) (SDK 10.18.0+). It uses managementURL when present and otherwise opens Google Play's subscriptions page, which covers account hold, where managementURL is null.
Purchases.sharedInstance.showManageSubscriptions(activity)
Test each transition:
entitlement.billingIssueDetectedAt becomes non null and isActive stays true.isActive flips to false while billingIssueDetectedAt remains non null.billingIssueDetectedAt returns to null.BILLING_ISSUE webhook fires on the first transition.What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub revenuecat/ai-toolkit --plugin revenuecat-play-billing20 skills in this plugin
/rc-alternative-billingUse this skill when scoping Google Play alternative billing work with RevenueCat Android SDK 11.x. Documents the support status as of purchases-android 11.1.0, which flows RevenueCat abstracts, and which require direct integration./rc-backendUse this skill when your backend needs to read or update RevenueCat state on Android. Covers the RevenueCat REST API (v1 subscribers endpoint, grant/revoke entitlements, attributes), secret vs public SDK API key usage, and why you do not build a receipt verification backend with RevenueCat./rc-cancellations-pauses-winbackOther plugins' skills for the same job