Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Traffic Stats API GET /online #1074

Closed
shakibamoshiri opened this issue May 6, 2024 · 0 comments
Closed

Traffic Stats API GET /online #1074

shakibamoshiri opened this issue May 6, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@shakibamoshiri
Copy link

shakibamoshiri commented May 6, 2024

Is your feature request related to a problem? Please describe.
cannot we say it is problem, but it is useful for better user management

Describe the solution you'd like
The Traffic Stats API has two endpoints

  • /traffic to get the rx and tx
  • /kick to disconnect an online user

in terms of user management, the third one is missing

  • /online to show/list connected users

Describe alternatives you've considered
As an alternative, a polling script can check every N minutes if a user tx-rx is 0 or not.
if they are 0, the user is not online
if they are non-zero, save them on database and /traffic?clear=all them
at last check tr-tx again, the ones their values are non-zero are online

this is how xray (project X) panel (e.g x-ui 3x-ui, etc) are handling the online list

Additional context
A server like SoftEther has API to check online users ,
A server like ocserv has a CLI (occtl) to list online users
And xray with a workaround we can check
but the standard and the straightforward way is a built-in API

@shakibamoshiri shakibamoshiri added the enhancement New feature or request label May 6, 2024
@tobyxdd tobyxdd closed this as completed May 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants