Access iCloud application data from linux - ios

I have a web application for my own use that accesses the data from an iPhone application (It's a bill tracking app, and I have a little web-app that generates a simple page with graphs, and calculates the utility division for my roomates).
This iPhone application previously supported syncing data via dropbox, but with dropbox's recent drop of their v1 API, the application decided to drop dropbox all together, and currently only supports syncing via iCloud.
How can I access my iCloud data? More specifically, I need to do this from linux.
I've been experimenting with PyiCloud, and while I can access my iCloud "drive", the application specific data storage does not appear to be stored there. Reading about, iCloud seems to have a quite complex API, but how it actually works is basically undocumented, as far as I can tell.
I assume the "correct" approach is "use a mac", but I don't have any mac servers (I don't have a mac at all, at the moment, actually).
So, all that said, I've been unable to determine how to do this. Is this something I'd use CloudKit for? That seems like it's more for the developer of an app to use for their users, rather then something I (as an end-user) would use for accessing my account.
All I want is to get the blasted app data from a single application automatically.
I'm using python, but frankly if there's an example in any language, I can probably port it to my language of choice.

Related

Sharing data between apps on iOS

I have several small apps that share common data (images, sounds files, etc). This data bloats the size of each app. When the user installs 2 or more of these apps that will bloat the device space with duplicate data. Is there a way that I can share this data between my apps so that each app doesn't duplicate this data within its bundle?
You can have a common file space between apps by using app groups. An example of how to use them can be found here: Sharing data in between apps in IOS
You can use this as part of a solve for not duplicating the data in every bundle. One way might be to have the data hosted on a server somewhere and when the app is installed you can check the App Group for the common data, if it is not there, you can download it and store it there. Then the next app that is installed will have the data already available. This should help avoid having to include it in every small app.
You can set up the code to check the shared location and download the data in a framework and share it between all your apps making it a bit easier to maintain. If you do not already have a content management system then you could google for a few that have iOS support. There are many out there. You would then host the shared data there. This would give you the ability to update the data for each app while they are in the field which could be a time saver. If these apps are very small though, this may be overkill.
No, this is not currently possible. Ideally, this kind of resource-sharing would require creating a common framework bundle that would have to
be submitted separately to the App Store as a third-party framework, so that even if only one of your apps is present on the
device, it would be able to load the appropriate resources and function properly.
Apple currently only allows third-party frameworks embedded within the app bundle.
Even if two of your apps use the same exact version of your framework, they have to embed it separately.

Core Data iCloud sync or smth else?

I build an iOS app which works with base. User can work with it everywhere, that is cool. When application starts for the first time, obviously, base will be empty. For now, user's base stores data locally with Core Data. But there is a case, when user may have his own base with a lot of data and he do not want to start work from scratch. For this reason I want to create simple Cocoa App for macOS, which will allow user to import some data from, for example - CSV file.
Both Core Data models (iOS app and macOS app) will be the same. I just want to make sync between two platforms.
I think it's possible with cloudKit, but which way is the best? Core Data Sync or smth like supporting MySQL database on server, etc...
Thanks in advance!
Asking which method is "best" is a matter of opinion, but in mine, Apple has made working with iCloud fairly simple. If all you want to do is sync between platforms, I would use cloudKit. There seems to be no reason to spin up your own MYSQL database instance and introduce another level of complexity, when the functionality you're looking for is free and easily accessible.
See this WWDC16 video for some cloudKit tips: https://developer.apple.com/videos/play/wwdc2016/226/

Storing an array online for access in iOS app

I have an array of integers that I'm using in an iOS app which is liable to change. Instead of updating the app each time the integers change, is there a way I can store the array online and access it within the app?
Where would I be able to store the information and what is the mechanism used to retrieve it in iOS?
CloudKit will probably work, but it seems like overkill, especially if the dataset isn't per-user. If don't mind paying for the backend, Amazon AWS can provide a place to host the dataset for use in your app.
You could try Parse heres a tutorial on how to set it up, https://parse.com/docs/ios_guide#top/iOS.
You can have the data served by any web server in the world. Then you can query it, either using the standard NSURL* family (and then parsing the contents, depending on the chosen format), or using libraries such as RestKit that will do both at once.

hybrid mobile app development features

I am developing one mobile app, the requirement is as follows.
1.The app should work offline and online.
2.It should have database in both local device and in the server.
3.When internet is on data has to be synced between local and server.
4.At any point of time local data and server data should be the same.
I have done lot of research on this but not able to find whether hybrid app development supports or not. Some one says we can do but other link says it's difficult and might not be possible.
Please help to me sort out this issue.Thanks in advance
for sure it is possible to have those features in an hybrid app. All depend what you choose to use to deal with that or how you choose to program it.
Remember than an hybrid app have almost all features that a web application could have as it could use almost all technologies, tricks, frameworks and libraries out there.
I have already developed an hybrid mobile app using cordova, jquery and jquery mobile that meet points 1 to 3. Though I am not saying you need to use jquery, or any of the other tools. I described the solutions I use for that app, however they are maybe not the best but it was the most practical and easiest solutions given the time frame and budget.
Was achieved by mirroring the server "data base" the first time the app is installed with WiFi access. When no internet is available the the app use the local data, when it is available then it take the data from the server and update the local data.
The local database was not a formal one, just JSON data files, very similar to the ones provided by the web service.
You can be checking for an active internet connection with the cordova network functions, once detected try to reach the server to check if the actual connection is working, on success then proceed to request mirroring the data. Just be sure to check if the local data is newer to the server one and instead of overriding you should first update the changes in the server.
I think this point is a bit difficult given the fact that you want to work offline. When you are offline you couldnĀ“t do too much to reflect the server data into the app, as you are offline. Then having an exact mirror at any time is not feasible. However having a mirror when you have connection then that is another story.
Having a perfect data sync should be done carefully and instead of programming you own solution try to use a service or tools for that, like http://www.couchbase.com/mobile.
Hope it helps.
Hybrid applications are, at core, websites packaged into a native wrapper. They look and feel like a native app. Hybrid app have main features are portability (one code base, multiple platforms), Access to various hardware/software capabilties, cheaper orginigation costs, faster speed to market.

Share Files between Apps on the same iPad (Without iCloud)

I have two iPad apps, one which downloads data from a server and stores it on the iPad and another one (the main app) which uses the data later.
(It would make sense to combine the two but it's a client requirement)
But I see no way to share the data between the two apps.
I have heard there are ways to do it using:
Custom URL Schemes
Document Support on iPad Devices
UIPasteboard
But I cannot find any thing explaining how to use any of these effectively.
Can anyone point me in the right direction.
Just to clarify:
It is an iPad only app
Both apps will not run at the same time
Basically I need to access the documents or caches folder of one app from another
Using iCloud or any other third part service is not possible
It would be great if I could make the downloader app into a sort of configuration page for the main app (if it is even possible)
So keeping these in mind which one would be the most suitable?
This link at github may be useful... Looks like someone has already made a file manager, using these elements you may be able to do what you are looking for. But as far as I know, your app is extremely sandboxed and does not really interact with other apps/the file system very much at all (Apple is very limiting that way)
EDIT
this post seems to have the explanations of local data sharing methods you were looking for. None of the methods in this post requires any connectivity, just a device and 2 apps :) Good luck!

Resources