Script: Subscribe to RSS from Safari with DT

Simply use it with an RSS feed visible in the curent Safari tab. Lets you choose the target group for the new feed in DT.

Please adjust the parameter ‘databaseName’ to select the database where you keep your RSS feeds.

tell application "Safari"
	set current_documents to documents
	set current_document to item 1 of current_documents
	set current_url to URL of current_document as text
	set current_title to my get_safari_title()
end tell

tell application "DEVONthink Pro"
       set databaseName to "RSS DB"

	set tg to display group selector "Choose target group for new feed..." for database databaseName
	create record with {name:current_title, type:feed, URL:current_url} in tg
end tell

on get_safari_title()
	set getTitle to "
            var theTitle = '';
            theTitle = document.title;
            '' + theTitle;
	tell application "Safari" to return (do JavaScript getTitle in document 1) as Unicode text
end get_safari_title

Thanks for posting the script! Two other possibilities are to drag & drop the feed’s URL on DEVONthink Pro’s Dock icon or to select the URL and to use the “Take Plain Note” service (assuming that the group selector is enabled in the Import preferences)