User groups linked to external groups (LDAP) are automatically synced with these groups on update. Remember this synchronization will remove any LDAP users manually added to the Foreman user group. Only LDAP users in the external groups will remain. Internal users can be added or removed freely.

Примеры

PUT /api/usergroups/3-usergroup190
{
  "usergroup": {
    "name": "test_usergroup",
    "usergroup_ids": [
      4
    ]
  }
}
200
{
  "admin": false,
  "created_at": "2019-09-11 14:33:33 UTC",
  "updated_at": "2019-09-11 14:33:33 UTC",
  "name": "test_usergroup",
  "id": 3,
  "external_usergroups": [],
  "usergroups": [
    {
      "name": "usergroup191",
      "id": 4,
      "created_at": "2019-09-11 14:33:33 UTC",
      "updated_at": "2019-09-11 14:33:33 UTC"
    }
  ],
  "users": [],
  "roles": []
}

Параметры

Имя параметра Описание
location_id
необязательно

Ограничить местоположением

Validations:

  • Must be a Integer

organization_id
необязательно

Ограничить организацией

Validations:

  • Must be a Integer

id
обязательно

Validations:

  • Must be a String

usergroup
обязательно

Validations:

  • Must be a Hash

usergroup[name]
необязательно

Validations:

  • Must be a String

usergroup[admin]
необязательно , nil разрешен

is an admin user group

Validations:

  • Must be one of: true, false, 1, 0.

usergroup[user_ids]
необязательно , nil разрешен

Validations:

  • Must be an array of any type

usergroup[usergroup_ids]
необязательно , nil разрешен

Validations:

  • Must be an array of any type

usergroup[role_ids]
необязательно , nil разрешен

Validations:

  • Must be an array of any type