How to convert bookmarklet script to javascript shortcut iOS

I want to use the bookmarklet script to create a shortcut (with javascript).

So I can activate the shortcut in the share menu.

Maybe someone can post an example.


For the Nextcloud Bookmarks app?


I have to convert (or decompress) the bookmarklet javascript from the bookmark app to a proper javascript witch I can use to make a shortcut in iOS.

With this script I don’t need an IOS app.

You can find the documentation of the bookmarks HTTP API here: Nextcloud Bookmarks API — Nextcloud Bookmarks documentation

It also allows you to create new bookmarks