feat(gql,google): add BillingClient 5.0+ and 7.0+ fields#78
Conversation
Android BillingClient enhancements: - purchaseOptionId on ProductAndroidOneTimePurchaseOfferDetail (7.0+) - InstallmentPlanDetailsAndroid type for subscription installments (7.0+) - installmentPlanDetails on ProductSubscriptionAndroidOfferDetails - PendingPurchaseUpdateAndroid for subscription upgrades/downgrades (5.0+) - pendingPurchaseUpdateAndroid on PurchaseAndroid Standardized offer types: - purchaseOptionIdAndroid on DiscountOffer - installmentPlanDetailsAndroid on SubscriptionOffer Closes #77 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Regenerate TypeScript, Swift, Kotlin, Dart, GDScript types from updated GraphQL schema with BillingClient 5.0+ and 7.0+ fields. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
BillingConverters: - Extract purchaseOptionId from OneTimePurchaseOfferDetails (7.0+) - Extract installmentPlanDetails from SubscriptionOfferDetails (7.0+) - Extract pendingPurchaseUpdate from Purchase (5.0+) Types.kt: - Add purchaseOptionIdAndroid to DiscountOffer - Add installmentPlanDetailsAndroid to SubscriptionOffer - Add pendingPurchaseUpdateAndroid to PurchaseAndroid Tests: - Add comprehensive tests for all new fields - Test toJson/fromJson serialization - Test use cases like subscription downgrades Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Release notes (notes.tsx): - Add v1.3.17 release entry for Android BillingClient Enhancement - Convert all References sections to accordion format - Add proper ul indentation for numbered headings Type documentation: - Add purchaseOptionIdAndroid to DiscountOffer (offer.tsx) - Add installmentPlanDetailsAndroid to SubscriptionOffer (offer.tsx) - Add pendingPurchaseUpdateAndroid to PurchaseAndroid (purchase.tsx) - Add PendingPurchaseUpdateAndroid type section (purchase.tsx) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add debug/run configurations: - GQL: Generate Types - Docs: Dev Server - Test: Apple (Swift) - Test: Google (Android) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
📝 WalkthroughWalkthroughThis PR introduces Android-specific support for installment plan details, purchase option identification, and pending purchase updates across multiple packages. New fields are added to Swift, Kotlin, and TypeScript models, GraphQL schemas are extended, and comprehensive documentation is provided across all supported languages. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Suggested labels
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
No actionable comments were generated in the recent review. 🎉 Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary of ChangesHello @hyochan, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly expands the Android billing capabilities by integrating support for several new features from Google Play Billing Library versions 5.0 and 7.0. It introduces fields for identifying specific purchase options in one-time purchases, detailing installment plans for subscriptions, and tracking pending subscription changes like upgrades or downgrades. These additions ensure the system can accurately capture and process more granular billing information, improving the overall robustness and feature parity with the latest Android billing APIs. Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request introduces support for new fields from Google Play Billing Library versions 5.0+ and 7.0+, specifically purchaseOptionId, InstallmentPlanDetailsAndroid, and PendingPurchaseUpdateAndroid. The changes are comprehensive, spanning GraphQL schemas, generated types for multiple languages, the native Android implementation, and documentation. The new functionality is also well-covered by unit tests. The code quality is high, and I have just one suggestion for a minor refactoring to improve maintainability by reducing code duplication.
## Summary - Sync with OpenIAP v1.3.17 - Add InstallmentPlanDetailsAndroid type (Billing Library 7.0+) - Add PendingPurchaseUpdateAndroid type (Billing Library 5.0+) - Add purchaseOptionIdAndroid field to DiscountOffer (Billing Library 7.0+) - Add tests for new types - Update llms.txt with new type documentation - Add release blog post ## Related - OpenIAP PR: hyodotdev/openiap#78 - OpenIAP Release Notes: https://www.openiap.dev/docs/updates/notes#gql-1-3-17-google-1-3-28 ## OpenIAP Versions | Package | Version | |---------|---------| | openiap-gql | 1.3.17 | | openiap-google | 1.3.28 | | openiap-apple | 1.3.14 | 🤖 Generated with [Claude Code](https://claude.ai/claude-code) --------- Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
## Summary - Sync with OpenIAP v1.3.17 - Add InstallmentPlanDetailsAndroid data class (Billing Library 7.0+) - Add PendingPurchaseUpdateAndroid data class (Billing Library 5.0+) - Add purchaseOptionIdAndroid field to DiscountOffer (Billing Library 7.0+) - Update llms.txt with new type documentation - Add release blog post ## Related - OpenIAP PR: hyodotdev/openiap#78 - OpenIAP Release Notes: https://www.openiap.dev/docs/updates/notes#gql-1-3-17-google-1-3-28 ## OpenIAP Versions | Package | Version | |---------|---------| | openiap-gql | 1.3.17 | | openiap-google | 1.3.28 | | openiap-apple | 1.3.14 | 🤖 Generated with [Claude Code](https://claude.ai/claude-code) Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
## Summary - Sync with OpenIAP v1.3.17 - Add InstallmentPlanDetailsAndroid class (Billing Library 7.0+) - Add PendingPurchaseUpdateAndroid class (Billing Library 5.0+) - Add purchaseOptionIdAndroid field to DiscountOffer (Billing Library 7.0+) - Update llms.txt with new type documentation - Add release blog post ## Related - OpenIAP PR: hyodotdev/openiap#78 - OpenIAP Release Notes: https://www.openiap.dev/docs/updates/notes#gql-1-3-17-google-1-3-28 ## OpenIAP Versions | Package | Version | |---------|---------| | openiap-gql | 1.3.17 | | openiap-google | 1.3.28 | | openiap-apple | 1.3.14 | 🤖 Generated with [Claude Code](https://claude.ai/claude-code) --------- Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
## Summary - Sync with OpenIAP v1.3.17 - Add InstallmentPlanDetailsAndroid class (Billing Library 7.0+) - Add PendingPurchaseUpdateAndroid class (Billing Library 5.0+) - Add purchase_option_id_android field to DiscountOffer (Billing Library 7.0+) - Update llms.txt with new type documentation - Add release blog post ## Related - OpenIAP PR: hyodotdev/openiap#78 - OpenIAP Release Notes: https://www.openiap.dev/docs/updates/notes#gql-1-3-17-google-1-3-28 ## OpenIAP Versions | Package | Version | |---------|---------| | openiap-gql | 1.3.17 | | openiap-google | 1.3.28 | | openiap-apple | 1.3.14 | 🤖 Generated with [Claude Code](https://claude.ai/claude-code) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added support for Google Play Billing Library 7.0+ features including installment payment plans and purchase option identification * Enhanced support for pending purchase updates (Billing Library 5.0+) * Improved data structure initialization across Android and iOS in-app purchases * **Documentation** * Added v1.2.4 release notes documenting new billing library feature support * **Chores** * Updated dependency versions for improved compatibility <!-- end of auto-generated comment: release notes by coderabbit.ai --> Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Summary
purchaseOptionIdfor one-time purchase offers (BillingClient 7.0+)InstallmentPlanDetailsAndroidfor subscription installment plans (BillingClient 7.0+)PendingPurchaseUpdateAndroidfor subscription upgrades/downgrades (BillingClient 5.0+)Closes #77
Changes
GraphQL Schema (packages/gql)
purchaseOptionIdonProductAndroidOneTimePurchaseOfferDetailInstallmentPlanDetailsAndroidtype withcommitmentPaymentsCountandsubsequentCommitmentPaymentsCountinstallmentPlanDetailsonProductSubscriptionAndroidOfferDetailsPendingPurchaseUpdateAndroidtype withproductsandpurchaseTokenpendingPurchaseUpdateAndroidonPurchaseAndroidStandardized Offer Types
purchaseOptionIdAndroidonDiscountOfferinstallmentPlanDetailsAndroidonSubscriptionOfferAndroid (packages/google)
BillingConverters.ktTypes.ktStandardizedOfferTypesTest.ktDocumentation (packages/docs)
Test plan
bun run typecheck(docs)🤖 Generated with Claude Code
Summary by CodeRabbit
Release Notes
New Features
Documentation
Tests