lucasheld / uptime-kuma-api

A Python wrapper for the Uptime Kuma Socket.IO API
https://uptime-kuma-api.readthedocs.io
MIT License
273 stars 23 forks source link

Support login / use via api-key #24

Closed simonmicro closed 1 year ago

simonmicro commented 1 year ago

Hi, I wanted to use this wonderful project for some hobby-stuff, but it turns out that the login() method does not support the "api-key" authentication method. In combination with enabled 2FA it is somewhat hard to use this project... Would it be possible to add support for that? Maybe I'm just too stupid to read the documentation properly :wink: ~Simon

...and I also tried login_by_token(), which just times out / reports invalid api keys.

Vinalti commented 1 year ago

I could reproduce the issue, I cannot connect to kuma with the API token... 😅

Vinalti commented 1 year ago

It seems to be native from UptimeKuma SocketIO endpoint, so I raised an issue there: https://github.com/louislam/uptime-kuma/issues/3107

simonmicro commented 1 year ago

I could reproduce the issue, I cannot connect to kuma with the API token... sweat_smile

I've also tried that, after reading in the documentation how the basic authentication should work. Didn't work :grimacing:

Vinalti commented 1 year ago

See #28

simonmicro commented 1 year ago

Well, this answers my question - let's hope they add proper token support via https://github.com/louislam/uptime-kuma/issues/3107 .

On the other hand, they mention token support for the http-api in their documentation...

lucasheld commented 1 year ago

So this issue can be closed then?

simonmicro commented 1 year ago

Fair point, this repo shall not have issues open, which are an issue in the upstream project!

Anybody else coming here - keep an eye onto https://github.com/louislam/uptime-kuma/issues/3107!