Well, to get HTML from a webpage and copy to the clipboard is fairly simple in AppleScript.
set theHTML to do shell script "curl -L http://twitter.com | pbcopy"
3
solved How to make an AppleScript that copies HTML source code from webpages? [closed]