---
title: "get a user by id"
method: GET
path: "/api/v1/users/{id}"
tags: ["user"]
---

# get a user by id

`GET /api/v1/users/{id}`

This can only be done by a logged in user who has the required privileges.

## Path parameters

- `id` string, required

## Response `200`

User data

- UserObject
  - `id` string — User Id
  - `username` string, required — Username as an email address
  - `firstname` string, required — firstname
  - `lastname` string, required — lastname
  - `status` 'ACTIVE' | 'PENDING' | 'DISABLED'
  - `tenant` string
  - `roles` Role[]
    - `id` string
    - `name` string
    - `permissions` Permissions[]
    - `scope` string
    - `createdAt` string
    - `updatedAt` string
    - `isGlobal` boolean
    - `description` string
  - `permissions` Permissions[]
  - `confirmed` boolean — true, if the confirmation link/email has been triggered
  - `img` string — url to user image

## Changes

- **2022-08-18** `016871a170fd` — 1 breaking, 1 info
  - api path removed without deprecation
  - endpoint added
- **2021-09-17** `1134b4a506a5` — 3 warning, 3 info
  - added the new `ACTIVE` enum value to the `status` response property for the response status `200`
  - added the new `DISABLED` enum value to the `status` response property for the response status `200`
  - added the new `PENDING` enum value to the `status` response property for the response status `200`
  - removed the `active` enum value from the `status` response property for the response status `200`
  - …2 more
- **2021-08-09** `214f3986034a` — 2 info
  - added the optional property `roles/items/description` to the response with the `200` status
  - added the optional property `roles/items/isGlobal` to the response with the `200` status
- **2021-08-06** `e3cb40d13d06` — 2 warning, 2 info
  - removed the optional property `roles/items/isCreated` from the response with the `200` status
  - removed the optional property `roles/items/isUpdated` from the response with the `200` status
  - added the optional property `roles/items/createdAt` to the response with the `200` status
  - added the optional property `roles/items/updatedAt` to the response with the `200` status
- …earlier changes not shown

[Full history](https://skmtc.dev/openintegrationhub/apis/iam-api-for-oih/changes/api/v1/users/:id/get.md)

---

[API](https://skmtc.dev/openintegrationhub/apis/iam-api-for-oih.md) · [All operations](https://skmtc.dev/openintegrationhub/apis/iam-api-for-oih/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/openintegrationhub/iam-api-for-oih/revisions/016871a170fd/schema)
