Search code examples
icloudcloudkit

CloudKit: Is it possible to have a custom zone in a public database?


I might get involved in building a Cloud Kit enabled App if the subscription service is available in the public domain.

Having subscriptions for custom zones in a private database would surely only allow you to register for changes YOU have made somewhere else?


Solution

  • Answering the question from your question title: The documentation of CKRecordZone says:

    A CKRecordZone object defines an area for organizing related records in a database. Zones are an important part of how you organize your data. The public and private databases have a single default zone, and in the private database you can create additional custom zones as needed. Use custom zones to arrange and encapsulate groups of related records in the private database. Custom zones support other capabilities too, such as the ability to write multiple records as a single atomic transaction

    So you can not create a zone in a public database

    You are right. A private database is always linked to only 1 apple ID. If you want to receive notifications for changes in the private database, then both the user/device making the change and the user/device that has to receive the notification must be loged in using the same Apple ID.