Skip to content

Support Configuring the SDK with the Galaxy Store#2905

Merged
fire-at-will merged 11 commits into
samsung-devfrom
configure-galaxy-sdk
Dec 9, 2025
Merged

Support Configuring the SDK with the Galaxy Store#2905
fire-at-will merged 11 commits into
samsung-devfrom
configure-galaxy-sdk

Conversation

@fire-at-will

@fire-at-will fire-at-will commented Dec 8, 2025

Copy link
Copy Markdown
Contributor

Description

This PR creates a new module for the Galaxy Store, and allows developers to set up the Android SDK to use the Galaxy Store when they configure the SDK, like so:

val configuration = GalaxyConfiguration.Builder(
     context,
     apiKey,
     GalaxyBillingMode.PRODUCTION,
).build()

Purchases.configure(configuration)

It also:

  • Introduces GalaxyBillingMode, an enum required when configuring the SDK to use the Galaxy Store, which determines the environment that the Galaxy Store processes IAPs with (prod, test, etc.).
  • When a Galaxy configuration is used, BillingFactory will wire up a GalaxyBillingWrapper
  • Adds unit tests :)

@fire-at-will fire-at-will added the pr:feat A new feature label Dec 8, 2025
@fire-at-will fire-at-will changed the base branch from main to samsung-dev December 8, 2025 18:56
@codecov

codecov Bot commented Dec 8, 2025

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 76.19048% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 78.37%. Comparing base (4364b68) to head (5e86405).

Files with missing lines Patch % Lines
.../kotlin/com/revenuecat/purchases/BillingFactory.kt 57.14% 3 Missing ⚠️
...com/revenuecat/purchases/PurchasesConfiguration.kt 77.77% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##           samsung-dev    #2905   +/-   ##
============================================
  Coverage        78.36%   78.37%           
============================================
  Files              335      336    +1     
  Lines            12931    12952   +21     
  Branches          1751     1752    +1     
============================================
+ Hits             10134    10151   +17     
- Misses            2062     2065    +3     
- Partials           735      736    +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@fire-at-will fire-at-will marked this pull request as ready for review December 8, 2025 19:50
@fire-at-will fire-at-will requested a review from a team as a code owner December 8, 2025 19:50
@fire-at-will fire-at-will changed the title Configure galaxy sdk Support Configuring the SDK with the Galaxy Store Dec 8, 2025

@tonidero tonidero left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking nice! Just some questions

Comment thread feature/galaxy/build.gradle.kts
Comment thread feature/galaxy/consumer-rules.pro Outdated
@@ -0,0 +1,4 @@
-dontwarn com.samsung.**
-keep class com.samsung.** {*;}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just to check, are these rules recommended by samsung? Since this basically keeps everything which is not a great practice (though we also need to clean this up 😅 )

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I haven't seen this recommended by samsung - I copied this over directly from our Amazon module and replaced amazon with samsung. Do you think we should remove this?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unless we have a reason to disable obfuscated of those classes, I would say yes, let's remove this 👍

@fire-at-will fire-at-will requested a review from tonidero December 9, 2025 13:50
* Holds parameters to initialize the SDK for the Galaxy Store. Create an instance of this class using the [Builder]
* and pass it to [Purchases.configure].
*/
public final class GalaxyConfiguration extends PurchasesConfiguration {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we add API tests for this as well? Alternatively, we could mark these public APIs as experimental, but since we're merging to an integration branch, I think it's ok to add that later only if needed.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll add some API tests! As for marking them as experimental, I think the plan is to not do that for now, keep merging into the dev branch, and then create a beta release for the first few customers who use the Galaxy store.

@tonidero tonidero left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! I think only removing the proguard rules for now, and we can readd them later if we think it's needed.

@fire-at-will fire-at-will merged commit 85ef92c into samsung-dev Dec 9, 2025
21 checks passed
@fire-at-will fire-at-will deleted the configure-galaxy-sdk branch December 9, 2025 14:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr:feat A new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants