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

No way to get current user 'active' state and other settings via API #13681

Closed
2 of 6 tasks
WilixLead opened this issue Nov 23, 2020 · 2 comments
Closed
2 of 6 tasks

No way to get current user 'active' state and other settings via API #13681

WilixLead opened this issue Nov 23, 2020 · 2 comments
Assignees
Labels
modifies/api This PR adds API routes or modifies them type/proposal The new feature has not been accepted yet but needs to be discussed first.

Comments

@WilixLead
Copy link

  • Gitea version (or commit ref): 1.12.6 (release)
  • Git version: 2.25.1
  • Operating system: Linux 5.4.0-48-generic x86_64
  • I get Gitea binnary from releases in Github
  • Run gitea from systemd (used config from gitea docs)
  • Database (use [x]):
    • PostgreSQL
    • MySQL
    • MSSQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
    • No (need admin rights)
  • Log gist: --

Description

I can't find any way for admin api to get user state like 'active', 'prohibit_login' and other checkboxes in admin page.
I thing it should be under /admin/users/{username} or /users/{username} (but it require additional role checking and changing output model)

Screenshots

@WilixLead WilixLead changed the title No way to get current user 'active' state and other settings No way to get current user 'active' state and other settings via API Nov 23, 2020
@6543 6543 added modifies/api This PR adds API routes or modifies them type/proposal The new feature has not been accepted yet but needs to be discussed first. labels Nov 23, 2020
@6543
Copy link
Member

6543 commented Nov 23, 2020

I think we can ad something like type to specify if it's a "normal" user or a "restricted" one ... (this way we can extend it to "bot", ...)

and 'active', 'prohibit_login' should just be exposed like is_admin ...

@6543 6543 self-assigned this Jun 16, 2021
@6543
Copy link
Member

6543 commented Jun 16, 2021

restricted, active, prohibit_login are already exposed for admin & user itself ...

a "type" field is useless for now ...

-> #15689

@6543 6543 closed this as completed Jun 16, 2021
@go-gitea go-gitea locked and limited conversation to collaborators Oct 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
modifies/api This PR adds API routes or modifies them type/proposal The new feature has not been accepted yet but needs to be discussed first.
Projects
None yet
Development

No branches or pull requests

2 participants