Skip to content

ArcGIS portals contain numerous content items including feature services, maps, apps, and more. The arcgisutils package provides three main approaches for discovering content: searching by group, searching by user, and full-text search across the portal.

Objective

This tutorial will teach you how to:

  • Get content items shared with a specific group
  • Get content items owned by a specific user
  • Search for content using full-text search
  • Filter search results by item type

Authentication

Content listings may require authentication depending on what you’re trying to access:

  • Public content: No authentication needed
  • Organization content: Requires authentication
  • Private content: Requires authentication as a user with appropriate permissions
library(arcgisutils)

# Authenticate to your portal
set_arc_token(auth_user())

Group Content

If you know a group ID, you can retrieve all content items shared with that group using arc_group_content().

First, get information about a group using arc_group():

# Web Application Templates group from esri_en
web_app_templates <- arc_group("2f0ec8cb03574128bd673cefab106f39")
web_app_templates
#> <PortalGroup<Web Application Templates>>
#> id: 2f0ec8cb03574128bd673cefab106f39
#> owner: esri_en
#> created: 2012-02-10 00:27:49

Then retrieve all content items shared with this group:

group_items <- arc_group_content(web_app_templates)
group_items
#> # A data frame: 33 × 45
#>    id      owner created             modified            guid  name  title type 
#>  * <chr>   <chr> <dttm>              <dttm>              <lgl> <chr> <chr> <chr>
#>  1 a42999… esri… 2019-06-25 23:54:33 2026-02-25 23:02:39 NA    <NA>  Indo… Web …
#>  2 197fe3… esri… 2020-04-15 03:24:25 2020-04-21 04:06:38 NA    <NA>  Capa… Web …
#>  3 2331e8… esri… 2020-04-15 04:17:40 2020-04-15 04:17:40 NA    2331… Capa… Code…
#>  4 9d3f21… esri… 2020-06-30 21:59:20 2026-02-25 23:02:39 NA    <NA>  Near… Web …
#>  5 6c4364… esri… 2020-06-30 21:59:20 2023-10-25 22:04:45 NA    <NA>  Indo… Web …
#>  6 731de3… esri… 2020-06-30 21:59:21 2026-02-25 23:02:39 NA    <NA>  Inte… Web …
#>  7 65dd2f… esri… 2020-06-30 21:59:22 2026-02-25 23:02:39 NA    <NA>  Atta… Web …
#>  8 8f483b… esri… 2020-06-30 21:59:24 2026-02-25 23:02:39 NA    <NA>  Zone… Web …
#>  9 7c5f70… esri… 2020-09-29 21:58:00 2026-02-25 23:02:39 NA    <NA>  Medi… Web …
#> 10 e28c4e… esri… 2020-09-29 23:07:55 2020-09-29 23:07:55 NA    e28c… Medi… Code…
#> # ℹ 23 more rows
#> # ℹ 37 more variables: typeKeywords <list>, description <chr>, tags <list>,
#> #   snippet <chr>, thumbnail <chr>, documentation <lgl>, extent <list>,
#> #   categories <list>, spatialReference <chr>, accessInformation <chr>,
#> #   classification <lgl>, licenseInfo <chr>, culture <chr>, properties <lgl>,
#> #   advancedSettings <lgl>, url <chr>, proxyFilter <lgl>, access <chr>,
#> #   size <int>, subInfo <int>, appCategories <list>, industries <list>, …

The result is a data frame containing metadata about each item, including:

  • id: Unique item identifier
  • title: Item title
  • type: Item type (e.g., “Feature Service”, “Web Map”)
  • owner: Username of the item owner
  • url: Service URL (if applicable)

You can pass a PortalGroup object or a group ID string directly to arc_group_content().

User Content

To retrieve content items owned by a specific user, use arc_user_content().

Your Own Content

To get your own content items, first retrieve your user information with arc_user_self():

# Get current user information
self <- arc_user_self()

