AnsweredAssumed Answered

Pass a JSON object to the script

Question asked by anusk on Nov 4, 2010
Latest reply on Nov 9, 2010 by anusk
I want to call a webscript from java, but there are some that I don't know how to do it.
For example, I call the webscript to delete a user with no problem, and it works fine, but reading the code of the "PUT /alfresco/service/api/people/{userName}" webscript, the parameter in the URL is only the name of the user and it uses a json object to change the properties…

if (!json.isNull("lastName"))
   {
      person.properties["lastName"] = json.get("lastName");
   }

so if I want to call that script to change the lastname…How would I call the webscript?

Thanks in advance,
Ana

Outcomes