Autorenewable Subscriptions

Hive SDK v4.11.6 supports new feature called auto-renewable subscriptions, which repeats payment on a regular basis. The types of subscription are monthly subscription, yearly subscription, and free trials in general. If you like to know more about the subscription format provided by Google and Apple, refer to the following table. Autorenewable subscriptions are available if user selects the period of regular payment by OS type.

OS Google Apple
Renewal terms Weekly
Monthly
Every 3 months
Every 6 months
Yearly
Weekly
Monthly
Every 2 months
Every 3 months
Every 6 months
Yearly

Make sure to let your game users access the auto-renewable subscriptions at any time regardless of device type if the user is regularly charged a specific subscription. Subscription restoration is essential feature in accordance with user needs.

Price change
Auto-renewal subscriptions are free to upgrade or downgrade the subscription level. Subscriptions are not a single-use, and provide receipt when users try to reinstate.

On Google, subscriptions are free to upgrade or downgrade the subscription level and change to new one regardless of previous subscription. If the user changes the price, the value of previous subscription is calculated on a daily basis and provided after the expiry of the new subscription.

On Apple platforms, subscription group is defined on iTunes console, so change to one of other subscription types in a same group is available. If the user upgrades his/her subscription, the value of previous subscription is calculated on a daily basis and provided after the expiry of the new subscription. In case of downgrade, it renews to the new subscription after the existing subscription is expired.

 

Purchase, Restoration and Grace period

Purchase

  • Free trials
    If a subscription has free-trial period, it is not calcualted as sales. After free-trial expires, the subscription is charged automatically.
  • Discount for new subscribers
    It is a promotion for new subscribers. This promotion is available in a specific period of time with discounted prices.

Cancellation

Subscribers can cancel the subscription prior to renewal period. How to cancel is described in Manage Subscriptions menu from each market. After the subscription canceled, auto-renewal is expired.

Refund

If a subscriber request to refund the rest value of the subscription after cancellation, the amount of refund is calculated based on the rest of time period and the value of subscription (Google console).

Restoration

Subscribers can reinstate the subscription if the subscription is unavailable after payment. Value calculation for restoration is based on the ownership policy if a subscriber has the ownership of the subscription.

Grace Period

When subscription renewal is failed to charge, use grace period. Make sure to value the state in grace period as same as that of subscription.

Account Hold (Google)

Account hold is a state that fails to renew a subscription due to issues occurred at the moment of payment, and ends with unsolved issues. In this case, make sure to process the subscription unavailable for maximum 30 days.

Pause (Google)

Pausing subscription is available for maximum three months. When the period ends, the subscription is automatically resumed.

Displaying Google Notification Popup

If Google subscription state is in grace period or on account hold, display a notification popup. The popup should contain the current subscription state, how to solve issues and a button that links to market settings. This button is not essential in the grace period, however, it is recommended for user convenience. In case the user changes the payment information in the grace period or on hold state, the subscription is automatically paid at the moment the user is set in case of the grace period state. On the account hold, the user should restart the subscription. When the subscription state of users is renewed after the restart, provide a subscription purchase page and a restoration button for users to give benefits of their subscription.

Notification popup samples are as follows. Use these phrases or customize them for each game.

  • Notification Phrases in Grace Period
