bakes82 86 Posted April 4, 2022 Share Posted April 4, 2022 There a way to block a device? Looking at the DeviceManager service doesnt look like a way to remove a device, is that possible, I see you can do it from the UI lol. If you delete a device does it kick all the stream/log out that user like I assume it should? Link to comment Share on other sites More sharing options...
Happy2Play 8139 Posted April 4, 2022 Share Posted April 4, 2022 Have you looked at DeviceServices. I just looked at the call made in the server log. 2022-04-04 15:37:31.576 Info Server: http/1.1 DELETE http://localhost:8097/emby/Devices?Id=439dba90-7484-41e4-b497-92b9c73345aa&X-Emby-Client=Emby I don't believe there is a global block, only a per user device access. Link to comment Share on other sites More sharing options...
bakes82 86 Posted April 4, 2022 Author Share Posted April 4, 2022 41 minutes ago, Happy2Play said: Have you looked at DeviceServices. I just looked at the call made in the server log. 2022-04-04 15:37:31.576 Info Server: http/1.1 DELETE http://localhost:8097/emby/Devices?Id=439dba90-7484-41e4-b497-92b9c73345aa&X-Emby-Client=Emby I don't believe there is a global block, only a per user device access. Yea this never applies to the plug-in c# api so idk why you keep referring me to it. I checked in C# the device manager service and didn’t see a remove. Link to comment Share on other sites More sharing options...
bakes82 86 Posted April 5, 2022 Author Share Posted April 5, 2022 Link to comment Share on other sites More sharing options...
Luke 36880 Posted April 5, 2022 Share Posted April 5, 2022 It's stored in UserPolicy for each user, so you'd have to update that. Link to comment Share on other sites More sharing options...
bakes82 86 Posted April 6, 2022 Author Share Posted April 6, 2022 @Luke Can I get a list of user Devices from ApiClient.getDevices(); In C# I have to use the users "InternalId" as its a long. But I dont see a "long" being returned in APIClient.GetUsers(); I tired passing in the user.Id from thats the GUID no dashes and it still gives me back all the users. Link to comment Share on other sites More sharing options...
Luke 36880 Posted April 7, 2022 Share Posted April 7, 2022 Is this a plugin or a separate app using our old c# libs? Link to comment Share on other sites More sharing options...
bakes82 86 Posted April 7, 2022 Author Share Posted April 7, 2022 (edited) 31 minutes ago, Luke said: Is this a plugin or a separate app using our old c# libs? Its a plugin so its the injected JS ApiClient. In c# I do this: var userDevices = _deviceManager.GetDevices(new DeviceQuery { UserId = user.InternalId }) .Items.Where(x => x.AppName != "Emby Web") .ToList(); In JS Im doing This: I looks like the getDevice() takes in a "query" but idk what to pass in, also when you do .getUsers from JS no "internalId" is returned. function loadUserDevices(userName) { ApiClient.getDevices().then((devices) => { Edited April 7, 2022 by bakes82 Link to comment Share on other sites More sharing options...
bakes82 86 Posted April 13, 2022 Author Share Posted April 13, 2022 @Luke Is there a way to figure out what devices are counted towards the device limit cap. Like if I set an account to a specific device, they can no longer use the web, but isnt the web a free device? And the only way to allow them to use the web would then be to allow all which means they could go add other devices. This whole device limit thing seems horribly flawed and then when you try to restrict it to a couple devices per user then being able to view the webpage gets broken. Link to comment Share on other sites More sharing options...
Luke 36880 Posted June 26, 2022 Share Posted June 26, 2022 OK the way the device id's come out of the api needs to be reworked, and that will resolve this. It's on my to do list. Link to comment Share on other sites More sharing options...
ebr 14858 Posted June 27, 2022 Share Posted June 27, 2022 On 4/13/2022 at 6:47 PM, bakes82 said: Is there a way to figure out what devices are counted towards the device limit cap Hi. Are you talking Premiere devices or your internal server? There is no way to see or manage the Premiere devices. This is for a number of reasons but the device limits are set generously for a home media server for a single family such that it really shouldn't be necessary for our intended usage. Link to comment Share on other sites More sharing options...
Luke 36880 Posted July 6, 2022 Share Posted July 6, 2022 This will be in the next beta build. The device id's coming out of the api will be the same as what you get internally via plugin. That will be the database id of the device. The reported device id that came from the client will be in it's own property now, ReportedDeviceId. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now