Netscape format a list of URLs from webpage

Want to be able to take a webpage containing a list of URLs, grab the urls and put them into a Netscape formatted html file - how would I go about this? I have Shortcuts and Drafts whichever would work best?
The idea is to output a file which can then be imported to so if the extra steps could be avoided and just send the urls individually to Raindrop using their api that would work too

Thanks for any help