Home > Cloud Cruiser 3 > REST API reference > Users and user groups > Get a user by ID

Get a user by ID

Retrieves the detailed information of the user specified by userId .

URL syntax

http://<ccServerURL
>/rest/v1/users/user/<userId
>

HTTP method

GET

Request

URL path parameters (required)

userId (type: int )

Request body

None

Response

Content-Type
application/xml
Response body

XML text with root element user and the following XML schema:

<xs:element name="user" xmlns:tns="http://www.cloudcruiser.com/webservices/v1/User">
  <xs:complexType>
    <xs:sequence>
      <xs:element name="userName" type="xs:string"/>
      <xs:element minOccurs="0" name="password" type="xs:string"/>
      <xs:element minOccurs="0" name="fullUserName" type="xs:string"/>
      <xs:element minOccurs="0" name="domainUsername" type="xs:string"/>
      <xs:element name="userGroup" type="tns:UserGroupItem"/>
      <xs:element minOccurs="0" name="emailAddress" type="xs:string"/>
      <xs:element default="true" name="enabled" type="xs:boolean"/>
      <xs:element default="true" name="nativeCCUser" type="xs:boolean"/>
      <xs:element maxOccurs="unbounded" name="role" type="tns:Role"/>
      <xs:element minOccurs="0" name="userflag1" type="xs:string"/>
      <xs:element minOccurs="0" name="userflag2" type="xs:string"/>
    </xs:sequence>
    <xs:attribute name="id" type="xs:int"/>
  </xs:complexType>
</xs:element>
 
<xs:complexType name="UserGroupItem">
  <xs:sequence/>
  <xs:attribute name="name" type="xs:string"/>
  <xs:attribute name="id" type="xs:int"/>
</xs:complexType>
JAXB type
com.cloudcruiser.server.webservices.v1.dto.user.User

Example

URL
http://localhost:8080/rest/v1/users/user/2
Response body
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<user xmlns="http://www.cloudcruiser.com/webservices/v1/User" id="2">
  <userName>admin</userName>
  <fullUserName>Administrator</fullUserName>
  <domainUsername>bigorg</domainUsername>
  <userGroup name="admin" id="2"/>
  <emailAddress>admin@bigorg.com</emailAddress>
  <enabled>true</enabled>
  <nativeCCUser>true</nativeCCUser>
  <role name="Admin" id="3">
    <description>Full access to all application functions</description>
  </role>
  <role name="Customer Budget" id="6">
    <description>Access to customer budgets</description>
  </role>
  <role name="Report User" id="4">
    <description>Access only to running reports</description>
  </role>
</user>
Java
User user = userServiceProxy.getUserById(2);
Last modified

Tags

This page has no custom tags.

Classifications

This page has no classifications.
© Copyright 2018 Hewlett Packard Enterprise Development LP