Creating groups

POST /v3/groups

Create a group in a domain.

Source: https://docs.openstack.org/api-ref/identity/v3/index.html?expanded=create-group-detail#create-group

Request

Parameters

Name In Type Description
group body object A group object.
description (Optional) body string The description of the group.
domain_id (Optional) body string The ID of the domain of the group. If the domain ID is not provided, the Identity service attempts to use the domain ID from the token. This requires a domain-scoped token.
name body string The name of the group.

To find out domain IDs, send a GET request to /v3/domains (refer to Listing domains).

Example

# curl -ks -H 'Content-Type: application/json' -H 'X-Auth-Token: gAAAAA<...>' -d '
{
  "group": {
    "description": "Domain administrators",
    "domain_id": "f2eeaaf15c254d4fa10255796122c8ec",
    "name": "domain_admins"
  }
}' https://<node_IP_addr>:5000/v3/groups

Response

Parameters

Name In Type Description
group body object A group object.
description body string The description of the group.
domain_id body string The ID of the domain of the group.
id body string The group ID.
links body object The link to the group resource.
name body string The name of the group.

Status codes

Success

Code Reason
201 - Created Resource was created and is ready to use.

Error

Code Reason
400 - Bad Request

Some content in the request was invalid.

401 - Unauthorized

User must authenticate before making a request.

403 - Forbidden

Policy does not allow current user to do this operation.

409 - Conflict

This operation conflicted with another operation on this resource.

Example

{
  "group": {
    "description": "Domain administrators",
    "domain_id": "f2eeaaf15c254d4fa10255796122c8ec",
    "id": "c0d675eac29945ad9dfd08aa1bb75751",
    "links": {
      "self": "https://<node_IP_addr>:5000/v3/groups/c0d675eac29945ad9dfd08aa1bb75751"
    },
    "name": "domain_admins"
  }
}