I recently developed the following workflow to attach images from my phone in emacs org mode. First, I created the folder NEXTCLOUD_FOLDER on my nextcloud instance and used the nextcloud app on my phone to create photos in that folder. Then I execute iko/org-attach-image-from-phone in an org mode document where I want the image to be attached using org-attach/org-download. Emacs then first syncs NEXTCLOUD_FOLDER with ATTACHMENTS_CACHE_DIR. On success I am prompted with yad to choose the attachment among the files in ATTACHMENTS_CACHE_DIR. It is then sized down to 720p with imagemagick; otherwise the preview in emacs is too slow. Finally, the image is attached to the current node and a link to it is written into the file at point.
To use it, you need to install yad, nextcloudcmd and imagemagick on your machine, as well as org-download, s.el and f.el in your emacs. Finally, you need to configure ATTACHMENTS_CACHE_DIR, YOUR_USERNAME, YOUR_PASSWORD, YOUR_SERVER and NEXTCLOUD_FOLDER.