CodeIgniter Forums
Using XML-RPC to access Box.net api - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Using XML-RPC to access Box.net api (/showthread.php?tid=12224)



Using XML-RPC to access Box.net api - El Forum - 10-10-2008

[eluser]Unknown[/eluser]
Hello,
I am trying to access my box.net account from a custom CI application. I am using the XML interface provided by Box.net. Here is the standard box.net request XML
Code:
<?xml version='1.0' encoding='UTF-8' ?>
<request>
    <action>get_ticket</action>
    <api_key>rrc1d3ntb53tt6b2vhail6rdtrsxov3v</api_key>
</request>

and the expected response is :
Code:
&lt;?xml version='1.0' encoding='UTF-8'?&gt;
<response>
    <status>get_ticket_ok</status>
    <ticket>bxquuv025arztljze2n438md9zef95e8</ticket>
</response>

This is the request array that I used:
Code:
$request = array(
                 array(
                       // Param 0
                       array(
                             'action'=>'get_ticket'
                             ),
                             'struct'
                       ),
                       array(
                             // Param 1
                             array(
                                   'api_key'=> $api_key
                                   ),
                             'struct'
                       )
                 );

However, I am getting the following error while trying to connect:
Code:
---DATA---
HTTP/1.1 200 OK
Server: nginx/0.6.32
Date: Fri, 10 Oct 2008 17:37:31 GMT
Content-Type: text/xml
Connection: close

&lt;?xml version='1.0' encoding='UTF-8' ?&gt;
<response><status>Wrong input XML</status></response>
---END DATA---


---Invalid Return--- Top level XML-RPC element is missing---Invalid Return--- The XML data receieved was either invalid or not in the correct form for XML-RPC. Turn on debugging to examine the XML data further. Top level XML-RPC element is missing

I'm afraid, the request array is not of the correct form. Can somebody help me to create the right array for the request XML posted above?

thanks
libregeek.


Using XML-RPC to access Box.net api - El Forum - 02-25-2011

[eluser]alexaaaaaaaaaa[/eluser]
Hi, i have the same error like you, did you fixed it???


Using XML-RPC to access Box.net api - El Forum - 02-25-2011

[eluser]Unknown[/eluser]
Sorry, I don't remember whether I solved this issue. If I remember correctly, the client dropped this enhancement and I didn't got time to look into it further.


Using XML-RPC to access Box.net api - El Forum - 02-25-2011

[eluser]alexaaaaaaaaaa[/eluser]
Ok, i was asking becouse i'm also working for the first time with XML-RPC and codeigniter.
Thank you anyway.