/link

GET

Acquisition link endpoint. Captures attribution and redirects straight to the App Store or Play Store — no app-open attempt or timeout delay.

Overview#

/link is Mobana's acquisition link path. Use it for ad campaigns, influencer drops, push notifications, email, and QR codes where you want the user to land in the App Store or Play Store as quickly as possible. It always captures attribution and redirects to the App Store or Play Store — even when the app is already installed — so there is no app-open attempt and no timeout delay that could hurt funnel conversion.

  • App not installed — Mobana captures attribution signals and redirects to the store. On first launch the SDK calls /find to match the install — attribution lands in getAttribution() and any payload fires via onDeepLink('deferred').
  • App installed — the OS does not intercept this path. The browser opens normally, captures attribution, and redirects to the store. The SDK's background probe picks up the click within five minutes and fires onDeepLink('probabilistic').

For links that should open the installed app immediately, use /deep instead. /deep is registered as a Universal Link / App Link so the OS hands it directly to the app, then falls back to the store with a 2–3 s timeout if the app is not installed.

See the Deeplinks guide for the full lifecycle and platform setup.

Endpoint#

GET https://YOUR_APP_ID.mobana.ai/link

Or use your custom endpoint: https://yourdomain.com/d/link

Query Parameters#

ParameterTypeDescription
utm_sourcestringTraffic source (e.g., facebook, google, tiktok). Highly recommended.
utm_mediumstringMarketing medium (e.g., cpc, social, email). Highly recommended.
utm_campaignstringCampaign name. Highly recommended.
utm_contentstringAd content identifier (e.g. ad variant name).
utm_termstringSearch keywords.
datastringURL-encoded JSON object for structured custom payloads (unlock codes, referral IDs, in-app routing). Delivered as a typed object on event.data in onDeepLink and on attribution.data in getAttribution(). For simple flat values, skip data and pass plain query params — they come back via click_params.
urlstringOverride the store redirect destination. If omitted, the endpoint auto-detects platform and uses the App Store / Play Store URLs configured for your app.

Every other query parameter (e.g. fbclid, ttclid, gclid, partner IDs) is captured automatically and surfaced as click_params — no configuration needed.

Examples#

Vanilla campaign link

Campaign URL
https://YOUR_APP_ID.mobana.ai/link
  ?utm_source=facebook
  &utm_campaign=summer_launch
  &utm_medium=cpc

A plain UTM-tagged link. No data payload — the OS still opens your app directly when installed, onDeepLink fires with empty data and the UTM fields populated, and your handler can ignore the event entirely.

Smart link with payload

Smart link
https://YOUR_APP_ID.mobana.ai/link
  ?utm_source=tiktok
  &utm_campaign=influencer_drop
  &data={"unlock":"PROMO50","ref":"sara"}

Use data for anything you want your app to act on:

interface Unlock { unlock?: string; ref?: string }

Mobana.onDeepLink<Unlock>(({ data, source }) => {
  if (data?.unlock) applyUnlock(data.unlock);  // "PROMO50"
  if (data?.ref) trackReferrer(data.ref);
  // No data fields set? It's a vanilla campaign tap — nothing to do.
});

Deep link setup#

The setup below applies to /deep links, which open the installed app directly. For /link (acquisition), no special native setup is required — attribution is captured in the browser regardless of install state.

  1. iOS URL Scheme in App Settings → Deeplinks (e.g. myapp) and the same scheme registered in your app's Info.plist. Mobana fires myapp://… from the /deep redirect page; if the app is installed iOS hands the URL to your app via Linking.
  2. Android intent-filter in AndroidManifest.xml scoped to android:pathPrefix="/deep". Mobana uses an intent:// URL targeting your package name; the intent-filter lets the Android Linking API receive the URL data.
  3. SDK wiring. Mobana.init() attaches the URL and AppState listeners that fire onDeepLink and notify the server about the delivered link.

See the Deeplinks guide for full setup steps (including code snippets, Expo config, and the optional Universal Links / App Links enhancement).

<!-- AndroidManifest.xml — required for intent:// routing on /deep links.
     autoVerify enables App Links (OS-level interception) when SHA-256
     fingerprints are configured in the Dashboard -->
<intent-filter android:autoVerify="true">
  <action android:name="android.intent.action.VIEW" />
  <category android:name="android.intent.category.DEFAULT" />
  <category android:name="android.intent.category.BROWSABLE" />
  <data
    android:scheme="https"
    android:host="YOUR_APP_ID.mobana.ai"
    android:pathPrefix="/deep" />
</intent-filter>

Custom endpoints#

To serve Mobana links from your own domain, your reverse proxy must forward two things:

  • /link, /link/record, /link/probe (plus the existing /find, /conversion, /flows, /ping) under your chosen path prefix.
  • /.well-known/apple-app-site-association and /.well-known/assetlinks.json at the host root, NOT under the path prefix — the OS only looks at the root.
# Using your custom endpoint
https://yourdomain.com/d/link?utm_source=email&utm_campaign=welcome

The nginx / Apache templates in App Settings → Custom Endpoint already include all of the above. See the Custom Endpoints guide for details.

AI agents: for complete Mobana SDK & API documentation, get full context here or visit llms.txt