Working Example with Services 3.x User.Login and System.Connect

Events happening in the community are now at Drupal community events on www.drupal.org.
iTiZZiMO's picture

Has anybody a working user.login example with services 3.x and user.login?

I downloaded the latest repository from this git hub

http://github.com/randallknutson/services

and get the node creation for anonymous user working.

But i cant using the user login method oder system connect. I activate the session authentication , because i think oauth is more complex.

my urls are

i tried with Firefox REST Client Extension and php curl test example:

HTTP-METHOD: POST
url: http://<path to rest>/user/login <- yes the blank page comes!
Content-Type: application/json
Accept: application/json

Body:
{ "username" : "admin" , "password" : "xxx" }

I always get a 406 error with no return message.

On the System.Connect Services, i get an unauthorized error 401 with message User 0 ('anonymous') Access denied.
I thought, that the system.connect is necessary to get the session id for user.login?

I had the same thing on rest 6.x-2.x so i switched to services 6.x-3.x and downloaded the latest version from today.

Thank you very much for your help!
Best Regards
Christian

Comments

Remember that Services 3.x is

voxpelli's picture

Remember that Services 3.x is still in an alpha state - that means it isn't feature complete and might very likely contain bugs of some kind.

If you still want to test 3.x then take a look at the awesome documentation that Heyrocker has created: http://drupal.org/node/736522

See http://drupanium.org/api

lelizondo's picture

See http://drupanium.org/api maybe it could help you, it is based on D7 and Services 3.x but it shouldn't be hard to make it work with D6 once you know the right URIs.

Luis

Can use the drupal 6.x and services 3.x together

stonevo's picture

Hi lelizondo ! currently we have a website with a several defauls and customized services of the services 2.x on drupal 6.x (use the key authenticate tactic and we also use multiple domains for authentication). We have plan to move forward services 3.x. Could you give me some advices. I was also try http://drupanium.org and It's very cool stuff honestly and it maybe intends more for drupal 7.x and services 3.x.

Drupal - The modern Lego game

Services

Group organizers

Group categories

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: