Server Error 500 when using [uploadFile] function to upload local file to [Account]

Server Error 500 when using [uploadFile] function to upload local file to [Account]

We would like to upload file to one of accounts using Zoho API.
However we get Server ERROR 500 when trying to do it.
What are we doing wrong?

Detais of request:

  1. POST https://crm.zoho.com/crm/private/xml/Accounts/uploadFile HTTP/1.1
  2. Content-Type: multipart/form-data; boundary=----------------------------8cff92225060c35
  3. Host: crm.zoho.com
  4. Content-Length: 573
  5. Expect: 100-continue


  6. ------------------------------8cff92225060c35
  7. Content-Disposition: form-data; name="scope";

  8. crmapi
  9. ------------------------------8cff92225060c35
  10. Content-Disposition: form-data; name="authtoken";

  11. 15eb4ee57fb1a4623b2e8b8692dadcfe
  12. ------------------------------8cff92225060c35
  13. Content-Disposition: form-data; name="id";

  14. 681948000000123012
  15. ------------------------------8cff92225060c35
  16. Content-Disposition: form-data; name="content"; filename="C:\Temp\test.txt"
  17.  Content-Type: application/octet-stream

  18. test
  19. ------------------------------8cff92225060c35


Response is following:

  1. HTTP/1.1 500 Internal Server Error
  2. Strict-Transport-Security: max-age=432000
  3. Set-Cookie: JSESSIONID=7BB6CF991DDD4C6C9D906B565660F63F; Path=/crm
  4. Set-Cookie: a623215f16=3; Path=/
  5. Content-Type: text/html;charset=UTF-8
  6. Date: Wed, 27 Mar 2013 14:49:12 GMT
  7. Server: ZGS
  8. P3P: CP="CAO PSA OUR"
  9. Transfer-Encoding: chunked

  10. 8be

  11. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
  12. <html><head></head>
  13.      
  14. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
  15. <html><head><title>Zoho CRM - Error</title><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><meta http-equiv="Pragma" content="no-cache"><link href="/crm/css/blue_banner.css" rel="stylesheet" type="text/css"></head><body leftmargin="0" topmargin="0" class="bodyBg" marginheight="0"
  16. marginwidth="0">
  17. <table width="98%" height="100%" border="0" align="center"
  18. cellpadding="0" cellspacing="0"
  19. style="background-color: rgb(255, 255, 255);">
  20. <tbody>
  21. <tr><td height="400" align="center" valign="middle"
  22. class="layoutBorder" style="padding-bottom: 10px;">
  23. <table border="0" cellpadding="0" cellspacing="0" width="670"><tbody>
  24. <tr align="left"><td class="signinTxt" style="color: rgb(0, 0, 0);"> <table border="0" cellspacing="0" cellpadding="0"
  25. width="100%" background="/crm/images/genPgBg.gif">
  26. <tbody>
  27. <tr><td><img src="/crm/images/genPgLeft.gif"></td> <td><img src="/crm/images/genPgLogo.gif"
  28. alt="Zoho CRM" title="Zoho CRM" border="0"></td>
  29. <td><img src="/crm/images/genPgError.gif"
  30. alt="Errors" title="Errors" style="border: 0px solid ;"></td>
  31. <td width="100%" class="alignright normalTxt"> <br></td></tr></tbody></table></td>
  32. <td class="alignright" nowrap="nowrap" valign="middle"> <br></td></tr><tr><td height="180" colspan="2" align="center" valign="top"> <table border="0" cellpadding="0" cellspacing="0"
  33. width="100%">
  34. <tbody>
  35. <tr><td align="left" valign="top"> <table cellpadding="5" cellspacing="5" width="100%"
  36. style="border-top: 1px solid rgb(204, 204, 204);">
  37. <tbody>
  38. <tr><td class="NormalTxt"><br><div align="center"><b>Sorry, the page you have requested was not found</b></div></td></tr><tr><td height="73" align="center" class="NormalTxt"><br>Please check the URL for proper spelling and capitalization.<br><br>If you're having trouble locating a destination on Zoho CRM, try visiting the Zoho CRM home page.<br><br>Go to <a href="/crm/ShowHomePage.do">Home Page</a>
  39. <br><br><br><br></td></tr></tbody></table></td></tr></tbody></table></td></tr><tr><td height="50" colspan="2"><br></td></tr></tbody></table></td></tr></tbody></table></body></html>
  40. </html>
  41. 0