Sending to Obsidian stopped working

I’ve got a couple of actions from the directory in my Drafts that I’ve been using to send notes to Obsidian, both of which worked nicely as recently as a few days ago. Now they are both no longer working on either my Mac or iPhone. All versions of Drafts and Obsidian are up to date, as are my MacOS and iOS. The two actions from the directory are:

This one and
This one

Anyone have any thoughts?

Thanks!

These are URL-based integrations with Obsidian. Possible something changed at their end with an update:

  • What happens when you run them?
  • Does Obsidian open?
  • Do you get an error message/banner in Drafts?
  • Any details in the action log?

Oh…sorry…yeah, that’d be helpful :wink:

Obsidian opens, but nothing happens (this is true on both iOS and MacOS)
No error message in Drafts, when I return to Drafts, I get a message to move the draft to either archive or trash (that’s my default for actions in Drafts)
The action log tells me that the draft ran successfully.

:man_shrugging:t2:

Are the problems specific to a certain draft, or on any draft?

If Obsidian is opening, a valid URL is being constructed, but presumably Obsidian does not recognize it as something it knows what to do with.

Next thing I would do is add the below line to the end of the script to log the URL opened, to troubleshoot what might be happening:

// begin additions
console.log(cb.url);
// end
var success = cb.open();

After running it again, you should have an entry in the action log with the URL opened. What is it?

1 Like

Remove any colons in the title of your Drafts note. I have found that a title with a colon makes the action die.

OMG! That was it!

Thank you!

And thanks Greg for your attention to this…you’re the best!

URL encoding the parameters in the callback URL should help to prevent these errors

In his examples, the parameters are encoded. Drafts would fail with an invalid URL error and Obsidian would never open if they were not.

I think this is a bug on Obsidian’s end. They should either be converting the “:” to a file-name valid character, or throwing an error, not failing silently.

If anyone know where to report bugs to Obsidian, you can demonstrate the silent failure by opening the below URL:

obsidian://new?name=TEST%3A2&content=TEST1&vault=Obsidian
1 Like

This is the forum for Obsidian bug reports: Bug reports - Obsidian Forum. I’m in the middle of moving so I don’t have time to post it right now. If someone else posts, please leave a note here. Otherwise I’ll post it next weekend.