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

feat: add filter support to listUsers #865

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

0x62
Copy link

@0x62 0x62 commented Mar 18, 2024

What kind of change does this PR introduce?

There is already support for a filter=xyz query param for the listUsers endpoint, but it is not exposed on the client. This PR adds support for the filter, which allows users to filter the respond of listUsers by a partial or full email address.

This PR also fixes pagination metadata for page values >9. This was originally proposed in #793, but changes were requested and that PR is now stale so I have implemented those changes here too.

What is the current behavior?

It is not possible to filter users via the SDK.

What is the new behavior?

You can now filter users.

Additional context

supabase/auth#880

@0x62
Copy link
Author

0x62 commented Apr 24, 2024

@kangmingtay any chance you could review this?

I came from supabase/auth#1330 (comment), but discovered there is no way to actually use this endpoint from the SDK

hi @JKFSOM, thanks for taking the time to contribute but i don't think we'll be adding this endpoint in - the GET /admin/users endpoint actually allows you to filter for a user's email address already:

for example:

curl -X GET "http://localhost:9999/admin/users?filter=<user_email_address>" -H "Authorization: Bearer ADMIN_JWT"

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.

None yet

1 participant