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

core/api: add uuid field to core api user http response #7110

Merged
merged 2 commits into from
Oct 9, 2023
Merged

core/api: add uuid field to core api user http response #7110

merged 2 commits into from
Oct 9, 2023

Conversation

horego
Copy link
Contributor

@horego horego commented Oct 9, 2023

#6941

Text from the issue:

Hey there. I have a "feature" request to Authentik. The /core/users endpoint has a couple of filtering options like name, path and for me more important the uuid.
Since we have the ability to filter the uuid there is no way to retreive it via the API. My suggestion is to add the uuid in the user response of the api.

Would you like to do that? We achived that by adding the uuid to the user Meta class of users.py file.
https://github.com/goauthentik/authentik/blob/main/authentik/core/api/users.py


    class Meta:
        model = User
        fields = [
            "pk",
            "username",
            "name",
            ....
            "uuid",
        ]
        extra_kwargs = {
            "name": {"allow_blank": True},
        }

@horego horego requested a review from a team as a code owner October 9, 2023 06:35
@netlify
Copy link

netlify bot commented Oct 9, 2023

Deploy Preview for authentik-storybook canceled.

Name Link
🔨 Latest commit 20dfd72
🔍 Latest deploy log https://app.netlify.com/sites/authentik-storybook/deploys/6523d0567e77910008673439

@BeryJu BeryJu requested a review from a team as a code owner October 9, 2023 09:50
@codecov
Copy link

codecov bot commented Oct 9, 2023

Codecov Report

All modified lines are covered by tests ✅

Comparison is base (4db365c) 92.66% compared to head (20dfd72) 92.66%.
Report is 3 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #7110   +/-   ##
=======================================
  Coverage   92.66%   92.66%           
=======================================
  Files         568      568           
  Lines       28049    28049           
=======================================
  Hits        25989    25989           
  Misses       2060     2060           
Flag Coverage Δ
e2e 51.17% <ø> (ø)
integration 26.34% <ø> (ø)
unit 89.57% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
authentik/core/api/users.py 92.64% <ø> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Signed-off-by: Jens Langhammer <jens@goauthentik.io>
@BeryJu BeryJu merged commit ab1b3b0 into goauthentik:main Oct 9, 2023
kensternberg-authentik added a commit that referenced this pull request Oct 9, 2023
* main: (22 commits)
  lifecycle: fix install_id migration not running (#7116)
  core: bump Go from 1.20 to 1.21 (#7117)
  providers/ldap: add windows adsi support (#7098)
  web: bump API Client version (#7113)
  translate: Updates for file web/xliff/en.xlf in zh-Hans on branch main (#7112)
  translate: Updates for file web/xliff/en.xlf in zh_CN on branch main (#7111)
  web: bump the wdio group in /tests/wdio with 4 updates (#7108)
  core/api: add uuid field to core api user http response (#7110)
  core: bump goauthentik.io/api/v3 from 3.2023083.4 to 3.2023083.5 (#7105)
  core: bump golang.org/x/oauth2 from 0.12.0 to 0.13.0 (#7106)
  web: bump the eslint group in /tests/wdio with 1 update (#7107)
  providers/proxy: improve SLO by backchannel logging out sessions (#7099)
  web: bump @rollup/plugin-node-resolve from 15.2.2 to 15.2.3 in /web (#7104)
  web: bump the eslint group in /web with 1 update (#7103)
  web: bump the storybook group in /web with 1 update (#7102)
  web: bump API Client version (#7101)
  providers/saml: add default RelayState value for IDP-initiated requests (#7100)
  lifecycle: improve reliability of system migrations (#7089)
  sources/ldap: fix attribute path resolution (#7090)
  root: Ignore the vendor folder (#7094)
  ...
kensternberg-authentik added a commit that referenced this pull request Oct 9, 2023
* main: (41 commits)
  lifecycle: fix install_id migration not running (#7116)
  core: bump Go from 1.20 to 1.21 (#7117)
  providers/ldap: add windows adsi support (#7098)
  web: bump API Client version (#7113)
  translate: Updates for file web/xliff/en.xlf in zh-Hans on branch main (#7112)
  translate: Updates for file web/xliff/en.xlf in zh_CN on branch main (#7111)
  web: bump the wdio group in /tests/wdio with 4 updates (#7108)
  core/api: add uuid field to core api user http response (#7110)
  core: bump goauthentik.io/api/v3 from 3.2023083.4 to 3.2023083.5 (#7105)
  core: bump golang.org/x/oauth2 from 0.12.0 to 0.13.0 (#7106)
  web: bump the eslint group in /tests/wdio with 1 update (#7107)
  providers/proxy: improve SLO by backchannel logging out sessions (#7099)
  web: bump @rollup/plugin-node-resolve from 15.2.2 to 15.2.3 in /web (#7104)
  web: bump the eslint group in /web with 1 update (#7103)
  web: bump the storybook group in /web with 1 update (#7102)
  web: bump API Client version (#7101)
  providers/saml: add default RelayState value for IDP-initiated requests (#7100)
  lifecycle: improve reliability of system migrations (#7089)
  sources/ldap: fix attribute path resolution (#7090)
  root: Ignore the vendor folder (#7094)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants