When retrieving a "perm" field, its format is:
{"field_id":94367,"label":"Visibilit\u00e9","type":"perm","granted_groups":["One","Two"],"granted_groups_ids":["1849","2149"]}
But when updating with such format, we encounter an error:
400 Bad Request: Permission field values must be passed as an array of ugroup ids e.g. "value" : {"granted_groups" : [158, "142_3"]}
Thus, we have to upload something like:
{"field_id":94367,"value":{"granted_groups":["1849","2149"]}}
Please, note the intermediate attribute value
and the drop of suffix _ids
.