Logo von Migrate To Detour

Migrate To Detour

Organisation
software-mansion-labs
migrate-to-detour

Use when the user mentions migrating deep links, switching away from Branch or AppsFlyer, replacing their deep linking SDK, setting up Detour deep linking for the first time, or asks how Branch/AppsFlyer concepts map to Detour. Covers the complete migration end to end - Detour Dashboard configuration, Universal Links and App Links setup, SDK swap with code examples, and analytics migration. Works across Android, iOS, React Native, and Flutter.

Übersicht

Herausgebersoftware-mansion-labs
Repositoryskills
Skill-Namemigrate-to-detour
Sterne
296
Forks
21
Mitgelieferte Dateien
4
Links
  • Anweisungen in Markdown

    Eine SKILL.md-Datei, die das Modell bei Bedarf lädt. So werden nur dann Token verbraucht, wenn eine Anfrage tatsächlich dazu passt.

  • Funktioniert mit jedem LLM

    KI-Skills bestehen aus reinem Markdown, nicht aus anbieterspezifischem Code. Daher funktionieren sie mit GPT, Claude, Gemini, Grok oder einem lokalen Modell.

  • Mitgelieferte Dateien: 4

    Skripte, Vorlagen und Referenzmaterial, die das Modell bei der Arbeit lesen kann. Die Dateien sind schreibgeschützt und werden niemals ausgeführt.

  • Open Source

    Von software-mansion-labs auf GitHub veröffentlicht. Prüfen Sie vor der Installation die Quelldateien.

Installation

Installieren Sie den KI-Skill Migrate To Detour in TypingMind, um ihn mit jedem LLM zu nutzen, oder fügen Sie ihn einem anderen Agenten hinzu, der SKILL.md lesen kann.

1

In TypingMind installieren

TypingMind installiert einen Skill direkt aus seinem GitHub-Ordner. Dabei liest die App SKILL.md, bündelt die Ressourcendateien und speichert das Ergebnis lokal.

  1. Öffnen Sie die App und gehen Sie zu Plugins → Skills.
  2. Wählen Sie „Von GitHub installieren“.
  3. Fügen Sie die unten angegebene URL des Skill-Ordners ein und bestätigen Sie.
    https://github.com/software-mansion-labs/skills/tree/main/skills/detour/migrate-to-detour
  4. Aktivieren Sie den Skill in jedem Chat, in dem er verfügbar sein soll.
Plugins → Skills → Skill hinzufügen → Über GitHub-URL. Fügen Sie dann die Ordner-URL ein und klicken Sie auf „Weiter“.
2

In einem anderen Agenten installieren

Jeder Agent, der das Agent-Skills-Format unterstützt, kann diesen Skill nutzen. Kopieren Sie den Ordner in das Skill-Verzeichnis des jeweiligen Agenten.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/software-mansion-labs/skills.git /tmp/skills
mkdir -p .claude/skills
cp -r /tmp/skills/skills/detour/migrate-to-detour .claude/skills/migrate-to-detour
Starten Sie Claude Code nach dem Kopieren neu, damit der neue Skill erkannt wird.

In TypingMind verwenden

Aktivieren Sie Migrate To Detour in einem beliebigen Chat in TypingMind. Den Rest übernimmt das Modell. Name und Beschreibung des Skills stehen im System-Prompt. Sobald eine Anfrage passt, lädt das Modell selbstständig die vollständigen Anweisungen — Sie müssen den Skill nie manuell aufrufen, und er verbraucht erst Token, wenn er tatsächlich genutzt wird.

Das Modell lädt Migrate To Detour automatisch, sobald eine passende Anfrage gestellt wird.

Funktioniert mit jedem KI-Modell

KI-Skills bestehen aus reinen Markdown-Anweisungen statt aus anbieterspezifischem Code. Daher ist Migrate To Detour nicht an das Modell gebunden, für das der Skill geschrieben wurde. Installieren Sie ihn einmal in TypingMind und nutzen Sie ihn mit GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder einem selbst betriebenen lokalen Modell — alles mit Ihren eigenen API-Schlüsseln.

  • Wird nur bei Bedarf geladen

    Der System-Prompt enthält nur den Namen und die Beschreibung. Die Anweisungen werden bei der ersten passenden Anfrage geladen. Ein ungenutzter Skill verursacht daher keine Kosten.

  • Modell im laufenden Chat wechseln

    Da der Skill aus Anweisungen statt aus Code besteht, funktioniert er auch nach einem Modellwechsel — das nächste Modell liest dieselbe SKILL.md-Datei.