# Get your content items
my_items <- arc_user_content(self$username)
my_items
#> # A data frame: 13 × 48
#>    id        owner orgId created             isOrgItem modified            guid 
#>  * <chr>     <chr> <chr> <dttm>              <lgl>     <dttm>              <lgl>
#>  1 86eba1c5… r-br… hLJb… 2025-11-18 16:45:09 TRUE      2025-11-18 16:45:29 NA   
#>  2 e2f68332… r-br… hLJb… 2025-11-25 15:24:14 TRUE      2025-11-25 15:24:14 NA   
#>  3 3fb0fd44… r-br… hLJb… 2025-11-25 15:24:17 TRUE      2025-11-25 15:24:30 NA   
#>  4 e85d050d… r-br… hLJb… 2025-11-25 15:24:42 TRUE      2025-11-25 15:24:42 NA   
#>  5 0c216044… r-br… hLJb… 2025-11-25 15:24:43 TRUE      2025-11-25 15:24:58 NA   
#>  6 a0440f6e… r-br… hLJb… 2025-11-25 17:11:10 TRUE      2025-11-25 17:11:10 NA   
#>  7 2e6d6636… r-br… hLJb… 2025-11-25 17:11:12 TRUE      2025-11-25 17:11:24 NA   
#>  8 a953fbd7… r-br… hLJb… 2025-12-01 17:22:07 TRUE      2025-12-01 17:22:28 NA   
#>  9 10377361… r-br… hLJb… 2026-02-02 18:47:16 TRUE      2026-02-02 18:47:16 NA   
#> 10 ca58d5cc… r-br… hLJb… 2026-02-02 18:47:17 TRUE      2026-02-02 18:47:22 NA   
#> 11 ddc88f18… r-br… hLJb… 2026-02-03 17:24:53 TRUE      2026-02-03 17:24:54 NA   
#> 12 64f8c6f4… r-br… hLJb… 2026-03-05 21:45:27 TRUE      2026-03-05 21:45:27 NA   
#> 13 aa5f73e1… r-br… hLJb… 2026-03-05 21:45:28 TRUE      2026-03-05 21:45:41 NA   
#> # ℹ 41 more variables: name <lgl>, title <chr>, type <chr>,
#> #   typeKeywords <list>, description <lgl>, tags <list>, snippet <lgl>,
#> #   thumbnail <chr>, documentation <lgl>, extent <list>, categories <list>,
#> #   spatialReference <chr>, accessInformation <lgl>, classification <lgl>,
#> #   licenseInfo <lgl>, culture <chr>, properties <lgl>, advancedSettings <lgl>,
#> #   url <chr>, proxyFilter <lgl>, access <chr>, size <int>, subInfo <int>,
#> #   appCategories <list>, industries <list>, languages <list>, …

Another User’s Content

You can also retrieve content for any other user by their username:

# Get content for a specific user
user_items <- arc_user_content("r-bridge-docs")
user_items
#> # A data frame: 13 × 48
#>    id        owner orgId created             isOrgItem modified            guid 
#>  * <chr>     <chr> <chr> <dttm>              <lgl>     <dttm>              <lgl>
#>  1 86eba1c5… r-br… hLJb… 2025-11-18 16:45:09 TRUE      2025-11-18 16:45:29 NA   
#>  2 e2f68332… r-br… hLJb… 2025-11-25 15:24:14 TRUE      2025-11-25 15:24:14 NA   
#>  3 3fb0fd44… r-br… hLJb… 2025-11-25 15:24:17 TRUE      2025-11-25 15:24:30 NA   
#>  4 e85d050d… r-br… hLJb… 2025-11-25 15:24:42 TRUE      2025-11-25 15:24:42 NA   
#>  5 0c216044… r-br… hLJb… 2025-11-25 15:24:43 TRUE      2025-11-25 15:24:58 NA   
#>  6 a0440f6e… r-br… hLJb… 2025-11-25 17:11:10 TRUE      2025-11-25 17:11:10 NA   
#>  7 2e6d6636… r-br… hLJb… 2025-11-25 17:11:12 TRUE      2025-11-25 17:11:24 NA   
#>  8 a953fbd7… r-br… hLJb… 2025-12-01 17:22:07 TRUE      2025-12-01 17:22:28 NA   
#>  9 10377361… r-br… hLJb… 2026-02-02 18:47:16 TRUE      2026-02-02 18:47:16 NA   
#> 10 ca58d5cc… r-br… hLJb… 2026-02-02 18:47:17 TRUE      2026-02-02 18:47:22 NA   
#> 11 ddc88f18… r-br… hLJb… 2026-02-03 17:24:53 TRUE      2026-02-03 17:24:54 NA   
#> 12 64f8c6f4… r-br… hLJb… 2026-03-05 21:45:27 TRUE      2026-03-05 21:45:27 NA   
#> 13 aa5f73e1… r-br… hLJb… 2026-03-05 21:45:28 TRUE      2026-03-05 21:45:41 NA   
#> # ℹ 41 more variables: name <lgl>, title <chr>, type <chr>,
#> #   typeKeywords <list>, description <lgl>, tags <list>, snippet <lgl>,
#> #   thumbnail <chr>, documentation <lgl>, extent <list>, categories <list>,
#> #   spatialReference <chr>, accessInformation <lgl>, classification <lgl>,
#> #   licenseInfo <lgl>, culture <chr>, properties <lgl>, advancedSettings <lgl>,
#> #   url <chr>, proxyFilter <lgl>, access <chr>, size <int>, subInfo <int>,
#> #   appCategories <list>, industries <list>, languages <list>, …

