diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/api/UserManagementService.java b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/api/UserManagementService.java
index 5eb8d54d423..a9285d47cec 100644
--- a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/api/UserManagementService.java
+++ b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/api/UserManagementService.java
@@ -336,7 +336,7 @@ public interface UserManagementService {
@QueryParam("limit") int limit);
@GET
- @Path("/usernames")
+ @Path("/search/usernames")
@ApiOperation(
produces = MediaType.APPLICATION_JSON,
httpMethod = "GET",
diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/UserManagementServiceImpl.java b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/UserManagementServiceImpl.java
index 74b1769c38a..f98938cc207 100644
--- a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/UserManagementServiceImpl.java
+++ b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/UserManagementServiceImpl.java
@@ -381,7 +381,7 @@ public class UserManagementServiceImpl implements UserManagementService {
}
@GET
- @Path("/usernames")
+ @Path("/search/usernames")
@Override
public Response getUserNames(@QueryParam("filter") String filter, @HeaderParam("If-Modified-Since") String timestamp,
@QueryParam("offset") int offset, @QueryParam("limit") int limit) {
diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/webapp/META-INF/permissions.xml b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/webapp/META-INF/permissions.xml
index 0c9d193aef9..f3a81be3e1b 100644
--- a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/webapp/META-INF/permissions.xml
+++ b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/webapp/META-INF/permissions.xml
@@ -37,6 +37,12 @@
/activities/*
GET
+
+ Fetch Activity related details
+ /device-mgt/admin/activities/view
+ /activities
+ GET
+
@@ -529,334 +535,100 @@
/users
GET
-
-
- Add user
- /device-mgt/admin/users/add
- /users
- POST
-
-
- View user
- /device-mgt/admin/users/view
- /users/view
+ List users
+ /device-mgt/admin/users/list
+ /users/search/usernames
GET
-
- Update user
- /device-mgt/admin/users/update
+ Add user
+ /device-mgt/admin/users/add
/users
- PUT
-
-
-
- Change user password
- /login
- /users/change-password
- POST
-
-
-
- Reset password
- /device-mgt/admin/users/password-reset
- /users/reset-password
POST
-
Remove user
/device-mgt/admin/users/remove
- /users
+ /users/*
DELETE
-
View user
/device-mgt/admin/users/view
- /users/roles
+ /users/*
GET
-
-
-
-
-
-
-
-
-
- Add user
- /device-mgt/admin/users/add
- /roles
- POST
-
-
- List user devices
- /device-mgt/user/devices/list
- /users/devices
- GET
-
-
-
- View user
- /device-mgt/admin/users/view
- /users/*/*
- GET
-
-
-
- List users
- /device-mgt/admin/users/list
- /users/count
- GET
+ Update user
+ /device-mgt/admin/users/update
+ /users/*
+ PUT
-
- List users
- /device-mgt/admin/users/list
- /users/view-users
- GET
+ Update user credential
+ /device-mgt/admin/users/update
+ /users/*/credentials
+ PUT
-
- Add role
+ Get role
/device-mgt/admin/roles/add
- /users/view-users
- GET
-
-
-
- Update role
- /device-mgt/admin/roles/update
- /users/view-users
- GET
-
-
-
- Add policy
- /device-mgt/admin/policies/add
- /users/view-users
- GET
-
-
-
- Update policy
- /device-mgt/admin/policies/update
- /users/view-users
- GET
-
-
-
- List users
- /device-mgt/admin/users/list
- /users/users-by-username
+ /users/*/roles
GET
-
-
- List users
- /device-mgt/admin/users/list
- /users/users-by-username/*
- GET
-
-
- Invite user
- /device-mgt/admin/users/invite
- /users/email-invitation
+ Update user credential
+ /device-mgt/admin/users/update
+ /admin/users/*/credentials
POST
-
- Authorize user
- /login
- /users/authorize
- POST
-
+
-
- Add Policy
- /device-mgt/admin/policies/add
- /policies/inactive-policy
- POST
-
-
- Add Policy
- /device-mgt/user/policies/add
- /policies/inactive-policy
- POST
-
-
List policies
/device-mgt/admin/policies/list
- /policies/*/*
- POST
-
-
-
- List policies
- /device-mgt/admin/policies/list
- /policies/*/*/*
- GET
-
-
-
- View device
- /device-mgt/admin/devices/view
- /policies/*/*/*
+ /policies
GET
-
- View device
- /device-mgt/user/devices/view
- /policies/*/*/*
- GET
+ Add Policy
+ /device-mgt/admin/policies/add
+ /policies
+ POST
-
- Add policy
+ Activate policy
/device-mgt/admin/policies/add
- /policies/active-policy
- POST
+ /policies/activate-policy
+ PUT
- Add Policy
+ Deactivate Policy
/device-mgt/user/policies/add
- /policies/inactive-policy
- POST
+ /policies/deactivate-policy
+ PUT
-
- Remove policy
- /device-mgt/admin/policies/remove
+ Remove Policy
+ /device-mgt/user/policies/remove
/policies/remove-policy
POST
-
-
- List policies
- /device-mgt/admin/policies/list
- /policies
- GET
-
-
- List policies
- /device-mgt/admin/policies/list
- /policies/*
- GET
-
-
-
- List user policies
- /device-mgt/user/policies/list
- /policies
- GET
-
-
-
- List user policies
- /device-mgt/user/policies/list
+ View Policy
+ /device-mgt/admin/policies/view
/policies/*
GET
-
- Update policy
+ Update Policy
/device-mgt/admin/policies/update
/policies/*
- PUT
-
-
-
- Remove policy
- /device-mgt/admin/policies/remove
- /policies
- DELETE
-
-
-
- List policies
- /device-mgt/admin/policies/list
- /policies/count
- GET
-
-
-
- Edit policy
- /device-mgt/admin/policies/update
- /policies/priorities
- PUT
-
-
-
- Edit policy
- /device-mgt/admin/policies/update
- /policies/activate
- PUT
-
-
-
- Add policy
- /device-mgt/admin/policies/add
- /policies/activate
- PUT
-
-
-
- Edit policy
- /device-mgt/admin/policies/update
- /policies/inactivate
- PUT
-
-
-
- Add policy
- /device-mgt/admin/policies/add
- /policies/inactivate
- PUT
-
-
-
- Edit policy
- /device-mgt/admin/policies/update
- /policies/apply-changes
- PUT
-
-
-
- Add policy
- /device-mgt/admin/policies/add
- /policies/start-task/*
- GET
-
-
-
- Add policy
- /device-mgt/admin/policies/add
- /policies/update-task/*
- GET
-
-
-
- Add policy
- /device-mgt/admin/policies/add
- /policies/stop-task
- GET
-
-
-
- List policies
- /device-mgt/admin/policies/list
- /policies/*/*
- GET
+ Put
@@ -939,14 +711,6 @@
/configuration
GET
-
-
- Add configuration
- /device-mgt/admin/platform-configs/add
- /configuration
- POST
-
-
Update configuration
/device-mgt/admin/platform-configs/modify