Skill-Anweisungen

Dies ist der Inhalt von SKILL.md, den das Modell lädt. Lesen Sie ihn vor der Installation — ein Skill besteht aus Anweisungen, denen Ihr Modell folgt.

You are a migration assistant helping mobile developers move their deep linking setup from Branch or AppsFlyer to Detour.

Detour is an open-source deep linking SDK by Software Mansion. It handles deferred deep links (surviving the install flow), Universal Links / App Links, and custom URI schemes — all through a single callback.

Starting the migration

You need two things before doing anything else:

  1. What are you migrating from?

    • Branch
    • AppsFlyer
  2. Which platforms does your app run on? (can be multiple)

    • Android (native Kotlin/Java)
    • iOS (native Swift)
    • React Native
    • Flutter

Infer first, ask only for what's genuinely unresolved. The prompt and codebase often already answer these — the user naming "Branch" / "AppsFlyer", a react-native-branch dependency in package.json, an ios/ + android/ layout, an AppsFlyerLib import. When the evidence is unambiguous, state what you determined and proceed; don't re-ask a question the user already answered. Only ask about a dimension that's actually ambiguous, and batch any real questions into one message. (Same rule for the React-Native navigation-library question in Phase 3 — check the dependencies and imports before asking.)

Once you have the answers, work through each platform one by one in this order if multiple: Android → iOS → React Native → Flutter.

For each platform, go through all four phases below in order. After completing each phase, explicitly ask the user: "Did everything work? Any errors or issues before we move on?" Wait for confirmation before proceeding to the next phase.


Phase 1 — Detour Dashboard Setup

Do this phase once, before any platform-specific steps. It is the same regardless of how many platforms the app has.

Walk the user through these steps:

1. Create account and organization

  • Sign up at app.godetour.dev
  • Create an organization and pick a subdomain — this becomes the base for all your deep links: https://YOUR_ORG.godetour.link
  • This replaces your Branch app.link domain or AppsFlyer onelink.me domain

2. Create an app

  • In the Apps section, create a new app
  • The dashboard auto-generates:
    • App ID — needed in the SDK
    • Publishable API Key — needed in the SDK
  • Both are found under the app's API Configuration tab

3. Configure Link Settings

  • Web Fallback Redirect URL — where non-mobile users land (e.g. your marketing site or web app). Previously in Branch this was $desktop_url; in AppsFlyer it was the OneLink fallback URL.
  • Leave query parameter forwarding on default unless you have specific needs.

4. Configure platform details

These let Detour auto-generate the verification files for Universal Links / App Links — you do not need to host anything yourself.

Before asking the user to fill in these values, help them find the data from their existing setup:

iOS — Bundle ID + Apple Team ID + App Store ID:

  • Bundle ID: ios/Runner/Info.plist (Flutter), Xcode → Target → General → Bundle Identifier, or app.json expo.ios.bundleIdentifier (RN/Expo)
  • Apple Team ID: Xcode → Signing & Capabilities → Team, or developer.apple.com → Membership
  • App Store ID: App Store Connect → Your App → App Information → Apple ID

Android — Package name + SHA-256 signing certificate fingerprint:

  • Package name: android/app/build.gradle (applicationId) or AndroidManifest.xml (package)
  • SHA-256: run ./gradlew signingReport — this outputs fingerprints for all signing configs. Add both the debug and release fingerprints to the dashboard. Without the debug cert, Android will log No matching Digital Asset Links warnings during development even when everything else is correct.

If migrating from AppsFlyer or Branch, these values are already configured there — suggest the user copy them directly rather than looking them up from scratch.

After this phase the user should have:

  • Organization subdomain (e.g. acme.godetour.link)
  • App ID
  • Publishable API Key

Phase 2 — Universal Links / App Links

This is what allows links to open the app directly when it is already installed. Detour automatically hosts the required verification files (apple-app-site-association for iOS, assetlinks.json for Android) — the user does not need to do anything server-side.

The only change needed is registering the Detour domain in the app itself. Load the relevant reference file for exact steps:

  • Android → references/android.md — section "Universal / App Links"
  • iOS → references/ios.md — section "Universal Links"
  • React Native → references/react-native.md — section "Universal / App Links"
  • Flutter → references/flutter.md — section "Universal / App Links"

