mobile-deep-linking-architect
Architect-level deep linking — universal links and app links versus custom schemes, association files and verification, deferred deep links, routing into authenticated state, and the failure behaviour when a link lands on the wrong screen or a cold start. Use when links must open the app correctly.
- License 许可
- MIT
- 最近更新
- 2026-11-13
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- mobile-deep-linking-architect
- license
- MIT
- metadata
- { "crusor-path": "mobile-architect/devices-architect/mobile-deep-linking-architect", "crusor-domain": "mobile-architect", "crusor-origin": "original", "crusor-sources": "developer.apple.com/documentation/xcode/allowing-apps-and-websites-to-link-to-your-content; developer.android.com/training/app-links; developer.apple.com/documentation/xcode/supporting-associated-domains", "crusor-triggers": "deep link, universal link, app link, associated domains, deferred deep link, url routing, custom scheme, app links verification", "crusor-verified-on": "2026-10-30" }
- description
- Architect-level deep linking — universal links and app links versus custom schemes, association files and verification, deferred deep links, routing into authenticated state, and the failure behaviour when a link lands on the wrong screen or a cold start. Use when links must open the app correctly.
- compatibility
- Universal Links, Android App Links, Branch/Firebase Dynamic Links
03 SKILL.md 正文
Deep Linking Architect
A link is an entry point into arbitrary app state — including not-signed-in, wrong-account, and deleted-content states. The architecture is the routing contract, not the URL.
When to use
- Marketing links, emails, push notifications, and QR codes open the app.
- Sharing content between users.
- Cross-app handoffs and OAuth redirects.
When NOT to use
- In-app navigation only — that is the navigation stack's job.
Decision 1 — Link type
| Type | Behaviour |
|---|---|
| universal link / app link | https, verified, falls back to web |
custom scheme (myapp://) |
no verification, works from anywhere, spoofable |
| deferred deep link | install → first launch → route |
- Prefer https universal/app links: verified, shareable, and they degrade to the web.
- Custom schemes are for internal handoffs; never for anything privileged.
- Deferred links require a matching strategy (fingerprint or a token in a landing page) and are best-effort.
Decision 2 — Verification
- Apple:
apple-app-site-associationat the domain root, correct content type, paths scoped narrowly. - Android:
assetlinks.jsonwith the signing certificate SHA-256; debug and release variants differ. - Changes propagate slowly and caching bites; test on a device that has never opened the app.
- Keep the web fallback real — the link must work in a browser.
Decision 3 — Routing
URL → parse → validate → auth check → resolve target → present
- One router owns URL → destination mapping; screens never parse URLs.
- Unknown or malformed paths go to a safe home screen, never a crash.
- Unauthenticated: route to login with a return intent, then resume. Do not drop the deep link.
- Cold start vs warm start behave differently — both paths get the same handling.
- Handle in-app links (from notifications) through the same router.
Decision 4 — Safety
- Validate every parameter: ids, paths, redirect targets. A deep link is untrusted input.
- Never allow an open redirect or execution of an action (delete, pay) from a link alone — require confirmation.
- Account context: a link from user A must not open a record in user B's session.
- Rate-limit and log suspicious patterns.
Decision 5 — Observability
- Log link open → route resolved → screen shown, with source (email, push, web).
- Track conversion per campaign; a broken association file is invisible otherwise.
- Alert on route-resolution failures spiking after a release.
Failure modes at scale
- Association file with a wildcard path; every URL opens the app.
- Android assetlinks missing release certificate; links open the browser in production.
- Deep link lost during login; the user lands on home.
- Link to a deleted item crashes on parse.
- Custom scheme hijacked by another app.
Verification receipts
- Link inventory: type, domain, path patterns, destination.
- Association files validated for both platforms with release certificates.
- Cold-start test from a link while signed out.
- Malformed and hostile link tests handled safely.
- Conversion metrics per source for one campaign.
04 同仓库更多 Skills
interaction-patterns-architect
Architect-level interaction design in code — choosing established patterns over invented ones, feedback and latency behaviour, destructive-action safeguards, navigation and overlay conventions, and the state model behind every interactive surface. Use when a screen has to behave, not just look.
design-system-ops-architect
Architect-level operation of a design system in code — token pipelines and versioning, component API and variant policy, the catalogue as the contract, adoption metrics, and the governance that stops a system from forking into three. Use when a component library must survive several teams.
design-handoff-architect
Architect-level design handoff — what must be specified before implementation starts, tokens over raw values, responsive and content-limit contracts, state matrices, and the review loop that catches drift between design and code. Use when a design is about to become code.
content-microcopy-architect
Architect-level UI content — where strings live, voice and terminology consistency, error and empty-state copy as part of the interface, translation-ready authoring, and the content model a product needs before it multiplies screens. Use when the words in the interface matter as much as the pixels.
ui-ux-implementation-architect
Architect-level direction for turning a design into working UI — the handoff contract, component ownership versus screen-level layout, interaction and state conventions, design QA gates, and the review habits that keep an implementation faithful without frozen pixels. Use before any specific UI implementation skill.
test-strategy-architect
Architect-level test strategy — allocating assertions across unit, integration, contract and end-to-end layers, designing for testability through dependency boundaries, fixture and data strategy, and the flake and coverage policies that keep a suite trustworthy. Use when defining how a codebase is tested.