Posted by cjnoyescrisp on March 7, 2011 at 7:54pm
Our company is planning to use the services with drupal to integrate with our other services.
I have done some work with 6-2x and was able to implement and test a client for our purposes using xmlrpc.
We would like to go with 7x I was doing some testing with the services module and 7x, using curl and no matter what I do, I get 404s which bring back the html text of the page, rather than an appropriate response. I have tried curl with the rest and an xmlrpc client testing tool with the xmlrpc
Comments
What method are you
What method are you calling?
Some context on where you're seeing the problem may help. Is this a node resource call? I assume you created a new endpoint and assigned permissions accordingly on it?
-=Aaron
I got past the first issue At
I got past the first issue
At one point while setting up endpoints, the ui seemed to require a full url which didn't make sense. I removed that
Now I am seeing 404 Not Found: Could not find resource ...
try any one.
for instance
curl -v --data-ascii text=something http://drupal.my.mlogic.be/rest/unauthenticated/system/connect
* About to connect() to drupal.my.mlogic.be port 80 (#0)
* Trying 127.0.0.1... connected
* Connected to drupal.my.mlogic.be (127.0.0.1) port 80 (#0)
I noticed this in the code
function _services_build_resources($endpoint_name = '') {
module_load_include('resource_runtime.inc', 'services');
there is no file resource_runtime.inc in the services module
Dear Christopher, Please make
Dear Christopher,
Please make sure you have enabled system resource and connect action in your services endpoint. 7.x version is quite stable and covered with tests. If you have difficulties with calling some methods please check the tests to see how everything is called.
Regarding system connect, in 7.x you can call user.login action without calling system.connect before.
Let me know if you still have difficulties with it.
in rest_server.module the
in rest_server.module the following lines are giving fatals from no method, I see this being fixed in git
drupal_add_http_header('HTTP/1.0 401 Unauthorized', $e->getMessage());
I have had experience with 6.x and I gave the necessary permissions
I am seeing persistent can't find resource i.e. for any resource type
I think the module_load_include is a problem below as I don't see the file it's trying to include
function _services_build_resources($endpoint_name = '') {
module_load_include('resource_runtime.inc', 'services');
I notice sessauth is going away as well as keyauth which was in 6.x, the reliance on oauth is going to be a problem because our intent is to do server to server communications
I would encourage your group to add integration and/or round trip testcases. I.e. a cases where the test invokes a service, I only see test cases for the ui.
I think the best is to use
I think the best is to use 7.x version from git. The tests for resources and actions are placed in folder tests/functional
Updating a user picture using the XMLRPC service.
I'm tring to update a user picture using an XMLRPC service.
It appears that the user.update function accepts two arguments, an int named uid that represents a user id, and a struct named data.
It appears that data must contain a string named current_pass that represents the login password.
I tried adding a struct value named picture to data. My picture struct has three string values, fid, uri, and status.
I also added a string value named mail to data.
When I called user.update, it updated the user's email address but ignored my picture update. What am I doing wrong?