Skip to contents

This function lists all users in a portal.

Usage

arc_portal_users(
  id = arc_portal_self(token)[["id"]],
  sort_field = NULL,
  provider = NULL,
  sort_order = NULL,
  role = NULL,
  fullname = NULL,
  username = NULL,
  firstname = NULL,
  lastname = NULL,
  filter_intersection = NULL,
  page_size = 50,
  max_pages = Inf,
  .progress = TRUE,
  host = arc_host(),
  token = arc_token()
)

Arguments

id

the portal ID. By default it fetches the id from arc_portal_self().

sort_field

optional field to sort by. It must be one of "username", "fullname", "created", "lastlogin", "mfaenabled", "level", "role".

provider

optional filter users based on their identity provider. Must be one of "arcgis", "enterprise", "facebook", "google", "apple", or "github".

sort_order

optional order to sort by. It must be one of "asc" or "desc".

role

optional role to filter down to. It must be one of "org_admin", "org_publisher", "org_user".

fullname

optional string of the user's fullanme to search for.

username

optional string of the user's user name to search for.

firstname

optional string of the user's first name to search for.

lastname

optional string of the user's last name to search for.

filter_intersection

optional boolean value. If TRUE mutliple filters are treated as an "and" condition. If FALSE, treated as an "or".

page_size

a scalar integer between 1 and 100 indicating the number of responses per page.

max_pages

the maximum number of pages to fetch. By default fetches all pages.

.progress

default TRUE. Whether to display a progress bar for requests.

host

default "https://www.arcgis.com". The host of your ArcGIS Portal.

token

an object of class httr2_token as generated by auth_code() or related function

Value

a data.frame of users.

References

API Reference

See also

Examples

if (FALSE) { # \dontrun{
set_arc_token(auth_user())
arc_portal_users()
} # }