You are not logged in.
Announcement
Unanswered posts
|
Pages: 1
Good day Talend community!
I have a problem trying to connect to Magento via XMLRPC.
I created test php file to check connection from Magento side - it works fine.
When I'm trying to access using tXMLRPCInput element I receive the following error:
Exception in component tXMLRPCInput_1
org.apache.xmlrpc.XmlRpcException: Method "customer.list" does not exist
at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(XmlRpcStreamTransport.java:184)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:145)
at org.apache.xmlrpc.client.XmlRpcHttpTransport.sendRequest(XmlRpcHttpTransport.java:94)
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:53)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:166)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:136)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:125)
at eav.xmlrpc_0_1.xmlrpc.tXMLRPCInput_1Process(xmlrpc.java:413)
at eav.xmlrpc_0_1.xmlrpc.runJobInTOS(xmlrpc.java:736)
at eav.xmlrpc_0_1.xmlrpc.main(xmlrpc.java:610)
I found out that this error doesn't depends of login data (I've tried removing login data, or putting wrong values) - the error remain the same.
Problem solved. I was treated XMLRPC in wrong way.
Well, never mind that. Figured it out myself.
Turns out that the Magento API's are arguments to the call method.
tXMLRPCInput
* method: "login"
* parameters:
"username" -> "apiUser"
"password" -> "apiKey"
Returns a session key. I map it to a context variable.
tXMLRPCInput
* method: "call"
* parameters:
"" -> context.magentoSession (no name, that's right)
"" -> "product.list" (no name, that's right)
That'll get you talking to the API.
Offline
Pages: 1