Nav
You are viewing an older version of this section. Click here to navigate to the latest version.

User Groups

About This Document

This document, as well as the rest of the documents that make up the Mule Management Console REST API Reference Guide, are a technical reference only. This document does not provide contextual information such as instructions, use cases or scenarios. To understand this document, you should be familiar with Mule ESB, User Groups, and the REST API.

Assumptions:

Host

localhost

Port

8080

Deployed app

mmc.war

User/Password

admin/admin

For a detailed description of the format used in this document, consult Content Organization and Conventions


         
      
1
/api/usergroups

POST

CREATE

Creates a new UserGroup.

JSON


    
            
         
1
2
3
4
5
{
  "name" : "NewUserGroupName",
  "description" : "Ability to view activity and delete events",
  "permissions" : ["VIEW_ACTIVITY", "TRACKING_DELETE"]
}
Key Type Summary Child of

name

String

Name of the User Group to be created

 — 

description

String

Description of the purpose of the Server Group to be created

 — 

permissions

String

Permissions assigned to the User Group. A user that belongs to this User Group will have the same permissions.

 — 

Using CURL on Windows


    
            
         
1
l --basic -u admin:admin -d "{ \"name\" : \"TestUserGroup\", \"description\": \"This is a test\", \"permissions\": [\"VIEW_ACTIVITY\",\"TRACKING_DELETE\"] }" --header "Content-Type: application/json" http://localhost:8080/mmc/api/usergroups

Using CURL on Linux


    
            
         
1
curl --basic -u admin:admin -d '{ "name" : "TestUserGroup", "description": "This is a test", "permissions": ["VIEW_ACTIVITY","TRACKING_DELETE"] }' --header 'Content-Type: application/json' http://localhost:8080/mmc/api/usergroups

JSON


    
            
         
1
2
3
4
5
6
{
  "name":"NewUserGroupName",
  "permissions":["VIEW_ACTIVITY","TRACKING_DELETE"],
  "description":"Ability to view activity and delete events",
  "href":"http://localhost:8080/mmc/api/groups/NewUserGroupName"
}
Key Type Summary Child of

name

String

Name of the User Group to be created

 — 

description

String

Description of the purpose of the Server Group to be created

 — 

permissions

String

Permissions assigned to the User Group. A user that belongs to this User Group will have the same permissions.

 — 

href

String

Full link to the resource

 — 

200

The operation was successful

401

Unauthorized user

From

3.3.0

GET

LIST ALL

List details for a specific User Group.

SYNTAX


    
            
         
1
GET http://localhost:8080/mmc/api/usergroups/{userGroupName}
Key Type Summary Child of

userGroupName

String

Name of the server group to be listed. Invoke LIST ALL to obtain it.

 — 

Using CURL


    
            
         
1
curl --basic -u admin:admin http://localhost:8080/mmc/api/usergroups/Administrators

JSON


    
            
         
1
2
3
4
5
6
7
8
9
10
11
12
{
  "name":"Administrators",
  "permissions":["VIEW_ACTIVITY","DELETE_ITEM","MANAGE_INDEXES","POOL_MODIFY","EXECUTE_ADMIN_SCRIPTS","SERVER_MODIFY",
    "MANAGE_ALERT_NOTIFICATIONS","MANAGE_ALERT_DEFINITIONS","READ_ITEM","MANAGE_POLICIES","DEPLOYMENT_MODIFY",
    "MANAGE_LIFECYCLES","SERVER_DISBAND_CLUSTER","DEPLOYMENT_DEPLOY","SERVER_THREADS_KILL","SERVER_RESTART",
    "SERVER_FILES_VIEW","DEPLOYMENT_READ","ENDPOINT_CONTROL","MANAGE_SERVER_GROUPS","VIEW_ALERTS",
    "SERVER_CREATE_CLUSTER","MANAGE_USERS","SERVER_UNREGISTER","SERVER_FILES_MODIFY","MANAGE_FLOW_AUDIT",
    "TRACKING_VIEW","SERVER_FILES_DELETE","MANAGE_GROUPS","MANAGE_ALERT_DESTINATIONS","DEPLOYMENT_DELETE",
    "FLOW_CONTROL","FLOW_LIST","MODIFY_ITEM","APPLICATION_VIEW","SERVER_THREADS_VIEW","MANAGE_PROPERTIES",
    "SERVER_REGISTER","TRACKING_DELETE","DEPLOYMENT_CREATE","SERVER_VIEW","TRACKING_MODIFY","APPLICATION_MANAGE"],
  "href":"http://localhost:8080/mmc/api/grops/Administrators"
}
Key Type Summary Child of

name

String

The identifying name of the User Group

 — 

permissions

String

Permissions assigned to the User Group

 — 

href

String

Full link to the User Group resource to which you can perform an operation

 — 

200

The operation was successful

