UPGRADE YOUR SKILLS: Learn advanced Swift and SwiftUI on Hacking with Swift+! >>

CloudKit multi user query

Forums > SwiftUI

@JimK  

Hello!

I need some assistance with the below please:

I am developing a multi user collaboration using cloud kit. The model is as follows. There is one manager who has a paid subscription, and there are five team members who use the app for free as part of the managers team. I tried to use unique key codes, but its against Apple policy. How do I invite the team members to be part of the team? using CK share doesn't feel right for this purpose. However, I'm no expert.

Thank you very much for your time, Jim

1      

From my understanding you can't invite any members with CloudKit via app for other people. The user (in your case the manager) has to invite them via share. I asked a while ago if it's possible f.e. to invite people who are in familiy sharing and this wasn't possible, either.

If you look at the different available containers you have private, shared and public containers. How I understand it you would need a shared container. But the shared container is owned (in your case) by the manager and not you as a developer. So only the manager is able to invite people to it and decides how the data is handled.

1      

@JimK  

thank you @Hatsushira for your response. Using CKShare seems cumbersome because every action they do they will have to share, and the team member will have to accept and this will go on for several times while using the app. For example each new doc the manage creates, he/she will have to share it and the team members accept it and so forth. If they are able to share once, and then continue with their work from that point onwards without disrupting the flow, it would be perfect.

Perhaps cloudkit is not cut out for this type of applications (or maybe I dont know how to use it properly :-).

Thought about using offer/promo codes also, but they are for another use case altogether.

Thank you!

1      

Perhaps, on the link you find something helpful. I'm not a experienced CloudKit developer, either. But from my understanding you can't automatically share CloudKit records. There has to be user interaction. Otherwise, a malicious developer could get access to sensitive information without the user knowing it.

https://developer.apple.com/documentation/cloudkit/shared_records

2      

TAKE YOUR SKILLS TO THE NEXT LEVEL If you like Hacking with Swift, you'll love Hacking with Swift+ – it's my premium service where you can learn advanced Swift and SwiftUI, functional programming, algorithms, and more. Plus it comes with stacks of benefits, including monthly live streams, downloadable projects, a 20% discount on all books, and free gifts!

Find out more

Sponsor Hacking with Swift and reach the world's largest Swift community!

Reply to this topic…

You need to create an account or log in to reply.

All interactions here are governed by our code of conduct.

 
Unknown user

You are not logged in

Log in or create account
 

Link copied to your pasteboard.