How to create a shortcut for capturing as Markdown?

When I read, see or listen something, I like to keep track of it in DEVONthink. When reading an article, I capture it using the DEVONthink share sheet, remove the unread status, put some tags, select Markdown as the capture format, then in DTTG, I move the record in a dedicated group (as the Share sheet does not let you select a group).

I’d like to create a shortcut for that, but I have not figure out how to instruct DTTG to capture a link as Markdown using URL commands. It looks like I’d have to create a markdown first, then create a record using this markdown, which is sad as I like the DTTG Markdown capture format.

Any ideas?

A quick try resulted in the following:

  • Create a new shortcut and give it a simple name
  • Enable the share sheet
  • Add action Get contents of URL
  • Add action Make Rich Text from HTML
  • Add action Make Markdown from Rich Text
  • Add DTTG action Create Item

Set the DTTG action filetype to ‘Markdown’, set a title and choose a location. You could obviously automatically add a date to the filename or ask for input to set a name in the shortcut.

1 Like

That’s a solution indeed, thanks @Solar-Glare.
Ideally, I’d like to have the “standard” DTTG markdown capture format. If I create the markdown by myself, I won’t this formatting.

I saw that the URL commands have a clip command. I believe this the action I need, however I believe there is no way to set the selected format as markdown (by default it captures as a bookmark).

If no way is found around this action, I guess I’ll use your proposal.