iCloud Web Service Server-to-Server Authentication in PHP
As my recent research and experiences have shown, it has become impossible to do a third party implementation of the server-to-server iCloud web-service based on Apple's documentation, examples and most of what had been written about it at (CloudKit Server-to-Server authentication and not in the most upvoted answers either, shockingly).
Despite being a raw PHP noob (C and Erlang are my languages,) I have managed to put together a few classes that successfully authenticates with an iCloud container using server-to-server keys registered in that container through the iCloud dashboard.
If anyone wants to use the code, or preferably take it a bit further into an actual library that brings the server-to-server parts of iCloud JS to the PHP server environment, I'd be happy to share. I'm just a little shy about my ineptitude with the new language, so you'd need to work around that.