401

User has no permission to access the group

404

Provided User Group name does not exist

500

Error while attempting to list User Group details

From

3.3.0

PUT

UPDATE

Updates a specific User Group.

SYNTAX


    
            
         
1
2
3
4
5
{
  "name" : "NewUserGroupName",
  "description" : "Ability to view activity and delete events",
  "permissions" : ["VIEW_ACTIVITY", "TRACKING_DELETE"]
}
Key Type Summary Child of

name

String

Name of the User Group to be created

 — 

description

String

Description of purpose of the Server Group to be created

permissions

Using CURL on Windows


    
            
         
1
curl --basic -u admin:admin -X PUT -d "{ \"name\" : \"NewUserGroupName\", \"description\": \"Ability to view activity and delete events\", \"permissions\": [\"VIEW_ACTIVITY\",\"TRACKING_DELETE\"] }" --header "Content-Type: application/json" http://localhost:8080/mmc/api/usergroups/Deployers

Using CURL on Linux


    
            
         
1
curl --basic -u admin:admin -X PUT -d { "name" : "NewUserGroupName", "description": "Ability to view activity and delete events", "permissions": ["VIEW_ACTIVITY","TRACKING_DELETE"] }" --header 'Content-Type: application/json' http://localhost:8080/mmc/api/usergroups/Deployers

JSON


    
            
         
1
2
3
4
5
6
{
  "name" : "NewUserGroupName",
  "description" : "Ability to view activity and delete events",
  "permissions" : ["VIEW_ACTIVITY", "TRACKING_DELETE"]
  "href" : "http://localhost:8080/mmc/api/usergroups/NewUserGroupName"
}
Key Type Summary Child of

name

String

Name of the User Group to be created

 — 

description

String

Description of the purpose of the Server Group to be created

 — 

permissions

String

Permissions assigned to the User Group. A user that belongs to this User Group will have the same permissions

 — 

href

String

Full link to the User Group resource to which you can perform an operation

 — 

200

The operation was successful

401

Unauthorized user

500

Error while updating User Group

From

3.3.0

DELETE

REMOVE

Removes a specific User Group.

SYNTAX


    
            
         
1
DELETE http://localhost:8080/mmc/api/usergroups/{userGroupName}
Key Type Summary Child of

userGroupName

String

Name of the User Group to be removed. Invoke LIST ALL to obtain it.

 — 

Using CURL


    
            
         
1
curl --basic -u admin:admin -X DELETE http://localhost:8080/mmc/api/usergroups/Monitors

JSON


    
            
         
1
200 OK

200

The operation was unsuccessful

500

Error while deleting User Group

From

3.3.0

User Group Permissions


         
      
1
/api/usergroups/permissions

GET

LIST ALL

List all available permissions.

SYNTAX


    
            
         
1
GET http://localhost:8080/mmc/api/usergroups/permissions

Using CURL


    
            
         
1
curl --basic -u admin:admin http://localhost:8080/mmc/api/usergroups/permissions

JSON


    
            
         
1
2
3
4
5
6
7
8
9
10
11
12
{
  "permissions":
    [
      "SERVER_FILES_DELETE","TRACKING_VIEW","MANAGE_FLOW_AUDIT","DEPLOYMENT_DELETE","FLOW_LIST","FLOW_CONTROL","MANAGE_ALERT_DESTINATIONS",
      "MODIFY_ITEM","MANAGE_PROPERTIES","SERVER_THREADS_VIEW","TRACKING_DELETE","APPLICATION_VIEW","SERVER_REGISTER","APPLICATION_MANAGE",
      "TRACKING_MODIFY","DEPLOYMENT_CREATE","SERVER_VIEW","MANAGE_INDEXES","DEPLOYMENT_MODIFY","MANAGE_ALERT_NOTIFICATIONS","READ_ITEM",
      "POOL_MODIFY","MANAGE_LIFECYCLES","MANAGE_ALERT_DEFINITIONS","SERVER_MODIFY","DELETE_ITEM","DEPLOYMENT_DEPLOY","MANAGE_SERVER_GROUPS",
      "SERVER_DISBAND_CLUSTER","SERVER_FILES_VIEW","VIEW_ACTIVITY","DEPLOYMENT_READ","EXECUTE_ADMIN_SCRIPTS","SERVER_THREADS_KILL",
      "SERVER_RESTART","MANAGE_POLICIES","SERVER_UNREGISTER","ENDPOINT_CONTROL","MANAGE_USERS","VIEW_ALERTS","SERVER_CREATE_CLUSTER",
      "MANAGE_GROUPS","SERVER_FILES_MODIFY"
    ]
}
Key Type Summary Child of

permissions

Array

Available permissions for User Groups

 — 

200

The operation was unsuccessful

401

Unauthorized user

500

Error while deleting User Group

From

3.3.0