You can only see content items that you have permission to access. Private items owned by other users will not be visible unless they are shared with you.

The search_items() function provides powerful full-text search capabilities across portal content. This is useful when you don’t know the specific group or user, but want to find content by keywords.

Provide a search query as the first argument:

# Search for crime-related content
search_items(
  query = "crime",
  max_pages = 1
)
#> # A data frame: 50 × 46
#>    id      owner created             modified            guid  name  title type 
#>  * <chr>   <chr> <dttm>              <dttm>              <lgl> <chr> <chr> <chr>
#>  1 ea0cfe… Toro… 2023-03-28 15:02:39 2026-02-02 17:45:21 NA    Neig… Neig… Feat…
#>  2 8d15d9… Chic… 2011-11-17 20:42:49 2015-02-05 20:28:42 NA    crim… Chic… Web …
#>  3 64691a… Temp… 2024-01-17 20:01:43 2024-01-17 20:04:45 NA    hate… Hate… Feat…
#>  4 5e055d… JASo… 2023-04-04 17:36:59 2023-09-07 19:05:06 NA    <NA>  Sher… Feat…
#>  5 30644d… MyCi… 2025-03-14 14:55:06 2025-08-20 13:55:24 NA    HPD_… HPD … Feat…
#>  6 e0992d… balt… 2023-07-31 20:27:01 2025-01-22 21:21:01 NA    Part… Part… Feat…
#>  7 2cb53d… KASU… 2019-12-10 19:06:39 2019-12-10 19:14:27 NA    Viol… Viol… Feat…
#>  8 5dc4e6… iwat… 2023-06-23 22:07:21 2023-08-09 15:33:46 NA    <NA>  Prop… Feat…
#>  9 ab92f5… KASU… 2019-12-09 16:16:13 2019-12-10 18:55:20 NA    Prop… Prop… Feat…
#> 10 348b60… admi… 2024-02-01 16:04:55 2026-01-09 16:39:26 NA    <NA>  Crim… Feat…
#> # ℹ 40 more rows
#> # ℹ 38 more variables: typeKeywords <list>, description <chr>, tags <list>,
#> #   snippet <chr>, thumbnail <chr>, documentation <lgl>, extent <list>,
#> #   categories <list>, spatialReference <chr>, accessInformation <chr>,
#> #   classification <lgl>, licenseInfo <chr>, culture <chr>, properties <list>,
#> #   advancedSettings <lgl>, url <chr>, proxyFilter <lgl>, access <chr>,
#> #   size <int>, subInfo <int>, appCategories <list>, industries <list>, …

By default, search_items() searches ArcGIS Online. To search your private or Enterprise portal, set the ARCGIS_HOST environment variable to your portal URL.

Filtering by Item Type

You can filter search results to specific item types using the item_type argument. To see all available item types, use portal_item_types():

# View all valid item types
head(portal_item_types())
#> [1] "360 VR Experience"     "3DTilesPackage"        "3DTilesService"       
#> [4] "Administrative Report" "Analysis Model"        "Apache Parquet"

Filter your search to only Feature Services:

# Search for crime feature services only
crime_fs <- search_items(
  query = "crime",
  item_type = "Feature Service",
  max_pages = 1
)

