---
title: "Retrieve a user by external ID"
method: GET
path: "/user/externalId/{externalId}"
tags: ["User"]
---

# Retrieve a user by external ID

`GET /user/externalId/{externalId}`

## Path parameters

- `externalId` string, required

## Response `200`

OK

- MyUserDTO — A user that can login on the platform
  - `id` integer
  - `self` string
  - `userName` string, required
  - `name` string, required — Given name
  - `surname` string, required — Family name
  - `fullName` string — Concatenation of name and surname
  - `password` string — Plain-text password, used only when setting a new password
  - `passwordHash` string — The hashed password, visible to platform administrator only
  - `language` string — Preferred user language
  - `email` string, required — User email address to receive platform notifications
  - `pec` string — User PEC address for Italian electronic invoicing
  - `phoneNumber` string
  - `company` UrlEntityDTO — Reference to a related resource
    - `url` string, required — Reference to another resource
  - `userCompany` UrlEntityDTO — Reference to a related resource
    - `url` string, required — Reference to another resource
  - `companyGroup` UrlEntityDTO — Reference to a related resource
    - `url` string, required — Reference to another resource
  - `address` AddressDTO — A physical address
    - `id` integer
    - `country` string — Country name
    - `city` string — City name
    - `address` string — Street name, with number
    - `zipCode` string — Local postal code
    - `state` string — Province/State code
    - `countryCode` string — Country code
  - `homeAddress` AddressDTO — A physical address
    - `id` integer
    - `country` string — Country name
    - `city` string — City name
    - `address` string — Street name, with number
    - `zipCode` string — Local postal code
    - `state` string — Province/State code
    - `countryCode` string — Country code
  - `userRole` 'ROLE_ANONYMOUS' | 'ROLE_USER' | 'ROLE_VENDOR' | 'ROLE_RESELLER' | 'ROLE_DISTRIBUTOR' | 'ROLE_SUPERVISOR' | 'ROLE_ADMIN' | 'ROLE_SUPERADMIN', required — Defines user roles across the platform
  - `groups` string[]
  - `companyName` string — Write-only field to specify a company name when creating a user with userRole ROLE_VENDOR
  - `companyTaxCode` string — Write-only field to specify a company tax code when creating a user with userRole ROLE_VENDOR
  - `enabled` boolean — If the user can login or not
  - `activated` boolean — If the user has a confirmed email address
  - `readOnly` boolean — If the user profile can be updated or is synchronized from an external system
  - `doNotTrack` boolean — If the user does not wants to be tracked
  - `acceptedTerms` boolean — If the user has accepted terms and conditions
  - `environment` string — The name of the environment this user belongs to
  - `activationDate` string, date-time — When the user has confirmed successfully his email address
  - `creationDate` string, date-time — When the user has created his account
  - `externalId` string — An externalId if the user is synchronized from an external system
  - `keycloakToken` string — The account id of the user when using the Keycloak SSO integration
  - `keycloakAuthenticated` boolean — If the current user is authenticated via Keycloak SSO integration
  - `fiscalCode` string — Fiscal code of a private customer, used only when userRole is ROLE_USER
  - `iban` string — IBAN of the user, to receive manually executed refunds
  - `paymentDataSaved` boolean — If the user has a valid payment method available
  - `culture` string — String representation of the culture, derived from language and country code
  - `passwordAlreadySet` boolean — If the user has a password set
  - `subscribedToNotificationEmails` boolean — If the user want to receive email notifications generated by the platform
  - `deleted` boolean — If the user has been deleted
  - `riskProfile` UrlEntityDTO — Reference to a related resource
    - `url` string, required — Reference to another resource
  - `resellerCatalog` UrlEntityDTO — Reference to a related resource
    - `url` string, required — Reference to another resource
  - `canImpersonate` string[] — What roles can this user impersonate
  - `canCreate` string[] — What roles can this user create
  - `validAddress` boolean — If the user has a configured valid address
  - `validBillingData` boolean — If the user has configured valid billing data
  - `publicKey` string — The user's SSH public key
  - `slug` string — Auto-generated string uniquely identifying the user
  - `canBeImpersonated` boolean — Whether the user can be impersonated by the requesting client
  - `metadata` UrlEntityDTO — Reference to a related resource
    - `url` string, required — Reference to another resource

## Other responses

- `400` — Bad Request
- `403` — Forbidden
- `404` — Not Found
- `405` — Method Not Allowed
- `409` — Conflict
- `422` — Unprocessable Entity
- `423` — Locked
- `429` — Too Many Requests
- `500` — Internal Server Error

---

[API](https://skmtc.net/cloudesire/apis/cloudesire-users-api.md) · [All operations](https://skmtc.net/cloudesire/apis/cloudesire-users-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cloudesire/cloudesire-users-api/versions/3d64889e8ae7/schema)
