Jump to content

Setting RemoteClientBitrateLimit via API


daschef

Recommended Posts

Hi, i try to change the RemoteClientBitrateLimit via the API.

 

I like to use /System/Configuration/{Key}, but what is the key name for RemoteClientBitrateLimit?

 

If I try

http://172.16.128.253:8096/emby/System/Configuration/RemoteClientBitrateLimit?api_key=$apikey

i get:

 

Configuration with key RemoteClientBitrateLimit not found.

Edited by daschef
Link to comment
Share on other sites

Hi. If you want to manipulate configuration settings, you need to retrieve the entire configuration object, change what you want, and then update with the entire object.

 

Thanks.

Link to comment
Share on other sites

Many thanks! Worked.

 

here is my script to limit the bitrate depending on the active user count

case `cat /$file_withe_the_number_of_external_users` in.
    0|1|2|3).
       jq '. + { "RemoteClientBitrateLimit" : 3000000 }' <<< `curl -X GET "http://$ip:8096/emby/System/Configuration?api_key=$key" -H  "accept: application/json"` > config.json
       ;;
    ?). 
       jq '. + { "RemoteClientBitrateLimit" : 250000 }' <<< `curl -X GET "http://$ip:8096/emby/System/Configuration?api_key=$key" -H  "accept: application/json"` > config.json
       ;;
esac
curl -s -X POST "http://$ip:8096/emby/System/Configuration?api_key=$key" -H  "accept: */*" -H  "Content-Type: application/json" -d @config.json


Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...