How to get link stored in variable into formatted hypertext?

If you look at the details of this macro:

( current version kept at GitHub - RobTrew/copy-as-md-link: macOS Keyboard Maestro macro group – single keystroke to copy MD links from different applications. )

You will see one approach to populating the clipboard with labelled links formatted as various kinds of text:

  • public.html
  • public.rtf
  • public.utf8-plain-text
  • com.hogbaysoftware.bike.xml

( You need to populate the pasteboard with multiple pasteboard items (or clipboard flavors) in order to paste a link into different types of applications )