aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Api/Controllers
diff options
context:
space:
mode:
authorcrobibero <cody@robibe.ro>2020-04-19 19:36:18 -0600
committercrobibero <cody@robibe.ro>2020-04-19 19:36:18 -0600
commit440f060da6cfa8336d51bd05b723d67cfcf168eb (patch)
tree0ec19fb4fe66392f8deb74d75ea8cd75f2facf45 /Jellyfin.Api/Controllers
parent21b54b4ad8477d654e4f79e9805701c9737346a6 (diff)
Fix Authenticated Roles
Diffstat (limited to 'Jellyfin.Api/Controllers')
-rw-r--r--Jellyfin.Api/Controllers/DevicesController.cs4
1 files changed, 4 insertions, 0 deletions
diff --git a/Jellyfin.Api/Controllers/DevicesController.cs b/Jellyfin.Api/Controllers/DevicesController.cs
index 7407c4487..a9dcfb955 100644
--- a/Jellyfin.Api/Controllers/DevicesController.cs
+++ b/Jellyfin.Api/Controllers/DevicesController.cs
@@ -48,6 +48,7 @@ namespace Jellyfin.Api.Controllers
/// <param name="userId">/// Gets or sets the user identifier.</param>
/// <returns>Device Infos.</returns>
[HttpGet]
+ [Authenticated(Roles = "Admin")]
[ProducesResponseType(typeof(DeviceInfo[]), StatusCodes.Status200OK)]
[ProducesResponseType(typeof(string), StatusCodes.Status500InternalServerError)]
public IActionResult GetDevices([FromQuery] bool? supportsSync, [FromQuery] Guid? userId)
@@ -70,6 +71,7 @@ namespace Jellyfin.Api.Controllers
/// <param name="id">Device Id.</param>
/// <returns>Device Info.</returns>
[HttpGet("Info")]
+ [Authenticated(Roles = "Admin")]
[ProducesResponseType(typeof(DeviceInfo), StatusCodes.Status200OK)]
[ProducesResponseType(StatusCodes.Status404NotFound)]
[ProducesResponseType(typeof(string), StatusCodes.Status500InternalServerError)]
@@ -97,6 +99,7 @@ namespace Jellyfin.Api.Controllers
/// <param name="id">Device Id.</param>
/// <returns>Device Info.</returns>
[HttpGet("Options")]
+ [Authenticated(Roles = "Admin")]
[ProducesResponseType(typeof(DeviceOptions), StatusCodes.Status200OK)]
[ProducesResponseType(StatusCodes.Status404NotFound)]
[ProducesResponseType(typeof(string), StatusCodes.Status500InternalServerError)]
@@ -125,6 +128,7 @@ namespace Jellyfin.Api.Controllers
/// <param name="deviceOptions">Device Options.</param>
/// <returns>Status.</returns>
[HttpPost("Options")]
+ [Authenticated(Roles = "Admin")]
[ProducesResponseType(StatusCodes.Status200OK)]
[ProducesResponseType(StatusCodes.Status404NotFound)]
[ProducesResponseType(typeof(string), StatusCodes.Status500InternalServerError)]