@jaanus, founder of @tact, has released Canopy!
There’s a little bit of my code in there from when I was working on the public beta. It encapsulates all the headaches we had to overcome to use CloudKit as a backend. From encapsulating the CloudKit API in a useful way, to how to make it testable.
@jaanus knows more than most about the intricacies of using CloudKit, and this library should save people a lot of time. Check it out.