Moving photos from iCloud to Nextcloud - eviltoast

Currently all my photos/videos are all stored in iCloud. I want to move these to my Nextcloud instance.

The Nextcloud iOS app does have a feature to automatically transfer an entire iCloud library to Nextcloud, but it’s broken right now (and has been for several months, see this issue). Unfortunately it doesn’t look like the iOS app developers are going to fix this any time soon.

Instead, I downloaded my photos/videos from privacy.apple.com, and I now have them all in archives. But their structure is all all over the place. I don’t think I can use a hacked-together script to convert them to a sane folder/file structure because nothing is dated.

For example, I would want a simple structure like /{year}/{month}/{day}/{images}. But the iCloud archive’s format is something like /Photos/{images}. Nothing is dated.

Any ideas about what I could do? It looks like my only options are just to have all my old photos in an esoteric folder/file structure, and have new photos/videos properly sorted. But that isn’t ideal.

The only other option is to hold out hope that Apple eventually add an option, as they recently added a way to transfer to Google Photos. But I am not expecting them to add support for Nextcloud.