Korean 구독 자동 결제에 실패하였습니다. Google Play의 구독 설정으로 이동하여 결제 수단을 확인해주세요.
English Failed to make automatic payment for subscription.
Go to the your Google Play subscription settings and check your payment method.
Japanese 購読自動決済に失敗しました。
Google Playの購読設定に移動し、決済方法を確認してください。
Chinese Simplified 自动付款失败。
前往谷歌商店的订阅设置,查看付款方式吧。
Chinese Traditional 自動續訂扣款失敗。
請至Google Play的[訂閱]設定中,確認付款方式。
French Echec du paiement automatique de l’abonnement.
Vérifiez le mode de paiement dans les paramètres d’abonnement de Google Play.
German Die automatische Zahlung des Abonnements ist fehlgeschlagen.
Gehe zu den Einstellungen deiner Google Play-Abonnements und überprüfe deine Zahlungsmethode.
Russian Не удалось совершить автоматическую оплату за подписку.
Перейдите в настройки подписки Google Play и проверьте метод оплаты.
Spanish No se pudo hacer el pago automático de la subscripción.
Ve a los ajustes de subscripción de tu Google Play y comprueba tu método de pago.
Portuguese Falha ao realizar o pagamento automático da assinatura.
Acesse as suas configurações de assinatura da Google Play e verifique o seu método de pagamento.
Indonesian Gagal melakukan pembayaran otomatis untuk berlangganan.
Silakan buka pengaturan langganan Google Play dan periksa metode pembayaranmu.
Vietnamese Thanh toán tự động cho đăng ký không thành công.
Vui lòng vào thiết lập đăng ký của Google Play và kiểm tra phương thức thanh toán của bạn.
Thai การชำระเงินอัตโนมัติเพื่อสมัครบริการล้มเหลว
กรุณาไปที่หน้าตั้งค่า Subscription ใน Google Play แล้วตรวจสอบวิธีการชำระเงิน
Italian Impossibile effettuare il pagamento automatico per l’abbonamento.
Vai alle impostazioni degli abbonamenti di Google Play e controlla il tuo metodo di pagamento.
Turkish Abonelik için otomatik ödeme başarısız.
Google Play Abonelik ayarına gidip ödeme yöntemini seçiniz.
Arabic فشل في إجراء عملية الدفع الآلي للاشتراك.
انتقل إلى إعداداتك في غوغل بلاي وتحقق من طريقة الدفع.
  • Notification Phrases when it is in pending state
Korean 구독 자동 결제가 정상적으로 이뤄지지 않아 구독 서비스가 만료되었습니다.
Google Play의 구독 설정으로 이동하여 결제 방법을 확인하고 다시 결제를 해주세요.
결제 후엔 반드시 복원(restore)버튼을 클릭하여 구독 상태를 확인해주세요.
English The subscription service has expired because the auto subscription payment has failed.
Go to the your Google Play subscription settings, check your payment method and try again.
Be sure to click Restore after purchase to check your subscription status.
Japanese 購読自動決済が行われなかったため、購読サービスが終了しました。
Google Playの購読設定に移動して決済方法を確認し、もう一度お試しください。
決済した後、必ず【復元】ボタンをタップして購読状態を確認してください。
Chinese Simplified 由于自动付款失败,订阅服务已到期。
前往谷歌商店的订阅设置,查看付款方式后重新进行付款吧。
付款后请务必点击复原(restore)按键查看订阅状态。
Chinese Traditional 自動續訂扣款失敗,已取消訂閱服務。
請至Google Play的[訂閱]設定中,確認付款方式後,再次付款。
付款完畢後,請務必點選[回復]按鈕,並確認訂閱狀態。
French Le service d’abonnement est interrompu : le paiement automatique ne s’est pas déroulé normalement.
Veuillez procéder de nouveau au paiement en vous rendant dans les paramètres d’abonnement de Google Play.
Après le paiement, confirmez bien le statut de l’abonnement en appuyant sur le bouton “Reprendre”.
German Der Abonnement ist abgelaufen, weil die automatische Zahlung für das Abonnement fehlgeschlagen ist.
Gehe zu den Einstellungen deiner Google Play-Abonnements, überprüfe deine Zahlungsmethode und versuche es erneut.
Bitte stelle sicher, dass du nach dem Kauf auf Wiederherstellen klickst, um den Status deines Abonnements zu überprüfen.
Russian Срок действия подписки истек, поскольку не удалось произвести автоматическую оплату за подписку.
Перейдите в настройки подписки Google Play, проверьте метод оплаты и повторите вновь.
После оплаты подтвердите статус подписки, нажав на кнопку «Возобновить».
Spanish La subscripción del servicio ha expirado porque ha fallado el método de pago automático de la subscripción.
Ve a los ajustes de subscripción de tu Google Play, comprueba tu método de pago e inténtalo de nuevo.
Asegúrate de pulsar Restaurar después de comprar para comprobar el estado de tu subscripción.
Portuguese O serviço de assinatura expirou porque houve uma falha no pagamento automático da assinatura.
Acesse as suas configurações de assinatura da Google Play, verifique o seu método de pagamento e tente novamente.
Certifique-se de clicar em Recuperar após a compra, para conferir o status da sua assinatura.
Indonesian Layanan berlangganan dihentikan karena pembayaran otomatis telah gagal.
Silakan buka pengaturan langganan Google Play, periksa metode pembayaranmu dan coba lagi.
Pastikan kamu klik Pulihkan setelah membeli untuk melihat status berlangganan.
Vietnamese Dịch vụ đăng ký đã hết hạn do thanh toán đăng ký tự động không thành công.
Vui lòng vào thiết lập đăng ký của Google Play để kiểm tra phương thức thanh toán của bạn và thanh toán lại.
Đừng quên nhấn vào nút Khôi Phục (Restore) sau khi thanh toán để kiểm tra tình trạng đăng ký của bạn.
Thai บริการจากการสมัครบริการหมดอายุแล้ว เนื่องจากชำระเงินอัตโนมัติไม่สำเร็จ
กรุณาไปที่หน้าตั้งค่า Subscription ใน Google Play แล้วตรวจสอบวิธีการชำระเงินอีกครั้ง
อย่าลืมกด Restore หลังซื้อ เพื่อตรวจสอบสถานะการสมัครของคุณ
Italian Il servizio di abbonamento è scaduto perché il pagamento dell’abbonamento automatico è fallito.
Vai alle impostazioni degli abbonamenti di Google Play, controlla il metodo di pagamento e riprova.
Assicurati di fare clic su Ripristina dopo l’acquisto per controllare lo stato dell’abbonamento.
Turkish Abone otomatik ödeme düzgün gerçekleşmediği için abonelik hizmeti sona erdi.
Google Play Abonelik ayarına gidip ödeme yöntemini kontrol edip tekrar ödeme yapınız.
Ödemeyi yaptıktan sonra geri yükle (restore) butonuna tıklayıp abonelik durumunuzu kontrol ediniz.
Arabic انتهت صلاحية خدمة الاشتراك بسبب فشل دفع الاشتراك الآلي.
انتقل إلى إعداداتك في غوغل بلاي وتحقق من طريقة الدفع و حاول مرة أخرى.
تأكد من النقر فوق زر استعادة الأشتراك بعد الشراء للتحقق من حالة اشتراكك.

 

