mirror of
https://github.com/danieldemus/openhab-core.git
synced 2025-01-11 05:41:52 +01:00
Add @SecurityRequirement annotation to PersistenceResource::httpPutPersistenceItemData function (#2406)
Signed-off-by: Paul Vogel <github@paulvogel.me>
This commit is contained in:
parent
f58fce3500
commit
5cc76378a0
@ -199,9 +199,10 @@ public class PersistenceResource implements RESTResource {
|
||||
@RolesAllowed({ Role.ADMIN })
|
||||
@Path("/items/{itemname: [a-zA-Z_0-9]+}")
|
||||
@Produces({ MediaType.APPLICATION_JSON })
|
||||
@Operation(operationId = "storeItemDataInPersistenceService", summary = "Stores item persistence data into the persistence service.", responses = {
|
||||
@ApiResponse(responseCode = "200", description = "OK"),
|
||||
@ApiResponse(responseCode = "404", description = "Unknown Item or persistence service") })
|
||||
@Operation(operationId = "storeItemDataInPersistenceService", summary = "Stores item persistence data into the persistence service.", security = {
|
||||
@SecurityRequirement(name = "oauth2", scopes = { "admin" }) }, responses = {
|
||||
@ApiResponse(responseCode = "200", description = "OK"),
|
||||
@ApiResponse(responseCode = "404", description = "Unknown Item or persistence service") })
|
||||
public Response httpPutPersistenceItemData(@Context HttpHeaders headers,
|
||||
@Parameter(description = "Id of the persistence service. If not provided the default service will be used") @QueryParam("serviceId") @Nullable String serviceId,
|
||||
@Parameter(description = "The item name.") @PathParam("itemname") String itemName,
|
||||
|
Loading…
Reference in New Issue
Block a user