feat(metadata): basic in-app purchase listing#3597
Draft
Conversation
Pull existing IAPs (productId / referenceName / type) into store.config.json and warn on push when ASC differs. Push is read-only for now because @expo/apple-utils only exposes the deprecated v1 inAppPurchases endpoint without create/update/delete; localization, pricing, deletes, and v2 are deferred follow-ups.
|
Subscribed to pull request
Generated by CodeMention |
…IAP task Add TODO block referencing expo/third-party#148 for the v2 CRUD migration (InAppPurchaseV2, InAppPurchaseLocalization). Document that auto-renewable subscriptions are a separate Apple resource (subscriptionGroups/subscriptions) and intentionally out of scope. Mark legacy v1-only type enum members as deprecated. Shorten the upload warning to reference the specific dependency. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
❌ It looks like a changelog entry is missing for this PR. Add it manually to CHANGELOG.md. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a new
InAppPurchasesTaskto EAS metadata that round-trips thebasic listing of an app's In-App Purchases (
productId,referenceName,type, plus a read-onlystate) to/fromstore.config.json.This is intentionally a thin first iteration. The goal is to give users a
declarative starting point for the IAP listing without overcommitting to
mutations the underlying API surface doesn't support yet.
Dependency: expo/third-party#148
The third-party repo has a PR (expo/third-party#148) adding:
InAppPurchaseV2model with full CRUD (getAsync,infoAsync,createAsync,updateAsync,deleteAsync)InAppPurchaseLocalizationmodel with CRUD (createAsync,updateAsync,deleteAsync,infoAsync)App.getInAppPurchasesV2Async()for sub-resource listinggetLocalizationsAsync(),createLocalizationAsync()What works now (v1 read-only)
metadata:pullreads existing IAPs via the v1App#getInAppPurchasesAsync()endpointmetadata:pushmatches config against ASC byproductIdand reports diffs (would-create / would-rename) as warnings — no mutationsWhat's blocked on apple-utils bump
InAppPurchaseV2.createAsync()/updateAsync()from expo/third-party#148InAppPurchaseLocalizationfrom expo/third-party#148; schema will need an optionallocalizationsarray per IAP entryAuto-renewable subscriptions: intentionally out of scope
Auto-renewable subscriptions are not part of the v2 IAP resource. They live
on separate
subscriptionGroups/subscriptionsendpoints. The v2InAppPurchaseV2Typeenum only hasCONSUMABLE,NON_CONSUMABLE, andNON_RENEWING_SUBSCRIPTION.Legacy v1 auto-renewable entries may still appear on
metadata:pull(the v1enum includes
AUTOMATICALLY_RENEWABLE_SUBSCRIPTION), but they cannot becreated or managed via IAP APIs. The type enum preserves these values with
@deprecatedmarkers for backward compatibility.Scope
In scope:
inAppPurchasesblock in the metadata schema typespackages/eas-cli/src/metadata/apple/tasks/in-app-purchases.tsmetadata:pullwrites the existing IAP listing tostore.config.jsonmetadata:pushmatches byproductIdagainst ASC and reports diffs without mutatingtasks/index.ts)Explicitly out of scope:
Test plan
npx jest src/metadata— 16 suites, 194 tests passing (10 new IAP tests)oxlinton changed files — cleanmetadata:pullagainst an app with IAPs and verifyinAppPurchasesinstore.config.jsonmetadata:pushafter editingreferenceNameand verify warning lists the diff without mutating ASCOpen questions / follow-ups
localizations: Record<locale, { name, description }>per IAP entry onceInAppPurchaseLocalizationis available.deleted: truemarker? Apple's flow is non-trivial.subscriptionstask forsubscriptionGroups/subscriptionsresources if there's demand.Co-Authored-By: Claude Opus 4.6 (1M context) noreply@anthropic.com