Skip to content

feat: open dev-null.sh links in the mobile app - #879

Draft
simonhamp wants to merge 2 commits into
dev-null-sh:productionfrom
simonhamp:feat/app-links
Draft

simonhamp wants to merge 2 commits into
dev-null-sh:productionfrom
simonhamp:feat/app-links

Conversation

@simonhamp

@simonhamp simonhamp commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

With the mobile app installed, a link to a profile, its followers, a commit or a Remotes conversation can now open in the app instead of the browser. Phones only do that when the site says the app may, so this serves the two files they check:

  • /.well-known/apple-app-site-association for iOS. It lists the app's ID and the paths it opens: /@* and /remotes/@*. It leaves out a profile's og.png, feed.atom, graph.svg and preview, which aren't pages.
  • /.well-known/assetlinks.json for Android. It lists the package name and the SHA-256 fingerprints of the keys the app is signed with. Android can't scope paths in this file, so the app's manifest does that.

The IDs live in config/mobile.php and can be set from the environment:

  • MOBILE_IOS_APP_IDS defaults to J68WFCX458.com.nativephp.devnull, the production app.
  • MOBILE_ANDROID_PACKAGE defaults to com.nativephp.devnull.
  • MOBILE_ANDROID_CERTIFICATE_FINGERPRINTS is empty, so Android won't verify the app until it's set to the release key's fingerprint.

Both responses are cached publicly for an hour. Apple's CDN caches the iOS file for longer anyway.

The app side is NativePHP/dev-null-app, which maps the web paths onto its own screens.

Serves /.well-known/apple-app-site-association and /.well-known/assetlinks.json, so a phone with the app installed opens links to profiles, their followers, commits and Remotes conversations in the app. The app IDs come from config/mobile.php.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant