Re: Put users in groups - JS app
Hello Danilo,
I see following problems with the JSON:
- grps - must be an Array
- src - must be defined in the root object of the JSON message, not inside of the "columns" object
{
"api": "PbxTableUsers",
"mt": "ReplicateUpdate",
"columns": {
"cn": "Danilo Volz",
"grps": {
"dyn": "in",
"name": "2000-1"
},
"guid": "8e4b16d1d79840ba980043ea0d9523a3",
"h323": "danilo.volz",
"src": "danilo.volz,inn-lab-ipva"
},
}
"api": "PbxTableUsers",
"mt": "ReplicateUpdate",
"columns": {
"cn": "Danilo Volz",
"grps": {
"dyn": "in",
"name": "2000-1"
},
"guid": "8e4b16d1d79840ba980043ea0d9523a3",
"h323": "danilo.volz",
"src": "danilo.volz,inn-lab-ipva"
},
}
Additionally, in case you want to update only the grps, i would use only guid to identify the object in the ReplicateUpdate message, and do not provide other columns like h323 and cn, if they are not changed.
Best Regards
Andreas Fink