Replace or Create a Group

Creates the group when no group with this name exists, and otherwise replaces it with the request. The request body is the same as for Create a Group, except that name may be left out: the name in the path is used. When name is given, it must be the same as the name in the path, or the request is rejected with 400.

Creating: the group is created exactly as Create a Group creates it, in the internal realm, or in the ldap realm when import_from_ldap_group_setting is set (see Create a Group). Returns 201.

Replacing: every field of the request replaces the group's value, and a field that is not sent is reset to its default; for example, a group replaced without admin_privileges loses its admin privileges. The members of the group are replaced by members, so a request without members removes all of them. Returns 200.

Note:

  • This REST API is part of the Access service REST APIs, where modifying the realm and realm attributes parameters is not supported. The group keeps its realm and realm attributes when it is replaced.
  • import_from_ldap_group_setting can only be set for an existing group when the group was imported from the same LDAP group, so that the import yields the realm and realm attributes the group already has, as when the request that imported the group is sent again; otherwise the request is rejected with 400. When it is accepted, the members of the group are left as they are, since LDAP login keeps them in sync with the directory. An import resolves name to the directory's name in lowercase, so the group replaced can be named differently from the path (for example devops for DevOps); the response has its name.

Security: Requires admin privileges.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
string
required

The group name

Body Params
string
required

The group name (required)

string

Group description

boolean
Defaults to false

Whether new users auto-join this group

boolean
Defaults to false

Whether group has admin privileges

string

External ID for SCIM

string

Name of an LDAP group setting to import the group from. The group whose name attribute equals name is looked up in the directory of that setting, using the directory's comparison rule for that attribute (case-insensitive for cn and the other standard name attributes), and created in the ldap realm. LDAP group names are imported in lowercase, so the created group can be named differently from the request (for example devops for DevOps); the response has the created name. The name must identify a single group. Cannot be combined with members; LDAP login manages the members.

members
array of strings

Initial group members

members
boolean
Defaults to false

Whether group has reports manager role. Available from Artifactory 7.128.0.

boolean
Defaults to false

Whether group has watch manager role. Available from Artifactory 7.128.0.

boolean
Defaults to false

Whether group has policy manager role. Available from Artifactory 7.128.0.

boolean
Defaults to false

Whether group has policy viewer role. Available from Artifactory 7.128.0.

boolean
Defaults to false

Whether group manages resources in the default project. Available from Artifactory 7.128.0.

boolean
Defaults to false

Whether group has manage webhook permissions. Available from Artifactory 7.128.0.

Responses

400

Bad Request - Invalid input, name in the body differs from the name in the path, or import_from_ldap_group_setting is set for an existing group that was not imported from the same LDAP group

401

Bad Credentials - Invalid credentials

403

Permission Denied - Insufficient permissions

404

Not Found - One or more users in members were not found, or, when importing an LDAP group, the LDAP group setting or the group in the directory was not found

Language
Credentials
Bearer
URL
LoadingLoading…
Response
Choose an example:
application/json