GET /user

Only users with administrator privileges can use the accounts API.

Syntax

Operation URI
Get a user by name GET /api/v3/user/by-name/{name}
Get a user by id GET /api/v3/user/{id}

Response Output

Dremio user output in JSON:

{
  "id": String [immutable, generated by Dremio],
  "name": String
}
Name Type Description
id String User ID. Generated by Dremio, immutable.
name String Name of the user.

Response Codes

403 - user does not have permission (has to be an administrator).
404 - user could not be found.

Example: Get user information by name

In this example, a Dremio Admin retrieves the user information by their username, cdarling.

curl -X GET \
    http://localhost:9047/api/v3/user/by-name/cdarling \
    -H "Content-Type: application/json" \
    -H "Authorization: _dremiohs85l11k2mh0b10l51ett9fsca" \

Alternatively, you can access the user information by the user ID.

curl -X GET \
    http://localhost:9047/api/v3/user/6be1a04a-f0bb-4ea8-a4f3-f86bf5e02bec \
    -H "Content-Type: application/json" \
    -H "Authorization: _dremiomn9i63s3r6sokad6hoif2j7730"

Response

The response body includes the username and their user ID.

{
  "id": "6be1a04a-f0bb-4ea8-a4f3-f86bf5e02bec",
  "name": "cdarling"
}

results matching ""

    No results matching ""