mirror of
https://repository.entgra.net/community/device-mgt-core.git
synced 2025-10-06 02:01:45 +00:00
Annotate APIs with 'Api' element to give users an abstract idea on what these APIs roughly do
This commit is contained in:
parent
88cab5abf5
commit
d92fb53dc9
@ -33,7 +33,7 @@ import javax.ws.rs.core.Response;
|
|||||||
*/
|
*/
|
||||||
@API(name = "Activities", version = "1.0.0", context = "/devicemgt_admin/activities", tags = {"devicemgt_admin"})
|
@API(name = "Activities", version = "1.0.0", context = "/devicemgt_admin/activities", tags = {"devicemgt_admin"})
|
||||||
@Path("/activities")
|
@Path("/activities")
|
||||||
@Api(value = "ActivityInfo", description = "Activity related information manipulation. For example operation details " +
|
@Api(value = "Activity Info Provider", description = "Activity related information manipulation. For example operation details " +
|
||||||
"and responses from devices.")
|
"and responses from devices.")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
|
|||||||
@ -33,7 +33,7 @@ import javax.ws.rs.core.Response;
|
|||||||
@API(name = "Configuration", version = "1.0.0", context = "/devicemgt_admin/configuration", tags = {"devicemgt_admin"})
|
@API(name = "Configuration", version = "1.0.0", context = "/devicemgt_admin/configuration", tags = {"devicemgt_admin"})
|
||||||
|
|
||||||
@Path("/configuration")
|
@Path("/configuration")
|
||||||
@Api(value = "Configuration", description = "General Tenant Configuration management capabilities are exposed " +
|
@Api(value = "Configuration Management", description = "General Tenant Configuration management capabilities are exposed " +
|
||||||
"through this API")
|
"through this API")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
|
|||||||
@ -43,7 +43,7 @@ import java.util.List;
|
|||||||
*/
|
*/
|
||||||
@API(name = "Device", version = "1.0.0", context = "/api/device-mgt/admin/devices", tags = {"devicemgt_admin"})
|
@API(name = "Device", version = "1.0.0", context = "/api/device-mgt/admin/devices", tags = {"devicemgt_admin"})
|
||||||
@Path("/devices")
|
@Path("/devices")
|
||||||
@Api(value = "Device Management API", description = "This API carries all device management related operations " +
|
@Api(value = "Device Management", description = "This API carries all device management related operations " +
|
||||||
"such as get all the available devices, etc.")
|
"such as get all the available devices, etc.")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
|
|||||||
@ -26,6 +26,7 @@ import javax.ws.rs.*;
|
|||||||
import javax.ws.rs.core.MediaType;
|
import javax.ws.rs.core.MediaType;
|
||||||
import javax.ws.rs.core.Response;
|
import javax.ws.rs.core.Response;
|
||||||
|
|
||||||
|
|
||||||
@Path("/groups")
|
@Path("/groups")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
|
|||||||
@ -32,7 +32,7 @@ import javax.ws.rs.core.Response;
|
|||||||
*/
|
*/
|
||||||
@API(name = "Device Notification Management API", version = "1.0.0", context = "/devicemgt_admin/notifications",
|
@API(name = "Device Notification Management API", version = "1.0.0", context = "/devicemgt_admin/notifications",
|
||||||
tags = {"devicemgt_admin"})
|
tags = {"devicemgt_admin"})
|
||||||
@Api(value = "Device Notification Management API", description = "Device notification related operations can be found here.")
|
@Api(value = "Device Notification Management", description = "Device notification related operations can be found here.")
|
||||||
@Path("/notifications")
|
@Path("/notifications")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
|
|||||||
@ -32,6 +32,8 @@ import java.util.List;
|
|||||||
* Policy related REST-API. This can be used to manipulated policies and associate them with devices, users, roles,
|
* Policy related REST-API. This can be used to manipulated policies and associate them with devices, users, roles,
|
||||||
* groups.
|
* groups.
|
||||||
*/
|
*/
|
||||||
|
@Api(value = "Device Policy Management", description = "This API carries all the necessary functionalities " +
|
||||||
|
"around device policy management")
|
||||||
@Path("/policies")
|
@Path("/policies")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
|
|||||||
@ -32,7 +32,7 @@ import java.util.List;
|
|||||||
|
|
||||||
@API(name = "Role", version = "1.0.0", context = "/devicemgt_admin/roles", tags = {"devicemgt_admin"})
|
@API(name = "Role", version = "1.0.0", context = "/devicemgt_admin/roles", tags = {"devicemgt_admin"})
|
||||||
@Path("/roles")
|
@Path("/roles")
|
||||||
@Api(value = "Role", description = "Role management related operations can be found here.")
|
@Api(value = "Role Management", description = "Role management related operations can be found here.")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
public interface RoleManagementService {
|
public interface RoleManagementService {
|
||||||
|
|||||||
@ -32,7 +32,7 @@ import java.util.Date;
|
|||||||
|
|
||||||
@API(name = "User Management API", version = "1.0.0", context = "/devicemgt_admin/users", tags = {"devicemgt_admin"})
|
@API(name = "User Management API", version = "1.0.0", context = "/devicemgt_admin/users", tags = {"devicemgt_admin"})
|
||||||
@Path("/users")
|
@Path("/users")
|
||||||
@Api(value = "User Management API", description = "User management related operations can be found here.")
|
@Api(value = "User Management", description = "User management related operations can be found here.")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
public interface UserManagementService {
|
public interface UserManagementService {
|
||||||
|
|||||||
@ -32,7 +32,9 @@ import javax.ws.rs.core.Response;
|
|||||||
@API(name = "Application", version = "1.0.0", context = "/devicemgt_admin/applications", tags = {"devicemgt_admin"})
|
@API(name = "Application", version = "1.0.0", context = "/devicemgt_admin/applications", tags = {"devicemgt_admin"})
|
||||||
|
|
||||||
@Path("/applications")
|
@Path("/applications")
|
||||||
@Api(value = "Application", description = "Application related operations are exposed through this API.")
|
@Api(value = "Application Management Administrative Service", description = "This an API intended to be used by " +
|
||||||
|
"'internal' components to log in as an admin user and do a selected number of operations. " +
|
||||||
|
"Further, this is strictly restricted to admin users only ")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
public interface ApplicationManagementAdminService {
|
public interface ApplicationManagementAdminService {
|
||||||
|
|||||||
@ -29,8 +29,9 @@ import javax.ws.rs.core.Response;
|
|||||||
@API(name = "DeviceManagementAdmin", version = "1.0.0", context = "/devicemgt_admin/applications",
|
@API(name = "DeviceManagementAdmin", version = "1.0.0", context = "/devicemgt_admin/applications",
|
||||||
tags = {"devicemgt_admin"})
|
tags = {"devicemgt_admin"})
|
||||||
@Path("/devices")
|
@Path("/devices")
|
||||||
@Api(value = "DeviceManagementAdmin", description = "Device management admin related operations are exposed through " +
|
@Api(value = "Device Management Administrative Service", description = "This an API intended to be used by " +
|
||||||
"this API.")
|
"'internal' components to log in as an admin user and do a selected number of operations. " +
|
||||||
|
"Further, this is strictly restricted to admin users only ")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
public interface DeviceManagementAdminService {
|
public interface DeviceManagementAdminService {
|
||||||
|
|||||||
@ -30,6 +30,9 @@ import java.util.Date;
|
|||||||
@Path("/groups")
|
@Path("/groups")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
|
@Api(value = "Group Management Administrative Service", description = "This an API intended to be used by " +
|
||||||
|
"'internal' components to log in as an admin user and do a selected number of operations. " +
|
||||||
|
"Further, this is strictly restricted to admin users only ")
|
||||||
public interface GroupManagementAdminService {
|
public interface GroupManagementAdminService {
|
||||||
|
|
||||||
@GET
|
@GET
|
||||||
|
|||||||
@ -18,10 +18,7 @@
|
|||||||
*/
|
*/
|
||||||
package org.wso2.carbon.device.mgt.jaxrs.service.api.admin;
|
package org.wso2.carbon.device.mgt.jaxrs.service.api.admin;
|
||||||
|
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.*;
|
||||||
import io.swagger.annotations.ApiParam;
|
|
||||||
import io.swagger.annotations.ApiResponse;
|
|
||||||
import io.swagger.annotations.ApiResponses;
|
|
||||||
import org.wso2.carbon.apimgt.annotations.api.Permission;
|
import org.wso2.carbon.apimgt.annotations.api.Permission;
|
||||||
import org.wso2.carbon.device.mgt.jaxrs.beans.UserCredentialWrapper;
|
import org.wso2.carbon.device.mgt.jaxrs.beans.UserCredentialWrapper;
|
||||||
|
|
||||||
@ -32,6 +29,9 @@ import javax.ws.rs.core.Response;
|
|||||||
@Path("/users")
|
@Path("/users")
|
||||||
@Produces(MediaType.APPLICATION_JSON)
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
@Consumes(MediaType.APPLICATION_JSON)
|
@Consumes(MediaType.APPLICATION_JSON)
|
||||||
|
@Api(value = "User Management Administrative Service", description = "This an API intended to be used by " +
|
||||||
|
"'internal' components to log in as an admin user and do a selected number of operations. " +
|
||||||
|
"Further, this is strictly restricted to admin users only ")
|
||||||
public interface UserManagementAdminService {
|
public interface UserManagementAdminService {
|
||||||
|
|
||||||
@PUT
|
@PUT
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user