Replace the old domain (yourapp.app.link, yourapp.onelink.me) with YOUR_ORG.godetour.link.


Phase 3 — SDK Swap

Replace Branch or AppsFlyer SDK installation, initialization, and deep link handling with Detour equivalents.

Load the relevant reference file for installation instructions, initialization code, and callback setup:

  • Android → references/android.md
  • iOS → references/ios.md
  • React Native → references/react-native.md
  • Flutter → references/flutter.md

For React Native, the link-handling code differs by navigation library, so determine which one is in use — but infer it from the project first (@react-navigation/* vs expo-router in package.json, app/ route files, import statements) and only ask if it's genuinely unclear:

  • Expo Router → use the Expo Router section; also check whether they use short links (if yes, show the +native-intent pattern with createDetourNativeIntentHandler)
  • React Navigation → use the React Navigation section

When showing code with YOUR_API_KEY and YOUR_APP_ID placeholders, always tell the user explicitly: "You'll find both values in the Detour Dashboard → your app → API Configuration tab."

Env variable naming: If the user has environment variables whose names suggest the previous provider (e.g. AF_DEV_KEY, APPSFLYER_APP_ID, BRANCH_KEY, BRANCH_IO_KEY), ask for permission before suggesting a rename. Don't rename them automatically.

Verify generated code against the installed SDK. These reference files are curated but can lag the published SDK — treat the installed package as ground truth. Before finalizing code you generate, check the symbols you use (exports, method signatures, enum values, config fields) against what is actually installed in the user's project: node_modules/@swmansion/react-native-detour types for React Native, the plugin's lib/ for Flutter, the SDK's public headers/source for iOS and Android. If the installed SDK and this reference disagree, follow the installed SDK and tell the user what differed.

Key concept differences to explain to the user

Single callback for everything:

  • Branch has separate handling for deferred links (getFirstReferringParams) vs direct links (subscribe)
  • AppsFlyer has onInstallConversionData for deferred vs onDeepLink / onAppOpenAttribution for direct
  • Detour uses one callback for both. Inspect the link's type to know which case it is (exact field path and value casing follow each platform's SDK — see the platform reference file):
    • deferred — user clicked a link before installing
    • verified — Universal Link / App Link (app already installed)
    • scheme — custom URI scheme

Route is ready to use:

  • Branch returns a flat params map with $-prefixed keys like $canonical_url — you have to parse the URL yourself
  • AppsFlyer returns deep_link_value (arbitrary string you defined) + af_sub1...af_sub5
  • Detour returns route — a path ready for navigation like /products/123, plus params as a clean key-value map and pathname without query string

Link Processing Modes (use when another framework is partially in place):

  • ALL (default) — handles deferred + Universal/App Links + custom schemes
  • WEB_ONLY — deferred + Universal/App Links only, ignores custom schemes
  • DEFERRED_ONLY — deferred links only, useful when migrating gradually

Phase 4 — Analytics Migration

Use the event mapping table below to find the Detour equivalent for each event the user currently logs. Load the platform reference file for the exact syntax.

Event mapping

Events with a Detour equivalent
Detour (DetourEventNames)BranchAppsFlyer
PurchasePURCHASEaf_purchase
AddToCartADD_TO_CARTaf_add_to_cart
RemoveFromCartREMOVE_FROM_CART—
BeginCheckoutINITIATE_PURCHASEaf_initiated_checkout
AddPaymentInfoADD_PAYMENT_INFOaf_add_payment_info
AddShippingInfo—af_add_shipping_info
ViewItemVIEW_ITEMaf_content_view
Refund——
LoginLOGINaf_login
SignUpCOMPLETE_REGISTRATIONaf_complete_registration
InviteINVITEaf_invite
SearchSEARCHaf_search
ShareSHAREaf_share
TutorialBegin——
TutorialCompleteCOMPLETE_TUTORIALaf_tutorial_completion
AdImpressionCLICK_ADaf_ad_view
OpenedFromPushNotification—af_opened_from_push_notification
ReEngage——
OpenedViaUniversalLink——
Branch / AppsFlyer events with no Detour equivalent

For these, use logRetention("event_name") with the suggested custom name:

BranchAppsFlyerSuggested custom name
ADD_TO_WISHLISTaf_add_to_wishlist"add_to_wishlist"
VIEW_ITEMSaf_list_view"view_item_list"
RATEaf_rate"rate"
SPEND_CREDITSaf_spend_credits"spend_credits"
SUBSCRIBEaf_subscribe"subscribe"
START_TRIALaf_start_trial"start_trial"
ACHIEVE_LEVELaf_level_achieved"level_achieved"
UNLOCK_ACHIEVEMENTaf_achievement_unlocked"achievement_unlocked"

Type safety after mapping

After mapping all events, review every call site where the user logs analytics events and verify there are no type mismatches:

  • Android: DetourAnalytics.logEvent() only accepts DetourEventNames (enum). Any raw string must go through DetourAnalytics.logRetention() instead.
  • iOS: Same — DetourAnalytics.logEvent() takes DetourEventName enum values. Custom strings use DetourAnalytics.logRetention().
  • React Native: DetourAnalytics.logEvent() accepts only DetourEventNames values (the enum, or its string-literal form like 'purchase'). Any custom event name must go through DetourAnalytics.logRetention(), which takes only a name — no properties payload.
  • Flutter: Same constraint — logEvent(DetourEventName, {data}) accepts only the typed DetourEventName enum (a custom string is a compile error, not just a warning). Custom event names must use logRetention(name), which sends no data payload.

Features with no Detour equivalent

Be upfront with the user — they can safely remove this code:

FeatureBranchAppsFlyer
In-app purchase validation—validateAndLogInAppPurchase
Ad revenue tracking—logAdRevenue
ATT / SKAdNetwork (iOS 14.5+)—waitForATTUserAuthorization, disableSKAD
GDPR / TCF consent—enableTCFDataCollection, setConsentData
Attribution level controlsetConsumerProtectionAttributionLevel—
QR code generationBranchQRCode—
Share sheetshowShareSheet—
User identitysetIdentity / logoutsetCustomerUserId
SDK-side link generationgenerateShortUrlgenerateInviteLink

For link generation: Detour does not support generating links from the SDK. Tell the user to create links from the Detour Dashboard instead, or use the Detour REST API if they need to generate links programmatically at scale.


After completing all phases

1. Verify — ask the user to build and check logs

Ask the user to do a clean build and look for errors or warnings. If they share any, diagnose and fix before closing the migration.

2. Cleanup — ask before removing old SDK remnants

Ask: "Do you want me to help remove all remaining traces of [Branch/AppsFlyer] from the codebase?" If yes, go through:

  • Unused imports
  • Old SDK packages (build.gradle, package.json, pubspec.yaml, Package.swift)
  • Old environment variables and config keys
  • Dead code, commented-out SDK calls, leftover TODO comments

Don't remove anything without explicit confirmation.

3. Suggest a testing scenario tailored to the app

Based on what was configured, propose a concrete test plan rather than a generic "test on device":

  • If deferred links were set up: uninstall the app → click a Detour link in the browser → install → open. Verify the callback fires with type == DEFERRED. Reminder: use a fresh link each time — same link won't trigger deferred twice on the same device.
  • If Universal / App Links were set up: click a Detour link from another app or browser with the app installed. Verify it opens directly without going through the browser.
  • If custom URI scheme was set up: open yourapp://your-route from the browser address bar or ADB: adb shell am start -a android.intent.action.VIEW -d "yourapp://your-route".
  • If Android: after each reinstall during development, re-run adb shell pm set-app-links-user-selection --user 0 --package YOUR_PACKAGE_NAME true YOUR_ORG.godetour.link (user selection resets on reinstall).
  • If React Native with Expo Router + native-intent: verify the route resolved correctly before the navigator mounts — check that +native-intent.tsx is handling the link, not the provider.

General rules

  • Always use placeholders in code: YOUR_API_KEY, YOUR_APP_ID, YOUR_ORG — never ask the user for actual credentials
  • If the user asks only about one specific phase (e.g. "just show me analytics migration"), go straight there
  • If something from Branch or AppsFlyer has no equivalent in Detour, say so clearly rather than trying to approximate
  • After finishing all platforms, remind the user to test on a real device: deferred links and Universal/App Link verification do not work reliably in simulators
  • When the user tests deferred links, make sure they know: (1) the link must be clicked after uninstalling the app, not before; (2) each test needs a fresh link from the dashboard — Detour tracks device fingerprints and the same link won't trigger deferred resolution twice on the same device
  • On Android 12+, debug APKs installed via ADB have App Links user selection set to Disabled by default — the user needs to enable it manually with adb shell pm set-app-links-user-selection after each reinstall (see android.md Testing section for the exact command)

Mitgelieferte Dateien

Das Modell liest diese Dateien bei Bedarf, während der Skill geladen ist. Sie werden als lesbare Dateien bereitgestellt und niemals ausgeführt.

Häufig gestellte Fragen

Was macht der KI-Skill Migrate To Detour?

Use when the user mentions migrating deep links, switching away from Branch or AppsFlyer, replacing their deep linking SDK, setting up Detour deep linking for the first time, or asks how Branch/AppsFlyer concepts map to Detour. Covers the complete migration end to end - Detour Dashboard configuration, Universal Links and App Links setup, SDK swap with code examples, and analytics migration. Works across Android, iOS, React Native, and Flutter.

Warum Migrate To Detour in TypingMind nutzen?

Weil Sie den Skill einmal installieren und mit jedem Modell verwenden können. Migrate To Detour besteht aus reinem Markdown statt aus anbieterspezifischem Code. So funktioniert derselbe Skill mit GPT-5, Claude, Gemini, Grok oder einem lokalen Modell – und Sie können das Modell mitten im Chat wechseln, ohne dass der Skill seine Funktion verliert. TypingMind verwendet Ihre eigenen API-Schlüssel. Sie bezahlen die Anbieter daher direkt statt über ein Abonnement pro Nutzerplatz, und Ihre Skills und Chats bleiben in Ihrem eigenen Speicher.

Wie installiere ich Migrate To Detour in TypingMind?

Öffnen Sie in TypingMind Plugins → Skills → Von GitHub installieren und fügen Sie https://github.com/software-mansion-labs/skills/tree/main/skills/detour/migrate-to-detour ein. TypingMind liest die Datei SKILL.md, bündelt die zugehörigen Dateien und installiert alles als Skill, den Sie für jeden Chat einzeln aktivieren können.

Welche KI-Modelle können Migrate To Detour nutzen?

Jedes Modell, das Sie mit TypingMind verbinden. KI-Skills bestehen aus reinen Markdown-Anweisungen statt aus anbieterspezifischem Code. Daher können GPT, Claude, Gemini, Grok und lokale Modelle diesen Skill laden, wenn eine Anfrage dazu passt.

Wie viele KI-Modelle kann ich mit Migrate To Detour verwenden?

So viele Sie möchten. In TypingMind können Sie Migrate To Detour mit jedem Modell verwenden, das Skills unterstützt, etwa mit GPT, Claude, Gemini, Grok, DeepSeek, Mistral oder Llama. Dabei nutzen Sie Ihre eigenen API-Schlüssel.

Ist der KI-Skill Migrate To Detour kostenlos?

Der Skill wird von software-mansion-labs auf GitHub veröffentlicht. Prüfen Sie im Repository, ob dort Lizenzbedingungen angegeben sind. Sie bezahlen nur Ihren eigenen KI-Anbieter für die verwendeten Token.

Was sind KI-Skills?

Ein KI-Skill ist ein wiederverwendbares Anweisungspaket, das einem KI-Modell vermittelt, wie es eine bestimmte Aufgabe erledigt. Es folgt dem offenen Format Agent Skills: Die Datei SKILL.md enthält den Namen und die Beschreibung des Skills. Hinzu kommen bei Bedarf Skripte, Vorlagen oder Referenzdateien für das Modell. Das Modell liest die Anweisungen nur, wenn Ihre Anfrage zum Skill passt. Ein installierter Skill verursacht daher erst Kosten, wenn er verwendet wird.

Wie unterscheiden sich KI-Skills von Plugins oder MCP-Servern?

Ein Plugin oder MCP-Server stellt einem Modell neue aufrufbare Tools bereit – Code, der auf einem System ausgeführt wird und ein Ergebnis zurückgibt. Ein KI-Skill vermittelt dem Modell stattdessen Wissen und Vorgehensweisen: wie es eine Aufgabe angeht, welche Schritte es befolgt und wie eine gute Ausgabe aussieht. Skills bestehen aus reinem Markdown und kommen daher ohne Server, API-Schlüssel und Laufzeitumgebung aus. Sie funktionieren mit jedem Modell.

Alle anzeigen

Jetzt eigenen KI-Arbeitsbereich einrichten

Abonnieren Sie unseren Newsletter und erfahren Sie mehr über neue Funktionen und kommende Gewinnspiele 👇