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

GET Organizations endpoint should return OK with empty list, not 401 if user has access to ORT Server but no organization permissions #1900

Open
mmurto opened this issue Jan 29, 2025 · 2 comments
Labels
api Issues related to the API. backend Issues related to the backend.

Comments

@mmurto
Copy link
Contributor

mmurto commented Jan 29, 2025

Currently a newly created user will receive a 401 error from the front page of the UI, as the API returns 401 if the user can't read any organizations. The endpoint for listing organizations should rather return an OK response with empty list of organizations, as the user is authorized to list the organizations with an empty list, even if they don't have access to any single organization. This would make the experience for a newly created user better.

@mmurto mmurto added api Issues related to the API. backend Issues related to the backend. labels Jan 29, 2025
@sschuberth
Copy link
Contributor

For transparency @hendrikebbers, this is something we'd like to address before your on-boarding.

@mnonnenmacher
Copy link
Contributor

mnonnenmacher commented Jan 31, 2025

This should already be the case, I tried to reproduce it in a test but I couldn't, for a user with no organization permissions it returned 200 with an empty organization list.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Issues related to the API. backend Issues related to the backend.
Projects
None yet
Development

No branches or pull requests

3 participants