Passer au contenu principal
GET
/
user-blocks
/
{id}
TypeScript
import { ManagementClient } from "auth0";

async function main() {
    const client = new ManagementClient({
        token: "<token>",
    });
    await client.userBlocks.list("id", {
        considerBruteForceEnablement: true,
    });
}
main();
{
  "blocked_for": [
    {
      "identifier": "john.doe@gmail.com",
      "ip": "10.0.0.1",
      "connection": "<string>"
    }
  ]
}

Autorisations

Authorization
string
header
requis

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Paramètres de chemin

id
string
requis

user_id of the user blocks to retrieve.

Paramètres de requête

consider_brute_force_enablement
boolean
If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses.
If true and Brute Force Protection is disabled, will return an empty list.

Réponse

User block successfully retrieved.

blocked_for
object[]

Array of identifier + IP address pairs. IP address is optional, and may be omitted in certain circumstances (such as Account Lockout mode).