Trouble with the API

Suggestions for our page
Kippers
Newbie
Posts: 7
Joined: Sun Oct 19, 2014 3:18 pm

Post by Kippers » Tue Oct 21, 2014 9:50 pm

Yeah the 302 session error for the search() method was a mistake on my part. I'm now receiving subtitle information for this test file, using your above XML structure.

So that's search() and supportedLanguages() both working. Thanks a bunch! It's much appreciated.

User avatar
MasterMind
Administrator
Posts: 1966
Joined: Wed May 21, 2003 7:41 pm
Location: Ljubljana

Post by MasterMind » Wed Oct 22, 2014 8:28 am

Actually, vector and array are both lists (just they are implemented differently). The first vector is because the API does not handle variable number of parameters (that why it has a vector paramater for this).

So this kind of params should work (pseudo representation!):

Code: Select all

params = Vector(session, Vector(hash1, hash2, ...))
The docs mention list because the whole system is implemented in python. In python you have lists, while in Java you have arrays, vectors, linkedlists etc.

Kippers
Newbie
Posts: 7
Joined: Sun Oct 19, 2014 3:18 pm

Post by Kippers » Wed Oct 22, 2014 10:57 am

Yeah that's what I meant, Vector in a Vector. First example you gave only had one Vector for parameters.

For the sake of being thorough I tried your above suggestion for the search() method with the Apache XML-RPC library, with this result:

Code: Select all

org.apache.xmlrpc.client.XmlRpcClientException: Failed to parse servers response: Expected name, got value
But hey who needs a library when you can do it yourself :)

User avatar
MasterMind
Administrator
Posts: 1966
Joined: Wed May 21, 2003 7:41 pm
Location: Ljubljana

Post by MasterMind » Wed Oct 22, 2014 10:59 am

Strange implementation :) .

Sitho1983
Newbie
Posts: 1
Joined: Mon Aug 13, 2012 12:54 pm

Re: Trouble with the API

Post by Sitho1983 » Sat Dec 24, 2016 2:50 am

Hi Kip. Is your application working?

MichaelVaf
Newbie
Posts: 5
Joined: Sat Jun 09, 2018 11:21 am
Location: Virgin Islands
Contact:

Trouble with the API

Post by MichaelVaf » Tue Jul 31, 2018 2:37 am

WIFE: "There's trouble with the car. It has water in the carburetor."

HUSBAND: "Water in the carburetor? That's ridiculous."

WIFE: "I tell you the car has water in the carburetor."

HUSBAND: "You don't even know what a carburetor is. I'll check it out. Where's the car?"

WIFE: "In the pool."

Post Reply