I am currently using Android subscriptions in the sandbox environment. When a user makes a purchase, the initial_purchase event is received correctly. However, events such as renew, cancellation, and expiration are not being received. Is this expected behavior in the sandbox environment?
For reference, below is the webhook I received:
{
"event": {
"event_timestamp_ms": 1724862639635,
"product_id": "premium:5-monthly",
"period_type": "NORMAL",
"purchased_at_ms": 1724862633772,
"expiration_at_ms": 1724862929764,
"environment": "SANDBOX",
"entitlement_id": null,
"entitlement_ids":
"premium"
],
"presented_offering_id": "default",
"transaction_id": "GPA.3346-5354-2391-53417",
"original_transaction_id": "GPA.3346-5354-2391-53417",
"is_family_share": false,
"country_code": "KR",
"app_user_id": "671e13db-492e-4779-a39e-a9f4cd89c245",
"aliases":
"671e13db-492e-4779-a39e-a9f4cd89c245"
],
"original_app_user_id": "671e13db-492e-4779-a39e-a9f4cd89c245",
"currency": "KRW",
"price": 5.189,
"price_in_purchased_currency": 6900,
"subscriber_attributes": {
"$attConsentStatus": {
"value": "notDetermined",
"updated_at_ms": 1724559204867
}
},
"store": "PLAY_STORE",
"takehome_percentage": 0.85,
"offer_code": null,
"tax_percentage": 0.0909,
"commission_percentage": 0.1364,
"renewal_number": 1,
"type": "INITIAL_PURCHASE",
"id": "6A33D390-764E-4CA1-90F6-925E4DD6344F",
"app_id": "app9705dc3e48"
},
"api_version": "1.0"
}
subscribers api
{
"request_date": "2024-08-28T16:30:41Z",
"request_date_ms": 1724862641115,
"subscriber": {
"entitlements": {
"premium": {
"expires_date": "2024-08-28T16:35:29Z",
"grace_period_expires_date": null,
"product_identifier": "premium",
"product_plan_identifier": "5-monthly",
"purchase_date": "2024-08-28T16:30:33Z"
}
},
"first_seen": "2024-08-25T04:00:56Z",
"last_seen": "2024-08-28T16:22:22Z",
"management_url": "https://play.google.com/store/account/subscriptions",
"non_subscriptions": {},
"original_app_user_id": "671e13db-492e-4779-a39e-a9f4cd89c245",
"original_application_version": "1.0",
"original_purchase_date": "2013-08-01T07:00:00Z",
"other_purchases": {},
"subscriptions": {
"ios_monthly_subscription": {
"auto_resume_date": null,
"billing_issues_detected_at": null,
"expires_date": "2024-08-25T05:13:20Z",
"grace_period_expires_date": null,
"is_sandbox": true,
"original_purchase_date": "2024-08-25T04:13:20Z",
"ownership_type": "PURCHASED",
"period_type": "normal",
"purchase_date": "2024-08-25T05:08:20Z",
"refunded_at": null,
"store": "app_store",
"store_transaction_id": "2000000694980037",
"unsubscribe_detected_at": "2024-08-25T05:08:06Z"
},
"membership": {
"auto_resume_date": null,
"billing_issues_detected_at": null,
"expires_date": "2024-08-24T16:37:32Z",
"grace_period_expires_date": null,
"is_sandbox": true,
"original_purchase_date": "2024-08-12T17:15:11Z",
"ownership_type": "PURCHASED",
"period_type": "normal",
"purchase_date": "2024-08-24T16:32:32Z",
"refunded_at": null,
"store": "app_store",
"store_transaction_id": "2000000694851722",
"unsubscribe_detected_at": "2024-08-25T04:13:27Z"
},
"premium": {
"auto_resume_date": null,
"billing_issues_detected_at": null,
"expires_date": "2024-08-28T16:35:29Z",
"grace_period_expires_date": null,
"is_sandbox": true,
"original_purchase_date": "2024-08-28T16:30:33Z",
"period_type": "normal",
"product_plan_identifier": "5-monthly",
"purchase_date": "2024-08-28T16:30:33Z",
"refunded_at": null,
"store": "play_store",
"store_transaction_id": "GPA.3346-5354-2391-53417",
"unsubscribe_detected_at": null
}
}
}
}