Citrullin
Citrullin

Reputation: 2321

How to implement deeplinks in KaiOS

A user should be able to click on a link like app:this/is/some/link?with=information and the desired app opens and does some action.

This question is similar but just the other side to KaiOS - Share using WhatsApp. Another application should link to my application.

Is this possible in KaiOS?

Upvotes: 3

Views: 247

Answers (1)

Tom
Tom

Reputation: 7091

Deeplinks do exist on KaiOS 2.5.3 or newer, but there is no documentation on them. For example, this is from the KaiStore app manifest:

"deeplinks": {
    "regex": "^(app://)(kaios-store|kaios-plus)(.kaiostech.com)($|/$|/\\?(apps|postResult)=)",
    "action": "open-deeplink"
},
"activities": {
  "open-deeplink": {
      "href": "./index.html",
      "disposition": "window",
      "filters": {
        "type": "url",
        "url": {
          "required": true,
          "pattern": "(app|rtsp|data):.{1,16384}"
        }
      },
      "returnValue": true
  },
}

The action under deeplinks points to one of the activities, which must accept a required URL parameter. An app can then register using navigator.mozSetMessageHandler to handle this activity (see B2G's Web Activities API).

That said, there is no way to deep-link to arbitrary apps. Apps must expose Web Activities in their manifest in order to be open-able by other apps.

Upvotes: 1

Related Questions