crime_fs
#> # A data frame: 50 × 46
#>    id      owner created             modified            guid  name  title type 
#>  * <chr>   <chr> <dttm>              <dttm>              <lgl> <chr> <chr> <chr>
#>  1 ea0cfe… Toro… 2023-03-28 15:02:39 2026-02-02 17:45:21 NA    Neig… Neig… Feat…
#>  2 64691a… Temp… 2024-01-17 20:01:43 2024-01-17 20:04:45 NA    hate… Hate… Feat…
#>  3 5e055d… JASo… 2023-04-04 17:36:59 2023-09-07 19:05:06 NA    <NA>  Sher… Feat…
#>  4 30644d… MyCi… 2025-03-14 14:55:06 2025-08-20 13:55:24 NA    HPD_… HPD … Feat…
#>  5 e0992d… balt… 2023-07-31 20:27:01 2025-01-22 21:21:01 NA    Part… Part… Feat…
#>  6 2cb53d… KASU… 2019-12-10 19:06:39 2019-12-10 19:14:27 NA    Viol… Viol… Feat…
#>  7 5dc4e6… iwat… 2023-06-23 22:07:21 2023-08-09 15:33:46 NA    <NA>  Prop… Feat…
#>  8 ab92f5… KASU… 2019-12-09 16:16:13 2019-12-10 18:55:20 NA    Prop… Prop… Feat…
#>  9 348b60… admi… 2024-02-01 16:04:55 2026-01-09 16:39:26 NA    <NA>  Crim… Feat…
#> 10 94bc33… admi… 2023-08-11 20:09:35 2026-01-09 17:03:25 NA    <NA>  Crim… Feat…
#> # ℹ 40 more rows
#> # ℹ 38 more variables: typeKeywords <list>, description <chr>, tags <list>,
#> #   snippet <chr>, thumbnail <chr>, documentation <lgl>, extent <list>,
#> #   categories <list>, spatialReference <chr>, accessInformation <chr>,
#> #   classification <lgl>, licenseInfo <chr>, culture <chr>, properties <list>,
#> #   advancedSettings <lgl>, url <chr>, proxyFilter <lgl>, access <chr>,
#> #   size <int>, subInfo <int>, appCategories <list>, industries <list>, …

Pagination

Search results are paginated. By default, search_items() will fetch all pages, but you can limit results using max_pages:

# Fetch only the first 3 pages of results
search_items(
  query = "demographics",
  item_type = "Feature Service",
  max_pages = 3
)
#> # A data frame: 150 × 46
#>    id      owner created             modified            guid  name  title type 
#>  * <chr>   <chr> <dttm>              <dttm>              <lgl> <chr> <chr> <chr>
#>  1 ddd151… esri… 2023-06-08 20:51:37 2026-02-06 01:13:31 NA    Esri… Esri… Feat…
#>  2 fc6f98… esri… 2023-03-01 00:40:06 2026-02-07 00:13:30 NA    Esri… Esri… Feat…
#>  3 8f6b71… esri… 2025-02-07 18:37:48 2025-12-02 00:25:14 NA    USA_… USA … Feat…
#>  4 48f0d1… esri… 2022-10-05 17:49:48 2025-12-11 01:43:10 NA    Euro… Euro… Feat…
#>  5 8a5569… esri… 2023-03-16 23:07:18 2025-08-26 21:43:08 NA    Esri… Esri… Feat…
#>  6 5dcc70… esri… 2022-10-05 17:15:18 2025-12-10 22:39:19 NA    Euro… Euro… Feat…
#>  7 5eb88d… esri… 2022-10-05 17:57:31 2025-12-11 02:28:06 NA    Euro… Euro… Feat…
#>  8 b0b3b3… esri… 2024-07-24 15:59:54 2025-11-05 05:12:57 NA    Esri… Esri… Feat…
#>  9 7c149b… esri… 2022-10-05 17:29:21 2025-12-11 00:54:11 NA    Euro… Euro… Feat…
#> 10 271897… esri… 2018-06-04 18:35:53 2025-11-11 04:01:09 NA    AGOL… Popu… Feat…
#> # ℹ 140 more rows
#> # ℹ 38 more variables: typeKeywords <list>, description <chr>, tags <list>,
#> #   snippet <chr>, thumbnail <chr>, documentation <lgl>, extent <list>,
#> #   categories <list>, spatialReference <chr>, accessInformation <chr>,
#> #   classification <lgl>, licenseInfo <chr>, culture <chr>, properties <list>,
#> #   advancedSettings <lgl>, url <chr>, proxyFilter <lgl>, access <chr>,
#> #   size <int>, subInfo <int>, appCategories <list>, industries <list>, …

