tracker issue : CF-3346538

select a category, or use search below
(searches all categories and all time range)
Title:

Http request to PhoneGap build API with valid data results in invalid data error

| View in Tracker

Status/Resolution/Reason: Closed/Withdrawn/CannotReproduce

Reporter/Name(from Bugbase): / ext-user (Akhila K Srinivas)

Created: 10/15/2012

Components: Net Protocols, HTTP

Versions: 10.0

Failure Type:

Found In Build/Fixed In Build: Final /

Priority/Frequency: Major / Few users will encounter

Locale/System: English / Mac 10 All,Win XP All

Vote Count: 0

Problem: When http POST request was made to PhoneGap build API, with valid data using <cfhttp>, the response is an error indicating "invalid data error". The same API with same data when tried from Node.js, the request was successful.

Method: Code snippet to illustrate this issue:

<cfhttp method="POST" url="https://build.phonegap.com/api/v1/apps"  result="res" multipart="true" multipartType="related"  username="aksriniv@adobe.com"  password="xxxxx" charset="UTF-8"> <cfhttpparam type="formfield" name="data" value='{"title":"API V1 App","package":"com.aks.test","version":"0.1.0","create_method":" file"}' encoded="false" /> 
<cfhttpparam type="file" name="file" file='C:\Users\Akhila\Dropbox\websites\testingzone\index.html' />  </cfhttp>
Result:

Expected:

Workaround:

----------------------------- Additional Watson Details -----------------------------

Watson Bug ID:	3346538

External Customer Info:
External Company:  
External Customer Name:  
External Customer Email:

Attachments:

Comments:

When tried to create a phonegap application, with the below code snippet, we were able to create it successfully : <cfhttp method="POST" url="https://build.phonegap.com/api/v1/apps" result="res" multipart="true" multipartType="related" username="***@adobe.com" password="***" charset="UTF-8"> <cfhttpparam type="formfield" name="data" value='{"title":"API V1 App","package":"com.aks.test","version":"0.1.0","create_method":"file"}' encoded="false" /> <cfhttpparam type="file" name="file" file='#expandPath(".")#\index.html' /> </cfhttp> In "index.html" : <html> <head> <title> From title.. </title> </head> <body> Hello World!!! </body> </html>
Comment by Akhila K.
17548 | March 03, 2014 03:53:06 AM GMT