Community Questions & Answers
how to read and write to aws s3 using REST and Titanium ?
I created a free tier membership with amazon web services. I have to upload and download files from my iPhone app. Can someone send sample code to do that. I also created a Access Key ID and Secret Access Key, and looking forward to use REST api of...
Databinding REST Adapter Collections to the TableView
Hi there- Has anyone successfully performed a databind from the Alloy custom rest adapter to a TableView? I definitely have a successful connection from my application to myservices using the restapi adapter, as specified...
Getting the REST Adapter Working with Alloy
Hi all- I am wondering if anyone has had success with the custom REST adapter in Alloy? I am trying to implement the custom REST adapter, as referenced in the JIRA discussion, and linked...
send push notification request to ACS - how to login?
I sent a REST POST request to: https://api.cloud.appcelerator.com/v1/push_notification/notify.json?key=jD...my API key the body is ~~~ "to_ids":"517eb4dda49ecc313e029b30", "payload":{ "badge": 2, ...
Alloy REST Authentication and Using Tokens within the Header Object
Hi all- I have a question. I have setup a system where I am extending my models to make REST queries/saves/etc using the new Alloy framework. Is there a method, or example available that would help me with the following scenario: On authentication, I...
Alloy Model Sync and Persist Data form JSON
I'm using restapi.js to fetch a json feed to an alloy collection. I can fetch the collection, but can't save it to the persistant stored on the device? If I call .save() on the model object i get this error. Basically I just want to call to a web...
Using Alloy and pulling data from a remote REST API (JSON)?
I've been away from Titanium for about 6 months and have just started working on a fairly simple little app, that pulls a list of items from our existing json api with basic authentication. I've been trying to look through the docs, but really cant fathom...
How deal with REST params in alloy model?
Hi Guys! I'm trying to do this: I have a model (like an article from newspaper), and a collection of news (grouped for topics, or sections, etc). I have to get the model from REST WebServices (not implemented by me). I have two kind of web services. One...
Dual Sync Adapter remote/local/cache for Titanium Alloy?
I have a models both on my Alloy mobile app and on my remote backend API. I am just starting the dev to get to connecting. I need to account for offline changes, that would be sync'ed later. I'm hoping for a way to sync data, with some sort of...
Parse.com Query Builder
Two questions, 1.) Is there any interest in a Parse.com query builder? Any feedback would be appreciated if you could give it a try: http://parse.whitneyland.com 2.) Would it be better to generate a full Titanium code method ready to drop in, or to...
REST PUT to AWS S3 -- works on iOS, not Android
What works ---------- We have successfully come up with the code to upload a file using a RESTful PUT to Amazon's S3 simple storage service. We have shared all of our code and required libraries at the links at the bottom of this question. Hopefully...
Backgrounding a network call
What I'm attempting to achieve: I have an iPhone app, that uploads an document to S3. (Already implemented). If the user prefers to save a copy of the document on Dropbox, I'd like to do this in the background. Since the uploading of the document...
fetch() with add:true and tableview
Hi all, I'm learning the brand new Alloy basics and began with a test populating a tableview bound to my models collection (the source is a paginated rest webservice). On table "scroll" event I check if I'm near the end of the list, I increment...
Fail to set Content-Type on POST method of Ti.Network.createHTTPClient
Titanium: 2.1 Device: iOS simulator Host Operation System: OSX 10.7 I made a login request to JSON server of Drupal 7 REST Service 3.x. For the first request, the server returns session info. For the rest requests, server returns 406 error and my debug...
Security in Rest Api
Hi everybody! I've got some quedtions about security. I've created a Rest Server with basic auth. In my app i call with Ti.Network and i specified user and pass in headers, question is, can anybody read this credentials when my app is in AppStore and copy...
Rest API for android push notifications?
Hello All, I am building a very simple app using parse for notifications. My question is how would you use the REST api to register a android device for push notifications. I have provided some links below of stuff I've read but most of it is general REST...
HTTPCLIENT PUT & DELETE
Hi, I see that httpClient can send GET or POST request but is it possible to use DELETE or PUT request. I have to use these method to request amazon api. thanks for help.
How to create mysql query from titanium mobile
How to create mysql query from titanium mobile, is my question. Does anyone have a lead to this? Cheers.
ACS Push not working (Aug 1 2012)
We have been working with the ACS push service for a good part of last night and today and can not get the REST API to send a push. The web console will send a message (after not working last night). So the question is: How can we debug this any...
Best way to return json from a model to view using mvc
Hi All I have started working with titanium and i want to learn best practises from the start i am working with a mvc framework and would like to know the best way to return a json rest response to a view using mvc? here is my...
Calling REST service from Mobile App
Hi all. I would lik to know how I can call a REST service from my Titanium App. Also, does anyone know of an online REST service, that I can test up against? I simple one would be great. Like a Hello-World kind of service, just to see im calling the...
TableViewRows not showing up
I'm having some problems with a TableView I'm trying to create for my app. I'm using REST to pull information from a website I'm developing. The information comes back the way it's supposed to but when I try to add them to my tableview it just shows blank...
REST Service Mapper
I currently use tiggzi. It has a nice REST Service visual mapper. Will Titanium Studio provide such a feature in upcoming version? Does anyone know of a plug-in REST service visual mapper that works with Titanium Studio today?
NTLM support for Network.createHTTPClient()?
Hello all, I'm attempting to make a request to a REST based service that is protected by NTLM authentication. Does Network.CreateHTTPClient() support NTLM authentication? I looked at the kitchen sink code and it has an example for Basic Auth (using...
How to login in gmail using HTTPClient ?
I need to open gmail using HTTPClient and login using my credentials ? how do i pass my credentials in the below code ? ~~~ var url = "http://mail.google.com"; var xhr = Ti.Network.createHTTPClient({ onload: function(e) { ...
Bug when making a GET request with spaces
[INFO] Titanium SDK version: 1.8.1 (01/27/12 17:31 a24502a) [INFO] iPhone Device family: universal [INFO] iPhone SDK version: 4.3 [INFO] iPhone simulated device: iphone [INFO] Found 4.3.2 patch installed I'm making a XHR GET request like: ~~~ var url =...
SalesForce REST API and OAuth "Authentication Needed" Error
I have successfully written code to go through the SF.com User-Agent authentication flow to log an iPad app user on to salesforce. Now that I have the access token, when I try to run a query through the REST API, I am getting an error: [INFO] Error...
Parse.com - users
In the iOS SDK, it has alot of features that allows users to signup, signin, etc to parse.com. When I checked the code from the Forging titanium episode 5, it looks like it's only using what's available in the REST API of parse.com. My question is, are...
Jquery request works, same Titanium request NOT works - Why??
Hello, I have a Jquery request that works great! Here it is: ~~~ $.ajax({ type: 'POST', url: 'http://myurl.com/service', success: function(data){ alert(data); } }); ~~~ Now I converted that into a Titanium.Network.HTTPClient(). Here...
How to read or detect new data in REST Webservice
I've created a REST-webservice with cakePHP for my mobile app. And the idea is to allow customers to load new data in to the system. Now the mobile app will have to check if there is new data available in the system. It can do this by asking the webservice...
Push incremental database updates to app - Best Practices
Hello, I am doing some proof-of-concept work on an app that searches a local SQLite database. **My requirements:** 1. Application database must be updatable independently of Application updates (Database updates are more frequent that Application...
Sending data using JSON to REST service
Hello, I've been following http://developer.appcelerator.com/guides/en/remote_data.html and i'm trying to use the following code for my Rails app: ~~~ var xhr_task =...
Can I use my own API?
Hey, I'm sorry if this is a simple question. I have a web application which accepts data trough a REST API. Can I use appcelerator to develop a iPhone app that GET/POSTs data from the application? Regards, T
RESTful api with GET and POST
Hi I am racking my head over these issue for 2 days.. My server scripts caters for both POST and GET with authentication. Both produces correct json responses with Poster (firefox plugin) but on the iphone, only the POST method is working and the GET...
REST API and JSON and Readystate
Hi I built a REST API using PHP. My iphone app POST json data to the api but never got back readystate == 4. I am returning http status=201 and a content containing json response but the readystate is either 1 or 2 but never 4. And the responsetext is...
XML Identifier
Hi there, i got an issue with a XML that i got from my RESTful webservice. E.g. i got: ~~~ -<name>SomeCoolName</name> -<game id=foo> <name>GameName</name> <desc>Description</desc> ...
Get data from childNodes
Hi there! I tried to get some data from a childNode of my XML. With the help from Chris Reed i got a good way to parse my data from my RESTful Webservice into a XML. Here's the snippet: ~~~ // 200 means it's OK, so as I'm getting XML data I extract the...
REST Connection
Hello! I want to fill my Table with data of a RESTful webservice. e.g. i got www.example.com/category/games as URL and it shows me my data. Is there a way to put them into the table? I'm very new to such topics but need to know hot thats...
Showing 1-38 of 38