Page tree
Skip to end of metadata
Go to start of metadata

You can obtain the list of users by sending the GET request to the following URL: /user.

Permission to run the request: Account Owner, Administrators, Department Administrators, Authors

Department Administrators and Authors can get a list of users belonging to departments they manage and their enclosed departments.

Request Headers

ParameterDescription
X-Auth-Account-Url (required)Base URL of the account, e.g. http://myaccount.ispringlearn.com
X-Auth-Email (required)Login of Account Owner, AdministratorDepartment Administrator, or Author.
X-Auth-Password (required)Password of Account Owner, Administrator, Department Administrator, or Author.
departments (optional)

Array of departments IDs you want to get user lists of.

groups (optional)Array of groups IDs you want to get user lists of.

After the request has been completed, the system returns the response with the 200 code. The body of the response will contain xml data with information on users.

Possible Response Codes

CodeTextDescription
200Successful operationThe request has been processed successfully.
400Bad Request A request error.
401UnauthorizedAn authorization error.
403Permission deniedThe user doesn't have enough permissions to complete the request.

Sample Request

GET /user?departments[]=e95b4ad0-5f50-11e9-80c4-0a580af406eb&groups[]=e0b394fc-44b9-11e9-92c8-0a580af401f6 HTTP/1.1
Host: api-learn.ispringlearn.com
X-Auth-Account-Url: https://myaccount.ispringlearn.com
X-Auth-Email: email@email.com
X-Auth-Password: password

Sample Response

HTTP/1.1 200 Successful operation
Connection: close

<?xml version="1.0" encoding="UTF-8"?>
<response>
	<userProfile>
		<userId>43eb7146-6280-11e9-b274-a6210366ac32</userId>
		<role>publisher</role>
		<departmentId>e95b4ad0-5f50-11e9-80c4-0a580af406eb</departmentId>
		<status>1</status>
		<fields>
          <field>
            <name>LOGIN</name>
            <value>helen@ispringsolutions.com</value>
          </field>
          <field>
            <name>EMAIL</name>
            <value>helen@ispringsolutions.com</value>
          </field>
          <field>
            <name>FIRST_NAME</name>
            <value>Helen</value>
          </field>
          <field>
            <name>LAST_NAME</name>
            <value>Smith</value>
          </field>
          <field>
            <name>JOB_TITLE</name>
            <value>Sales Manager</value>
          </field>
          <field>
            <name>COUNTRY</name>
            <value>643</value>
          </field>
        </fields>
		<groups>
			<id>e0b394fc-44b9-11e9-92c8-0a580af401f6 </id>
		</groups>
		<manageableDepartmentIds>
			<id>3fa85f64-5717-4562-b3fc-2c963f66afa6</id>
		</manageableDepartmentIds>
		<addedDate>2019-04-30</addedDate>
		<lastLoginDate>2019-04-30</lastLoginDate>
	</userProfile>
    <userProfile>
		<userId>43eb7146-6280-11e9-b274-a6210366ac33</userId>
		<role>string</role>
		<departmentId>e95b4ad0-5f50-11e9-80c4-0a580af406eb</departmentId>
		<status>1</status>
		<fields>
          <field>
            <name>LOGIN</name>
            <value>daniel@ispringsolutions.com</value>
          </field>
          <field>
            <name>EMAIL</name>
            <value>daniel@ispringsolutions.com</value>
          </field>
          <field>
            <name>FIRST_NAME</name>
            <value>Daniel</value>
          </field>
          <field>
            <name>LAST_NAME</name>
            <value>Brown</value>
          </field>
          <field>
            <name>JOB_TITLE</name>
            <value>Sales Manager</value>
          </field>
          <field>
            <name>COUNTRY</name>
            <value>643</value>
          </field>
        </fields>
		<groups>
			<id>e0b394fc-44b9-11e9-92c8-0a580af401f6</id>
		</groups>
		<manageableDepartmentIds>
			<id>3fa85f64-5717-4562-b3fc-2c963f66afa6</id>
		</manageableDepartmentIds>
		<addedDate>2019-04-29</addedDate>
		<lastLoginDate>2019-04-30</lastLoginDate>
	</userProfile>
</response>



  • No labels