Purchase process of subscription

Diagram

Flowchart

Google Subscription V2 Support

Google subscription API V2 allows you to create and manage multiple benefits using a new subscription method. The examples of the benefits include a benefit on your first subscription, and a discount by subscribing an additional product when you already had a subscription. For more information on Google subscriptions, see here.

If you use Google subscription V2, you can grant differentiated benefits to the payment price according to the subscription status, such as the subscription period and the number of the past subscriptions. To use Google subscription V2, please follow the steps below.

Register Product in the Google Play Console

Register your products to be sold using Google subscription V2 on the Google Play Console. For more details, please refer to Play Console Guide.

Check the Registered Product Information with getSubscriptionProductInfo

You can check your product information registered in the Google Play Console at the response value of IAPV4.getSubscriptionProductInfo method, the originalMarketJson of the IAPV4Product object.

  • productId: product
  • basePlanId: subscription plan
  • offerIdToken: benefit

The below presents an example product called “sub003” whose information can be found in originalMarketJson, after registering a weekly and a monthly payment each and defining two benefits for the monthly payment.

There are a total of 3 benefit key values shown in the offerIdToken example above, 2 benefit types for the monthly payment and 1 base benefit for the weekly payment. The first or the second benefit will actually be applied to the users when making monthly payment.

Request Subscription

Request a subscription as shown below using IAPV4Product object originalMarketJson obtained above. You can request a subscription with applying the corresponding benefits to the user.

