Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing subscription fields #14

Merged
merged 2 commits into from
Oct 21, 2024

Conversation

dgalambos
Copy link
Contributor

AutoResumeDate, GracePeriodExpiresDate, RefundedAt, OwnershipType, and StoreTransactionID fields are missing from the Subscriptions struct fields. This PR adds them to the struct.
To maintain consistency, OwnershipType is its own type, as official documentation is (similar to PeriodType):

ownership_type | string
Enum: "PURCHASED" "FAMILY_SHARED"
How the Customer received access to this subscription:
* PURCHASED: The Customer purchased the product.
* FAMILY_SHARED: The Customer has access to the product via their family.

StoreTransactionID is not documented by RevenueCat, but is part of the response sent.

Also - minor typo fixed in Store comment. This could have been its own PR, but for a tiny single-word change in a comment, I figured it could be merged together.

Add missing fields from subscription struct: AutoResumeDate, GracePeriodExpiresDate, RefundedAt, OwnershipType, StoreTransactionID.
Also add OwnershipType type to be consistent with rest of code.
fix preexisting type in Store type comment
@dgalambos
Copy link
Contributor Author

Ping @mhemmings

@mhemmings mhemmings merged commit 7fe5fbf into mhemmings:master Oct 21, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants