Skip to main content

Retrieve a user

Jetmir Abdija avatar
Written by Jetmir Abdija
Updated this week

These are the steps to find a specific user in BlueDolphin. Only the Administrator role in BlueDolphin can retrieve other users from the system.

HTTP responses

HTTP response status code

Interpretation

200 OK

User retrieved successfully

400 Bad Request

One or more parameters are missing or incorrect.

The response body returns a specific error:

  • ID is missing or incorrect

  • Path parameter contains a non-existent ID

401 Unauthorized

Invalid or missing API key secret and/or tenant

403 Forbidden

The user doesn’t have admin rights

To retrieve a specific user from the system, make a GET request to the /users/{id} endpoint specifying:

  • Resource/endpoint destination URL. Replace the path parameter {id} with the ID of the existing user that you want to retrieve.

  • The header for your API request

In this example, we want to retrieve the user with the user ID 41b4433f326cf6efc524f7b7. To get the user, we will pass a GET request to the URI https://public-api.eu.bluedolphin.app/v1/users/41b4433f326cf6efc524f7b7.

curl -L 'https://public-api.eu.bluedolphin.app/v1/users/41b4433f326cf6efc524f7b7' \
-H 'x-api-key: YOURAPIKEYSECRET' \
-H 'tenant: yourtenantname' \
-H 'Content-Type: application/json'

Response properties

Property

Type

Description

id

string

Unique identifier for the user

first_name

string

The first name of the user

last_name

string

The last name of the user

email

string

The email of the user

invite_id

string

Invite ID that the user must use to complete the signup. Once the user signs up, it is no longer active and an empty value is returned.

roles

array

The roles of the user

roles[].id

string

Unique identifier for the role

roles[].name

string

The name of the role

roles[].internal_name

string

The internal name of the role

avatar

string

The URL of the user’s avatar

default_view_mode

boolean

Indicates if the user’s default mode is view mode or edit mode

A successful call returns a response with a 200 OK HTTP status code and the following body:

{
    "id": "41b4433f326cf6efc524f7b7",
    "first_name": "Jack",
    "last_name": "White",
    "email": "[email protected]",
    "invite_id": "",
    "roles": [
        {
            "id": "52f83f88b52c4efb3d7953b3",
            "name": "Default users",
            "internal_name": "users"
        },
        {
            "id": "52f83f88b52c4efb3d7953b2",
            "name": "Administrators",
            "internal_name": "administrators"
        }
    ],
    "avatar": "https://www.gravatar.com/avatar/bce65ae227ae45e2396b572cd5e35b3a.jpg?d=https%3A%2F%2Fcdn.domain.app%2Fmedia%2Fimages%2Fdomain%2Fdefault_avatar.png",
    "default_view_mode": true
}
Did this answer your question?