Manage users

You can use the portal service to access and manage users in an organization. A user is a stored identity that represents a registered user of the portal.

Content
Users displayed in Members section in an organization in ArcGIS portal

Working with users

A user is created when someone signs up for a developer account, when an account is created for a user by an administrator, or when someone joins an organization. When an account is created, an identity and a role are assigned. The role defines the set of privileges and operations that the user can perform within the organization associated with the account.

Administrators can also use data management tools and ArcGIS REST API to create and manage users. Only an administrator or the owner of a user's account can make updates to users within an organization.

The typical way to work with users is to:

  1. Invite users or create new users in the portal.
  2. Search for users.
  3. Assign users to groups.
  4. Manage user properties.

Code examples

Create a new user

Create a new user using new member default values.

Python

ArcGIS API for PythonArcGIS API for PythonArcGIS REST JS
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
from arcgis.gis import GIS
gis = GIS() # Default portal: https://www.arcgis.com/
new_user = gis.users.create(username= 'new_unique_username',
                            password= '<strong_password>',
                            firstname= 'user_firstname',
                            lastname= 'user_lastname',
                            email= 'user_email@company.com',
                            description= 'new user using member defaults')
print(f"New user: {new_user.username}")
print(f"Role: {new_user.role}")
print(f"User type: {new_user.userLicenseTypeId}")

REST API

cURLcURLHTTP
Use dark colors for code blocksCopy
1
2
3
4
curl https://www.arcgis.com/sharing/rest/community/users \
-d 'q=JSmith' \
-d 'f=pjson' \
-d 'token=<ACCESS_TOKEN>'

Search for a user

Use a query to search users by name, description, and other information.

APIs

ArcGIS Maps SDK for JavaScriptArcGIS Maps SDK for JavaScriptArcGIS API for PythonArcGIS REST JS
Expand
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
        const portal = new Portal();
        portal.url = "https://www.arcgis.com/"
        portal.authMode = "auto";
        portal.load()
          .then(()=> {
            const queryParameters = {
            query: "JSmith"
          };
            portal.queryUsers(queryParameters).then((response)=>{
              console.log(response);
            });
          });

REST API

cURLcURLHTTP
Use dark colors for code blocksCopy
1
2
3
4
curl https://www.arcgis.com/sharing/rest/community/users \
-d 'q=JSmith' \
-d 'f=pjson' \
-d 'token=<ACCESS_TOKEN>'

Get a user

Find a user with their username.

APIs

ArcGIS Maps SDK for JavaScriptArcGIS Maps SDK for JavaScriptArcGIS API for PythonArcGIS REST JS
Expand
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
      const url = "https://www.arcgis.com/sharing/rest/community/users/jsmith"

      const options = {
        query: {
          f: "pjson"
        },
        responseType: "pjson"
      };

        esriRequest(url, options,{
        }).then((response)=>{
          const data = response.data
          console.log(data);
      })

REST API

cURLcURLHTTP
Use dark colors for code blocksCopy
1
2
curl https://www.arcgis.com/sharing/rest/community/users/jsmith \
-d 'f=pjson'

Update user information

Update user profile information such as their role or credits assigned.

APIs

ArcGIS API for PythonArcGIS API for PythonArcGIS REST JS
Use dark colors for code blocksCopy
1
2
3
4
5
from arcgis.gis import GIS
gis = GIS(username="USERNAME", password="PASSWORD")
user = gis.users.get(gis.users.me.username)
results = user.update(description="A new description of your user account.")
print(results)

REST API

cURLcURLHTTP
Use dark colors for code blocksCopy
1
2
3
4
5
curl https://www.arcgis.com/sharing/rest/community/users/<USERNAME>/update \
-d 'username=<USERNAME>'
-d 'description=A new description of user ' \
-d 'f=pjson' \
-d 'token=<ACCESS_TOKEN>'

Get invitation status

Find the status of an invitation that was sent to a user to join the portal.

APIs

ArcGIS API for PythonArcGIS API for PythonArcGIS REST JS
Use dark colors for code blocksCopy
1
2
3
4
from arcgis.gis import GIS
gis = GIS(username="USERNAME", password="PASSWORD")
invitation = gis.users.invitations.get("INVITATION_ID")
print(invitation)

REST API

cURLcURLHTTP
Use dark colors for code blocksCopy
1
2
3
curl https://www.arcgis.com/sharing/rest/community/users/<USERNAME>/invitations/<INVITATION_ID> \
-d 'f=pjson' \
-d 'token=<ACCESS_TOKEN>'

Services

API support

SearchItemsUsersGroupsSettingsSecurity
ArcGIS Maps SDK for JavaScript1111
ArcGIS Maps SDK for .NET1111
ArcGIS Maps SDK for Kotlin1111
ArcGIS Maps SDK for Swift1111
ArcGIS Maps SDK for Flutter1111
ArcGIS Maps SDK for Java1111
ArcGIS Maps SDK for Qt1111
ArcGIS API for Python
ArcGIS REST JS
Esri Leaflet222222
MapLibre GL JS222222
OpenLayers222222
Full supportPartial supportNo support
  • 1. Limited operations, use HTTP requests.
  • 2. Access via ArcGIS REST JS.

Tools

Use tools to access the portal and create and manage content for applications.

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