Hi there!
We have one subscription subscription_id
, within which there are two base plans base_plan_id_1
and base_plan_id_2
.
After purchasing, our application sends a fetch token to our server, which we forward to /v1/receipt/
:
1{2 "app_user_id": "$someUserId",3 "fetch_token": "$someValidFetchToken",4 "is_restore": false,5 "product_id": "subscription_id"6}7
The call is executed successfully, but in RevCat and all webhook events, it always shows that the base plan base_plan_id_1
was purchased, regardless of which actual base plan was bought.
Example:
- User buys a Monthly subscription for 0.99 - it works and is tracked correctly
- User buys a Yearly subscription for 9.99 - it’s tracked in RevenueCat as Monthly for the price of 9.99
After studying the SDK, we tried sending the following variants, but nothing changed.
- Sending
platform_product_id
:
1{2 "app_user_id": "$someUserId",3 "fetch_token": "$someValidFetchToken",4 "is_restore": false,5 "product_ids": [6 "subscription_id"7 ],8 "platform_product_ids": [9 {10 "product_id": "subscription_id",11 "base_plan_id": "base_plan_id_2"12 }13 ]14}
- Sending
platform_product_id
andpricing_phases
:
1{2 "app_user_id": "$someUserId",3 "fetch_token": "$someValidFetchToken",4 "is_restore": false,5 "product_ids": [6 "subscription_id"7 ],8 "platform_product_ids": [9 {10 "product_id": "subscription_id",11 "base_plan_id": "base_plan_id_2"12 }13 ],14 "pricing_phases": [15 {16 "billingPeriod": "P1Y",17 "billingCycleCount": null,18 "recurrenceMode": 1,19 "formattedPrice": "£58.99",20 "priceAmountMicros": "58990000",21 "priceCurrencyCode": "GBP"22 }23 ]24}