Questions tagged [cloudkit-js]
16 questions
3
votes
2 answers
CloudKit JS Hello World Example: No Auth Method Found
I'm working through Apple's CloudKit Catalog example, and I'm just trying to get authentication to work. I want to run this JS code in a browser window (not Node JS). I have taken their code from their site like this:

Clifton Labrum
- 13,053
- 9
- 65
- 128
2
votes
0 answers
Cannot authenticate CloudKit JS using apiTokenAuth only without serverToServerKeyAuth
I am building a web in Node that uses data stored in iCloud using CloudKit on a Public Database. To query the data I have created an apiToken and a serverToServerKey. For the first one I have a string but for the server to server authentication I've…

javierdemartin
- 595
- 6
- 24
2
votes
1 answer
How to save records with Asset field use server-to-server cloudkit.js
I want to use server-to-server cloudkit js. to save record with Asset field.
the Asset field is a m4a audio. after saved, the audio file is corrupt to play
The Apple's Doc is not clear about the Asset field.
In a record that is being saved to the…

Haozes
- 352
- 2
- 12
1
vote
0 answers
CloudKit Bad Request on Users Record Update with Web Services API
I added a custom field to the default Users record type in CloudKit, and I'm trying to push a value to that new field.
Here's how my request is structured in Node JS:
var query = {
operations :[{
operationType: 'forceUpdate',
record:{
…

Clifton Labrum
- 13,053
- 9
- 65
- 128
1
vote
1 answer
Cloudkit JS - Is there possible to generate Api token dynamically without using iCloud dashboard
I need to access iCloud container private database data from web, so i am using cloudkit js and I can access the iCloud container private data using containerIdentifier and apiTokenAuth.apiToken.
The apiToken is genereated by using iCloud…

karthy periyasamy
- 45
- 8
1
vote
2 answers
Add CloudKit JS to Vue Project
I'm trying to add CloudKit JS to a new Vue project. Ideally I'd be able to access CloudKit's functions from any component in my app. I'm brand new to Vue, so please go easy on me. :)
So far, I've tried putting the following in main.js:
var fetch =…

Clifton Labrum
- 13,053
- 9
- 65
- 128
0
votes
0 answers
CloudKit JS issue with Advanced Data Protection
I am using CloudKit JS to allow users to access iCloud data through a web page. It was working fine until I enabled Advanced Data Protection. After enabling ADP (and the "Access iCloud Data on the Web" option), I received this error when requesting…

Arnol
- 2,107
- 2
- 17
- 19
0
votes
1 answer
setting ko observable inside a promise not working
I have a view model below (from an article about cloudkitjs). The problem is that the observables are not changed in the return from the db call. The page displays recCount as 3 even though the db call finds 40 records.
function TILViewModel()
{
…

john elemans
- 2,578
- 2
- 15
- 26
0
votes
1 answer
Why does CloudKit JS "sortBy" return a different order on Safari?
I'm trying to mirror a high scores leader board from my app on a webpage. Following an old raywenderlich tutorial I am using CloudKit JS and Knockout to accomplish this.
Naturally, I want to sort by scores from highest to lowest.
The example code in…

Hyoryusha
- 175
- 1
- 11
0
votes
0 answers
What is the best way to access CloudKit from C#?
I have a website using ASP.NET (Blazor server-side) on which I'd like to display data loaded from CloudKit. What is the best way for me to use only C# code to query CloudKit and receive data and pass the data to a Blazor component that is already…

Todd
- 500
- 4
- 10
0
votes
1 answer
CloudKit JS deserialize [Double] Transformable type data
I followed How to save Array to CoreData? to create a Transformable field in my data model, and have saved records of that type to CloudKit. I would now like to access this data from a web app. How can I deserialize it?
The data looks like this in…

Peter Lu
- 157
- 2
- 11
0
votes
1 answer
401 Error on CloudKit Server-to-Server Authentication on Node JS
I'm trying to query my public CloudKit database using server-to-server authentication. I've generated the key according to Apple's docs, but no matter what I do I get this error:
401 - Unauthorized
data: {
uuid: '...',
serverErrorCode:…

Clifton Labrum
- 13,053
- 9
- 65
- 128
0
votes
1 answer
How to save a CLLocation with Cloudkit JS
I'm using Cloudkit JS to save data to a public database. Its easy to do when the fields are all strings. I'm stuck now trying to figure out how to save data when the field type is a CLLocation. Somehow I need to structure the JavaScript to send both…

GoPlaces
- 3
- 2
0
votes
1 answer
Unable to connect with CloudKit-JS CONFIGURATION_ERROR
I am trying to set up Cloudkit-JS to access an existing Cloudkit database through a web browser. The db itself works fine and I have an iOS app which connects to the db without any problems.
I've generated an API Token in the Cloudkit Dashboard and…

GoPlaces
- 3
- 2
0
votes
1 answer
Can we create an API token for Cloudkit JS, to access shared data without authentication
I created an iCloud user webuser@somedomain.com then I shared specific records with that user.
What I want to do is have a web site use that user to access only the shared records it can access but without having him authenticate through iCloud with…

Patrick Miron
- 221
- 3
- 12