json formatting – Open local app from button on SharePont Online list


On a SharePoint Online list I would like to add a custom button.
This button should open a local application (like Word).

When I try in my browser

ms-word://

I get they notification that my browser tries to open a local application. But when I’m using that same logic in a custom created JSON-btn on a SharePoint Online button, it just disappears and it’s not working.

The button should be formatted in JSON. And at the moment it looks like this

{
  "elmType": "a",
  "txtContent": "Open in client App",
  "attributes": {
    "target": "_blank",
    "class": "sp-field-quickAction",
    "href": "ms-word://"
  }
}

When I create a tinyurl with the same ms-word:// and put that in place it works like a charm.
Unfortunaly I’ll have to do this for like 350 different lists 🙂

Any suggestions?