Field Name Description Required
YOUR_PRODUCT_MARKET_PID This is the productId in originalMarketJson. Y
YOUR_PRODUCT_OLD_MARKET_PID The productId the user has already subscribed to. It is required when upgrading the existing subscription to the one the user is currently requesting. N
YOUR_PAYLOAD This is the purchase metadata predefined by the game studio. N
YOUR_OFFER_ID_TOKEN This is the offerIdToken in originalMarketJson. If you do not enter a value in this field, the Hive SDK will use the first offerIdToken in the subscriptionOfferDetails of originalMarketJson. N
Unity®

API Reference: IAPV4 .purchaseSubscription

C++

API Reference: IAPV4 ::purchaseSubscription

Kotlin

API Reference: IAPV4.purchaseSubscription

Java

API Reference: IAPV4.INSTANCE .purchaseSubscription

Swift

API Reference: IAPV4Interface.purchaseSubscription

Objective-C

API Reference: HIVEIAPV4 purchaseSubscription

 

Subscription API

Get Subscription Product List

When a user enters the subscription product shop in the game, the IAPV4.getSubscriptionProductInfo() method which queries the list of subscription products must be called. When this API is called, the IAPV4Product object which contains the product list and product information will be returned as the result. The IAPV4Product object is similar to the one returned in Searching Product List.

IAPV4Product object

Field Name Description
marketPid the unique product ID registered at in-app store
currency Currency type (e.g. KRW/USD)
price Product price
title Product title
displayPrice the string of the product price (e.g. $100.00) More
productDescription Product details
originalMarketJson the original product information received from the market
when using Google subscription V2, the product information defined in the Google Play Console can be checked with this.
displayOriginalPrice Price string before discount
Available with Hive SDK v4.12.0 and later, for Google only
originalPrice Original price without discount
iconURL Product icon (512*512)
Available with Hive SDK v4.12.0 and later, for Google only
displayPrice
  • Send the displayPrice with the combination of currency sign and price in order (e.g. $0.99). As Android or iOS has its own display type, the order of currency sign and price may show up differently in several countries depending on the OS.
  • Make sure to output the currency sign of each country as the same with its table. Refer to the Hive Identifier Policy to confirm the table of currency sign.
  • In case of additional countries to add or change VAT, server calculates VAT of all currency and adds to displayPrice, price, displayOriginalPrice andoriginalPrice. Therefore, you have no more work relevant to VAT.

 

Followings are sample codes to implement getSubscriptionProductInfo() method.

Unity®

API Reference: hive.IAPV4.getProductInfo

C++

API Reference: IAPV4::getSubscriptionProductInfo

Android

API Reference: com.hive.IAPV4.getSubscriptionProductInfo

iOS

API Reference: HIVEIAPV4::getSubscriptionProductInfo:

 

Purchase Subscription Product

Call the IAPV4 class purchaseSubscriptionUpdate() method to request subscription purchase using MarketPid registered in Apple App Store and Google Play Store as a parameter.

The following is an example implementation of purchaseSubscriptionUpdate().

Unity®

API Reference: hive.IAPV4.purchaseSubscriptionUpdate

C++

API Reference: IAPV4::purchaseSubscriptionUpdate

Kotlin

API Reference: com.hive.IAPV4.purchaseSubscriptionUpdate

Java

API Reference: com.hive.IAPV4.purchaseSubscriptionUpdate

Swift

API Reference: HIVEIAPV4::purchaseSubscriptionUpdate:oldMarketPid:additionalInfo:handler:

Obj-C

API Reference: HIVEIAPV4::purchaseSubscriptionUpdate:oldMarketPid:additionalInfo:handler:

Restoring subscription state

If the current subscription is not available on the subscriber’s device, implement restoreSubscription() method in the IAPV4 class to restore the subscription and request the receipt of the charged subscription.

Followings are sample codes to implement restoreSubscription() method.

Unity®

API Reference: hive .IAPV4.restoreSubscription

C++

API Reference: IAPV4 ::restoreSubscription

Kotlin

API Reference: IAPV4.restoreSubscription

Java

API Reference: com .hive.IAPV4.restoreSubscription

Swift

API Reference: IAPV4Interface .restoreSubscription

Objective-C

API Reference: HIVEIAPV4 ::restoreSubscription: