Note: To get access to the iOS Mobile Checkout SDK, contact your account manager or get in touch.

The iOS Mobile Checkout SDK allows you to integrate a mobile checkout experience directly into your iOS game. Instead of using traditional in-app purchases, players are sent to a fast, mobile-optimized checkout page where they can buy items like coin packs, character skins, or bundles.​

To use the iOS Mobile Checkout SDK:

  1. Follow the instructions to import and configure the SDK.
  2. Initialize the SDK.
  3. Implement the SDK callback methods.
  4. Launch the checkout.

After integrating the SDK, see the typical payment link flow:

Step 1 | Create a server-to-server checkout session

When a player selects an offer in your game, such as a coin pack or a character skin, send the item details from the game client to your game server. From your server, call the Create Checkout Session API to create a checkout session.

Step 2 | Use the SDK to open the checkout page

Implement the SDK to launch the Appcharge checkout page.

Step 3 | Receive the payment notification event if relevant

The player selects a payment method and completes the purchase. The Player Order Reporting Webhook is then triggered, and your game server receives a POST request with full transaction data.

If the player doesn’t complete the purchase, the checkout session will automatically expire after 1 hour or when the player actively closes the checkout page. To cancel an open checkout session at any time, such as when multiple checkout tabs are open, call the Cancel Checkout Session API.

You can listen for order events that are triggered based on different checkout outcomes.

Step 4 | Redirect the player back to your app

After a player completes a purchase or exits the checkout, they’ll be redirected back to your app via a Universal Link or deeplink. This behavior is configured during SDK setup. Your app must capture this URL and forward it to the SDK to finalize the transaction.

Step 5 | Handle success & failure callbacks

Appcharge receives the URL, validates the transaction against the webhook data, and dispatches a success or failure event.

Step 6 | Validate the purchase with your server

If the purchase is successful, the onPurchaseSuccess callback is triggered with an OrderResponseModel argument containing the purchaseId. You can use this to validate the purchase with your game server. The purchaseId also serves as the identifier for the transaction, allowing you to track the purchase and retrieve the offer item details associated with it. Once validated, fulfill the order by granting the purchased items to the player’s account.