Webhooks
App Store and Google Play webhook events handled by Nuxie
Webhooks
Nuxie processes webhooks from App Store Connect and Google Play to keep subscription state in sync. Configure webhook URLs in your payment processor settings to enable automatic entitlement updates, subscription tracking, and revenue analytics.
Webhook URLs
Find your webhook URLs in the dashboard under Settings > Apps > [Your App]. Each app has separate URLs for test and live environments:
Replace {env} with test or live depending on the environment.
Tip: Configure your test environment webhooks first. Use the App Store sandbox or Google Play license testing to verify everything works before going live.
App Store server notifications
Setup
- Open App Store Connect > App > App Information.
- Scroll to App Store Server Notifications.
- Set the Production Server URL to your live webhook URL.
- Set the Sandbox Server URL to your test webhook URL.
- Select Version 2 for the notification format.
Notification verification
Nuxie validates App Store server notifications using Apple's signed JWT format. Each notification is verified for:
- JWT signature validity
- Environment match (Apple Sandbox maps to Nuxie
test, Apple Production maps to Nuxielive) - Bundle ID match against your app configuration
Idempotency
Each App Store notification includes a unique notificationUUID. Nuxie uses this to deduplicate notifications. If the same notification arrives twice within 7 days, the duplicate is acknowledged without reprocessing.
Handled notification types
What happens on subscription change
When Nuxie receives an App Store notification:
- The notification JWT is verified and decoded.
- Nuxie checks for duplicate notifications using the
notificationUUID. - The handler updates the user's subscription status, auto-renew state, and expiration dates.
- Entitlements are recalculated and available at the edge immediately.
- Transaction and notification records are written asynchronously for audit.
Google Play Real-time Developer Notifications
Google Play RTDN messages arrive through a Pub/Sub push subscription pointed at your Nuxie Play Store webhook URL.
Setup
Follow the full Google Play integration guide to configure the Developer API service account, Pub/Sub topic, push subscription, and Play Console RTDN topic.
Notification verification
Nuxie verifies Google Play RTDN using:
- Package name match against your app configuration
- Pub/Sub OpenID Connect JWT email and audience when a Pub/Sub service account email is configured
- Optional shared verification token through the
tokenquery parameter
Idempotency
Nuxie uses the Pub/Sub messageId when available. If a raw developer notification is processed without a Pub/Sub envelope, Nuxie derives a stable notification ID from the package name, event time, payload kind, notification type, and purchase token or order ID.
Webhook ingress claims the provider event before queueing work. The queue handler marks the event processed only after purchase fulfillment, provider notification logging, and billing event fanout succeed.
Handled notification types
For Google Play cancellation events, customer webhook payloads include cancellationReason, cancelSurveyReason, and cancelSurveyReasonUserInput when Google returns that context from purchases.subscriptionsv2. Pending subscription or one-time purchase cancellations are delivered as pending_purchase_canceled so they do not look like an active entitlement cancellation. Billing retry webhooks can include billingIssueReason and billingIssuePendingOrderId for renewal-declined account hold or grace-period states. Price step-up RTDNs are delivered as price_increase_consent with the recurring price, price-change state, consent deadline, and new price when Google returns them. Google Play refund webhooks include refundType, refundReason, refundSource, refundAmount, refundCurrency, refundTaxAmount, refundedQuantity, and remainingQuantity when the voided purchase payload or hydrated transaction contains that context.
Error handling and retries
Apple and Google Pub/Sub retry webhook deliveries if they do not receive a successful response. See Apple's documentation and Google Pub/Sub push subscriptions for provider-specific retry behavior.
Nuxie returns a success response (200) as quickly as possible. Durable writes (transaction records, notification logs) are processed asynchronously after the response is sent, so webhook timeouts are rare.
If Nuxie cannot load your app's edge configuration when a webhook arrives, it returns a 503 error. The payment provider retries automatically. This can happen briefly after initial setup before your configuration has propagated.
Next steps
- App Store Connect Integration -- Link your App Store credentials
- Google Play Integration -- Link your Google Play credentials
- Products & Prices -- Configure products that map to entitlements