Setting max_pages = NULL will fetch all available pages. Use caution with broad searches that may return thousands of items.

Using Search Results

Once you have search results, you can extract item IDs and open them with arc_open() from the arcgislayers package:

library(arcgislayers)

# Search for feature services
results <- search_items(
  query = "crime",
  item_type = "Feature Service",
  max_pages = 1
)

# Open the first result
arc_open(results$id[1])
#> <FeatureServer <1 layer, 0 tables>>
#> CRS: 26917
#> Capabilities: Query,Extract
#>   0: NEIGHBOURHOOD_CRIME_RATE_OPEN_DATA (esriGeometryPolygon)

Advanced Search Queries

The query parameter accepts Esri’s advanced search syntax, allowing you to build complex queries:

# Search for items owned by a specific user
search_items(
  query = "owner:r-bridge-docs",
  max_pages = 1
)
#> # A data frame: 13 × 48
#>    id        owner orgId created             isOrgItem modified            guid 
#>  * <chr>     <chr> <chr> <dttm>              <lgl>     <dttm>              <lgl>
#>  1 3fb0fd44… r-br… hLJb… 2025-11-25 15:24:17 TRUE      2025-11-25 15:24:30 NA   
#>  2 10377361… r-br… hLJb… 2026-02-02 18:47:16 TRUE      2026-02-02 18:47:16 NA   
#>  3 0c216044… r-br… hLJb… 2025-11-25 15:24:43 TRUE      2025-11-25 15:24:58 NA   
#>  4 e85d050d… r-br… hLJb… 2025-11-25 15:24:42 TRUE      2025-11-25 15:24:42 NA   
#>  5 a953fbd7… r-br… hLJb… 2025-12-01 17:22:07 TRUE      2025-12-01 17:22:28 NA   
#>  6 ca58d5cc… r-br… hLJb… 2026-02-02 18:47:17 TRUE      2026-02-02 18:47:22 NA   
#>  7 aa5f73e1… r-br… hLJb… 2026-03-05 21:45:28 TRUE      2026-03-05 21:45:41 NA   
#>  8 e2f68332… r-br… hLJb… 2025-11-25 15:24:14 TRUE      2025-11-25 15:24:14 NA   
#>  9 2e6d6636… r-br… hLJb… 2025-11-25 17:11:12 TRUE      2025-11-25 17:11:24 NA   
#> 10 64f8c6f4… r-br… hLJb… 2026-03-05 21:45:27 TRUE      2026-03-05 21:45:27 NA   
#> 11 ddc88f18… r-br… hLJb… 2026-02-03 17:24:53 TRUE      2026-02-03 17:24:54 NA   
#> 12 86eba1c5… r-br… hLJb… 2025-11-18 16:45:09 TRUE      2025-11-18 16:45:29 NA   
#> 13 a0440f6e… r-br… hLJb… 2025-11-25 17:11:10 TRUE      2025-11-25 17:11:10 NA   
#> # ℹ 41 more variables: name <lgl>, title <chr>, type <chr>,
#> #   typeKeywords <list>, description <lgl>, tags <list>, snippet <lgl>,
#> #   thumbnail <chr>, documentation <lgl>, extent <list>, categories <list>,
#> #   spatialReference <chr>, accessInformation <lgl>, classification <lgl>,
#> #   licenseInfo <lgl>, culture <chr>, properties <lgl>, advancedSettings <lgl>,
#> #   url <chr>, proxyFilter <lgl>, access <chr>, size <int>, subInfo <int>,
#> #   appCategories <list>, industries <list>, languages <list>, …

Summary

Choose the approach that best fits your workflow:

  • Use group content when working with curated collections
  • Use user content when you know the content owner
  • Use search when exploring content by keywords or attributes

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