DeleteGroup

Last Updated: Nov 10, 2017

Interface description

Deletes a specified group.

  • Before deleting a group, you must ensure that the group does not have any authorization policies.
  • Before deleting a group, you must ensure that the group does not have any users.

Request parameters

Action
  • Type: String
  • Required: Yes
  • Description: Operation name. Value: DeleteGroup
GroupName
  • Type: String
  • Required: Yes
  • Description: Group name.Example: dev.
  • Format: ^[a-zA-Z0-9\-]+$

Return parameters

Only public parameters are returned. For details, see Public return parameters.

Required permissions

Action

ram:DeleteGroup

Resource

acs:ram:*:${AccountId}:group/${GroupName}

Error messages

InvalidParameter.GroupName.InvalidChars
  • HTTP Status: 400
  • Error Message: The parameter - “GroupName” contains invalid chars.
InvalidParameter.GroupName.Length
  • HTTP Status: 400
  • Error Message: The parameter - “GroupName” beyond the length limit.
EntityNotExist.Group
  • HTTP Status: 404
  • Error Message: The group does not exist.
DeleteConflict.Group.User
  • HTTP Status: 409
  • Error Message: The group CAN NOT has any user member while deleting the group.
DeleteConflict.Group.Policy
  • HTTP Status: 409
  • Error Message: The entity CAN NOT has any attached policy while deleting the group.

Operation examples

Request example

  1. https://ram.aliyuncs.com/?Action=DeleteGroup
  2. &GroupName=Dev-Team
  3. &<Public request parameters>

Return example

XML format

  1. <DeleteGroupResponse>
  2. <RequestId>FCF40AB5-881C-A0F9-334C-B0AD423AA69D</RequestId>
  3. </DeleteGroupResponse>

JSON format

  1. {
  2. "RequestId": "FCF40AB5-881C-A0F9-334C-B0AD423AA69D"
  3. }
Thank you! We've received your feedback.