Fetching Zones (zones/list)
This request fetches all the zones and their sync tokens in the specified database.
Path
GET [path]/database/[version]/[container]/[environment]/[database]/zones/list
Parameters
- path
The URL to the CloudKit web service, which is
https://api.apple-cloudkit.com
.- version
The protocol version—currently, 1.
- container
A unique identifier for the app’s container. The container ID begins with
iCloud.
.- environment
The version of the app’s container. Pass
development
to use the environment that is not accessible by apps available on the store. Passproduction
to use the environment that is accessible by development apps and apps available on the store.- database
The database to store the data within the container. Pass
public
to use the database that is accessible to all users of the app. Passprivate
to use the database that is visible only to the currently signed-in user.
Response
The response is a dictionary containing the results per zone with the following key:
Key |
Description |
---|---|
|
An array containing a dictionary for each zone in the specified database. If successful, the dictionary contains the keys described in Zone Dictionary. If unsuccessful, the dictionary contains the keys described in Zone Fetch Error Dictionary. |
Zone Fetch Error Dictionary
Dictionary describing a failed zone fetch with the following keys:
Key |
Description |
---|---|
|
Dictionary that identifies a record zone in the database, described in Zone ID Dictionary. |
|
String indicating the reason for the error. |
|
A string containing the code for the error that occurred. For possible values, see Error Codes. |
|
The suggested time to wait before trying this operation again. If this key is not set, the operation can’t be retried. |
|
A redirect URL for the user to securely sign in using their Apple ID. This key is present when |
Related Framework API
This request is similar to using the CKFetchRecordZonesOperation
class in the CloudKit framework.
Referencing Existing Assets (assets/rereference)
Copyright © 2018 Apple Inc. All rights reserved. Terms of Use | Privacy Policy | Updated: 2016-06-13