I am using the public cloud database to store my application data, this data is accessed by all users of the application, but at some point it is necessary for a user who did not create a respective data in the database to delete it, but from what I read in the documentation this is not possible, only with a permission. How do I allow a user to change or delete any data created by another user in the public cloud database?
CloudKit Dashboard
RSS for tagMonitor and manage the CloudKit database containers used by your apps.
Posts under CloudKit Dashboard tag
28 Posts
Sort by:
Post
Replies
Boosts
Views
Activity
Hello,
We have a problem and we don't know how to solve it.
Our application uses CloudKit databases.
We can no longer access the CloudKit databases. When we connect to the CloudKit console and select CloudKit Database, we get the message "No Containers".
However, the application continues to work by downloading files located on CloudKit Database.
How can I modify CloudKit Database data?
Hello, everyone!
I'm currently working in creating a new web app that will replicate the functionalities of an existing iOS and Mac app.
However, since those apps rely on CloudKit to manage all user information, we decided on using CloudKit JS as our backend for our web app. The framework we chose for developing our frontend is React.
The question is, since this documentation only mentions the CloudKit JS usage through a CDN (embedded directly in the HTML file) I wanted to ask:
is there a "suggested" method for using CloudKit JS in a React project other than importing the CDN in the main html file?
in case not, should we use a "traditional" server to access data like they suggest in this thread?
All your help will be very much appreciated.
Best regards, Eduardo
I'm building two apps. They both share a CloudKit container. One application is designed to edit the contents of the public database regardless of who a record's creator is. The other should only be allowed to read from the public database.
Since CloudKit is largely a client-side framework it's easy enough to enforce this client side.
Are there any additional guarantees that iCloud provides to enforce what the clients are signed to do? Or is there a risk of having some actor tamper with the public database that isn't using the editing application?
Afternoon all,
I am starting out and want to store data in the App, some will be user specific and some general. So I have a new developer account which should have CloudKit permissions.
I am just trying to make any of the most basic example applications work, but keep hitting issues.
I create an App, select CloudKit and SwiftData. When I go into the signing and capabilities I select the Team which has the developer account. Then the CloudKit is selected as I clicked it when creating the project, but no Container is selected. I create a Container using the +, it names it iCloud.com.mydomain.AppName. However it is coloured in Red text.
I press the refresh and then it turns into black text, the Push Notifications appear all populated for 1 second then all disappear. I have nothing under Push now, only a Trashcan button.
The Container is now selected however.
Is this an issue that the Push notifications items appeared then vanished?
When I then try to run the app, using any of the many attempts I have had with simple code samples, it always fails to create the Container, usually with an error like this:
error: Store failed to load. <NSPersistentStoreDescription: 0x600000c79ce0> (type: SQLite, url: file:///Users/cal/Library/Developer/CoreSimulator/Devices/6D2BA1B3-C7CA-499D-A280-AFF4C5E98180/data/Containers/Data/Application/B9CD5E35-08BD-44CC-A72D-EB170E3691C6/Library/Application%20Support/default.store) with error = Error Domain=NSCocoaErrorDomain Code=134060 "A Core Data error occurred." UserInfo={NSLocalizedFailureReason=CloudKit integration requires that all attributes be optional, or have a default value set. The following attributes are marked non-optional but do not have a default value:
Item: name} with userInfo {
NSLocalizedFailureReason = "CloudKit integration requires that all attributes be optional, or have a default value set. The following attributes are marked non-optional but do not have a default value:\nItem: name";
If I go into the CloudKit database view on Apple, I see the Container listed, albeit it is marked as not deployed to production.
To try to remove my newbie issues I have used many web examples, the most recent of which was the "A Beginner’s Guide to SwiftData with a to-do app" from medium.com, which should just work really, snipped from Item.swift below but I have tried several other simple examples which all give the same issue:
import Foundation
import SwiftData
@Model
class Item: Identifiable {
var name: String
init(name: String){
self.name = name
}
}
Any ideas really appreciated.
Thank you
When I logged into my cloudkit console to inspect the database for some debugging work I couldn't access the private database. It keeps saying "failed to access iCloud data, please signi n again". No matter how many times I sign in again, whether with password or passwordless key it keeps saying the same thing. It says that message when I click on Public database, and private and shared databases are below it. I only noticed this a couple of days ago. It's done this in the past, but I eventually got back into the database but I don't know what changed to make it work.
Very simple one. how do I add “create“ permissions for my CloudKit security roles. For some reason “create“ is greyed out when I try to check the box for _creator
Hi all,
We have an iOS app which has Cloudkit Coredata as storage mechanism. Whenever user logout of iCloud in settings app, then the Coredata is wiped out and no row exists in the tables. Can we prevent this. We want to retain the coredata values until there is another iCloud user logs into settings app.
Thanks
Vinoth