Ventia
Users

Get a user by ID

Retrieves a user by the `id` parameter. Only active users belonging to the authenticated group or its descendant groups are returned.

GET
/users/{id}

Authorization

bearerAuth
headerAuthorizationBearer <token>

API key sent as Authorization: Bearer <API_KEY>.

Path Parameters

id*string

The ID of the user to retrieve

Header Parameters

X-API-KEY*string

The API key used to authenticate the request

Response Body

User retrieved successfully

application/json
  1. response
_id?string

User ID

name?string

The user's first name

lastname?string

The user's last name

email?string

The user's email address

Formatemail
phone_work?|

The user's work phone number

firstLogin?string

The date of the user's first login

Formatdate-time
group?string

The ID of the group to which the user belongs

roles?array<string>

The roles assigned to the user

curl -X GET 'https://api.getventia.com/api/v1.0/users/string' \  -H 'X-API-KEY: string'
{  "_id": "64b7654c3f3ae9b9d1e7c5d8",  "name": "John",  "lastname": "Doe",  "email": "john.doe@example.com",  "phone_work": "+1234567890",  "firstLogin": "2024-01-01T12:00:00Z",  "group": "64b7654c3f3ae9b9d1e7c5d7",  "roles": [    "user",    "super"  ]}