Try to edit data of a single user by Ajax. please Help

Ajax:

function test(){
$.ajax({
     type:"GET",
     url:"../../..ocs/v1.php/cloud/users/test",
     data:{
     "key":"quota",
     "value":"2000MB"    
},
    contentType:"application/json",
    headers:{
     "OCS-APIRequest":"true"
}
    ,success:function(data){
     alert(data);
},error:function(data){
     alert("failed")
}
});

}

Out put:
<ocs>

<meta>

<status>ok</status>

<statuscode>100</statuscode>

<message/>

</meta>

<data>

<quota>

<free>1066630521</free>

<used>7111303</used>

<total>1073741824</total>

<relative>0.66</relative>

<quota>1073741824</quota>

</quota>

<email/>

<displayname>test</displayname>

</data>

</ocs>

then I search

function test(){
$.ajax({
     type:"GET",
     url:"../../..ocs/v1.php/cloud/users/test",
  
    contentType:"application/json",
    headers:{
     "OCS-APIRequest":"true"
},
    success:function(data){
     alert(data);
},error:function(data){
     alert("failed")
}
});

}

Out put:
<ocs>

<meta>

<status>ok</status>

<statuscode>100</statuscode>

<message/>

</meta>

<data>

<quota>

<free>1066630521</free>

<used>7111303</used>

<total>1073741824</total>

<relative>0.66</relative>

<quota>1073741824</quota>

</quota>

<email/>

<displayname>test</displayname>

</data>

it doesn’t change anything …

my idea is from

Examples

  • PUT http://admin:secret@example.com/ocs/v1.php/cloud/users/Frank -d key="email" -dvalue="franksnewemail@example.org"

in user_provisioning_api.

I believe I can use curl to get what I want, but I wanna use ajax.
And here I guess the data:{“key”:“quota”,“value”:“2000MB”} doesn’t work here.

Any one knows how can I solve this?