Post

Replies

Boosts

Views

Activity

PhotoKit. Changing iCloudId between devices.
While developing a gallery app, I noticed that the iCloudId can change between devices Phone1 and Phone2, on which iCloud is active. First, I know the assetId is unstable, but the iCloud ID ( How it can be? I thought it was stable and I could use it for sending, for example as a UUID for a items on BE to prevent duplication. Could you please explain to me in which cases the iCloudId can change, and what I can use for stable UUID for my internal item to prevent duplication on the BE side? Additional info: Phone1: - assetId part = B01B27D9-10BE-4C95-BE35-C9A03DBA4006 - iCloudId part = 39E0E3A6-6A37-4E8E-83E9-C1B837E2E973 - iCloudId full = 39E0E3A6-6A37-4E8E-83E9-C1B837E2E973:001:ARUcJ2AQQ/nM6BIRu2dq/NSPi61u Phone2: - assetId part = F51B272C-1BE6-41B3-AB54-39E6BDE1C984 - iCloudId part = F51B272C-1BE6-41B3-AB54-39E6BDE1C984 - iCloudId full = F51B272C-1 BE6-41B3-AB54-39E6BDE1C984:001:ARUcJ2AQQ/mM6BIRu2dq/NSPi61u
0
0
65
2w
How to get iCloud item(photo/video) size?
How I can get iCloud photo file size? Could I use private API like this in prod? Does anyone know another way? (without downloading the file to the device) func getFileSize(asset: PHAsset) -> Int64? { let resources = PHAssetResource.assetResources(for: asset) let resource = resources.first let size = resource?.value(forKey: "fileSize") as? Int64 return size }
1
0
381
Mar ’26
PhotoKit. Changing iCloudId between devices.
While developing a gallery app, I noticed that the iCloudId can change between devices Phone1 and Phone2, on which iCloud is active. First, I know the assetId is unstable, but the iCloud ID ( How it can be? I thought it was stable and I could use it for sending, for example as a UUID for a items on BE to prevent duplication. Could you please explain to me in which cases the iCloudId can change, and what I can use for stable UUID for my internal item to prevent duplication on the BE side? Additional info: Phone1: - assetId part = B01B27D9-10BE-4C95-BE35-C9A03DBA4006 - iCloudId part = 39E0E3A6-6A37-4E8E-83E9-C1B837E2E973 - iCloudId full = 39E0E3A6-6A37-4E8E-83E9-C1B837E2E973:001:ARUcJ2AQQ/nM6BIRu2dq/NSPi61u Phone2: - assetId part = F51B272C-1BE6-41B3-AB54-39E6BDE1C984 - iCloudId part = F51B272C-1BE6-41B3-AB54-39E6BDE1C984 - iCloudId full = F51B272C-1 BE6-41B3-AB54-39E6BDE1C984:001:ARUcJ2AQQ/mM6BIRu2dq/NSPi61u
Replies
0
Boosts
0
Views
65
Activity
2w
How to get iCloud item(photo/video) size?
How I can get iCloud photo file size? Could I use private API like this in prod? Does anyone know another way? (without downloading the file to the device) func getFileSize(asset: PHAsset) -> Int64? { let resources = PHAssetResource.assetResources(for: asset) let resource = resources.first let size = resource?.value(forKey: "fileSize") as? Int64 return size }
Replies
1
Boosts
0
Views
381
Activity
Mar ’26