---
title: Return to the game
nav: Deep links
order: 5
---
# Return to the game

After checkout, Appside sends the player back to your app through your **return URL**. The SDK turns that URL into a `PurchaseResult` you can show in the UI.

> The return is a **UI hint**. Grant items only from the [webhook](/docs/webhooks/) (or `getOrder` on your server). A player can close the browser before returning, and the webhook still arrives.

## Choose a return URL
- **Universal Link (iOS) / App Link (Android), recommended:** `https://yourgame.com/appside/return`. It works even when the app isn't installed. Studio → Integration generates the `apple-app-site-association` and `assetlinks.json` entries to host on your domain.
- **Custom scheme:** `orbitquest://appside`. Simplest to set up, but other apps could register the same scheme.

## Handle it
- iOS: `Appside.handle(url)` in `scene(_:openURLContexts:)` or SwiftUI `.onOpenURL`.
- Android: `Appside.handle(intent.data)` in the activity with the matching `<intent-filter>`.
- Unity: the SDK registers the handler. Subscribe to `Appside.OnPurchaseCompleted`.
- Web: the store returns to `returnURL` with `?appside_order=…`, and `Appside.handle(location.href)` reads it.

## Result fields
`status` (`completed` · `canceled` · `failed`), `orderId`, `sku`, `credits`, `error` (for failures).
