We are in the development of an iOS(iPhone) application that consumes a web services. We are planning to host our web service (ReSTful web services) in the AWS. Initially we planned to use Restkit or ASIHttpRequest libraries for invoking the web services. Our web services contains GET, POST api and some image uploading for setting the profile photos of the users. Also we are sending video, audio files in to the database and accessing these files through web services. We are using JSON as our output format.
While searching through the web we found that AWS SDK for iOS is this. Can somebody advice us is it possible to do the above requirements (GET/POST/Upload Photo/etc) using AWS SDK for iOS? Or shall we continue with other third-party libraries like Restkit or ASIHttpRequest.
Please advise us.
You can use both ASIHttpRequest and Amazon SDK for IOS at the same time.You would want to use Amazon S3 service (by creating a bucket) for your media files.Amazon S3 is cheap,fast and easy to use. When you download AWS SDK you can see sample folder and an example of S3_Uploader for ios.
For example in my latest app user upload their photos to Amazon S3 and comment&vote to other user pictures etc... I use AWS SDK to upload pictures to the Amazon S3 service. While uploading photos with AWS SDK I keep URL,path, of the photos in a database and use ASIHttpRequest , POSTto update my MYSQL database, which is in another server. When I fetch data from my server I use JSON and AWS SDK.
So If I were you, I would use Amazon S3 for my files(photo,video etc...) and I would use either Amazon EC2 or another web service for rest of the database. I am assuming you keep your data in a database and interact thru GET and POST methods. If so keeping media files and database in separate places would be my choice
Related
I'm trying to distribute an Android and iOS SDK through AWS S3 with credential authentication.
I've already successfully done it on the Android (that I've much more experience).
I've read these two awesome articles:
1 https://medium.com/streamroot-developers-blog/delivering-proprietary-libraries-via-amazon-s3-5aea2b7ccac8
2 https://medium.com/#porten/publishing-android-library-artifacts-to-amazon-s3-buckets-8db4231e844f
What I'm trying to do is something like the second link, that has the AWS authentication baked in.
I've achieved this goal on Android by creating a Groovy script that read the credentials from an encrypted file and communicate with the S3 bucket using Gradle.
How can I achieve the same thing with iOS?
PS.The example on the first link didn't shown how to authenticate
with the S3 bucket, I've assumed that is a public SDK
So my current task at the company I'm interning with is to create a mobile version (iOS) of a web app written using Flask, HTML & CSS that currently exists and is being hosted on AWS's EC2. Assume I'm a complete noob at AWS and only just learned that EC2 is a cloud computing service.
Essentially, I just want to be able to reflect what's currently on EC2 over to a mobile app in a secure fashion. I guess I'm just trying to avoid rebuilding something in Swift that's already been done. For those familiar with WebView in Xcode, I tried to use that to reflect the web page, but it didn't work (I assume because our web app on EC2 requires login credentials when you open it in a browser?).
I thought that maybe using AWS's SDK for iOS would net me some luck, so I installed cocoapods and setup a pod, but don't know how or which of these AWS services will help me achieve what I'm trying to do (from reading the documentation, it seems like their purpose is for building an app, not necessarily just projecting a webpage with data already in it).
For some more information, some key features that I think would be useful for our clients that would be using the app are:
The ability to persist data on the app when their device is offline
Some sort of temporary logins for the users. This app wouldn't be distributed through the app store; it would probably just have to be locally downloaded onto certain clients' devices
Lastly, I saw this post come up before creating this one: Does REST API for mobile apps hosted on https protocol web app will be slow? and I noticed that the asker of this question said "Lets say I have built a mobile app running on Android and iOS platform and REST API's for these apps lie under https based web application." This possibly sounds like something that could be helpful, and if anyone could explain what s/he meant by REST API's and what they are, I would be very grateful.
Any advice on how to proceed from here, using anything, would be much appreciated. Thanks!
I have an mobile application (native iOS) and I want to provide the user the ability to upload videos and associate them to their account.
Some considerations:
I have a Node.js API running on Heroku that I use to maintain the DB.
Videos on will be stored on S3
I am looking for some suggestions on how to architect this. Here is my sequence of events I am thinking...
The app POSTs to the API to create the "event" and receives back an S3 path
The mobile app uploads the video to the S3 path it received in step 1 response.
Upon successful upload the mobile app makes a PUT to update the API that the upload was successful.
I am curious how others have approached this problem.
Your example will work fine.
You can probably get rid of the first POST request to the API and offload the responsibility of dealing with S3 to your client app.
The opposite can also work -- you can have the API deal with uploading, so that you upload your file to the API and then it will store it in S3. This could be beneficial in situations where you have multiple client apps on different platforms and you want to offload all that work to the API instead of each client having to implement it.
I'm trying hard to get my mind wrapped around how you would be able to store files in the cloud from an enterprise app without requesting the user to log in.
The background:
I'm developing an iOS app that will be distributed to certain employees in our company. As of today we already have an app that uses an FTP server to upload user created files. In this new app, I would like to skip the FTP server and instead use some sort of cloud storage (DropBox, Google Drive etc.)
The users will upload some files (around 1-2 uploads per day) to the cloud service, and people at our HQ will be able to look at these files.
I don't want to have each employee create a personal cloud drive account that would be linked with a "master" account. Rather, I want this specific application to always upload it's files to the cloud storage "master" account. Is this even possible?
Since only our employees have access to the app, I don't see the security factor as limiting. The information sent is not of use to anyone else than our company (no high-security stuff).
Is it possible to "hard-code" an OAuth token that corresponds with a certain account that the app always uses? Are there other possibilities that I'm not aware of (other than FTP or cloud storage)?
Any help will be appreciated.
Regards,
Jens Nilsson
how about use one dropbox account and hard code it in your app? then your enterprise user can upload their files respectively. surely you need do some trick to make no any file with duplicate name.
i am developing one iOs application that uses a parse cloud service to upload user generated files.
in that parse service, user dont need to create a account separately.each and every user can be able to uploads files to cloud where user can be able to visit all the files which is in the cloud which is created by some other user.
suppose if we want limit some user files accessibility or upload files privilege also we can achieve that through using the parse.
i just remember parse is not open source.
I have an app using RestKit successfully. I am building an IAP in the app and for iOS5 I needed a place to host the app files for the IAP. I decided using Amazon S3 for that.
Now I now that I can integrate amazon API but I wish to keep my app simple, and since I am using RestKit I just want to use it to download the files.
Is there a guide or explanation on how to generate a bucket url with expiration and secrets ?
Thanks
Shani
Sure: all the information you need is in the Authenticating REST Requests documentation page.
Also, it's not entirely clear from your question, but I hope you're putting the URL generation in some web app somewhere that you control, rather than directly embedding it in the IOS app. I also hope you're using IAM to restrict that key to the appropriate permissions level regardless.