stefanodvx / crunpyroll

Async API wrapper for Crunchyroll
MIT License
74 stars 21 forks source link

Add way to delete devices from account and PLAY HOST ? #16

Closed khyinn closed 7 months ago

khyinn commented 8 months ago

Hello,

With the normal API, there is a possibility to delete the devices registered on our account. This can come in handy as they become numerous over time (DEVICE_ID is generated instead of being fixed, which adds a new device each time a program using Crunpyroll is launched and we are limited to 20 devices per account). Is it possible to implement the corresponding endpoint (https://www.crunchyroll.com/accounts/v1/i_think_account_id_goes_here_or_something_like_"me"/devices/deactivate)?

And is there something similar on the PLAY_HOST? Apparently, deleting all devices from my account is not enough to disable all open streams on the PLAY_HOST, which leads to an API error with get_streams (420 too_many_queued_streams, useStreamLimits: true in the error message).

Burve commented 8 months ago

It looks like the utils.py class generates a new random DEVICE_ID every time it is initialized, so every time the app is launched, a new device is added.

Vorffeed commented 7 months ago

I join the request, is there a way to do that when the download is finished it kills the session id, because when it reaches 15 sessions it says that there are many open connections and even if only one appears, if you delete it, the same number of times you have downloaded appears again.