I have an existing action that creates a text file in a certain directory in the Drafts folder. I’d like to add an additional step that should let me chose one or more images from the photos on my iPhone and upload them to the same directory Drafts created in the first step. Is this possible?
Any help is appreciated,
Not automatically. Drafts doesn’t have any photo access functionality - it is very much based in text processing. You could trigger a Shortcuts custom shortcut (or something with Scriptable, Pythonista, etc.) from a Drafts action that could deal with the images. You would just manually have to select the iCloud Drafts folder to save the images to, as other apps can’t access Drafts’ folders directly without interaction. That’s standard and due to Apple’s sandboxing constraints.
If you used a ‘Drafts’ folder in Dropbox instead of iCloud, then the sandboxing constraints would not be applicable for automation of access.
Hope that helps.
This is what I do, and I have a Shortcut I can trigger from Drafts which tells it which folder to add photos, names them, uploads them, and then sends the markdown reference back to Drafts which then inputs it where the cursor is. I really ought to make this available!
this would be really helpful if you could share the shortcut and how you hand the folder from Drafts to the shortcut (including initiating the shortcut from Drafts).
Many, many thanks in advance, Yves
thanks for the clarification and suggestion. I am so used to iA Writer where I can add images to an iCloud folder where the edited text file used to be. I think I can build something similar with the shortcut Rosemary has developed. Thanks again for pointing me in the right direction.
Key point is the use of Dropbox over iCloud.