# List of blocked users via API

**URL:** <https://community.auth0.com/t/list-of-blocked-users-via-api/133177>\
**Category:** Get Help\
**Tags:** users, management-api\
**Created:** [May 1, 2024, 8:35am UTC](https://community.auth0.com/t/list-of-blocked-users-via-api/133177 "2024-05-01T08:35:29Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![kulturnat](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@kulturnat](https://community.auth0.com/u/kulturnat)\
**Post date:** [May 1, 2024, 8:35am UTC](https://community.auth0.com/t/list-of-blocked-users-via-api/133177/1 "2024-05-01T08:35:29Z")

</div>

Hi!

I’m having trouble for users not coping with password-less email login 😉

Requesting a lot of codes way to fast, and then entering the wrong code, and being block by the brute-force-filter.

There seems to be no way I can get a list of these users, except pulling each user thru th /user-blocks api endpoint, and to me it doesn’t sound very efficient. Neither for me nor for Auth0, to force me the sweep thru all my users, to detect who has been blocked.

Is there any other way to get a lost of all blocked users?

The normal blocked users is listed to me via the /users API-endpoint

/Henning

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [May 2, 2024, 6:24pm UTC](https://community.auth0.com/t/list-of-blocked-users-via-api/133177/3 "2024-05-02T18:24:17Z")

</div>

Hi @kulturnat,

You can use the Management API’s [List of search users endpoint](https://auth0.com/docs/api/management/v2/users/get-users) to get a list of users. Then you can add a filter for blocked users using `q=blocked:true` in your request.

For example:

```auto
curl -L 'https://YOUR_DOMAIN.auth0.com/api/v2/users?q=blocked:true' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer 🔒'

```

Let me know if there’s anything else I can do to help.

Cheers,  
Rueben

---

<div class="post-metadata">

**Author:** ![kulturnat](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@kulturnat](https://community.auth0.com/u/kulturnat)\
**Post date:** [May 2, 2024, 6:42pm UTC](https://community.auth0.com/t/list-of-blocked-users-via-api/133177/4 "2024-05-02T18:42:33Z")

</div>

> [@rueben.tiow](#):
>
> You can use the Management API’s [List of search users endpoint](https://auth0.com/docs/api/management/v2/users/get-users) to get a list of users. Then you can add a filter for blocked users using `q=blocked:true` in your request.

No that’s not what I’m looking for.

That query gets all the blocked users ( eg using the “block”-button on the dashboard ),  
 ![image](https://global.discourse-cdn.com/auth0/original/3X/9/0/9021ce9e223b9ff966e977276b28e3e2fd8df9e8.png)  
not the users that was block for brute-force (users entring the wrong password too many times ):  
 ![image](https://global.discourse-cdn.com/auth0/original/3X/1/0/1000270e202de8eb19d06ad91bec2e6c6dd52642.png)

Images are screenshots of two of my test-users for testing this problem.

/Henning

---

<div class="post-metadata">

**Author:** ![kulturnat](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@kulturnat](https://community.auth0.com/u/kulturnat)\
**Post date:** [May 2, 2024, 6:56pm UTC](https://community.auth0.com/t/list-of-blocked-users-via-api/133177/5 "2024-05-02T18:56:41Z")

</div>

Hi again.

I just noticed that the information is displayed in the “raw JSON” tab in the dashboard.

```
"blocked_for": [
    {
        "identifier": "email@example.org",
        "connection": "email",
        "ip": "aaaa:bbbb:cccc:dddd:eeee:ffff:gggg:hhhh"
    }

```

But I can’t use blocked\_for in the query.

/Henning

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [May 6, 2024, 5:07pm UTC](https://community.auth0.com/t/list-of-blocked-users-via-api/133177/6 "2024-05-06T17:07:29Z")

</div>

Hi @kulturnat,

Thanks for the update and clarification.

Unfortunately, there isn’t an endpoint to get a list of users blocked by brute force protection.

I suggest referring to this knowledge solution, which addresses this:

[https://community.auth0.com/t/get-a-list-of-brute-force-blocked-users/116380](https://community.auth0.com/t/get-a-list-of-brute-force-blocked-users/116380)

Cheers!  
Rueben

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [May 20, 2024, 5:07pm UTC](https://community.auth0.com/t/list-of-blocked-users-via-api/133177/7 "2024-05-20T17:07:40Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
