/updateUserLevel: Update User Level

URL:
https://[root]/portals/[portalID]/updateUserLevel
Methods:
POST

Example usage

The following is a sample ArcGIS Online POST request for the updateUserLevel operation:

Use dark colors for code blocksCopy
1
2
3
4
5
6
POST /sharing/rest/portals/0123456789ABCDEF/updateUserLevel HTTP/1.1
Host: org.arcgis.com
Content-Type: application/x-www-form-urlencoded
Content-Length: []

userName=jsmight&level=2&f=pjson

Description

The updateUserLevel operatio allows administrators of an organization to update the level of a user. Administrators can leverage two levels of membership when assigning roles and privileges to members, membership levels allow organizations to control access to some ArcGIS capabilities for some members while granting more complete access to other members. Level 1 membership is designed for members who need privileges to view and interact with existing content, while Level 2 membership is for those who contribute, create, and share content and groups, in addition to other tasks.

Maximum user quota of an organization at the given level is checked before allowing the update.

Built-in roles including organization administrator, publisher, and user are assigned as Level 2, members with custom roles can be assigned as Level 1 or Level 2.

Level 1 membership allows for limited capabilities given through a maximum of 9 privileges:

  • portal:user:joinGroup
  • portal:user:viewOrgGroups
  • portal:user:viewOrgItems
  • portal:user:viewOrgUsers
  • premium:user:geocode
  • premium:user:networkanalysis
  • premium:user:demographics
  • premium:user:elevation
  • portal:user:joinNonOrgGroup

If updating the role of a Level 1 user with a custom role that has more privileges than the nine, additional privileges will be disabled for the user to ensure restriction.

Level 1 users are not allowed to own any content or group which can be reassigned to other users through the Reassign Item and Reassign Group operations before downgrading them. The operation will also fail if the user being updated has got licenses assigned to premium apps that are not allowed at the targeting level.

Request parameters

ParameterDetails

user

The username whose level to be updated.

level

The level of the user to be set.

Values: 1 (for user with custom role only) | 2 (for user with any built-in or custom role)

f

The response format. The default format is html.

Values: html | json | pjson

Response properties

PropertyDetails

success

Indicates if the operation was successful.

JSON Response syntax

Use dark colors for code blocksCopy
1
2
3
{
  "success": true
}

JSON Response example

Below is a sample success response:

Use dark colors for code blocksCopy
1
2
3
{
  "success": true
}

Below is a sample error message:

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
{
  "error": {
    "code": 400,
    "messageCode": "ORG_1084",
    "message": "Unable to change user's level. User must not own items or groups.",
    "details": []
  }
}

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.