What's the proper way to insert a command into the right click context menu for a link?

Hello, I'm trying to find a clear cut example way to add a command in the right click context menu, when right clicking on a link's text in the editor (RTE)

This specifically would be for adding a command when right clicking the link to another Joplin note in the editor, so I would also need to be able to suss out the link formatting between internal Joplin and http.

I do know the command to open in a new window is pretty straight forward: joplin.commands.execute('openNoteInNewWindow', noteIdGoesHere);