Update Group's Users

Updates the list of Users that belong to a Group.

MethodPUT
URLhttps://{subdomain}.kintone.com/v1/group/users.json
Authentication Password Authentication, Session Authentication
Content-Typeapplication/json

Contents

Permissions

Only Administrators (External link) can use this API.

Request Parameters

Parameter Value Required Description
code String Yes The Group's code.
Must be 128 characters or less.
Dynamic groups (External link) cannot be specified.
users Array of Strings Yes A list of User Codes (log-in names) belonging to the Group.
Up to 1000 User Codes can be specified.
Users already belonging to the group will be removed if their User Codes are not included.
To remove all users belonging to the group, specify an empty array.

Sample Request

JavaScript (using Kintone REST API Request)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
var body = {
  'codes': [
    {
      'code': 'Recruit2023',
      'users': [
        'Krispy', 'Morris'
      ]
    }
  ]
};

kintone.api(kintone.api.url('/v1/group/users.json', true), 'PUT', body, function(resp) {
  // success
  console.log(resp);
}, function(error) {
  // error
  console.log(error);
});

curl Sample

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
$ curl -X PUT \
  https://{subdomain}.kintone.com/v1/group/users.json \
  -H 'Content-Type: application/json' \
  -H 'X-Cybozu-Authorization: QWRtaW5pc3RyYXRvcjpjeWJvenU=' \
  -d '{
    'code': 'Recruit2023',
    'users': [
      'Krispy', 'Morris'
    ]
  }'

Response Parameters

An empty JSON object is returned.

Sample Response

1
{}

Limitations

  • Dynamic groups (External link) cannot be updated.
    To update the users belonging to the Groups, edit the conditions of the Dynamic groups.
  • It is not recommended run this API while performing the following operations on the Users & System Administration page: