From b8d52d6e794bac8a491b461159e070be5747aa10 Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Tue, 6 Jan 2026 17:42:53 -0500 Subject: [PATCH 01/11] Update authentication to support new EDI IAM system (#60) Update the authentication functions to be compatible with the new EDI Identity and Access Management system. Ensure support for the new EDI IAM while maintaining backward compatibility with the previous release. Closes #60 --- EDIutils.Rproj | 1 + R/login.R | 10 ++++++---- R/logout.R | 5 +++-- R/utilities.R | 10 +++++++--- tests/testthat/setup-EDIutils.R | 2 +- tests/testthat/test_utilities.R | 7 +++++-- vignettes/evaluate_and_upload.Rmd | 2 +- vignettes/tests_requiring_authentication.Rmd | 2 +- 8 files changed, 25 insertions(+), 14 deletions(-) diff --git a/EDIutils.Rproj b/EDIutils.Rproj index 21a4da08..dfb6a1b9 100644 --- a/EDIutils.Rproj +++ b/EDIutils.Rproj @@ -1,4 +1,5 @@ Version: 1.0 +ProjectId: cad0fc9a-82d4-4af8-b8ce-a598f5372c69 RestoreWorkspace: Default SaveWorkspace: Default diff --git a/R/login.R b/R/login.R index 82956afe..e82c8898 100644 --- a/R/login.R +++ b/R/login.R @@ -6,8 +6,8 @@ #' @param config (character) Path to config.txt, which contains \code{userId} #' and \code{userPass} (see details below) #' -#' @return (character) A temporary (~10 hour) authentication token written to -#' the system variable "EDI_TOKEN". +#' @return (character) Temporary (~10 hour) authentication tokens written to +#' the system variables "EDI_TOKEN" and "AUTH_TOKEN". #' #' @note Only works when authenticating with EDI credentials. Does not work #' when authenticating with ORCiD, GitHub, or Google credentials. @@ -79,6 +79,8 @@ login <- function(userId = NULL, userPass = NULL, config = NULL) { handle = httr::handle("") ) httr::stop_for_status(resp) - token <- httr::cookies(resp)$value - Sys.setenv(EDI_TOKEN = token) + token_name <- httr::cookies(resp)$name + token_value <- httr::cookies(resp)$value + Sys.setenv(EDI_TOKEN = token_value[token_name == "edi-token"]) + Sys.setenv(AUTH_TOKEN = token_value[token_name == "auth-token"]) } diff --git a/R/logout.R b/R/logout.R index 179c10bd..7420c627 100644 --- a/R/logout.R +++ b/R/logout.R @@ -1,7 +1,7 @@ #' Logout of the EDI repository #' -#' @details Removes the temporary authentication token system variable -#' "EDI_TOKEN". +#' @details Removes the temporary authentication token system variables +#' "EDI_TOKEN" and "AUTH_TOKEN". #' #' @return (NULL) No return value. #' @@ -16,4 +16,5 @@ #' logout <- function() { suppressWarnings(Sys.unsetenv("EDI_TOKEN")) + suppressWarnings(Sys.unsetenv("AUTH_TOKEN")) } diff --git a/R/utilities.R b/R/utilities.R index 04e62ac8..661ef461 100644 --- a/R/utilities.R +++ b/R/utilities.R @@ -6,13 +6,17 @@ #' @noRd #' bake_cookie <- function() { - token <- Sys.getenv("EDI_TOKEN") - if (token == "") { + edi_token <- Sys.getenv("EDI_TOKEN") + auth_token <- Sys.getenv("AUTH_TOKEN") + if (edi_token == "" || auth_token == "") { stop("Authentication token not found. Run 'login()' then try again.", call. = FALSE ) } - cookie <- httr::set_cookies(`auth-token` = token) + cookie <- httr::set_cookies( + `edi-token` = edi_token, + `auth-token` = auth_token + ) cookie$options$cookie <- curl::curl_unescape(cookie$options$cookie) return(cookie) } diff --git a/tests/testthat/setup-EDIutils.R b/tests/testthat/setup-EDIutils.R index d302d3a3..e2d0dba5 100644 --- a/tests/testthat/setup-EDIutils.R +++ b/tests/testthat/setup-EDIutils.R @@ -10,6 +10,7 @@ if (!nzchar(Sys.getenv("EDI_TOKEN"))) { if (dir.exists(vcr_dir)) { # Fake API token to fool our package Sys.setenv("EDI_TOKEN" = "foobar") + Sys.setenv("AUTH_TOKEN" = "foobar") } else { # If there's no mock files nor API token, impossible to run tests stop("No API key nor cassettes, tests cannot be run.", @@ -23,4 +24,3 @@ invisible(vcr::vcr_configure( filter_request_headers = list(`auth-token` = "<<>>"), filter_response_headers = list(`auth-token` = "<<>>") )) -vcr::check_cassette_names() diff --git a/tests/testthat/test_utilities.R b/tests/testthat/test_utilities.R index d46c96ca..fa8acfe3 100644 --- a/tests/testthat/test_utilities.R +++ b/tests/testthat/test_utilities.R @@ -36,11 +36,14 @@ testthat::test_that('Landing page URLs are constructed', { testthat::test_that("bake_cookie() works", { - token <- Sys.getenv("EDI_TOKEN") + edi_token <- Sys.getenv("EDI_TOKEN") Sys.setenv(EDI_TOKEN = "foobar") + auth_token <- Sys.getenv("AUTH_TOKEN") + Sys.setenv(AUTH_TOKEN = "foobar") res <- bake_cookie() expect_equal(class(res), "request") - Sys.setenv(EDI_TOKEN = token) + Sys.setenv(EDI_TOKEN = edi_token) + Sys.setenv(AUTH_TOKEN = auth_token) }) diff --git a/vignettes/evaluate_and_upload.Rmd b/vignettes/evaluate_and_upload.Rmd index c5c94861..2b9db7d3 100644 --- a/vignettes/evaluate_and_upload.Rmd +++ b/vignettes/evaluate_and_upload.Rmd @@ -39,7 +39,7 @@ login(userId = "my_name", userPass = "my_secret") login(config = paste0(tempdir(), "/config.txt")) ``` -The `login()` function exchanges credentials for a temporary (~10 hour) authentication token, which is written to the `EDI_TOKEN` environment variable referenced by EDIutils functions requiring authentication. +The `login()` function exchanges credentials for temporary (~10 hour) authentication tokens, which are written to the `EDI_TOKEN` and `AUTH_TOKEN` environment variable referenced by EDIutils functions requiring authentication. ## Reserve a Data Package ID diff --git a/vignettes/tests_requiring_authentication.Rmd b/vignettes/tests_requiring_authentication.Rmd index 55f34716..ddad759a 100644 --- a/vignettes/tests_requiring_authentication.Rmd +++ b/vignettes/tests_requiring_authentication.Rmd @@ -26,7 +26,7 @@ The EDI repository "staging" environment is a sandbox for testing data package r #### Requiring Authentication -The first line of any test requiring authentication should include `skip_if_logged_out()`. This is an internal use only function located in R/utilities.R. Tests including this line will be skipped unless the R environment variable `EDI_TOKEN` is set. Use `login()` to set this variable. +The first line of any test requiring authentication should include `skip_if_logged_out()`. This is an internal use only function located in R/utilities.R. Tests including this line will be skipped unless the R environment variables `EDI_TOKEN` and `AUTH_TOKEN` are set. Use `login()` to set this variable. Example: ```{r eval=FALSE} From 2a767cff721b3db4306f6cedff6f36da35ad8e32 Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Tue, 6 Jan 2026 17:51:39 -0500 Subject: [PATCH 02/11] Update docs, news, etc. for release --- DESCRIPTION | 4 ++-- NEWS.md | 7 +++++++ codemeta.json | 6 +++--- man/create_event_subscription.Rd | 2 +- man/delete_event_subscription.Rd | 2 +- man/execute_event_subscription.Rd | 2 +- man/login.Rd | 4 ++-- man/logout.Rd | 4 ++-- man/query_event_subscriptions.Rd | 4 ++-- man/read_data_entity.Rd | 14 +++++++------- man/read_data_entity_checksum.Rd | 16 ++++++++-------- man/read_data_entity_name.Rd | 14 +++++++------- man/read_data_entity_names.Rd | 14 +++++++------- man/read_data_entity_resource_metadata.Rd | 16 ++++++++-------- man/read_data_entity_size.Rd | 14 +++++++------- man/read_data_entity_sizes.Rd | 14 +++++++------- man/read_data_package.Rd | 14 +++++++------- man/read_data_package_archive.Rd | 16 ++++++++-------- man/read_data_package_citation.Rd | 16 ++++++++-------- man/read_data_package_doi.Rd | 16 ++++++++-------- man/read_data_package_error.Rd | 16 ++++++++-------- man/read_data_package_from_doi.Rd | 16 ++++++++-------- man/read_data_package_report.Rd | 14 +++++++------- man/read_data_package_report_checksum.Rd | 16 ++++++++-------- ...read_data_package_report_resource_metadata.Rd | 16 ++++++++-------- man/read_data_package_report_summary.Rd | 16 ++++++++-------- man/read_data_package_resource_metadata.Rd | 16 ++++++++-------- man/read_evaluate_report.Rd | 14 +++++++------- man/read_evaluate_report_summary.Rd | 14 +++++++------- man/read_metadata.Rd | 12 ++++++------ man/read_metadata_checksum.Rd | 16 ++++++++-------- man/read_metadata_dublin_core.Rd | 16 ++++++++-------- man/read_metadata_entity.Rd | 16 ++++++++-------- man/read_metadata_format.Rd | 16 ++++++++-------- man/read_metadata_resource_metadata.Rd | 16 ++++++++-------- 35 files changed, 218 insertions(+), 211 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index be00ad71..36d321ec 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: EDIutils Title: An API Client for the Environmental Data Initiative Repository -Version: 1.0.3 +Version: 1.1.0 Authors@R: c(person("Colin", "Smith", email = "colin.smith@wisc.edu", role = c("aut", "cre"), comment = "https://orcid.org/0000-0003-2261-9931"), person("Corinna", "Gries", role = "ctb", comment = "https://orcid.org/0000-0002-9091-6543"), @@ -10,7 +10,7 @@ Description: A client for the Environmental Data Initiative repository REST API. Imports: curl, httr, jsonlite, xml2 License: MIT + file LICENSE Encoding: UTF-8 -RoxygenNote: 7.2.3 +RoxygenNote: 7.3.3 Suggests: knitr, readr, vcr, rmarkdown, roxygen2, testthat URL: https://github.com/ropensci/EDIutils, https://docs.ropensci.org/EDIutils/ BugReports: https://github.com/ropensci/EDIutils/issues diff --git a/NEWS.md b/NEWS.md index b9cac4a7..0526b593 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,10 @@ +EDIutils 1.1.0 (2026-01-06) +=========================== + +### MINOR IMPROVEMENTS + + * Update authentication to support new EDI IAM system (#60) + EDIutils 1.0.3 (2023-10-10) =========================== diff --git a/codemeta.json b/codemeta.json index 0fbdb01a..40c927c0 100644 --- a/codemeta.json +++ b/codemeta.json @@ -8,13 +8,13 @@ "codeRepository": "https://github.com/ropensci/EDIutils", "issueTracker": "https://github.com/ropensci/EDIutils/issues", "license": "https://spdx.org/licenses/MIT", - "version": "1.0.3", + "version": "1.1.0", "programmingLanguage": { "@type": "ComputerLanguage", "name": "R", "url": "https://r-project.org" }, - "runtimePlatform": "R version 4.2.2 (2022-10-31)", + "runtimePlatform": "R version 4.5.2 (2025-10-31)", "provider": { "@id": "https://cran.r-project.org", "@type": "Organization", @@ -172,7 +172,7 @@ }, "SystemRequirements": null }, - "fileSize": "645.787KB", + "fileSize": "646.446KB", "citation": [ { "@type": "SoftwareSourceCode", diff --git a/man/create_event_subscription.Rd b/man/create_event_subscription.Rd index 2a61b501..79ceae1d 100644 --- a/man/create_event_subscription.Rd +++ b/man/create_event_subscription.Rd @@ -58,8 +58,8 @@ logout() Other Event Notifications: \code{\link{delete_event_subscription}()}, \code{\link{execute_event_subscription}()}, -\code{\link{get_event_subscription_schema}()}, \code{\link{get_event_subscription}()}, +\code{\link{get_event_subscription_schema}()}, \code{\link{query_event_subscriptions}()} } \concept{Event Notifications} diff --git a/man/delete_event_subscription.Rd b/man/delete_event_subscription.Rd index 5f28ccc0..b7007f69 100644 --- a/man/delete_event_subscription.Rd +++ b/man/delete_event_subscription.Rd @@ -60,8 +60,8 @@ logout() Other Event Notifications: \code{\link{create_event_subscription}()}, \code{\link{execute_event_subscription}()}, -\code{\link{get_event_subscription_schema}()}, \code{\link{get_event_subscription}()}, +\code{\link{get_event_subscription_schema}()}, \code{\link{query_event_subscriptions}()} } \concept{Event Notifications} diff --git a/man/execute_event_subscription.Rd b/man/execute_event_subscription.Rd index fc3fb22f..27a885dc 100644 --- a/man/execute_event_subscription.Rd +++ b/man/execute_event_subscription.Rd @@ -59,8 +59,8 @@ logout() Other Event Notifications: \code{\link{create_event_subscription}()}, \code{\link{delete_event_subscription}()}, -\code{\link{get_event_subscription_schema}()}, \code{\link{get_event_subscription}()}, +\code{\link{get_event_subscription_schema}()}, \code{\link{query_event_subscriptions}()} } \concept{Event Notifications} diff --git a/man/login.Rd b/man/login.Rd index 934d348d..38ba27cf 100644 --- a/man/login.Rd +++ b/man/login.Rd @@ -16,8 +16,8 @@ If using} and \code{userPass} (see details below)} } \value{ -(character) A temporary (~10 hour) authentication token written to -the system variable "EDI_TOKEN". +(character) Temporary (~10 hour) authentication tokens written to +the system variables "EDI_TOKEN" and "AUTH_TOKEN". } \description{ Login to the EDI repository diff --git a/man/logout.Rd b/man/logout.Rd index fece3200..d56e2f3e 100644 --- a/man/logout.Rd +++ b/man/logout.Rd @@ -13,8 +13,8 @@ logout() Logout of the EDI repository } \details{ -Removes the temporary authentication token system variable -"EDI_TOKEN". +Removes the temporary authentication token system variables +"EDI_TOKEN" and "AUTH_TOKEN". } \examples{ \dontrun{ diff --git a/man/query_event_subscriptions.Rd b/man/query_event_subscriptions.Rd index f5f96ca4..1b890bcf 100644 --- a/man/query_event_subscriptions.Rd +++ b/man/query_event_subscriptions.Rd @@ -70,7 +70,7 @@ Other Event Notifications: \code{\link{create_event_subscription}()}, \code{\link{delete_event_subscription}()}, \code{\link{execute_event_subscription}()}, -\code{\link{get_event_subscription_schema}()}, -\code{\link{get_event_subscription}()} +\code{\link{get_event_subscription}()}, +\code{\link{get_event_subscription_schema}()} } \concept{Event Notifications} diff --git a/man/read_data_entity.Rd b/man/read_data_entity.Rd index 71dd2786..40bc1299 100644 --- a/man/read_data_entity.Rd +++ b/man/read_data_entity.Rd @@ -68,29 +68,29 @@ data \seealso{ Other Accessing: \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_entity_checksum.Rd b/man/read_data_entity_checksum.Rd index 39e4a506..e9f8f673 100644 --- a/man/read_data_entity_checksum.Rd +++ b/man/read_data_entity_checksum.Rd @@ -43,30 +43,30 @@ checksum } \seealso{ Other Accessing: -\code{\link{read_data_entity_names}()}, +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_entity_name.Rd b/man/read_data_entity_name.Rd index 4c26c9ea..36f064b9 100644 --- a/man/read_data_entity_name.Rd +++ b/man/read_data_entity_name.Rd @@ -41,30 +41,30 @@ entityName } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, \code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_entity_names.Rd b/man/read_data_entity_names.Rd index f84e7185..b76dcd15 100644 --- a/man/read_data_entity_names.Rd +++ b/man/read_data_entity_names.Rd @@ -35,30 +35,30 @@ read_data_entity_names("knb-lter-cap.691.2") } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, \code{\link{read_data_entity_name}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_entity_resource_metadata.Rd b/man/read_data_entity_resource_metadata.Rd index 6d344aa4..d4cb7b71 100644 --- a/man/read_data_entity_resource_metadata.Rd +++ b/man/read_data_entity_resource_metadata.Rd @@ -51,30 +51,30 @@ resourceMetadata <- read_data_entity_resource_metadata( } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, -\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_entity_size.Rd b/man/read_data_entity_size.Rd index 517aaa70..bfe2a6a9 100644 --- a/man/read_data_entity_size.Rd +++ b/man/read_data_entity_size.Rd @@ -39,30 +39,30 @@ size } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, \code{\link{read_data_entity_sizes}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_entity_sizes.Rd b/man/read_data_entity_sizes.Rd index 9e7833f5..020e9fc4 100644 --- a/man/read_data_entity_sizes.Rd +++ b/man/read_data_entity_sizes.Rd @@ -35,30 +35,30 @@ sizes } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package.Rd b/man/read_data_package.Rd index 33ace479..ab4edb61 100644 --- a/man/read_data_package.Rd +++ b/man/read_data_package.Rd @@ -55,30 +55,30 @@ resourceMap } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package_archive.Rd b/man/read_data_package_archive.Rd index 04f7e541..bf0a9459 100644 --- a/man/read_data_package_archive.Rd +++ b/man/read_data_package_archive.Rd @@ -37,30 +37,30 @@ dir(tempdir()) } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package_citation.Rd b/man/read_data_package_citation.Rd index 9ead38ec..da0bdde7 100644 --- a/man/read_data_package_citation.Rd +++ b/man/read_data_package_citation.Rd @@ -143,30 +143,30 @@ citation } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package_doi.Rd b/man/read_data_package_doi.Rd index 3e055bdf..0b7dda32 100644 --- a/man/read_data_package_doi.Rd +++ b/man/read_data_package_doi.Rd @@ -36,30 +36,30 @@ doi } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package_error.Rd b/man/read_data_package_error.Rd index 3a940ee9..27c59a82 100644 --- a/man/read_data_package_error.Rd +++ b/man/read_data_package_error.Rd @@ -25,30 +25,30 @@ User authentication is required (see \code{login()}) } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package_from_doi.Rd b/man/read_data_package_from_doi.Rd index 13636b1f..02f0e14a 100644 --- a/man/read_data_package_from_doi.Rd +++ b/man/read_data_package_from_doi.Rd @@ -54,30 +54,30 @@ resourceMap } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package_report.Rd b/man/read_data_package_report.Rd index 6c9c1d9e..45a2348c 100644 --- a/man/read_data_package_report.Rd +++ b/man/read_data_package_report.Rd @@ -61,13 +61,14 @@ qualityReport <- read_data_package_report( } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, @@ -77,14 +78,13 @@ Other Accessing: \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package_report_checksum.Rd b/man/read_data_package_report_checksum.Rd index 91b6a377..021b6cb4 100644 --- a/man/read_data_package_report_checksum.Rd +++ b/man/read_data_package_report_checksum.Rd @@ -30,30 +30,30 @@ checksum } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package_report_resource_metadata.Rd b/man/read_data_package_report_resource_metadata.Rd index e369ebfe..26978af4 100644 --- a/man/read_data_package_report_resource_metadata.Rd +++ b/man/read_data_package_report_resource_metadata.Rd @@ -36,30 +36,30 @@ resourceMetadata <- read_data_package_report_resource_metadata( } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package_report_summary.Rd b/man/read_data_package_report_summary.Rd index e4fd648e..5d233b8c 100644 --- a/man/read_data_package_report_summary.Rd +++ b/man/read_data_package_report_summary.Rd @@ -51,30 +51,30 @@ read_data_package_report_summary("knb-lter-knz.260.4") } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_data_package_resource_metadata.Rd b/man/read_data_package_resource_metadata.Rd index cb6d2dff..319f43d3 100644 --- a/man/read_data_package_resource_metadata.Rd +++ b/man/read_data_package_resource_metadata.Rd @@ -36,30 +36,30 @@ resourceMetadata <- read_data_package_resource_metadata( } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_evaluate_report.Rd b/man/read_evaluate_report.Rd index d3d53c66..ca494b13 100644 --- a/man/read_evaluate_report.Rd +++ b/man/read_evaluate_report.Rd @@ -75,30 +75,30 @@ logout() } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, \code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_evaluate_report_summary.Rd b/man/read_evaluate_report_summary.Rd index eb4ec68b..16f20eba 100644 --- a/man/read_evaluate_report_summary.Rd +++ b/man/read_evaluate_report_summary.Rd @@ -68,30 +68,30 @@ logout() } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_metadata.Rd b/man/read_metadata.Rd index a0c030e8..e5585d01 100644 --- a/man/read_metadata.Rd +++ b/man/read_metadata.Rd @@ -38,26 +38,26 @@ eml } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, diff --git a/man/read_metadata_checksum.Rd b/man/read_metadata_checksum.Rd index bc4455da..e469ff46 100644 --- a/man/read_metadata_checksum.Rd +++ b/man/read_metadata_checksum.Rd @@ -29,30 +29,30 @@ checksum } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_metadata_dublin_core.Rd b/man/read_metadata_dublin_core.Rd index 72943a01..19954eec 100644 --- a/man/read_metadata_dublin_core.Rd +++ b/man/read_metadata_dublin_core.Rd @@ -36,30 +36,30 @@ dc } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_entity}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_metadata_entity.Rd b/man/read_metadata_entity.Rd index 95bb2fca..bda18ef5 100644 --- a/man/read_metadata_entity.Rd +++ b/man/read_metadata_entity.Rd @@ -45,30 +45,30 @@ meta } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_format}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_metadata_format.Rd b/man/read_metadata_format.Rd index 3da0b98a..016b21ee 100644 --- a/man/read_metadata_format.Rd +++ b/man/read_metadata_format.Rd @@ -29,30 +29,30 @@ metadataFormat } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, -\code{\link{read_metadata_resource_metadata}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_resource_metadata}()} } \concept{Accessing} diff --git a/man/read_metadata_resource_metadata.Rd b/man/read_metadata_resource_metadata.Rd index ef3ced85..9ebc9d86 100644 --- a/man/read_metadata_resource_metadata.Rd +++ b/man/read_metadata_resource_metadata.Rd @@ -37,30 +37,30 @@ resourceMetadata <- read_metadata_resource_metadata( } \seealso{ Other Accessing: +\code{\link{read_data_entity}()}, \code{\link{read_data_entity_checksum}()}, -\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_name}()}, +\code{\link{read_data_entity_names}()}, \code{\link{read_data_entity_resource_metadata}()}, -\code{\link{read_data_entity_sizes}()}, \code{\link{read_data_entity_size}()}, -\code{\link{read_data_entity}()}, +\code{\link{read_data_entity_sizes}()}, +\code{\link{read_data_package}()}, \code{\link{read_data_package_archive}()}, \code{\link{read_data_package_citation}()}, \code{\link{read_data_package_doi}()}, \code{\link{read_data_package_error}()}, \code{\link{read_data_package_from_doi}()}, +\code{\link{read_data_package_report}()}, \code{\link{read_data_package_report_checksum}()}, \code{\link{read_data_package_report_resource_metadata}()}, \code{\link{read_data_package_report_summary}()}, -\code{\link{read_data_package_report}()}, \code{\link{read_data_package_resource_metadata}()}, -\code{\link{read_data_package}()}, -\code{\link{read_evaluate_report_summary}()}, \code{\link{read_evaluate_report}()}, +\code{\link{read_evaluate_report_summary}()}, +\code{\link{read_metadata}()}, \code{\link{read_metadata_checksum}()}, \code{\link{read_metadata_dublin_core}()}, \code{\link{read_metadata_entity}()}, -\code{\link{read_metadata_format}()}, -\code{\link{read_metadata}()} +\code{\link{read_metadata_format}()} } \concept{Accessing} From d3dad27892845b0900fdffd6c4b3a6585dd8dfae Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Tue, 6 Jan 2026 18:32:48 -0500 Subject: [PATCH 03/11] Fix syntax of author ORCiDs --- DESCRIPTION | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 36d321ec..0f306b82 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -2,10 +2,10 @@ Package: EDIutils Title: An API Client for the Environmental Data Initiative Repository Version: 1.1.0 Authors@R: - c(person("Colin", "Smith", email = "colin.smith@wisc.edu", role = c("aut", "cre"), comment = "https://orcid.org/0000-0003-2261-9931"), - person("Corinna", "Gries", role = "ctb", comment = "https://orcid.org/0000-0002-9091-6543"), - person("Jasmine", "Lai", role = "rev", comment = "https://orcid.org/0000-0001-8888-547X"), - person("Rodrigo", "Pires", role = "rev", comment = "https://orcid.org/0000-0001-7384-6849")) + c(person("Colin", "Smith", email = "colin.smith@wisc.edu", role = c("aut", "cre"), comment = "0000-0003-2261-9931"), + person("Corinna", "Gries", role = "ctb", comment = "0000-0002-9091-6543"), + person("Jasmine", "Lai", role = "rev", comment = "0000-0001-8888-547X"), + person("Rodrigo", "Pires", role = "rev", comment = "0000-0001-7384-6849")) Description: A client for the Environmental Data Initiative repository REST API. The 'EDI' data repository is for publication and reuse of ecological data with emphasis on metadata accuracy and completeness. It is built upon the 'PASTA+' software stack and was developed in collaboration with the US 'LTER' Network . 'EDIutils' includes functions to search and access existing data, evaluate and upload new data, and assist other data management tasks common to repository users. Imports: curl, httr, jsonlite, xml2 License: MIT + file LICENSE From 95e87e21e1713372f6ad7cb3a34e6386c2248257 Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Wed, 7 Jan 2026 10:21:29 -0500 Subject: [PATCH 04/11] Report rhub checks --- cran-comments.md | 59 +++++++++--------------------------------------- 1 file changed, 11 insertions(+), 48 deletions(-) diff --git a/cran-comments.md b/cran-comments.md index c5c5d7f1..eebd5081 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,58 +1,21 @@ ## Revision -This release fixes a deprecated endpoint in the EDI API and fixes outdated -documentation. +This release updates authentication methods to use the NEW EDI Identity and +Access Management (IAM) system. These changes maintain backward compatibility. ## Test environments -* aarch64-apple-darwin20, (local machine), R 4.2.2 -* x86_64-w64-mingw32 (R-hub), R-devel (2023-07-21 r84722 ucrt) -* x86_64-w64-mingw32 (R-hub), R 4.3.1 (2023-06-16 ucrt) -* x86_64-w64-mingw32 (R-hub), R 4.2.3 (2023-03-15 ucrt) -* x86_64-pc-linux-gnu Ubuntu (R-hub), R-devel (2023-06-09 r84528) -* x86_64-pc-linux-gnu Fedora (R-hub), R-devel (2023-06-09 r84528) -* x86_64-pc-linux-gnu Debian (R-hub), 4.2.2 Patched (2022-11-10 r83330) -* x86_64-pc-linux-gnu Ubuntu (R-hub), 4.3.0 (2023-04-21) +* aarch64-apple-darwin20, (local machine), R 4.5.2 +* aarch64-apple-darwin20 (R-hub), R development (unstable) (2026-01-06 r89281) +* x86_64-w64-mingw32 (R-hub), R development (unstable) (2026-01-06 r89281 ucrt) +* x86_64-w64-mingw32 (R-hub), R version 4.5.2 (2025-10-31 ucrt) +* x86_64-w64-mingw32 (R-hub), R version 4.4.3 (2025-02-28 ucrt) +* x86_64-pc-linux-gnu Ubuntu (R-hub), R development (unstable) (2026-01-06 r89281) +* x86_64-pc-linux-gnu Ubuntu (R-hub), R version 4.5.2 (2025-10-31) +* x86_64-pc-linux-gnu Ubuntu (R-hub), R version 4.5.2 Patched (2026-01-05 r89281) ## R CMD check results -0 ERROR | 0 WARNINGS | 3 NOTES - -### NOTES - -``` - #> * checking for non-standard things in the check directory ... NOTE - #> Found the following files/directories: - #> ''NULL'' -``` -This note appears to be an issue with the R-hub platform. This note occurs on: - -* x86_64-w64-mingw32 (R-hub), R-devel (2023-07-21 r84722 ucrt) -* x86_64-w64-mingw32 (R-hub), R 4.3.1 (2023-06-16 ucrt) -* x86_64-w64-mingw32 (R-hub), R 4.2.3 (2023-03-15 ucrt) - -``` - #> * checking for detritus in the temp directory ... NOTE - #> Found the following files/directories: - #> 'lastMiKTeXException' -``` -This note is a recognized bug on R-hub test platforms (for more -see [here](https://github.com/r-hub/rhub/issues/560)). This note occurs on: - -* x86_64-w64-mingw32 (R-hub), R-devel (2023-07-21 r84722 ucrt) -* x86_64-w64-mingw32 (R-hub), R 4.3.1 (2023-06-16 ucrt) -* x86_64-w64-mingw32 (R-hub), R 4.2.3 (2023-03-15 ucrt) - -``` -#> * checking HTML version of manual ... NOTE -#> Skipping checking HTML validation: no command 'tidy' found -``` -This note appears to be an issue with the R-hub test platform. This note occurs -on: - -* x86_64-pc-linux-gnu Fedora (R-hub), R-devel (2023-06-09 r84528) -* x86_64-pc-linux-gnu Ubuntu (R-hub), 4.3.0 (2023-04-21) -* x86_64-pc-linux-gnu Ubuntu (R-hub), R-devel (2023-06-09 r84528) - +0 ERROR | 0 WARNINGS | 0 NOTES ## Downstream dependencies There are currently no downstream dependencies for this package. From 498f9a04b663af1dddeee8f2df1015ecd8e44d9c Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Wed, 7 Jan 2026 12:20:37 -0500 Subject: [PATCH 05/11] Deprecate get_audit_report in favor of get_audit_csv_report (#62) Add a deprecation warning to get_audit_report() to notify users of the transition to get_audit_csv_report(). --- NAMESPACE | 1 + NEWS.md | 3 + R/get_audit_csv_report.R | 71 +++++++++++++++++ R/get_audit_report.R | 5 +- man/get_audit_count.Rd | 1 + man/get_audit_csv_report.Rd | 83 ++++++++++++++++++++ man/get_audit_record.Rd | 1 + man/get_audit_report.Rd | 5 +- man/get_docid_reads.Rd | 1 + man/get_packageid_reads.Rd | 1 + man/get_recent_uploads.Rd | 1 + tests/fixtures/get_audit_csv_report.yml | 38 +++++++++ tests/fixtures/get_audit_report.yml | 67 ++++++---------- tests/testthat/_vcr/get_audit_csv_report.yml | 38 +++++++++ tests/testthat/_vcr/get_audit_report.yml | 42 ++++++++++ tests/testthat/test_get_audit_csv_report.R | 14 ++++ tests/testthat/test_get_audit_report.R | 2 +- 17 files changed, 328 insertions(+), 46 deletions(-) create mode 100644 R/get_audit_csv_report.R create mode 100644 man/get_audit_csv_report.Rd create mode 100644 tests/fixtures/get_audit_csv_report.yml create mode 100644 tests/testthat/_vcr/get_audit_csv_report.yml create mode 100644 tests/testthat/_vcr/get_audit_report.yml create mode 100644 tests/testthat/test_get_audit_csv_report.R diff --git a/NAMESPACE b/NAMESPACE index 8c3f48d0..0b29983a 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -15,6 +15,7 @@ export(delete_reservation) export(evaluate_data_package) export(execute_event_subscription) export(get_audit_count) +export(get_audit_csv_report) export(get_audit_record) export(get_audit_report) export(get_docid_reads) diff --git a/NEWS.md b/NEWS.md index 0526b593..cfb889a7 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,6 +1,9 @@ EDIutils 1.1.0 (2026-01-06) =========================== +### DEPRECATED + * Deprecate `get_audit_report()` in favor of `get_audit_csv_report()` (#62) + ### MINOR IMPROVEMENTS * Update authentication to support new EDI IAM system (#60) diff --git a/R/get_audit_csv_report.R b/R/get_audit_csv_report.R new file mode 100644 index 00000000..cfdd5fd1 --- /dev/null +++ b/R/get_audit_csv_report.R @@ -0,0 +1,71 @@ +#' Get audit csv report +#' +#' @param query (character) Query (see details below) +#' @param env (character) Repository environment. Can be: "production", +#' "staging", or "development". +#' +#' @return (data.frame or xml_document) Zero or more audit records matching +#' the query parameters as specified in the request (see details below) and +#' streams back a comma separated values result set. +#' +#' @details Query parameters are specified as key=value pairs, multiple pairs +#' must be delimited with ampersands (&), and only a single value should be +#' specified for a particular key. The following query parameter keys are +#' allowed: +#' +#' \itemize{ +#' \item category - Can be: debug, info, error, warn +#' \item service - Any of the EDI data repository services +#' \item serviceMethod - Any of the EDI data repository service Resource +#' class JAX-RS methods +#' \item user - Any user +#' \item group - Any group +#' \item authSystem - A valid auth system identifier +#' \item status - A valid HTTP Response Code +#' \item resourceId - An EDI data repository resource identifier, e.g. +#' https://pasta.lternet.edu/package/eml/knb-lter-and/2719/6, or a thereof +#' (see details below) +#' \item fromTime - An ISO8601 timestamp +#' \item toTime - An ISO8601 timestamp +#' \item limit - A positive whole number +#' } +#' +#' The query parameters fromTime and optionally toTime should be used to +#' indicate a time span. When toTime is absent, the report will consist of all +#' matching records up to the current time. Either of these parameters may only +#' be used once. The query parameter limit sets an upper limit on the number of +#' audit records returned. For example, "limit=1000". The query parameter +#' resourceId will match any audit log entry whose resourceId value contains +#' the specified string value. Thus, a query parameter of +#' "resourceId=knb-lter-and" will match any audit log entry whose resourceId +#' value contains the substring "knb-lter-and", while a query parameter of +#' "resourceId=knb-lter-and/2719/6" will match any audit log entry whose +#' resourceId value contains the substring "knb-lter-and/2719/6". +#' +#' @note User authentication is required (see \code{login()}) +#' +#' @family Audit Manager Services +#' +#' @export +#' +#' @examples +#' \dontrun{ +#' +#' login() +#' +#' # Get audit report for data reads between 2021-12-01 and 2021-12-02 +#' query <- "serviceMethod=readDataEntity&fromTime=2021-12-01&toTime=2021-12-02" +#' auditReport <- get_audit_csv_report(query) +#' +#' logout() +#' } +#' +get_audit_csv_report <- function(query, env = "production") { + url <- paste0(base_url(env), "/audit/csvreport?", query) + cookie <- bake_cookie() + resp <- httr::GET(url, set_user_agent(), cookie, handle = httr::handle("")) + res <- httr::content(resp, as = "text", encoding = "UTF-8") + httr::stop_for_status(resp, res) + res <- read.csv(text = res, stringsAsFactors = FALSE) + return(res) +} diff --git a/R/get_audit_report.R b/R/get_audit_report.R index e67ba9a8..c2b2a9f0 100644 --- a/R/get_audit_report.R +++ b/R/get_audit_report.R @@ -1,4 +1,6 @@ -#' Get audit report +#' Get audit report (deprecated) +#' +#' This function is deprecated. Please use get_audit_csv_report() instead. #' #' @param query (character) Query (see details below) #' @param as (character) Format of the returned object. Can be: "data.frame" @@ -62,6 +64,7 @@ #' } #' get_audit_report <- function(query, as = "data.frame", env = "production") { + .Deprecated("get_audit_csv_report") url <- paste0(base_url(env), "/audit/report?", query) cookie <- bake_cookie() resp <- httr::GET(url, set_user_agent(), cookie, handle = httr::handle("")) diff --git a/man/get_audit_count.Rd b/man/get_audit_count.Rd index 2f498b5e..d155fb91 100644 --- a/man/get_audit_count.Rd +++ b/man/get_audit_count.Rd @@ -75,6 +75,7 @@ logout() } \seealso{ Other Audit Manager Services: +\code{\link{get_audit_csv_report}()}, \code{\link{get_audit_record}()}, \code{\link{get_audit_report}()}, \code{\link{get_docid_reads}()}, diff --git a/man/get_audit_csv_report.Rd b/man/get_audit_csv_report.Rd new file mode 100644 index 00000000..930c5a66 --- /dev/null +++ b/man/get_audit_csv_report.Rd @@ -0,0 +1,83 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/get_audit_csv_report.R +\name{get_audit_csv_report} +\alias{get_audit_csv_report} +\title{Get audit csv report} +\usage{ +get_audit_csv_report(query, env = "production") +} +\arguments{ +\item{query}{(character) Query (see details below)} + +\item{env}{(character) Repository environment. Can be: "production", +"staging", or "development".} +} +\value{ +(data.frame or xml_document) Zero or more audit records matching +the query parameters as specified in the request (see details below) and +streams back a comma separated values result set. +} +\description{ +Get audit csv report +} +\details{ +Query parameters are specified as key=value pairs, multiple pairs +must be delimited with ampersands (&), and only a single value should be +specified for a particular key. The following query parameter keys are +allowed: + +\itemize{ + \item category - Can be: debug, info, error, warn + \item service - Any of the EDI data repository services + \item serviceMethod - Any of the EDI data repository service Resource + class JAX-RS methods + \item user - Any user + \item group - Any group + \item authSystem - A valid auth system identifier + \item status - A valid HTTP Response Code + \item resourceId - An EDI data repository resource identifier, e.g. + https://pasta.lternet.edu/package/eml/knb-lter-and/2719/6, or a thereof + (see details below) + \item fromTime - An ISO8601 timestamp + \item toTime - An ISO8601 timestamp + \item limit - A positive whole number +} + +The query parameters fromTime and optionally toTime should be used to +indicate a time span. When toTime is absent, the report will consist of all +matching records up to the current time. Either of these parameters may only +be used once. The query parameter limit sets an upper limit on the number of +audit records returned. For example, "limit=1000". The query parameter +resourceId will match any audit log entry whose resourceId value contains +the specified string value. Thus, a query parameter of +"resourceId=knb-lter-and" will match any audit log entry whose resourceId +value contains the substring "knb-lter-and", while a query parameter of +"resourceId=knb-lter-and/2719/6" will match any audit log entry whose +resourceId value contains the substring "knb-lter-and/2719/6". +} +\note{ +User authentication is required (see \code{login()}) +} +\examples{ +\dontrun{ + +login() + +# Get audit report for data reads between 2021-12-01 and 2021-12-02 +query <- "serviceMethod=readDataEntity&fromTime=2021-12-01&toTime=2021-12-02" +auditReport <- get_audit_csv_report(query) + +logout() +} + +} +\seealso{ +Other Audit Manager Services: +\code{\link{get_audit_count}()}, +\code{\link{get_audit_record}()}, +\code{\link{get_audit_report}()}, +\code{\link{get_docid_reads}()}, +\code{\link{get_packageid_reads}()}, +\code{\link{get_recent_uploads}()} +} +\concept{Audit Manager Services} diff --git a/man/get_audit_record.Rd b/man/get_audit_record.Rd index 028e7adf..28193a80 100644 --- a/man/get_audit_record.Rd +++ b/man/get_audit_record.Rd @@ -39,6 +39,7 @@ logout() \seealso{ Other Audit Manager Services: \code{\link{get_audit_count}()}, +\code{\link{get_audit_csv_report}()}, \code{\link{get_audit_report}()}, \code{\link{get_docid_reads}()}, \code{\link{get_packageid_reads}()}, diff --git a/man/get_audit_report.Rd b/man/get_audit_report.Rd index 1fdaa885..fdceed73 100644 --- a/man/get_audit_report.Rd +++ b/man/get_audit_report.Rd @@ -2,7 +2,7 @@ % Please edit documentation in R/get_audit_report.R \name{get_audit_report} \alias{get_audit_report} -\title{Get audit report} +\title{Get audit report (deprecated)} \usage{ get_audit_report(query, as = "data.frame", env = "production") } @@ -20,7 +20,7 @@ or "xml".} the query parameters as specified in the request (see details below). } \description{ -Get audit report +This function is deprecated. Please use get_audit_csv_report() instead. } \details{ Query parameters are specified as key=value pairs, multiple pairs @@ -76,6 +76,7 @@ logout() \seealso{ Other Audit Manager Services: \code{\link{get_audit_count}()}, +\code{\link{get_audit_csv_report}()}, \code{\link{get_audit_record}()}, \code{\link{get_docid_reads}()}, \code{\link{get_packageid_reads}()}, diff --git a/man/get_docid_reads.Rd b/man/get_docid_reads.Rd index 391b34f1..59f3b845 100644 --- a/man/get_docid_reads.Rd +++ b/man/get_docid_reads.Rd @@ -35,6 +35,7 @@ resourceReads <- get_docid_reads(scope = "knb-lter-sgs", identifier = 817) \seealso{ Other Audit Manager Services: \code{\link{get_audit_count}()}, +\code{\link{get_audit_csv_report}()}, \code{\link{get_audit_record}()}, \code{\link{get_audit_report}()}, \code{\link{get_packageid_reads}()}, diff --git a/man/get_packageid_reads.Rd b/man/get_packageid_reads.Rd index 1dc93faf..52d60c25 100644 --- a/man/get_packageid_reads.Rd +++ b/man/get_packageid_reads.Rd @@ -32,6 +32,7 @@ resourceReads <- get_packageid_reads("knb-lter-sgs.817.17") \seealso{ Other Audit Manager Services: \code{\link{get_audit_count}()}, +\code{\link{get_audit_csv_report}()}, \code{\link{get_audit_record}()}, \code{\link{get_audit_report}()}, \code{\link{get_docid_reads}()}, diff --git a/man/get_recent_uploads.Rd b/man/get_recent_uploads.Rd index abbb029a..20ab7919 100644 --- a/man/get_recent_uploads.Rd +++ b/man/get_recent_uploads.Rd @@ -55,6 +55,7 @@ auditReport <- get_recent_uploads( \seealso{ Other Audit Manager Services: \code{\link{get_audit_count}()}, +\code{\link{get_audit_csv_report}()}, \code{\link{get_audit_record}()}, \code{\link{get_audit_report}()}, \code{\link{get_docid_reads}()}, diff --git a/tests/fixtures/get_audit_csv_report.yml b/tests/fixtures/get_audit_csv_report.yml new file mode 100644 index 00000000..919415ad --- /dev/null +++ b/tests/fixtures/get_audit_csv_report.yml @@ -0,0 +1,38 @@ +http_interactions: +- request: + method: GET + uri: https://pasta.lternet.edu/audit/csvreport?serviceMethod=readDataEntity&limit=1 + response: + status: 200 + headers: + access-control-allow-origin: '*' + cache-control: no-cache + connection: keep-alive + content-disposition: attachment; filename=auditreport.csv + content-length: '505' + content-type: application/octet-stream + date: Wed, 07 Jan 2026 17:03:56 GMT + server: nginx/1.18.0 (Ubuntu) + set-cookie: + - auth-token="dWlkPWNzbWl0aCxvPUVESSxkYz1lZGlyZXBvc2l0b3J5LGRjPW9yZypodHRwczovL3Bhc3RhLmVkaXJlcG9zaXRvcnkub3JnL2F1dGhlbnRpY2F0aW9uKjE3Njc4MzQyMzYxOTYqdmV0dGVkKmF1dGhlbnRpY2F0ZWQ=-GI+IVERS6cW7SU45F6KH0TzKZYKM2MXcs1Ng+BKNxgBmT3ypODGd8Y8Lo3l4v9SgNHFSsUxsq4KCrv5nIavt4cZ8n50TFYBRKvgaNppbVxGo6/SOJbj4TM5I5bI5FhTluoqx62eG+XI5vDkE419xc47REnG5X0ebsJSOhh12XuShkv4KjbI4IH7jjjytoPPzWJK2HMS1LHSvIbEXMWtmJWqno4PflWUatPFiee0JtO940wxJyxXhzkgSSLEMAhKwE2WInKps2vkeYamqyzhe4QMiHXTYfKGJzKaT1wB7MCTWLlOOBOZkMU8oWW6D2AcyjI74EDMhgfFkJk1OJ0ryUw=="; + HttpOnly; Path=/; SameSite=lax + - edi-token=eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJFREktNTQzYWZhODBjODU5ODI1ZDM1ZDM3ZDkxMTFjMjRhNGE2NWEwZGI5ZiIsImNuIjoiY3NtaXRoIiwiZW1haWwiOm51bGwsInByaW5jaXBhbHMiOlsiRURJLTA3OGU2ZTNjZWU0ZjdmMjgxMmYxNTA3MDFkYTkzNTFhY2I1MWUwODkiLCJFREktN2JlMzUxMGQwOGRlZjBkZmM2Njc4MjRlYmQ0ZjRmMWJiZDc3MDIzNCIsIkVESS1iZGFlNzQ5NzJlZDcxMGM1NmIxZTBkZjE4Y2NiNmUyM2MzMWY2MGY2Il0sImxpbmtzIjpbXSwiaXNFbWFpbEVuYWJsZWQiOmZhbHNlLCJpc0VtYWlsVmVyaWZpZWQiOmZhbHNlLCJpZHBDb21tb25OYW1lIjoiY3NtaXRoIiwiaWRwTmFtZSI6ImxkYXAiLCJpZHBVaWQiOiJ1aWQ9Y3NtaXRoLG89RURJLGRjPWVkaXJlcG9zaXRvcnksZGM9b3JnIiwiaXNzIjoiaHR0cHM6Ly9hdXRoLmVkaXJlcG9zaXRvcnkub3JnIiwiaGQiOiJlZGlyZXBvc2l0b3J5Lm9yZyIsImlhdCI6MTc2NzgwMjczNSwibmJmIjoxNzY3ODAyNzM1LCJleHAiOjE3Njc4MzE1MzV9.FP9ToOdyH99Fi6OABA0ZU6RMeRITGWd90XcQ8ekVQm4uHWPA_0mhsgqBQW8xPVpFASWZfcM3ihaWXtOJdxdYyA; + HttpOnly; Path=/; SameSite=lax + web-service: AuditManager-0.1 + body: + raw_gzip: |- + eJxdUc1u2zAMvhfoO/g+2bIUp07dU7B2ww5NijnDgF0MWqITrbZkSHRQv33l9OfQgyiBpPj9 + cG80e7D + k54MZkNXoz0Yh+w6ER+fnj8Qj0sl9NOILsd8Y3OQV/tLLc3Q2YE1AU2B/AvpL2B7R + Evvp3TQGtp3oVM + +BcLi+EjebIh4hmMylTIVIZXHI82pdVqtNlt+Kf+weCJ5APcMRH8HG6FOR + 5czYzjGPoJd6JGNoZm9Xs + oMBqwSVI49Wh0ZsikbcJfv2Pyp6r4LVzXZ3n/6tV41y5zh07MFS + eqh3sljLshkxSrLUzAi+nzMVznfJ + ApX8cH4AqhKK2nlMsxPRGCrORwgEWU/oLVKGeoqZC22u + 4z+OQ88/OfHIiUu+kflNK/Wqg1uRyy7vsFB + QlG0plGy7tYqu5Gyc2t6oiw/73UP6NEf/LV9l + RVYm3xbwiL0gOIuZ80fOvjBCbTyOLhiKW7x0QNxA1G + YUkHH2+uoVTGisIQ== + recorded_at: 2026-01-07 17:03:56 +recorded_with: VCR-vcr/2.1.0 diff --git a/tests/fixtures/get_audit_report.yml b/tests/fixtures/get_audit_report.yml index 732bef65..1a967120 100644 --- a/tests/fixtures/get_audit_report.yml +++ b/tests/fixtures/get_audit_report.yml @@ -1,59 +1,42 @@ http_interactions: - request: - method: get + method: GET uri: https://pasta.lternet.edu/audit/report?serviceMethod=readDataEntity&limit=1 - body: - encoding: '' - string: '' - headers: - Accept: application/json, text/xml, application/xml, */* response: - status: - status_code: 200 - category: Success - reason: OK - message: 'Success: (200) OK' + status: 200 headers: - server: nginx/1.14.0 (Ubuntu) - date: Tue, 18 Jan 2022 05:32:47 GMT - content-type: application/xml - content-length: '1401' - connection: keep-alive + access-control-allow-origin: '*' cache-control: no-cache + connection: keep-alive + content-length: '689' + content-type: application/xml + date: Wed, 07 Jan 2026 17:03:58 GMT + pasta-first-oid: '39180366' + pasta-last-oid: '39180366' + server: nginx/1.18.0 (Ubuntu) + set-cookie: + - auth-token="dWlkPWNzbWl0aCxvPUVESSxkYz1lZGlyZXBvc2l0b3J5LGRjPW9yZypodHRwczovL3Bhc3RhLmVkaXJlcG9zaXRvcnkub3JnL2F1dGhlbnRpY2F0aW9uKjE3Njc4MzQyMzgxOTYqdmV0dGVkKmF1dGhlbnRpY2F0ZWQ=-KCdfNaTGR/U94rikOHbPiA7eFxYkZpwrP9x508bzek6ywrERh+5Jp1dhoelZ/Hl0mSgoiEAw6reHNMEvkaBk/Jz3pj4c+awRk9yjNbCA73ZSq9OgbB+32iWnHA6szWqFM0W85KC3Le7711xCUjXEzmON8sxGMKQ40RcPlolT2N1YUuqExbm/4bPDDDXK1uI8JNOMdm8cNW2/OfIGC69A8w8dmmF3wwjWGqo24wMGytLPZEqGuv+h88cQr8pz9YED4pmctN2UR9v7RRjxm8BeEmW5EHj8zfkPackwMlr84LQ8g2jPJv3nVd0dVpgfBs+uyOfz4iO7rz8tzqgViCbDLA=="; + HttpOnly; Path=/; SameSite=lax + - edi-token=eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJFREktNTQzYWZhODBjODU5ODI1ZDM1ZDM3ZDkxMTFjMjRhNGE2NWEwZGI5ZiIsImNuIjoiY3NtaXRoIiwiZW1haWwiOm51bGwsInByaW5jaXBhbHMiOlsiRURJLTA3OGU2ZTNjZWU0ZjdmMjgxMmYxNTA3MDFkYTkzNTFhY2I1MWUwODkiLCJFREktN2JlMzUxMGQwOGRlZjBkZmM2Njc4MjRlYmQ0ZjRmMWJiZDc3MDIzNCIsIkVESS1iZGFlNzQ5NzJlZDcxMGM1NmIxZTBkZjE4Y2NiNmUyM2MzMWY2MGY2Il0sImxpbmtzIjpbXSwiaXNFbWFpbEVuYWJsZWQiOmZhbHNlLCJpc0VtYWlsVmVyaWZpZWQiOmZhbHNlLCJpZHBDb21tb25OYW1lIjoiY3NtaXRoIiwiaWRwTmFtZSI6ImxkYXAiLCJpZHBVaWQiOiJ1aWQ9Y3NtaXRoLG89RURJLGRjPWVkaXJlcG9zaXRvcnksZGM9b3JnIiwiaXNzIjoiaHR0cHM6Ly9hdXRoLmVkaXJlcG9zaXRvcnkub3JnIiwiaGQiOiJlZGlyZXBvc2l0b3J5Lm9yZyIsImlhdCI6MTc2NzgwMjczNSwibmJmIjoxNzY3ODAyNzM1LCJleHAiOjE3Njc4MzE1MzV9.m-umUoeOuiEMAAPR8itPvt2GYPpNNfdte8qiFvKblW1oFeFP_zOnJTmI8rh-Lzx2I4uqWKkmG7gfMYLJD-Pzdw; + HttpOnly; Path=/; SameSite=lax web-service: AuditManager-0.1 body: - encoding: UTF-8 - file: no string: | - 121606334 - 2021-12-01T00:00:07 - warn - DataPackageManager-1.0 - readDataEntity - 401 - - robot - null - - https://pasta.edirepository.org/authentication - Robots are not authorized access to data objects. Robot detected: Mozilla/5.0 (compatible; SemrushBot/7~bl; +http://www.semrush.com/bot.html) - - - 121606349 - 2021-12-01T00:00:21 - warn + 39180366 + 2018-05-02T00:16:14 + info DataPackageManager-1.0 readDataEntity - 401 - - robot - null + 200 + https://pasta.lternet.edu/package/data/eml/knb-lter-sgs/157/18/c219e8dbce02b9620d910f1c94bce2c0 + public + https://pasta.edirepository.org/authentication - Robots are not authorized access to data objects. Robot detected: Mozilla/5.0 (compatible; SemrushBot/7~bl; +http://www.semrush.com/bot.html) + Entity Name: otc_gas; Object Name: otc_gas.txt; Data Format: text/csv - recorded_at: 2022-01-18 05:32:47 GMT - recorded_with: vcr/1.0.2, webmockr/0.8.0 + recorded_at: 2026-01-07 17:03:58 +recorded_with: VCR-vcr/2.1.0 diff --git a/tests/testthat/_vcr/get_audit_csv_report.yml b/tests/testthat/_vcr/get_audit_csv_report.yml new file mode 100644 index 00000000..af157a81 --- /dev/null +++ b/tests/testthat/_vcr/get_audit_csv_report.yml @@ -0,0 +1,38 @@ +http_interactions: +- request: + method: GET + uri: https://pasta.lternet.edu/audit/csvreport?serviceMethod=readDataEntity&limit=1 + response: + status: 200 + headers: + access-control-allow-origin: '*' + cache-control: no-cache + connection: keep-alive + content-disposition: attachment; filename=auditreport.csv + content-length: '505' + content-type: application/octet-stream + date: Wed, 07 Jan 2026 16:36:06 GMT + server: nginx/1.18.0 (Ubuntu) + set-cookie: + - auth-token="dWlkPWNzbWl0aCxvPUVESSxkYz1lZGlyZXBvc2l0b3J5LGRjPW9yZypodHRwczovL3Bhc3RhLmVkaXJlcG9zaXRvcnkub3JnL2F1dGhlbnRpY2F0aW9uKjE3Njc4MzI1NjY0NzUqdmV0dGVkKmF1dGhlbnRpY2F0ZWQ=-L5LuGdDkfP+nVR6BoRlXrvRUivfdB2JrcuzcmC/XWp+fHtcKe9hn4XL6hfHEDXa9nbh5FB1WVk/KxuT08y2WNZebZRSW94rFqMky5ZzPYpGmYjaGok05Vo7Gm9kpREghrEgi7URI6MoRcTaPqeibUeJGTL/bL7A47aLwJ96qVL/T9Ru3m7vMU74ZtCHMk3/iYJuen2roW3+QHzEX/hDbAVqEv8+oVxxlp/gcrShKEbNmCaSspRiD7+77XQ5Ik84AAOH97wSy8WJpMir+aW1U3oEfFYikcQ46o+4XHOTcguUrxIgsU0pEh9UojNw90aQ+n7vx6HjjVSVopnNHoACEIw=="; + HttpOnly; Path=/; SameSite=lax + - edi-token=eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJFREktNTQzYWZhODBjODU5ODI1ZDM1ZDM3ZDkxMTFjMjRhNGE2NWEwZGI5ZiIsImNuIjoiY3NtaXRoIiwiZW1haWwiOm51bGwsInByaW5jaXBhbHMiOlsiRURJLTA3OGU2ZTNjZWU0ZjdmMjgxMmYxNTA3MDFkYTkzNTFhY2I1MWUwODkiLCJFREktN2JlMzUxMGQwOGRlZjBkZmM2Njc4MjRlYmQ0ZjRmMWJiZDc3MDIzNCIsIkVESS1iZGFlNzQ5NzJlZDcxMGM1NmIxZTBkZjE4Y2NiNmUyM2MzMWY2MGY2Il0sImxpbmtzIjpbXSwiaXNFbWFpbEVuYWJsZWQiOmZhbHNlLCJpc0VtYWlsVmVyaWZpZWQiOmZhbHNlLCJpZHBDb21tb25OYW1lIjoiY3NtaXRoIiwiaWRwTmFtZSI6ImxkYXAiLCJpZHBVaWQiOiJ1aWQ9Y3NtaXRoLG89RURJLGRjPWVkaXJlcG9zaXRvcnksZGM9b3JnIiwiaXNzIjoiaHR0cHM6Ly9hdXRoLmVkaXJlcG9zaXRvcnkub3JnIiwiaGQiOiJlZGlyZXBvc2l0b3J5Lm9yZyIsImlhdCI6MTc2NzgwMjczNSwibmJmIjoxNzY3ODAyNzM1LCJleHAiOjE3Njc4MzE1MzV9.b8IfNHQ5I-CSrZxjJUWusuGiLABBrgTXFct8ckeFl7lnWT96aCLLRksmaLj6ZoSbiBH4I48ztNbPid73SvQImA; + HttpOnly; Path=/; SameSite=lax + web-service: AuditManager-0.1 + body: + raw_gzip: |- + eJxdUc1u2zAMvhfoO/g+2bIUp07dU7B2ww5NijnDgF0MWqITrbZkSHRQv33l9OfQgyiBpPj9 + cG80e7D + k54MZkNXoz0Yh+w6ER+fnj8Qj0sl9NOILsd8Y3OQV/tLLc3Q2YE1AU2B/AvpL2B7R + Evvp3TQGtp3oVM + +BcLi+EjebIh4hmMylTIVIZXHI82pdVqtNlt+Kf+weCJ5APcMRH8HG6FOR + 5czYzjGPoJd6JGNoZm9Xs + oMBqwSVI49Wh0ZsikbcJfv2Pyp6r4LVzXZ3n/6tV41y5zh07MFS + eqh3sljLshkxSrLUzAi+nzMVznfJ + ApX8cH4AqhKK2nlMsxPRGCrORwgEWU/oLVKGeoqZC22u + 4z+OQ88/OfHIiUu+kflNK/Wqg1uRyy7vsFB + QlG0plGy7tYqu5Gyc2t6oiw/73UP6NEf/LV9l + RVYm3xbwiL0gOIuZ80fOvjBCbTyOLhiKW7x0QNxA1G + YUkHH2+uoVTGisIQ== + recorded_at: 2026-01-07 16:36:06 +recorded_with: VCR-vcr/2.1.0 diff --git a/tests/testthat/_vcr/get_audit_report.yml b/tests/testthat/_vcr/get_audit_report.yml new file mode 100644 index 00000000..4a882482 --- /dev/null +++ b/tests/testthat/_vcr/get_audit_report.yml @@ -0,0 +1,42 @@ +http_interactions: +- request: + method: GET + uri: https://pasta.lternet.edu/audit/report?serviceMethod=readDataEntity&limit=1 + response: + status: 200 + headers: + access-control-allow-origin: '*' + cache-control: no-cache + connection: keep-alive + content-length: '689' + content-type: application/xml + date: Wed, 07 Jan 2026 16:55:17 GMT + pasta-first-oid: '39180366' + pasta-last-oid: '39180366' + server: nginx/1.18.0 (Ubuntu) + set-cookie: + - auth-token="dWlkPWNzbWl0aCxvPUVESSxkYz1lZGlyZXBvc2l0b3J5LGRjPW9yZypodHRwczovL3Bhc3RhLmVkaXJlcG9zaXRvcnkub3JnL2F1dGhlbnRpY2F0aW9uKjE3Njc4MzM3MTc1NjYqdmV0dGVkKmF1dGhlbnRpY2F0ZWQ=-YX84grtqdiEyYlowWqbvJvFnq0FrKnQ/DkasxAshEutyVDlzZ96RdlzprH0zB1iCCT9+Un8f2kIk873czZQ2SIAcCVIjV5XQq/Zn4BPsE0cEJaDGKOiiGD6kG3Wl0uk+X4Ekwu2MtuxY4d4s2JsWeKh0oWV3zyHYfh5VbnOBXMK9HH0Wrne7Si+Yapru0qK5Hg+K++sEX9wGJ5hlIo9NvvPOOW349I4xcWyFMWZDLRWJfdMQOHat9fmkWcbeO/3Q3P7cdP6S95etfJSVd+y6NCO9wi4rbK85PNH8gHnH/jXp3zwMF5GbohhJIyspj2Z+hw6ZN6rRbGbEi8fNN937cQ=="; + HttpOnly; Path=/; SameSite=lax + - edi-token=eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJFREktNTQzYWZhODBjODU5ODI1ZDM1ZDM3ZDkxMTFjMjRhNGE2NWEwZGI5ZiIsImNuIjoiY3NtaXRoIiwiZW1haWwiOm51bGwsInByaW5jaXBhbHMiOlsiRURJLTA3OGU2ZTNjZWU0ZjdmMjgxMmYxNTA3MDFkYTkzNTFhY2I1MWUwODkiLCJFREktN2JlMzUxMGQwOGRlZjBkZmM2Njc4MjRlYmQ0ZjRmMWJiZDc3MDIzNCIsIkVESS1iZGFlNzQ5NzJlZDcxMGM1NmIxZTBkZjE4Y2NiNmUyM2MzMWY2MGY2Il0sImxpbmtzIjpbXSwiaXNFbWFpbEVuYWJsZWQiOmZhbHNlLCJpc0VtYWlsVmVyaWZpZWQiOmZhbHNlLCJpZHBDb21tb25OYW1lIjoiY3NtaXRoIiwiaWRwTmFtZSI6ImxkYXAiLCJpZHBVaWQiOiJ1aWQ9Y3NtaXRoLG89RURJLGRjPWVkaXJlcG9zaXRvcnksZGM9b3JnIiwiaXNzIjoiaHR0cHM6Ly9hdXRoLmVkaXJlcG9zaXRvcnkub3JnIiwiaGQiOiJlZGlyZXBvc2l0b3J5Lm9yZyIsImlhdCI6MTc2NzgwMjczNSwibmJmIjoxNzY3ODAyNzM1LCJleHAiOjE3Njc4MzE1MzV9.pDFlNFLzPG0l704ykDG5SdteZRkY-0X_WO8o4_tS9swOdGFU6-mG4fhYVi3vovsSnzxpNZxbiGvdJrd79Uf18Q; + HttpOnly; Path=/; SameSite=lax + web-service: AuditManager-0.1 + body: + string: | + + + 39180366 + 2018-05-02T00:16:14 + info + DataPackageManager-1.0 + readDataEntity + 200 + https://pasta.lternet.edu/package/data/eml/knb-lter-sgs/157/18/c219e8dbce02b9620d910f1c94bce2c0 + public + + + https://pasta.edirepository.org/authentication + Entity Name: otc_gas; Object Name: otc_gas.txt; Data Format: text/csv + + + recorded_at: 2026-01-07 16:55:18 +recorded_with: VCR-vcr/2.1.0 diff --git a/tests/testthat/test_get_audit_csv_report.R b/tests/testthat/test_get_audit_csv_report.R new file mode 100644 index 00000000..3e18e6a1 --- /dev/null +++ b/tests/testthat/test_get_audit_csv_report.R @@ -0,0 +1,14 @@ +context("Get audit csv report") + +testthat::test_that("get_audit_csv_report() works", { + query <- "serviceMethod=readDataEntity&limit=1" + vcr::use_cassette("get_audit_csv_report", { + auditReport <- get_audit_csv_report(query) + }) + expect_true("data.frame" %in% class(auditReport)) + expected_columns <- c( + "Oid", "EntryTime", "Service", "Category", "ServiceMethod", "EntryText", + "ResourceId", "ResponseStatus", "User", "UserAgent", "Groups", "AuthSystem" + ) + expect_true(all(expected_columns %in% colnames(auditReport))) +}) diff --git a/tests/testthat/test_get_audit_report.R b/tests/testthat/test_get_audit_report.R index c7d7304e..589c6d75 100644 --- a/tests/testthat/test_get_audit_report.R +++ b/tests/testthat/test_get_audit_report.R @@ -3,7 +3,7 @@ context("Get audit report") testthat::test_that("get_audit_report() works", { query <- "serviceMethod=readDataEntity&limit=1" vcr::use_cassette("get_audit_report", { - auditReport <- get_audit_report(query, as = "xml") + auditReport <- suppressWarnings(get_audit_report(query, as = "xml")) }) expect_true("xml_document" %in% class(auditReport)) expect_true("auditRecord" %in% From c8f220977c83ec53fc08071fbb26fd4fc024be49 Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Wed, 7 Jan 2026 12:48:30 -0500 Subject: [PATCH 06/11] Update package docs for release --- DESCRIPTION | 2 +- NAMESPACE | 1 + R/get_audit_csv_report.R | 2 ++ codemeta.json | 16 +++++++++------- 4 files changed, 13 insertions(+), 8 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 0f306b82..1bddbe23 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -7,7 +7,7 @@ Authors@R: person("Jasmine", "Lai", role = "rev", comment = "0000-0001-8888-547X"), person("Rodrigo", "Pires", role = "rev", comment = "0000-0001-7384-6849")) Description: A client for the Environmental Data Initiative repository REST API. The 'EDI' data repository is for publication and reuse of ecological data with emphasis on metadata accuracy and completeness. It is built upon the 'PASTA+' software stack and was developed in collaboration with the US 'LTER' Network . 'EDIutils' includes functions to search and access existing data, evaluate and upload new data, and assist other data management tasks common to repository users. -Imports: curl, httr, jsonlite, xml2 +Imports: curl, httr, jsonlite, xml2, utils License: MIT + file LICENSE Encoding: UTF-8 RoxygenNote: 7.3.3 diff --git a/NAMESPACE b/NAMESPACE index 0b29983a..79f5a128 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -73,3 +73,4 @@ export(read_metadata_format) export(read_metadata_resource_metadata) export(search_data_packages) export(update_data_package) +importFrom(utils,read.csv) diff --git a/R/get_audit_csv_report.R b/R/get_audit_csv_report.R index cfdd5fd1..a78d8f59 100644 --- a/R/get_audit_csv_report.R +++ b/R/get_audit_csv_report.R @@ -45,6 +45,8 @@ #' @note User authentication is required (see \code{login()}) #' #' @family Audit Manager Services +#' +#' @importFrom utils read.csv #' #' @export #' diff --git a/codemeta.json b/codemeta.json index 40c927c0..9a20b360 100644 --- a/codemeta.json +++ b/codemeta.json @@ -26,16 +26,14 @@ "@type": "Person", "givenName": "Colin", "familyName": "Smith", - "email": "colin.smith@wisc.edu", - "@id": "https://orcid.org/0000-0003-2261-9931" + "email": "colin.smith@wisc.edu" } ], "contributor": [ { "@type": "Person", "givenName": "Corinna", - "familyName": "Gries", - "@id": "https://orcid.org/0000-0002-9091-6543" + "familyName": "Gries" } ], "maintainer": [ @@ -43,8 +41,7 @@ "@type": "Person", "givenName": "Colin", "familyName": "Smith", - "email": "colin.smith@wisc.edu", - "@id": "https://orcid.org/0000-0003-2261-9931" + "email": "colin.smith@wisc.edu" } ], "softwareSuggestions": [ @@ -170,9 +167,14 @@ }, "sameAs": "https://CRAN.R-project.org/package=xml2" }, + "5": { + "@type": "SoftwareApplication", + "identifier": "utils", + "name": "utils" + }, "SystemRequirements": null }, - "fileSize": "646.446KB", + "fileSize": "662.058KB", "citation": [ { "@type": "SoftwareSourceCode", From 69938471dbbe3f304fb510e0af53e52c11551963 Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Wed, 7 Jan 2026 13:53:13 -0500 Subject: [PATCH 07/11] Update CRAN comments --- cran-comments.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cran-comments.md b/cran-comments.md index eebd5081..baef4fa9 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,6 +1,7 @@ ## Revision This release updates authentication methods to use the NEW EDI Identity and -Access Management (IAM) system. These changes maintain backward compatibility. +Access Management (IAM) system and deprecates a function. These changes maintain +backward compatibility. ## Test environments From 8f67c74d643026fb992b9dd18ab4491b67af8dbf Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Thu, 8 Jan 2026 11:08:04 -0500 Subject: [PATCH 08/11] Update tests to handle new fields from various API methods --- tests/testthat/test_get_journal_citation.R | 4 +++- tests/testthat/test_list_data_package_citations.R | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/tests/testthat/test_get_journal_citation.R b/tests/testthat/test_get_journal_citation.R index 11e4ba73..4a73d334 100644 --- a/tests/testthat/test_get_journal_citation.R +++ b/tests/testthat/test_get_journal_citation.R @@ -16,6 +16,8 @@ testthat::test_that("get_journal_citation() works ", { children_found <- xml2::xml_name(xml2::xml_children(res)) children_expected <- c("journalCitationId", "packageId", "principalOwner", "dateCreated", "articleDoi", "articleTitle", - "articleUrl", "journalTitle", "relationType") + "articleUrl", "journalTitle", "relationType", + "pubDate", "journalIssue", "journalVolume", + "articlePages", "articleAuthors") expect_true(all(children_found %in% children_expected)) }) diff --git a/tests/testthat/test_list_data_package_citations.R b/tests/testthat/test_list_data_package_citations.R index 96e78ad8..bf094120 100644 --- a/tests/testthat/test_list_data_package_citations.R +++ b/tests/testthat/test_list_data_package_citations.R @@ -10,6 +10,8 @@ testthat::test_that("list_data_package_citations() works", { xml2::xml_children(xml2::xml_children(res)[1])) children_expected <- c("journalCitationId", "packageId", "principalOwner", "dateCreated", "articleDoi", "articleTitle", - "articleUrl", "journalTitle", "relationType") + "articleUrl", "journalTitle", "relationType", + "pubDate", "journalIssue", "journalVolume", + "articlePages", "articleAuthors") expect_true(all(children_found %in% children_expected)) }) From f14f388795e9116fc6543c69de41e50679270ab9 Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Thu, 8 Jan 2026 17:06:12 -0500 Subject: [PATCH 09/11] Set create_dn as defunct --- NEWS.md | 1 + R/create_dn.R | 10 +- R/list_principal_owner_citations.R | 10 +- R/list_user_data_packages.R | 17 +- R/login.R | 14 +- R/utilities.R | 9 +- codemeta.json | 2 +- man/create_dn.Rd | 8 +- man/list_principal_owner_citations.Rd | 10 +- man/list_user_data_packages.Rd | 15 +- .../list_principal_owner_citations.yml | 1506 ++++++++++++++++- tests/fixtures/list_user_data_packages.yml | 389 ++++- tests/fixtures/query_event_subscriptions.yml | 43 +- .../_vcr/list_principal_owner_citations.yml | 26 + .../testthat/_vcr/list_user_data_packages.yml | 23 + tests/testthat/test_create_data_package.R | 3 +- tests/testthat/test_create_dn.R | 14 - tests/testthat/test_evaluate_data_package.R | 3 +- .../test_list_principal_owner_citations.R | 8 +- tests/testthat/test_list_user_data_packages.R | 2 +- .../testthat/test_query_event_subscriptions.R | 2 +- tests/testthat/test_update_data_package.R | 6 +- tests/testthat/test_utilities.R | 6 +- vignettes/tests_requiring_authentication.Rmd | 5 +- 24 files changed, 2006 insertions(+), 126 deletions(-) create mode 100644 tests/testthat/_vcr/list_principal_owner_citations.yml create mode 100644 tests/testthat/_vcr/list_user_data_packages.yml delete mode 100644 tests/testthat/test_create_dn.R diff --git a/NEWS.md b/NEWS.md index cfb889a7..96436b8d 100644 --- a/NEWS.md +++ b/NEWS.md @@ -7,6 +7,7 @@ EDIutils 1.1.0 (2026-01-06) ### MINOR IMPROVEMENTS * Update authentication to support new EDI IAM system (#60) + * Update tests to handle new fields from various API methods EDIutils 1.0.3 (2023-10-10) =========================== diff --git a/R/create_dn.R b/R/create_dn.R index ba223a00..2e694c9b 100644 --- a/R/create_dn.R +++ b/R/create_dn.R @@ -1,4 +1,10 @@ -#' Create a users distinguished name +#' Create a users distinguished name (defunct) +#' +#' This function is defunct. Distinguished names are no longer used in EDI +#' authentication. Use an EDI ID token instead. This ID can be obtained by +#' logging into the EDI Identity and Access +#' Manager (\url{https://auth.edirepository.org/auth/ui/signin}) and +#' copying the "EDI-ID" string from your profile home page. #' #' @param userId (character) User identifier of an EDI data repository account #' @param ou (character) Organizational unit in which \code{userId} belongs. @@ -20,6 +26,8 @@ #' dn <- create_dn(userId = "my_userid", ou = "LTER") #' dn create_dn <- function(userId, ou = "EDI") { + .Defunct(msg = "'create_dn()' is defunct. Distinguished names are no longer + used in EDI authentication. Use an EDI ID token instead.") ou <- toupper(ou) res <- paste0("uid=", userId, ",o=", ou, ",") if (ou == "EDI") { diff --git a/R/list_principal_owner_citations.R b/R/list_principal_owner_citations.R index 9a1130ad..824224fb 100644 --- a/R/list_principal_owner_citations.R +++ b/R/list_principal_owner_citations.R @@ -1,7 +1,9 @@ #' List principal owner citations #' -#' @param principalOwner (character) Principal owner in the format returned by -#' \code{create_dn()} +#' @param principalOwner (character) The EDI-ID of the principal owner. +#' This ID can be obtained by logging into the EDI Identity and Access +#' Manager (\url{https://auth.edirepository.org/auth/ui/signin}) and +#' copying the "EDI-ID" string from your profile home page. #' @param as (character) Format of the returned object. Can be: "data.frame" #' or "xml". #' @param env (character) Repository environment. Can be: "production", @@ -18,8 +20,8 @@ #' \dontrun{ #' #' # List citations -#' dn <- create_dn(userId = "FCE", ou = "EDI") -#' journalCitations <- list_principal_owner_citations(principalOwner = dn) +#' edi_id <- "EDI-543afa80c859825d35d37d9111c24a4a65a0ff9e" +#' journalCitations <- list_principal_owner_citations(principalOwner = edi_id) #' } list_principal_owner_citations <- function(principalOwner, as = "data.frame", diff --git a/R/list_user_data_packages.R b/R/list_user_data_packages.R index 2c6090d1..50ea3a63 100644 --- a/R/list_user_data_packages.R +++ b/R/list_user_data_packages.R @@ -5,12 +5,15 @@ #' distinguished name. Data packages that were uploaded by the specified user #' but have since been deleted are excluded from the list. #' -#' @param dn (character) Distinguished name of user. Create with -#' \code{create_dn()}. +#' @param edi_id (character) The EDI-ID of the user. This ID can be obtained by +#' logging into the EDI Identity and Access Manager +#' (\url{https://auth.edirepository.org/auth/ui/signin}) and copying the +#' "EDI-ID" string from your profile home page. #' @param env (character) Repository environment. Can be: "production", #' "staging", or "development". #' -#' @return (character) Data package identifiers belonging to a \code{dn} +#' @return (character) Data package identifiers belonging to a +#' \code{edi_id} #' #' @family Listing #' @@ -20,13 +23,13 @@ #' \dontrun{ #' #' # List user data packages -#' dn <- create_dn(userId = "dbjourneynorth") -#' packageIds <- list_user_data_packages(dn) +#' edi_id <- "EDI-543afa80c859825d35d37d9111c24a4a65a0ff9e" +#' packageIds <- list_user_data_packages(edi_id = edi_id) #' packageIds #' #> [1] "edi.948.1" "edi.949.1" #' } -list_user_data_packages <- function(dn, env = "production") { - url <- paste0(base_url(env), "/package/user/", dn) +list_user_data_packages <- function(edi_id, env = "production") { + url <- paste0(base_url(env), "/package/user/", edi_id) resp <- httr::GET(url, set_user_agent(), handle = httr::handle("")) res <- httr::content(resp, as = "text", encoding = "UTF-8") httr::stop_for_status(resp, res) diff --git a/R/login.R b/R/login.R index e82c8898..37968b36 100644 --- a/R/login.R +++ b/R/login.R @@ -72,7 +72,7 @@ login <- function(userId = NULL, userPass = NULL, config = NULL) { regmatches(txt[i], regexpr(pattern, txt[i], perl = TRUE)) ) } - dn <- create_dn(userId, "EDI") + dn <- .create_dn(userId, "EDI") resp <- httr::GET( url = paste0(base_url("production"), "/package/eml"), config = httr::authenticate(dn, userPass, type = "basic"), @@ -84,3 +84,15 @@ login <- function(userId = NULL, userPass = NULL, config = NULL) { Sys.setenv(EDI_TOKEN = token_value[token_name == "edi-token"]) Sys.setenv(AUTH_TOKEN = token_value[token_name == "auth-token"]) } + + +.create_dn <- function(userId, ou = "EDI") { + ou <- toupper(ou) + res <- paste0("uid=", userId, ",o=", ou, ",") + if (ou == "EDI") { + res <- paste0(res, "dc=edirepository,dc=org") + } else { + res <- paste0(res, "dc=ecoinformatics,dc=org") + } + return(res) +} diff --git a/R/utilities.R b/R/utilities.R index 661ef461..62300270 100644 --- a/R/utilities.R +++ b/R/utilities.R @@ -123,6 +123,10 @@ config_test_eml <- function(userId, url) { #' written to file #' @param packageId (character) Package identifier, of the form #' "scope.identifier.revision", for the new EML file +#' @param edi_id (character) The EDI-ID of the user. This ID can be obtained by +#' logging into the EDI Identity and Access Manager +#' (\url{https://auth.edirepository.org/auth/ui/signin}) and copying the +#' "EDI-ID" string from your profile home page. #' #' @return (character) Full path to EML file written by this function to #' \code{path}. Should be \code{tempdir()} if executed in a testthat context. @@ -132,16 +136,15 @@ config_test_eml <- function(userId, url) { #' #' @noRd #' -create_test_eml <- function(path, packageId) { +create_test_eml <- function(path, packageId, edi_id) { # Read EML template eml <- system.file("extdata", "eml.xml", package = "EDIutils") eml <- xml2::read_xml(eml) # Add packageId xml2::xml_attr(eml, "packageId") <- packageId # Add principal - dn <- create_dn(Sys.getenv("EDI_USERID")) principal <- xml2::xml_find_first(eml, ".//principal") - xml2::xml_text(principal) <- dn + xml2::xml_text(principal) <- edi_id # Add URL url <- xml2::xml_find_first(eml, ".//online/url") xml2::xml_text(url) <- Sys.getenv("EDI_TEST_URL") diff --git a/codemeta.json b/codemeta.json index 9a20b360..afef49c5 100644 --- a/codemeta.json +++ b/codemeta.json @@ -174,7 +174,7 @@ }, "SystemRequirements": null }, - "fileSize": "662.058KB", + "fileSize": "662.381KB", "citation": [ { "@type": "SoftwareSourceCode", diff --git a/man/create_dn.Rd b/man/create_dn.Rd index a35db3e3..5d2fd258 100644 --- a/man/create_dn.Rd +++ b/man/create_dn.Rd @@ -2,7 +2,7 @@ % Please edit documentation in R/create_dn.R \name{create_dn} \alias{create_dn} -\title{Create a users distinguished name} +\title{Create a users distinguished name (defunct)} \usage{ create_dn(userId, ou = "EDI") } @@ -17,7 +17,11 @@ Can be "EDI" or "LTER". All \code{userId} issued after "2020-05-01" have (character) Distinguished name } \description{ -Create a users distinguished name +This function is defunct. Distinguished names are no longer used in EDI +authentication. Use an EDI ID token instead. This ID can be obtained by +logging into the EDI Identity and Access +Manager (\url{https://auth.edirepository.org/auth/ui/signin}) and +copying the "EDI-ID" string from your profile home page. } \examples{ # For an EDI account diff --git a/man/list_principal_owner_citations.Rd b/man/list_principal_owner_citations.Rd index e9d16d61..fb72bf00 100644 --- a/man/list_principal_owner_citations.Rd +++ b/man/list_principal_owner_citations.Rd @@ -11,8 +11,10 @@ list_principal_owner_citations( ) } \arguments{ -\item{principalOwner}{(character) Principal owner in the format returned by -\code{create_dn()}} +\item{principalOwner}{(character) The EDI-ID of the principal owner. +This ID can be obtained by logging into the EDI Identity and Access +Manager (\url{https://auth.edirepository.org/auth/ui/signin}) and +copying the "EDI-ID" string from your profile home page.} \item{as}{(character) Format of the returned object. Can be: "data.frame" or "xml".} @@ -31,8 +33,8 @@ List principal owner citations \dontrun{ # List citations -dn <- create_dn(userId = "FCE", ou = "EDI") -journalCitations <- list_principal_owner_citations(principalOwner = dn) +edi_id <- "EDI-543afa80c859825d35d37d9111c24a4a65a0ff9e" +journalCitations <- list_principal_owner_citations(principalOwner = edi_id) } } \seealso{ diff --git a/man/list_user_data_packages.Rd b/man/list_user_data_packages.Rd index de99d761..d93bcf7d 100644 --- a/man/list_user_data_packages.Rd +++ b/man/list_user_data_packages.Rd @@ -4,17 +4,20 @@ \alias{list_user_data_packages} \title{List user data packages} \usage{ -list_user_data_packages(dn, env = "production") +list_user_data_packages(edi_id, env = "production") } \arguments{ -\item{dn}{(character) Distinguished name of user. Create with -\code{create_dn()}.} +\item{edi_id}{(character) The EDI-ID of the user. This ID can be obtained by +logging into the EDI Identity and Access Manager +(\url{https://auth.edirepository.org/auth/ui/signin}) and copying the +"EDI-ID" string from your profile home page.} \item{env}{(character) Repository environment. Can be: "production", "staging", or "development".} } \value{ -(character) Data package identifiers belonging to a \code{dn} +(character) Data package identifiers belonging to a + \code{edi_id} } \description{ List all data packages (including their revision values) @@ -26,8 +29,8 @@ but have since been deleted are excluded from the list. \dontrun{ # List user data packages -dn <- create_dn(userId = "dbjourneynorth") -packageIds <- list_user_data_packages(dn) +edi_id <- "EDI-543afa80c859825d35d37d9111c24a4a65a0ff9e" +packageIds <- list_user_data_packages(edi_id = edi_id) packageIds #> [1] "edi.948.1" "edi.949.1" } diff --git a/tests/fixtures/list_principal_owner_citations.yml b/tests/fixtures/list_principal_owner_citations.yml index 64e64fc5..c91d9e81 100644 --- a/tests/fixtures/list_principal_owner_citations.yml +++ b/tests/fixtures/list_principal_owner_citations.yml @@ -1,34 +1,1488 @@ http_interactions: - request: - method: get - uri: https://pasta.lternet.edu/package/citations/eml/uid=csmith,o=EDI,dc=edirepository,dc=org - body: - encoding: '' - string: '' - headers: - Accept: application/json, text/xml, application/xml, */* + method: GET + uri: https://pasta.lternet.edu/package/citations/eml/EDI-543afa80c859825d35d37d9111c24a4a65a0db9f response: - status: - status_code: 200 - category: Success - reason: OK - message: 'Success: (200) OK' + status: 200 headers: - server: nginx/1.14.0 (Ubuntu) - date: Tue, 18 Jan 2022 19:55:15 GMT + access-control-allow-origin: '*' + connection: keep-alive content-type: application/xml + date: Thu, 08 Jan 2026 21:11:06 GMT + server: nginx/1.18.0 (Ubuntu) + set-cookie: + - auth-token="cHVibGljKmh0dHBzOi8vcGFzdGEuZWRpcmVwb3NpdG9yeS5vcmcvYXV0aGVudGljYXRpb24qMTc2NzkzNTQ2NjA5Mw==-OwwfbZ9hZ6PZhaG04Snq+5rH1/p05aFay/VmO8tWlSsndAOzYrVT6cx5QBWW5/bmG1KNAM6w3aO9k1a6TS9XG1IOlqriQb/8RLs9k6z7w4URb9AZV9MNScRoiPUS9lUOCZFSrH01L5S9r9I8X8CjJRRvbx1laY58QnFPYiELadis0uDbe+xwW4EgCUvhCMCdOb5D7zmosLY+wvCqw/zM2z7/NG0OyNKNJTdRsT5xzLpXIiepFTVohjBCEvO3AcGKidm/jG962BLFTPAzgsTFPyjSsYmBA0Zh51RPdw+mMle6wQ3AFuvi5z24oQPbel7vs0KeuUeJ4paA2VRXTPnS1g=="; + HttpOnly; Max-Age=0; Path=/; SameSite=lax + - edi-token=eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJFREktMDc4ZTZlM2NlZTRmN2YyODEyZjE1MDcwMWRhOTM1MWFjYjUxZTA4OSIsImNuIjoiUHVibGljIEFjY2VzcyIsImVtYWlsIjpudWxsLCJwcmluY2lwYWxzIjpbXSwibGlua3MiOltdLCJpc0VtYWlsRW5hYmxlZCI6ZmFsc2UsImlzRW1haWxWZXJpZmllZCI6ZmFsc2UsImlkcENvbW1vbk5hbWUiOiJQdWJsaWMgQWNjZXNzIiwiaWRwTmFtZSI6InN5c3RlbSIsImlkcFVpZCI6bnVsbCwiaXNzIjoiaHR0cHM6Ly9hdXRoLmVkaXJlcG9zaXRvcnkub3JnIiwiaGQiOiJlZGlyZXBvc2l0b3J5Lm9yZyIsImlhdCI6MTc2NzkwNjY2NiwibmJmIjoxNzY3OTA2NjY2LCJleHAiOjE3Njc5MzU0NjZ9.ZYQKuPBaIEBqEooBwjbuhIUjSTanAAM0GeEawIQL-p8U2Vu_p1_zXXwXu6xXYCnS8q2Qn4Nbgr8c8btpYXFUjw; + HttpOnly; Max-Age=0; Path=/; SameSite=lax transfer-encoding: chunked - connection: keep-alive web-service: DataPackageManager-1.0 body: - encoding: UTF-8 - file: no - string: "\n\n\n - \ 46\n edi.17.1\n - \ uid=csmith,o=EDI,dc=edirepository,dc=org\n - \ 2018-09-06T09:36:54.459\n https://doi.org/10.1890/11-1026.1\n - \ Corridors promote fire via connectivity and edge effects\n - \ https://esajournals.onlinelibrary.wiley.com/doi/abs/10.1890/11-1026.1\n - \ Ecological Applications\n IsCitedBy\n\n" - recorded_at: 2022-01-18 19:55:15 GMT - recorded_with: vcr/1.0.2, webmockr/0.8.0 + string: |- + + + + 46 + edi.17.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-09-06T09:36:54.459 + 10.1890/11-1026.1 + Corridors promote fire via connectivity and edge effects + https://esajournals.onlinelibrary.wiley.com/doi/abs/10.1890/11-1026.1 + Ecological Applications + IsCitedBy + + + + + + + + + 47 + edi.43.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-09-06T09:40:34.073 + 10.3368/er.31.1.23 + Landscape Corridors Promote Long-Distance Seed Dispersal by Birds During Winter but Not During Summer at an Experimentally Fragmented Restoration Site + http://er.uwpress.org/content/31/1/23 + Ecological Restoration + IsCitedBy + + + + + + + + + 48 + edi.44.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-09-06T09:45:13.156 + 10.1890/15-0734.1 + Connectivity from a different perspective: comparing seed dispersal kernels in connected vs. unfragmented landscapes + https://esajournals.onlinelibrary.wiley.com/doi/abs/10.1890/15-0734.1 + Ecology + IsCitedBy + + + + + + + + + 49 + edi.45.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-09-06T09:51:31.059 + 10.1007/s13592-017-0499-1 + Testing the relative importance of local resources and landscape connectivity on Bombus impatiens (Hymenoptera, Apidae) colonies + https://link.springer.com/article/10.1007%2Fs13592-017-0499-1 + Apidologie + IsCitedBy + + + + + + + + + 50 + edi.51.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-09-06T09:56:18.229 + 10.1111/een.12517 + Mean body size predicts colony performance in the common eastern bumble bee (Bombus impatiens) + https://onlinelibrary.wiley.com/doi/abs/10.1111/een.12517 + Ecological Entomology + IsCitedBy + + + + + + + + + 51 + edi.90.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-09-06T09:59:21.981 + 10.1890/10-1072.1 + Edge effects, not connectivity, determine the incidence and development of a foliar fungal plant disease + https://esajournals.onlinelibrary.wiley.com/doi/abs/10.1890/10-1072.1 + Ecology + IsCitedBy + + + + + + + + + 52 + edi.102.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-09-06T10:02:28.191 + 10.1002/ecy.1466 + Disentangling fragmentation effects on herbivory in understory plants of longleaf pine savanna + https://esajournals.onlinelibrary.wiley.com/doi/abs/10.1002/ecy.1466 + Ecology + IsCitedBy + + + + + + + + + 53 + edi.103.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-09-06T10:05:39.720 + 10.1890/ES12-00266.1 + Habitat corridors alter relative trophic position of fire ants + https://esajournals.onlinelibrary.wiley.com/doi/abs/10.1890/ES12-00266.1 + Ecosphere + IsCitedBy + + + + + + + + + 54 + edi.105.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-09-06T10:09:03.417 + 10.1890/10-1116.1 + Can dispersal mode predict corridor effects on plant parasites? + https://esajournals.onlinelibrary.wiley.com/doi/abs/10.1890/10-1116.1 + Ecology + IsCitedBy + + + + + + + + + 55 + edi.106.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-09-06T10:12:41.044 + 10.1656/058.008.0412 + Effects of Corridors on Genetics of a Butterfly in a Landscape Experiment + http://www.bioone.org/doi/abs/10.1656/058.008.0412 + Southeastern Naturalist + IsCitedBy + + + + + + + + + 58 + edi.107.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-10-12T12:01:25.083 + 10.2307/1942321 + Biological accommodation in the benthic community at McMurdo Sound, Antarctica + https://esajournals.onlinelibrary.wiley.com/doi/abs/10.2307/1942321 + Ecological Monographs + IsCitedBy + + + + + + + + + 62 + edi.255.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2018-10-23T09:21:17.034 + 10.1007/s10980-011-9650-y + Edge-mediated patterns of seed removal in experimentally connected and fragmented landscapes + + Landscape Ecology + IsCitedBy + + + + + + + + + 87 + edi.276.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2019-01-25T16:24:09.177 + + Low dissolved oxygen in an estuarine channel (San Joaquin River, California): mechanisms and models based on long-term time series + https://doi.org/10.15447/sfews.2005v3iss2art2 + San Francisco Estuary and Watershed Science + IsCitedBy + + + + + + + + + 88 + edi.276.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2019-01-25T16:24:41.327 + + Sources of oxygen demand in the lower San Joaquin River, California + https://link.springer.com/article/10.1007/BF02803533 + Estuaries and Coasts + IsCitedBy + + + + + + + + + 115 + edi.332.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2019-03-15T11:30:35.684 + 10.1111/1365-2745.12985 + Predicting landscape-level distribution and abundance: Integrating demography, fire, elevation, and landscape habitat configuration + + Journal of Ecology + IsCitedBy + + + + + + + + + 116 + edi.332.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2019-03-15T11:31:02.924 + 10.1111/j.1461-0248.2006.00988.x + Sensitivity of the population growth rate to demographic variability within and between phases of the disturbance cycle + + Ecology Letters + IsCitedBy + + + + + + + + + 154 + edi.378.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2019-06-10T18:28:27.761 + 10.1111/j.1365-2427.2007.01941.x + Untangling the complex issue of dissolved organic carbon uptake: A stable isotope approach + + Freshwater Biology + IsCitedBy + + + + + + + + + 189 + edi.435.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2019-10-17T18:45:40.218 + 10.1007/s00442-019-04518-6 + Soil microbes that may accompany climate warming increase alpine plant production + https://doi.org/10.1007/s00442-019-04518-6 + Oecologia + IsCitedBy + + + + + + + + + 197 + edi.417.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-01-08T08:51:51.693 + 10.1111/gbi.12365 + Biogeochemical and physical controls on methane fluxes from two ferruginous meromictic lakes + https://doi.org/10.1111/gbi.12365 + Geobiology + IsCitedBy + + + + + + + + + 200 + edi.460.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-01-21T11:37:48.968 + 10.1007/s12237-019-00577-3 + Resistance to Hurricane Effects Varies Among Wetland Vegetation Types in the Marsh-Mangrove Ecotone + https://doi.org/10.1007/s12237-019-00577-3 + Estuaries and Coasts + IsCitedBy + + + + + + + + + 204 + edi.404.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-02-03T12:53:20.269 + 10.1029/2019JG005139 + Response of Humic Acids and Soil Organic Matter to Vegetation Replacement in Subtropical High Mountain Forests + https://doi.org/10.1029/2019JG005139 + JGR Biogeosciences + IsCitedBy + + + + + + + + + 206 + edi.443.2 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-02-18T10:00:37.820 + 10.1002/lol2.10135 + Paired O2-CO2 measurements provide emergent insights into aquatic ecosystem function + https://doi.org/10.1002/lol2.10135 + Limnology and Oceanography Letters + IsCitedBy + + + + + + + + + 224 + edi.494.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-04-10T11:32:43.957 + 10.1002/aqc.620 + Effects of flow variation on channel and floodplain biota and habitats of the Sacramento River, California, USA + https://doi.org/10.1002/aqc.620 + Aquatic Conservation: Marine and Freshwater Ecosystems + IsCitedBy + + + + + + + + + 225 + edi.494.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-04-10T11:33:03.553 + 10.1002/tafs.10028 + Effects of Extreme Hydrologic Regimes on Juvenile Chinook Salmon Prey Resources and Diet Composition in a Large River Floodplain + https://doi.org/10.1002/tafs.10028 + Transactions of the American Fisheries Society + IsCitedBy + + + + + + + + + 226 + edi.494.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-04-10T11:33:34.294 + 10.1139/f00-245 + Floodplain rearing of juvenile chinook salmon: evidence of enhanced growth and survival + https://doi.org/10.1139/f00-245 + Canadian Journal of Fisheries and Aquatic Sciences + IsCitedBy + + + + + + + + + 232 + edi.468.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-05-05T16:07:51.443 + 10.1038/s41561-020-0571-8 + Significant methane ebullition from alpine permafrost rivers on the East Qinghai-Tibet Plateau + https://doi.org/10.1038/s41561-020-0571-8 + Nature Geoscience + IsCitedBy + + + + + + + + + 285 + edi.587.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-08-06T11:15:38.049 + 10.1080/09640568.2018.1530099 + Affective ecologies, adaptive management and restoration efforts in the Sacramento-San Joaquin Delta + https://doi.org/10.1080/09640568.2018.1530099 + Journal of Environmental Planning and Management + IsCitedBy + + + + + + + + + 319 + edi.637.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-12-19T15:11:01.794 + 10.1660/062.121.0417 + Ontogenetic changes in tail-length and the possible relation to caudal luring in northeast Kansas Copperheads, Agkistrodon contortrix + https://bioone.org/journals/transactions-of-the-kansas-academy-of-science/volume-121/issue-3-4/062.121.0417/Ontogenetic-Changes-in-Tail-Length-and-the-Possible-Relation-to/10.1660/062.121.0417.short + Transactions of the Kansas Academy of Science + IsCitedBy + + + + + + + + + 320 + edi.637.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2020-12-19T15:13:29.594 + 10.1660/062.123.0120 + Revisiting old data to answer modern conservation questions: Population modeling of two species in Kingsnakes, Lampropeltis sp. in Kansas + https://doi.org/10.1660/062.123.0120 + Transactions of the Kansas Academy of Science + IsCitedBy + + + + + + + + + 326 + edi.699.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-01-19T17:12:18.850 + 10.1007/s00442-020-04816-4 + Behaviorally-mediated trophic cascade attenuated by prey use of risky places at safe times + https://doi.org/10.1007/s00442-020-04816-4 + Ecosystem ecology + IsCitedBy + + + + + + + + + 334 + edi.552.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-03T10:10:12.180 + 10.1029/2020GL090959 + Climate change and teleconnections amplify lake stratification with differential local controls of surface water warming and deep water cooling + https://doi.org/10.1029/2020GL090959 + Geophysical Research Letters + IsCitedBy + + + + + + + + + 346 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:28:57.865 + 10.2307/1351412 + Zooplankton distribution and abundance in the Sacramento-San Joaquin delta in relation to certain environmental factors + https://doi.org/10.2307/1351412 + Estuaries + IsCitedBy + + + + + + + + + 347 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:30:07.317 + 10.1007/BF02692224 + Physical, biological, and management responses to variable freshwater flow into the San Francisco Estuary + https://doi.org/10.1007/BF02692224 + Estuaries + IsCitedBy + + + + + + + + + 348 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:31:57.423 + 10.15447/sfews.2005v3iss2art2 + Low Dissolved Oxygen in an Estuarine Channel (San Joaquin River, California): Mechanisms and Models Based on Long-term Time Series + https://doi.org/10.15447/sfews.2005v3iss2art2 + San Francisco Estuary and Watershed Science + IsCitedBy + + + + + + + + + 349 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:33:07.704 + 10.15447/sfews.2008v6iss1art2 + Phytoplankton in the Upper San Francisco Estuary: Recent Biomass Trends, Their Causes, and Their Trophic Significance + https://doi.org/10.15447/sfews.2008v6iss1art2 + San Francisco Estuary and Watershed Science + IsCitedBy + + + + + + + + + 350 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:33:50.570 + 10.15447/sfews.2010v8iss1art2 + Benthic Assemblage Variability in the Upper San Francisco Estuary: A 27-Year Retrospective + https://doi.org/10.15447/sfews.2010v8iss1art2 + San Francisco Estuary and Watershed Science + IsCitedBy + + + + + + + + + 351 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:34:50.477 + 10.1371/journal.pone.0024465 + Projected Evolution of California's San Francisco Bay-Delta-River System in a Century of Climate Change + https://doi.org/10.1371/journal.pone.0024465 + PLOS ONE + IsCitedBy + + + + + + + + + 352 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:35:45.734 + 10.1007/s12237-010-9342-x + Shifts in Zooplankton Community Structure: Implications for Food Web Processes in the Upper San Francisco Estuary + https://doi.org/10.1007/s12237-010-9342-x + Estuaries and Coasts + IsCitedBy + + + + + + + + + 353 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:37:04.938 + 10.1029/2012RG000397 + Drivers of change in estuarine� coastal ecosystems: Discoveries from four decades of study in San Francisco Bay + https://doi.org/10.1029/2012RG000397 + Reviews of Geophysics + IsCitedBy + + + + + + + + + 354 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:38:06.518 + 10.1007/s10661-012-2708-8 + Benthic macrofaunal assemblages of the San Francisco Estuary and Delta, USA + https://doi.org/10.1007/s10661-012-2708-8 + Environmental Monitoring and Assessment + IsCitedBy + + + + + + + + + 355 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:39:04.450 + 10.1007/s12237-013-9753-6 + Phytoplankton Growth Balanced by Clam and Zooplankton Grazing and Net Transport into the Low-Salinity Zone of the San Francisco Estuary + https://doi.org/10.1007/s12237-013-9753-6 + Estuaries and Coasts + IsCitedBy + + + + + + + + + 356 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:39:56.366 + 10.15447/sfews.2016v14iss3art2 + Fine-Scale Distributions of Zooplankton in the Northern San Francisco Estuary + https://doi.org/10.15447/sfews.2016v14iss3art2 + San Francisco Estuary and Watershed Science + IsCitedBy + + + + + + + + + 357 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:40:57.564 + 10.1016/j.hal.2017.01.011 + Impacts of the 2014 severe drought on the Microcystis bloom in San Francisco Estuary + https://doi.org/10.1016/j.hal.2017.01.011 + Harmful Algae + IsCitedBy + + + + + + + + + 358 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:41:56.370 + 10.1002/lno.10958 + Patterns, pace, and processes of water� quality variability in a long� studied estuary + https://doi.org/10.1002/lno.10958 + Limnology and Oceanography + IsCitedBy + + + + + + + + + 359 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:42:47.956 + 10.1007/s10750-017-3385-y + Effects of freshwater flow and phytoplankton biomass on growth, reproduction, and spatial subsidies of the estuarine copepod Pseudodiaptomus forbesi + https://doi.org/10.1007/s10750-017-3385-y + Hydrobiologia + IsCitedBy + + + + + + + + + 360 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:47:23.867 + 10.1002/tafs.10015 + Individual� Based Modeling of Delta Smelt Population Dynamics in the Upper San Francisco Estuary III. Effects of Entrainment Mortality and Changes in Prey + https://doi.org/10.1002/tafs.10015 + Transactions of the American Fisheries Society + IsCitedBy + + + + + + + + + 361 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:48:14.167 + 10.1016/j.margeo.2013.05.008 + A step decrease in sediment concentration in a highly modified tidal river delta following the 1983 El Niño floods + https://doi.org/10.1016/j.margeo.2013.05.008 + Marine Geology + IsCitedBy + + + + + + + + + 362 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:48:59.055 + 10.1029/96RG00986 + Phytoplankton bloom dynamics in coastal ecosystems: A review with some general lessons from sustained investigation of San Francisco Bay, California + https://doi.org/10.1029/96RG00986 + Reviews of Geophysics + IsCitedBy + + + + + + + + + 363 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:49:36.035 + 10.15447/sfews.2018v16iss1/art3 + Physical and Biological Responses to Flow in a Tidal Freshwater Slough Complex + https://doi.org/10.15447/sfews.2018v16iss1/art3 + San Francisco Estuary and Watershed Science + IsCitedBy + + + + + + + + + 364 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:50:56.164 + 10.1002/1099-0755(200009/10)10:5%3C323::AID-AQC417%3E3.0.CO;2-J + Organic matter sources and rehabilitation of the Sacramento� San Joaquin Delta (California, USA) + https://doi.org/10.1002/1099-0755(200009/10)10:5%3C323::AID-AQC417%3E3.0.CO;2-J + Aquatic Conservation: Marine and Freshwater Ecosystems + IsCitedBy + + + + + + + + + 365 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:52:02.974 + 10.1016/S0272-7714(06)80012-0 + Hydrodynamic influences on interannual chlorophyll variability in an estuary: Upper San Francisco Bay-Delta (California, U.S.A.) + https://doi.org/10.1016/S0272-7714(06)80012-0 + Estuarine, Coastal and Shelf Science + IsCitedBy + + + + + + + + + 366 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:52:41.226 + 10.4319/lo.2000.45.3.0580 + The influence of climate on phytoplankton community biomass in San Francisco Bay Estuary + https://doi.org/10.4319/lo.2000.45.3.0580 + Limnology and Oceanography + IsCitedBy + + + + + + + + + 367 + edi.458.4 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-02-17T17:53:35.933 + 10.2307/1351412 + Zooplankton distribution and abundance in the Sacramento-San Joaquin delta in relation to certain environmental factors + https://doi.org/10.2307/1351412 + Estuaries + IsCitedBy + + + + + + + + + 375 + edi.754.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-05-20T09:18:52.697 + 10.3390/f12050614 + Forest Development over a Twenty-Year Chronosequence of Reforested Urban Sites + https://doi.org/10.3390/f12050614 + Forests + IsCitedBy + + + + + + + + + 376 + edi.753.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-05-20T09:19:41.943 + 10.3390/f12050614 + Forest Development over a Twenty-Year Chronosequence of Reforested Urban Sites + https://doi.org/10.3390/f12050614 + Forests + IsCitedBy + + + + + + + + + 377 + edi.738.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-05-20T10:27:20.425 + 10.3390/f12050614 + Forest Development over a Twenty-Year Chronosequence of Reforested Urban Sites + https://doi.org/10.3390/f12050614 + Forests + IsCitedBy + + + + + + + + + 380 + edi.842.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-05-24T18:51:38.231 + 10.1016/j.foreco.2020.118523 + Topographic position amplifies consequences of short-interval stand-replacing fires on postfire tree establishment in subalpine conifer forests + https://doi.org/10.1016/j.foreco.2020.118523 + Forest Ecology and Management + IsCitedBy + + + + + + + + + 381 + edi.845.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-05-27T13:23:14.981 + 10.1016/j.scitotenv.2021.148033 + Bioturbation frequency alters methane emissions from reservoir sediments + https://doi.org/10.1016/j.scitotenv.2021.148033 + Science of the Total Environment + IsCitedBy + + + + + + + + + 556 + edi.984.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-10-20T06:06:15.156 + 10.1029/2020WR029552 + The Influence of Weather Forecast Resolution on the Circulation of Lake George, NY + https://doi.org/10.1029/2020WR029552 + Water Resources Research + IsCitedBy + + + + + + + + + 830 + edi.1031.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-11-19T12:09:15.357 + 10.1111/j.1365-2699.2012.02731.x + Dissecting NDVI–species richness relationships in Hawaiian dry forests + https://doi.org/10.1111/j.1365-2699.2012.02731.x + Journal of Biogeography + IsReferencedBy + + + + + + + + + 1031 + edi.8.5 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-01T11:25:22.901 + 10.1073/pnas.1620211114 + Salting our freshwater lakes + https://doi.org/10.1073/pnas.1620211114 + PNAS + IsCitedBy + + + + + + + + + 1472 + edi.1044.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-21T08:12:27.923 + 10.1086/716236 + Bloom and bust: Historical trends of harmful algal blooms in Muskegon Lake, Michigan, a Great Lakes estuary + https://doi.org/10.1086/716236 + Freshwater Science + IsReferencedBy + + + + + + + + + 1473 + edi.1044.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-21T08:13:13.919 + 10.1016/j.jglr.2021.07.003 + Cold and Wet: Diatoms dominate the phytoplankton community during a year of anomalous weather in a Great Lakes estuary + https://doi.org/10.1016/j.jglr.2021.07.003 + Journal of Great Lakes Research + IsReferencedBy + + + + + + + + + 1474 + edi.1044.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-21T08:13:53.333 + 10.1111/jai.14076 + Adult lake sturgeon (Acipenser fulvescens Rafinesque, 1817) occurrence in the Muskegon River system, a Lake Michigan drowned river mouth, USA + https://doi.org/10.1111/jai.14076 + Journal of Applied Ichthyology + IsReferencedBy + + + + + + + + + 1475 + edi.1044.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-21T08:14:36.277 + 10.1016/j.jglr.2019.09.025 + Influence of episodic wind events on thermal stratification and bottom water hypoxia in a Great Lakes estuary + https://doi.org/10.1016/j.jglr.2019.09.025 + Journal of Great Lakes Research + IsReferencedBy + + + + + + + + + 1476 + edi.1044.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-21T08:15:15.402 + 10.1016/j.jglr.2017.12.008 + Chronicles of Hypoxia: Time-series buoy observations reveal annually recurring seasonal basin-wide hypoxia in Muskegon Lake – a Great Lakes estuary + https://doi.org/10.1016/j.jglr.2017.12.008 + Journal of Great Lakes Research + IsCitedBy + + + + + + + + + 1477 + edi.1044.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-21T08:16:26.318 + 10.1016/j.ecss.2018.05.014 + Modeling reveals the role of coastal upwelling and hydrologic inputs on biologically distinct water exchanges in a Great Lakes estuary + https://doi.org/10.1016/j.ecss.2018.05.014 + Estuarine, Coastal and Shelf Science + IsCitedBy + + + + + + + + + 1478 + edi.1044.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-21T08:17:30.435 + 10.1007/s10021-017-0160-x + From Bacteria to Fish: Ecological consequences of seasonal hypoxia in a Great Lakes estuary + https://doi.org/10.1007/s10021-017-0160-x + Ecosystems + IsCitedBy + + + + + + + + + 1479 + edi.1044.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-21T08:18:27.251 + 10.1127/fal/2015/0626 + Alternative approaches for estimating components of lake metabolism using the free-water dissolved-oxygen (FWDO) method + https://doi.org/10.1127/fal/2015/0626 + Fundamental and Applied Limnology + IsCitedBy + + + + + + + + + 1480 + edi.1044.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-21T08:19:04.787 + 10.1093/plankt/fbu066 + Systematically variable planktonic carbon metabolism along a land-to-lake gradient in a Great Lakes coastal zone + https://doi.org/10.1093/plankt/fbu066 + Journal of Plankton Research + IsReferencedBy + + + + + + + + + 1481 + edi.1044.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2021-12-21T08:19:34.809 + 10.1016/j.ecolmodel.2013.05.010 + New methods for estimating components of lake metabolism based on free-water dissolved- oxygen dynamics + https://doi.org/10.1016/j.ecolmodel.2013.05.010 + Ecological Modelling + IsCitedBy + + + + + + + + + 3005 + edi.1018.3 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2022-07-12T09:41:36.813 + 10.1029/2021JG006723 + Soil Amended With Organic Matter Increases Fluvial Erosion Resistance of Cohesive Streambank Soil + https://doi.org/10.1029/2021JG006723 + Journal of Geophysical Research: Biogeosciences + IsCitedBy + + + + + + + + + 3512 + edi.1341.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2023-02-27T15:13:26.613 + 10.1016/j.aquabot.2020.103209 + Variations in aquatic macrophyte phenology across three temperate lakes in the Coeur d’Alene Basin + https://doi.org/10.1016/j.aquabot.2020.103209 + Aquatic Botany + IsReferencedBy + + + + + + + + + 3591 + edi.1371.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2023-03-16T10:56:46.044 + 10.1016/j.jenvman.2023.117690 + Synergistic effects of precipitation and groundwater extraction on freshwater wetland inundation + https://doi.org/10.1016/j.jenvman.2023.117690 + Journal of Environmental Management + IsCitedBy + + + + + + + + + 3598 + edi.1098.2 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2023-03-28T10:10:49.731 + 10.1371/journal.pone.0230996 + Quantifying nutrient recovery efficiency and loss from compost-based urban agriculture + https://doi.org/10.1371/journal.pone.0230996 + PLOS One + IsReferencedBy + + + + + + + + + 3599 + edi.1098.2 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2023-03-28T10:12:29.938 + 10.1007/s11252-021-01191-7 + Investigating potential hydrological ecosystem services in urban gardens through soil amendment experiments and hydrologic models + https://doi.org/10.1007/s11252-021-01191-7 + Urban Ecosystems + IsReferencedBy + + + + + + + + + 3601 + edi.1098.2 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2023-03-28T10:26:36.929 + 10.2495/UA200041 + Urban Heat Island Mitigation Due to Enhanced Evapotransporation in an Urban Garden in Saint Paul, Minnesota, USA + https://doi.org/10.2495/UA200041 + + IsReferencedBy + + + + + + + + + 4659 + edi.1614.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2024-04-09T15:00:41.561 + 10.1139/cjz-2022-0174 + Landscapes of fear and safety: the integration of two different sensory landscapes determines behavioral responses in the crayfish <i>Faxonius rusticus</i> and is mediated by chemical cues + https://cdnsciencepub.com/doi/10.1139/cjz-2022-0174 + Canadian Journal of Zoology + IsCitedBy + 2023 + + + + + + + + 4693 + edi.1142.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2024-05-03T15:04:49.903 + 10.1139/cjz-2022-0050 + Are you scared yet? Variations to cue indices elicit differential prey behavioral responses even when gape-limited predators are relatively small + https://cdnsciencepub.com/doi/10.1139/cjz-2022-0050 + Canadian Journal of Zoology + IsCitedBy + 2022 + + + + + + + + 4727 + edi.1693.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2024-06-28T17:16:05.338 + 10.1899/11-011.1 + Altering aquatic food webs with a global insecticide: arthropod–amphibian links in mesocosms that simulate pond communities + https://www.journals.uchicago.edu/doi/10.1899/11-011.1 + Journal of the North American Benthological Society + IsReferencedBy + 2011 + + + + + + + + 4728 + edi.1691.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2024-06-28T17:21:05.859 + 10.1073/pnas.031076198 + Predator-induced stress makes the pesticide carbaryl more deadly to gray treefrog tadpoles ( <i>Hyla versicolor</i> ) + https://pnas.org/doi/full/10.1073/pnas.031076198 + Proceedings of the National Academy of Sciences + IsReferencedBy + 2002 + + + + + + + + 4729 + edi.1694.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2024-06-28T17:31:09.914 + 10.1890/0012-9658(2001)082[0523:MABPOL]2.0.CO;2 + MORPHOLOGICAL AND BEHAVIORAL PLASTICITY OF LARVAL ANURANS IN RESPONSE TO DIFFERENT PREDATORS + https://doi.org/10.1890/0012-9658(2001)082[0523:MABPOL]2.0.CO;2 + Ecology + IsReferencedBy + 2001 + + + + + + + + 4730 + edi.1692.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2024-06-28T17:36:04.280 + 10.1890/0012-9658(2001)082[1947:TLEOAP]2.0.CO;2 + THE LASTING EFFECTS OF ADAPTIVE PLASTICITY: PREDATOR-INDUCED TADPOLES BECOME LONG-LEGGED FROGS + https://doi.org/10.1890/0012-9658(2001)082[1947:TLEOAP]2.0.CO;2 + Ecology + IsReferencedBy + 2001 + + + + + + + + 4731 + edi.1698.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2024-06-28T17:40:20.513 + 10.1890/0012-9658(2000)081[2278:TMIEIL]2.0.CO;2 + TRAIT-MEDIATED INDIRECT EFFECTS IN LARVAL ANURANS: REVERSING COMPETITION WITH THE THREAT OF PREDATION + https://doi.org/10.1890/0012-9658(2000)081[2278:TMIEIL]2.0.CO;2 + Ecology + IsCitedBy + 2000 + + + + + + + + 4732 + edi.1699.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2024-06-28T17:44:22.881 + 10.1643/0045-8511(2000)2000[0178:MPIFLA]2.0.CO;2 + Morphological Plasticity in Four Larval Anurans Distributed along an Environmental Gradient + https://doi.org/10.1643/0045-8511(2000)2000[0178:MPIFLA]2.0.CO;2 + Ichthyology and Herpetology + IsCitedBy + 2000 + + + + + + + + 4740 + edi.1199.1 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + 2024-07-18T13:49:22.043 + 10.1016/j.foreco.2022.120568 + The effects of fire, climate, and species composition on longleaf pine stand structure and growth rates across diverse natural communities in Florida + https://linkinghub.elsevier.com/retrieve/pii/S037811272200562X + Forest Ecology and Management + IsCitedBy + 2022 + + + + + + + + recorded_at: 2026-01-08 21:11:06 +recorded_with: VCR-vcr/2.1.0 diff --git a/tests/fixtures/list_user_data_packages.yml b/tests/fixtures/list_user_data_packages.yml index 88c4b559..abd4942c 100644 --- a/tests/fixtures/list_user_data_packages.yml +++ b/tests/fixtures/list_user_data_packages.yml @@ -1,30 +1,375 @@ http_interactions: - request: - method: get - uri: https://pasta.lternet.edu/package/user/uid=dbjourneynorth,o=EDI,dc=edirepository,dc=org - body: - encoding: '' - string: '' - headers: - Accept: application/json, text/xml, application/xml, */* + method: GET + uri: https://pasta.lternet.edu/package/user/EDI-543afa80c859825d35d37d9111c24a4a65a0db9f response: - status: - status_code: 200 - category: Success - reason: OK - message: 'Success: (200) OK' + status: 200 headers: - server: nginx/1.14.0 (Ubuntu) - date: Tue, 18 Jan 2022 20:41:41 GMT - content-type: text/plain - content-length: '19' + access-control-allow-origin: '*' connection: keep-alive + content-type: text/plain + date: Thu, 08 Jan 2026 21:06:35 GMT + server: nginx/1.18.0 (Ubuntu) + set-cookie: + - auth-token="cHVibGljKmh0dHBzOi8vcGFzdGEuZWRpcmVwb3NpdG9yeS5vcmcvYXV0aGVudGljYXRpb24qMTc2NzkzNTE5NTQ2Mw==-K/+Ybx4I2eJCOJQP3tvzPse8Hz/fSDabssMm8X/of8L2AEVaq30wTWQfh96IfIwR3Db6sDUZbizaO/av7i9dz2RqNV2TpFZ2D9NJwnsuTXEvqSEGxpVcaVslzCkVuOKOt7BWuipKkoi4P+KZz8Ib/E8GcK3PUkC1dvgXR2hBV3MunKX+QUaPMT7IAcSwX50pNC76OBuxaT7+7ybSfjswGz+pGwKFts2ZrHQObtUfkSnBi+WxtNIN1CzBPzWZEbuWGHCKrwW/HdOMhGp8Ev1VwW+EQK8Rlvp1009cPBgAEZxKZfHq6IlplB28h9M+TI/MeAcTGQeGvPK2waIIJ88BcA=="; + HttpOnly; Max-Age=0; Path=/; SameSite=lax + - edi-token=eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJFREktMDc4ZTZlM2NlZTRmN2YyODEyZjE1MDcwMWRhOTM1MWFjYjUxZTA4OSIsImNuIjoiUHVibGljIEFjY2VzcyIsImVtYWlsIjpudWxsLCJwcmluY2lwYWxzIjpbXSwibGlua3MiOltdLCJpc0VtYWlsRW5hYmxlZCI6ZmFsc2UsImlzRW1haWxWZXJpZmllZCI6ZmFsc2UsImlkcENvbW1vbk5hbWUiOiJQdWJsaWMgQWNjZXNzIiwiaWRwTmFtZSI6InN5c3RlbSIsImlkcFVpZCI6bnVsbCwiaXNzIjoiaHR0cHM6Ly9hdXRoLmVkaXJlcG9zaXRvcnkub3JnIiwiaGQiOiJlZGlyZXBvc2l0b3J5Lm9yZyIsImlhdCI6MTc2NzkwNjM5NSwibmJmIjoxNzY3OTA2Mzk1LCJleHAiOjE3Njc5MzUxOTV9.hcA2FrftlkjaxKQex5x-hIZBr9XUy-dy9bgvbU4Ts1rXQXjd7F5RjPPVhYj0Tn_qfX8VHDTXiRpf7o9fyAKRLQ; + HttpOnly; Max-Age=0; Path=/; SameSite=lax + transfer-encoding: chunked web-service: DataPackageManager-1.0 body: - encoding: UTF-8 - file: no string: |- - edi.948.1 - edi.949.1 - recorded_at: 2022-01-18 20:41:41 GMT - recorded_with: vcr/1.0.2, webmockr/0.8.0 + edi.12.1 + edi.13.1 + edi.14.1 + edi.17.1 + edi.18.1 + edi.19.1 + edi.20.1 + edi.21.1 + edi.22.1 + edi.23.1 + edi.24.1 + edi.25.1 + edi.26.1 + edi.27.1 + edi.28.1 + edi.29.1 + edi.30.1 + edi.31.1 + edi.32.1 + edi.33.1 + edi.34.1 + edi.35.1 + edi.36.1 + edi.37.1 + edi.38.1 + edi.39.1 + edi.40.1 + edi.41.1 + edi.42.1 + edi.43.1 + edi.44.1 + edi.45.1 + edi.46.1 + edi.47.1 + edi.48.1 + edi.49.1 + edi.50.1 + edi.51.1 + edi.52.1 + edi.53.1 + edi.54.1 + edi.55.1 + edi.56.1 + edi.56.2 + edi.57.1 + edi.57.2 + edi.58.1 + edi.59.1 + edi.60.1 + edi.61.1 + edi.62.1 + edi.63.3 + edi.64.1 + edi.65.1 + edi.66.1 + edi.67.1 + edi.68.1 + edi.69.2 + edi.70.1 + edi.71.1 + edi.72.1 + edi.73.1 + edi.74.1 + edi.75.1 + edi.76.1 + edi.77.1 + edi.78.1 + edi.79.1 + edi.80.1 + edi.81.1 + edi.82.1 + edi.83.1 + edi.84.1 + edi.85.1 + edi.86.2 + edi.87.1 + edi.88.1 + edi.89.1 + edi.90.1 + edi.91.1 + edi.92.1 + edi.93.1 + edi.94.1 + edi.95.1 + edi.96.1 + edi.97.1 + edi.98.1 + edi.98.2 + edi.98.3 + edi.99.3 + edi.99.4 + edi.99.5 + edi.100.1 + edi.100.4 + edi.102.1 + edi.103.1 + edi.104.1 + edi.105.1 + edi.106.1 + edi.107.1 + edi.108.1 + edi.115.1 + edi.116.1 + edi.121.1 + edi.122.1 + edi.181.1 + edi.181.2 + edi.187.1 + edi.191.1 + edi.191.2 + edi.191.3 + edi.192.1 + edi.192.2 + edi.192.3 + edi.193.1 + edi.193.2 + edi.193.3 + edi.193.4 + edi.193.5 + edi.194.1 + edi.247.1 + edi.247.2 + edi.248.1 + edi.251.1 + edi.252.1 + edi.253.1 + edi.253.2 + edi.254.1 + edi.255.1 + edi.261.1 + edi.262.1 + edi.263.1 + edi.264.1 + edi.273.1 + edi.274.1 + edi.275.1 + edi.275.2 + edi.275.3 + edi.275.4 + edi.275.5 + edi.276.1 + edi.276.2 + edi.277.1 + edi.278.1 + edi.279.1 + edi.280.1 + edi.281.1 + edi.282.1 + edi.283.1 + edi.283.2 + edi.319.1 + edi.320.1 + edi.321.1 + edi.322.1 + edi.323.1 + edi.324.1 + edi.325.1 + edi.326.1 + edi.327.1 + edi.328.1 + edi.329.1 + edi.330.1 + edi.331.1 + edi.332.1 + edi.332.2 + edi.333.1 + edi.334.1 + edi.335.1 + edi.336.1 + edi.337.1 + edi.338.1 + edi.339.1 + edi.340.1 + edi.341.1 + edi.342.1 + edi.343.1 + edi.344.1 + edi.345.1 + edi.346.1 + edi.347.1 + edi.348.1 + edi.349.1 + edi.350.1 + edi.351.1 + edi.352.1 + edi.353.1 + edi.354.1 + edi.355.1 + edi.356.1 + edi.357.1 + edi.359.1 + edi.359.2 + edi.362.1 + edi.363.1 + edi.364.1 + edi.365.1 + edi.366.1 + edi.367.1 + edi.368.1 + edi.369.1 + edi.370.1 + edi.371.1 + edi.372.1 + edi.373.1 + edi.378.1 + edi.379.1 + edi.386.1 + edi.388.1 + edi.388.2 + edi.388.3 + edi.404.1 + edi.417.1 + edi.421.1 + edi.435.1 + edi.442.1 + edi.443.1 + edi.443.2 + edi.444.1 + edi.457.1 + edi.458.1 + edi.458.2 + edi.458.3 + edi.458.4 + edi.460.1 + edi.468.1 + edi.468.2 + edi.471.1 + edi.472.1 + edi.473.1 + edi.474.1 + edi.475.1 + edi.476.1 + edi.477.1 + edi.478.1 + edi.479.1 + edi.480.1 + edi.494.1 + edi.494.2 + edi.502.1 + edi.509.1 + edi.513.1 + edi.520.1 + edi.527.1 + edi.585.1 + edi.587.1 + edi.591.1 + edi.591.2 + edi.600.1 + edi.615.1 + edi.616.1 + edi.628.1 + edi.637.1 + edi.644.1 + edi.682.1 + edi.682.2 + edi.694.1 + edi.695.1 + edi.696.1 + edi.699.1 + edi.704.1 + edi.710.1 + edi.714.1 + edi.715.1 + edi.724.1 + edi.735.1 + edi.735.2 + edi.738.1 + edi.739.1 + edi.739.2 + edi.742.1 + edi.752.1 + edi.752.2 + edi.753.1 + edi.754.1 + edi.759.1 + edi.759.2 + edi.759.3 + edi.759.4 + edi.759.5 + edi.820.1 + edi.821.1 + edi.829.1 + edi.831.1 + edi.834.1 + edi.834.2 + edi.838.1 + edi.842.1 + edi.845.1 + edi.846.1 + edi.858.1 + edi.860.1 + edi.863.1 + edi.873.1 + edi.876.1 + edi.877.1 + edi.882.1 + edi.889.1 + edi.973.1 + edi.984.1 + edi.1001.1 + edi.1031.1 + edi.1044.1 + edi.1063.1 + edi.1089.1 + edi.1107.1 + edi.1117.1 + edi.1118.1 + edi.1142.1 + edi.1155.1 + edi.1160.1 + edi.1161.1 + edi.1162.1 + edi.1164.1 + edi.1191.1 + edi.1204.1 + edi.1205.1 + edi.1206.1 + edi.1210.1 + edi.1212.1 + edi.1216.1 + edi.1218.1 + edi.1220.1 + edi.1261.1 + edi.1283.1 + edi.1341.1 + edi.1342.1 + edi.1342.2 + edi.1355.1 + edi.1363.1 + edi.1371.1 + edi.1410.1 + edi.1427.1 + edi.1436.1 + edi.1514.1 + edi.1519.1 + edi.1520.1 + edi.1553.1 + edi.1614.1 + edi.1621.1 + edi.1686.1 + edi.1687.1 + edi.1688.1 + edi.1689.1 + edi.1691.1 + edi.1692.1 + edi.1693.1 + edi.1694.1 + edi.1695.1 + edi.1698.1 + edi.1699.1 + edi.1783.1 + knb-lter-ntl.419.1 + recorded_at: 2026-01-08 21:06:35 +recorded_with: VCR-vcr/2.1.0 diff --git a/tests/fixtures/query_event_subscriptions.yml b/tests/fixtures/query_event_subscriptions.yml index 34632856..3b115b21 100644 --- a/tests/fixtures/query_event_subscriptions.yml +++ b/tests/fixtures/query_event_subscriptions.yml @@ -1,35 +1,30 @@ http_interactions: - request: - method: get - uri: https://pasta-s.lternet.edu/package/event/eml?scope=edi - body: - encoding: '' - string: '' - headers: - Accept: application/json, text/xml, application/xml, */* + method: GET + uri: https://pasta.lternet.edu/package/event/eml?scope=edi response: - status: - status_code: 200 - category: Success - reason: OK - message: 'Success: (200) OK' + status: 200 headers: - server: nginx/1.14.0 (Ubuntu) - date: Tue, 18 Jan 2022 23:11:43 GMT - content-type: application/xml - content-length: '852' + access-control-allow-origin: '*' connection: keep-alive + content-type: application/xml + date: Thu, 08 Jan 2026 21:49:51 GMT + server: nginx/1.18.0 (Ubuntu) + set-cookie: + - auth-token="dWlkPWNzbWl0aCxvPUVESSxkYz1lZGlyZXBvc2l0b3J5LGRjPW9yZypodHRwczovL3Bhc3RhLmVkaXJlcG9zaXRvcnkub3JnL2F1dGhlbnRpY2F0aW9uKjE3Njc5Mzc3OTE4NjgqdmV0dGVkKmF1dGhlbnRpY2F0ZWQ=-egmbjL7OXJS3vzSsT/Cl6fUo/8GTn4AxZQEJnA5Gk0ssFpMRyQ0D4AdlBJ0L573eRq9myPQN0iyH0r3B+rOar5+iRW7QWbm79jKymx2ALGRlAouMD7FrcqV/ouVHEw3568UniqMlcSgMr2YLwZr1iWsbUP3Ls8vi8VK52uJxAlgh/HheSA/39O7vBh7qPvuC5bSC1MN0YuBCpb76vmYu5BCIAQbifdmSOFlT7/j5Hex4xleoHh7hpN9f1edWJhzJwshT6R+bXbXJb71tdppT3NQ3r7e85qjSfqhblmEnZS4t5RPCJO4fFN8BVGKNAqNFfi//zc+Ne7EfXjYuC0X72Q=="; + HttpOnly; Path=/; SameSite=lax + - edi-token=eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJFREktNTQzYWZhODBjODU5ODI1ZDM1ZDM3ZDkxMTFjMjRhNGE2NWEwZGI5ZiIsImNuIjoiY3NtaXRoIiwiZW1haWwiOm51bGwsInByaW5jaXBhbHMiOlsiRURJLTA3OGU2ZTNjZWU0ZjdmMjgxMmYxNTA3MDFkYTkzNTFhY2I1MWUwODkiLCJFREktN2JlMzUxMGQwOGRlZjBkZmM2Njc4MjRlYmQ0ZjRmMWJiZDc3MDIzNCIsIkVESS1iZGFlNzQ5NzJlZDcxMGM1NmIxZTBkZjE4Y2NiNmUyM2MzMWY2MGY2Il0sImxpbmtzIjpbXSwiaXNFbWFpbEVuYWJsZWQiOmZhbHNlLCJpc0VtYWlsVmVyaWZpZWQiOmZhbHNlLCJpZHBDb21tb25OYW1lIjoiY3NtaXRoIiwiaWRwTmFtZSI6ImxkYXAiLCJpZHBVaWQiOiJ1aWQ9Y3NtaXRoLG89RURJLGRjPWVkaXJlcG9zaXRvcnksZGM9b3JnIiwiaXNzIjoiaHR0cHM6Ly9hdXRoLmVkaXJlcG9zaXRvcnkub3JnIiwiaGQiOiJlZGlyZXBvc2l0b3J5Lm9yZyIsImlhdCI6MTc2NzkwODk3NSwibmJmIjoxNzY3OTA4OTc1LCJleHAiOjE3Njc5Mzc3NzV9.k4J7EwZ-9B73ZEg0yZ7_3Qp_aVDaTgJnKg0sggRlLsq-GFxurm16qPnjSw0VTUBNdIn6bCw4kz58ayU92wzzBg; + HttpOnly; Path=/; SameSite=lax + transfer-encoding: chunked body: - encoding: UTF-8 - file: no string: | - 97 - uid=ediutils,o=EDI,dc=edirepository,dc=org - edi.3.1 - https://some.server.org + 43 + EDI-543afa80c859825d35d37d9111c24a4a65a0db9f + edi.2241 + https://myendpoint/location - recorded_at: 2022-01-18 23:11:43 GMT - recorded_with: vcr/1.0.2, webmockr/0.8.0 + recorded_at: 2026-01-08 21:49:51 +recorded_with: VCR-vcr/2.1.0 diff --git a/tests/testthat/_vcr/list_principal_owner_citations.yml b/tests/testthat/_vcr/list_principal_owner_citations.yml new file mode 100644 index 00000000..ecd49397 --- /dev/null +++ b/tests/testthat/_vcr/list_principal_owner_citations.yml @@ -0,0 +1,26 @@ +http_interactions: +- request: + method: GET + uri: https://pasta.lternet.edu/package/citations/eml/uid=csmith,o=EDI,dc=edirepository,dc=org + response: + status: 200 + headers: + access-control-allow-origin: '*' + connection: keep-alive + content-type: application/xml + date: Thu, 08 Jan 2026 16:19:37 GMT + server: nginx/1.18.0 (Ubuntu) + set-cookie: + - auth-token="cHVibGljKmh0dHBzOi8vcGFzdGEuZWRpcmVwb3NpdG9yeS5vcmcvYXV0aGVudGljYXRpb24qMTc2NzkxNzk3NzI3Ng==-GvQ0q4LQ4UQS0OprHA9oPz06gQIm5cc7B5uOkjYgM2n6kLKKzj52bva5hy2Rca9wst56YywawHVqiFuRaLAKIxeZcOJIt5kk4o1ahly3R+Jp3Ps89Oh56pvHoN2srtY86UnAsMh0NM+J1+LZCoQ5lSBhRP2VggfWsT1Nf5Eh0yNLZ3WhcbYqNjg7LT3DApotSODJbxDJVyNq70KPvz606vRGsMXDgiYsmEvMNUdUJuLOAqgbYnIEHQ+ondlXcB1PMLO5nacJCwMDHIJexS6nX62JXOJ8Cq4xhB597ZpGZ+o6S5E+rbelLFNXPvKBKf8bAoGEXb8voGtOOR7k4taQSQ=="; + HttpOnly; Max-Age=0; Path=/; SameSite=lax + - edi-token=eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJFREktMDc4ZTZlM2NlZTRmN2YyODEyZjE1MDcwMWRhOTM1MWFjYjUxZTA4OSIsImNuIjoiUHVibGljIEFjY2VzcyIsImVtYWlsIjpudWxsLCJwcmluY2lwYWxzIjpbXSwibGlua3MiOltdLCJpc0VtYWlsRW5hYmxlZCI6ZmFsc2UsImlzRW1haWxWZXJpZmllZCI6ZmFsc2UsImlkcENvbW1vbk5hbWUiOiJQdWJsaWMgQWNjZXNzIiwiaWRwTmFtZSI6InN5c3RlbSIsImlkcFVpZCI6bnVsbCwiaXNzIjoiaHR0cHM6Ly9hdXRoLmVkaXJlcG9zaXRvcnkub3JnIiwiaGQiOiJlZGlyZXBvc2l0b3J5Lm9yZyIsImlhdCI6MTc2Nzg4OTE3NywibmJmIjoxNzY3ODg5MTc3LCJleHAiOjE3Njc5MTc5Nzd9.Sz2cKqUnH2kPGCyRYPznZvgZBgpkpCxFi4nUzQ-ppHtnxr9tzAZl1KeA6fxFsVXvkMF-nHM0nl01bIpKTWmxFg; + HttpOnly; Max-Age=0; Path=/; SameSite=lax + transfer-encoding: chunked + web-service: DataPackageManager-1.0 + body: + string: |- + + + + recorded_at: 2026-01-08 16:19:37 +recorded_with: VCR-vcr/2.1.0 diff --git a/tests/testthat/_vcr/list_user_data_packages.yml b/tests/testthat/_vcr/list_user_data_packages.yml new file mode 100644 index 00000000..5e733e8f --- /dev/null +++ b/tests/testthat/_vcr/list_user_data_packages.yml @@ -0,0 +1,23 @@ +http_interactions: +- request: + method: GET + uri: https://pasta.lternet.edu/package/user/uid=csmith,o=EDI,dc=edirepository,dc=org + response: + status: 200 + headers: + access-control-allow-origin: '*' + connection: keep-alive + content-length: '0' + content-type: text/plain + date: Thu, 08 Jan 2026 16:29:38 GMT + server: nginx/1.18.0 (Ubuntu) + set-cookie: + - auth-token="cHVibGljKmh0dHBzOi8vcGFzdGEuZWRpcmVwb3NpdG9yeS5vcmcvYXV0aGVudGljYXRpb24qMTc2NzkxODU3NzkzMw==-OuSaqNFKISRTg1tGjuNkq1wKCy/A5d6t8rVkbEvfvWV/bwCpUhiK3iKwCkXRqBWhFUT87H2WykPq21GuKeitPjHdd1Jk+nUNblOhRCFtz5FuScloAgMKE8MbtWErAT5Xomc/GNwor/n9Dm6XGdisusAREEGyA/uZooA5d009n/AYdppWeUSC/wFDpk0FOdnf1JNSXb7eMeEpGA9PngBl754arBYXybsT1qETUkbP++ceKmwsNsYh8AYR3OfGn/aub90jQxxcAokbCOnwePgwMktVuoaoc3v63o7O63lsOtd+2WFC1Xemu5pol0gaBYOtj1tlwzlrrhk49mIB8XoA3g=="; + HttpOnly; Max-Age=0; Path=/; SameSite=lax + - edi-token=eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJFREktMDc4ZTZlM2NlZTRmN2YyODEyZjE1MDcwMWRhOTM1MWFjYjUxZTA4OSIsImNuIjoiUHVibGljIEFjY2VzcyIsImVtYWlsIjpudWxsLCJwcmluY2lwYWxzIjpbXSwibGlua3MiOltdLCJpc0VtYWlsRW5hYmxlZCI6ZmFsc2UsImlzRW1haWxWZXJpZmllZCI6ZmFsc2UsImlkcENvbW1vbk5hbWUiOiJQdWJsaWMgQWNjZXNzIiwiaWRwTmFtZSI6InN5c3RlbSIsImlkcFVpZCI6bnVsbCwiaXNzIjoiaHR0cHM6Ly9hdXRoLmVkaXJlcG9zaXRvcnkub3JnIiwiaGQiOiJlZGlyZXBvc2l0b3J5Lm9yZyIsImlhdCI6MTc2Nzg4OTc3NywibmJmIjoxNzY3ODg5Nzc3LCJleHAiOjE3Njc5MTg1Nzd9.N-g1qJ-ZQdZnsHLlP-42o3eGsCVnkaTngtqgnFTek4ZXmuSN7opV5CewxWDmoQ7IaFlOqhPgkbjMSk5-XZ_a5g; + HttpOnly; Max-Age=0; Path=/; SameSite=lax + web-service: DataPackageManager-1.0 + body: + string: '' + recorded_at: 2026-01-08 16:29:38 +recorded_with: VCR-vcr/2.1.0 diff --git a/tests/testthat/test_create_data_package.R b/tests/testthat/test_create_data_package.R index 9665a725..a6cc11cb 100644 --- a/tests/testthat/test_create_data_package.R +++ b/tests/testthat/test_create_data_package.R @@ -6,7 +6,8 @@ testthat::test_that("Test attributes of returned object", { # Create data package identifier <- create_reservation(scope = "edi", env = "staging") packageId <- paste0("edi.", identifier, ".1") - eml <- create_test_eml(path = tempdir(), packageId = packageId) + eml <- create_test_eml(path = tempdir(), packageId = packageId, + edi_id = "EDI-543afa80c859825d35d37d9111c24a4a65a0db9f") on.exit(file.remove(eml), add = TRUE, after = FALSE) transaction <- create_data_package(eml, env = "staging") # Check creation status diff --git a/tests/testthat/test_create_dn.R b/tests/testthat/test_create_dn.R deleted file mode 100644 index a72c0124..00000000 --- a/tests/testthat/test_create_dn.R +++ /dev/null @@ -1,14 +0,0 @@ -context("Create distinguished name") - -testthat::test_that("Test attributes of returned object", { - # Create distinguished name within EDI organizational unit - userId <- "my_userid" - ou <- "EDI" - dn <- create_dn(userId, ou) - expect_true(grepl("edirepository", dn)) - # Create distinguished name within LTER organizational unit - userId <- "my_userid" - ou <- "LTER" - dn <- create_dn(userId, ou) - expect_true(grepl("ecoinformatics", dn)) -}) diff --git a/tests/testthat/test_evaluate_data_package.R b/tests/testthat/test_evaluate_data_package.R index 99521d42..08200ad1 100644 --- a/tests/testthat/test_evaluate_data_package.R +++ b/tests/testthat/test_evaluate_data_package.R @@ -6,7 +6,8 @@ testthat::test_that("Test attributes of returned object", { # Create data package for evaluation identifier <- create_reservation(scope = "edi", env = "staging") packageId <- paste0("edi.", identifier, ".1") - eml <- create_test_eml(path = tempdir(), packageId = packageId) + eml <- create_test_eml(path = tempdir(), packageId = packageId, + edi_id = "EDI-543afa80c859825d35d37d9111c24a4a65a0db9f") on.exit(file.remove(eml), add = TRUE, after = FALSE) # Evaluate transaction <- evaluate_data_package(eml, env = "staging") diff --git a/tests/testthat/test_list_principal_owner_citations.R b/tests/testthat/test_list_principal_owner_citations.R index 20183f09..0b7f33bb 100644 --- a/tests/testthat/test_list_principal_owner_citations.R +++ b/tests/testthat/test_list_principal_owner_citations.R @@ -2,15 +2,17 @@ context("List principal owner citations") testthat::test_that("list_principal_owner_citations() works", { vcr::use_cassette("list_principal_owner_citations", { - principalOwner <- create_dn("csmith") + principalOwner <- "EDI-543afa80c859825d35d37d9111c24a4a65a0db9f" res <- list_principal_owner_citations(principalOwner, as = "xml") }) expect_true(all(class(res) %in% c("xml_document", "xml_node"))) expect_true("journalCitation" %in% xml2::xml_name(xml2::xml_children(res))) children_found <- xml2::xml_name( xml2::xml_children(xml2::xml_children(res)[1])) - children_expected <- c("journalCitationId", "packageId", "principalOwner", + children_expected <- c("journalCitationId", "packageId", "principalOwner", "dateCreated", "articleDoi", "articleTitle", - "articleUrl", "journalTitle", "relationType") + "articleUrl", "journalTitle", "relationType", + "pubDate", "journalIssue", "journalVolume", + "articlePages", "articleAuthors") expect_true(all(children_found %in% children_expected)) }) diff --git a/tests/testthat/test_list_user_data_packages.R b/tests/testthat/test_list_user_data_packages.R index a1e66f4b..ca8c307c 100644 --- a/tests/testthat/test_list_user_data_packages.R +++ b/tests/testthat/test_list_user_data_packages.R @@ -2,7 +2,7 @@ context("List user data packages") testthat::test_that("list_user_data_packages() works", { vcr::use_cassette("list_user_data_packages", { - res <- list_user_data_packages(create_dn("dbjourneynorth", "EDI")) + res <- list_user_data_packages(edi_id = "EDI-543afa80c859825d35d37d9111c24a4a65a0db9f") }) expect_equal(class(res), "character") expect_true(length(res) > 0) diff --git a/tests/testthat/test_query_event_subscriptions.R b/tests/testthat/test_query_event_subscriptions.R index 53053297..c0646b02 100644 --- a/tests/testthat/test_query_event_subscriptions.R +++ b/tests/testthat/test_query_event_subscriptions.R @@ -2,7 +2,7 @@ context("Query event subscriptions") testthat::test_that("query_event_subscriptions() works", { vcr::use_cassette("query_event_subscriptions", { - res <- query_event_subscriptions("scope=edi", as = "xml", env = "staging") + res <- query_event_subscriptions("scope=edi", as = "xml", env = "production") }) expect_true(all(class(res) %in% c("xml_document", "xml_node"))) expect_true("subscription" %in% xml2::xml_name(xml2::xml_children(res))) diff --git a/tests/testthat/test_update_data_package.R b/tests/testthat/test_update_data_package.R index 50aee33c..03cf2ff1 100644 --- a/tests/testthat/test_update_data_package.R +++ b/tests/testthat/test_update_data_package.R @@ -6,13 +6,15 @@ testthat::test_that("Test attributes of returned object", { # Create new data packaging identifier <- create_reservation(scope = "edi", env = "staging") packageId <- paste0("edi.", identifier, ".1") - eml <- create_test_eml(path = tempdir(), packageId = packageId) + eml <- create_test_eml(path = tempdir(), packageId = packageId, + edi_id = "EDI-543afa80c859825d35d37d9111c24a4a65a0db9f") on.exit(file.remove(eml), add = TRUE, after = FALSE) transaction <- create_data_package(eml, env = "staging") res <- check_status_create(transaction, env = "staging") # Update data package packageId <- paste0("edi.", identifier, ".2") - eml <- create_test_eml(path = tempdir(), packageId = packageId) + eml <- create_test_eml(path = tempdir(), packageId = packageId, + edi_id = "EDI-543afa80c859825d35d37d9111c24a4a65a0db9f") transaction <- update_data_package(eml, env = "staging") res <- check_status_update(transaction, env = "staging") expect_true(res) diff --git a/tests/testthat/test_utilities.R b/tests/testthat/test_utilities.R index fa8acfe3..afa6d59a 100644 --- a/tests/testthat/test_utilities.R +++ b/tests/testthat/test_utilities.R @@ -49,7 +49,11 @@ testthat::test_that("bake_cookie() works", { testthat::test_that("create_test_eml() works", { - path <- create_test_eml(tempdir(), "edi.1.1") + path <- create_test_eml( + tempdir(), + "edi.1.1", + edi_id = "EDI-543afa80c859825d35d37d9111c24a4a65a0db9f" + ) expect_true(file.exists(path)) }) diff --git a/vignettes/tests_requiring_authentication.Rmd b/vignettes/tests_requiring_authentication.Rmd index ddad759a..f422c83a 100644 --- a/vignettes/tests_requiring_authentication.Rmd +++ b/vignettes/tests_requiring_authentication.Rmd @@ -68,7 +68,10 @@ testthat::test_that("Test attributes of returned object", { # Create data package for evaluation identifier <- create_reservation(scope = "edi", env = "staging") packageId <- paste0("edi.", identifier, ".1") - eml <- create_test_eml(path = tempdir(), packageId = packageId) + eml <- create_test_eml( + path = tempdir(), + packageId = packageId, + edi_id = "EDI-543afa80c859825d35d37d9111c24a4a65a0ff3e") on.exit(file.remove(eml), add = TRUE, after = FALSE) # Evaluate transaction <- evaluate_data_package(eml, env = "staging") From 2b88e50871d5fb0dbe0be963f80f3675130bf8c3 Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Fri, 9 Jan 2026 11:09:49 -0500 Subject: [PATCH 10/11] Migrate IAM authentication from DN to EDI ID - Mark `create_dn()` as defunct following IAM system upgrade. - Update `list_principal_owner_citations()` and `list_user_data_packages()` to require EDI ID instead of Distinguished Name (DN). - Update documentation with instructions on retrieving EDI ID from the Identity and Access Manager portal. Closes #65 --- DESCRIPTION | 2 +- NEWS.md | 11 ++++++++--- R/create_dn.R | 8 +++----- R/list_principal_owner_citations.R | 7 +++---- R/list_user_data_packages.R | 9 ++++----- R/utilities.R | 7 +++---- codemeta.json | 4 ++-- man/create_dn.Rd | 8 +++----- man/list_principal_owner_citations.Rd | 7 +++---- man/list_user_data_packages.Rd | 9 ++++----- 10 files changed, 34 insertions(+), 38 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 1bddbe23..d6274413 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: EDIutils Title: An API Client for the Environmental Data Initiative Repository -Version: 1.1.0 +Version: 2.0.0 Authors@R: c(person("Colin", "Smith", email = "colin.smith@wisc.edu", role = c("aut", "cre"), comment = "0000-0003-2261-9931"), person("Corinna", "Gries", role = "ctb", comment = "0000-0002-9091-6543"), diff --git a/NEWS.md b/NEWS.md index 96436b8d..d7f2694c 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,13 +1,18 @@ -EDIutils 1.1.0 (2026-01-06) +EDIutils 2.2.0 (2026-01-09) =========================== -### DEPRECATED +### DEPRECATED AND DEFUNCT * Deprecate `get_audit_report()` in favor of `get_audit_csv_report()` (#62) + * Defunct `create_dn()`. This introduces a breaking change for + `list_principal_owner_citations()` and `list_user_data_packages()`, + which now require an EDI-ID instead of a Distinguished Name (DN). Users can + obtain their EDI-ID by logging into the + [EDI Identity and Access Manager](https://auth.edirepository.org/auth/ui/signin) + and copying the "EDI-ID" from their profile home page. (#65) ### MINOR IMPROVEMENTS * Update authentication to support new EDI IAM system (#60) - * Update tests to handle new fields from various API methods EDIutils 1.0.3 (2023-10-10) =========================== diff --git a/R/create_dn.R b/R/create_dn.R index 2e694c9b..6717949e 100644 --- a/R/create_dn.R +++ b/R/create_dn.R @@ -1,10 +1,8 @@ #' Create a users distinguished name (defunct) #' -#' This function is defunct. Distinguished names are no longer used in EDI -#' authentication. Use an EDI ID token instead. This ID can be obtained by -#' logging into the EDI Identity and Access -#' Manager (\url{https://auth.edirepository.org/auth/ui/signin}) and -#' copying the "EDI-ID" string from your profile home page. +#' This function is defunct. Distinguished names are deprecated in favor of EDI +#' IDs. An EDI ID can be obtained from the EDI Identity and Access +#' Manager (\url{https://auth.edirepository.org/auth/ui/signin}). #' #' @param userId (character) User identifier of an EDI data repository account #' @param ou (character) Organizational unit in which \code{userId} belongs. diff --git a/R/list_principal_owner_citations.R b/R/list_principal_owner_citations.R index 824224fb..aca05f78 100644 --- a/R/list_principal_owner_citations.R +++ b/R/list_principal_owner_citations.R @@ -1,9 +1,8 @@ #' List principal owner citations #' -#' @param principalOwner (character) The EDI-ID of the principal owner. -#' This ID can be obtained by logging into the EDI Identity and Access -#' Manager (\url{https://auth.edirepository.org/auth/ui/signin}) and -#' copying the "EDI-ID" string from your profile home page. +#' @param principalOwner (character) The EDI ID of the principal owner. +#' EDI IDs can be obtained from the EDI Identity and Access +#' Manager (\url{https://auth.edirepository.org/auth/ui/signin}). #' @param as (character) Format of the returned object. Can be: "data.frame" #' or "xml". #' @param env (character) Repository environment. Can be: "production", diff --git a/R/list_user_data_packages.R b/R/list_user_data_packages.R index 50ea3a63..9611797a 100644 --- a/R/list_user_data_packages.R +++ b/R/list_user_data_packages.R @@ -5,10 +5,9 @@ #' distinguished name. Data packages that were uploaded by the specified user #' but have since been deleted are excluded from the list. #' -#' @param edi_id (character) The EDI-ID of the user. This ID can be obtained by -#' logging into the EDI Identity and Access Manager -#' (\url{https://auth.edirepository.org/auth/ui/signin}) and copying the -#' "EDI-ID" string from your profile home page. +#' @param edi_id (character) The EDI ID of the user. An EDI ID can be obtained +#' from the EDI Identity and Access Manager +#' (\url{https://auth.edirepository.org/auth/ui/signin}). #' @param env (character) Repository environment. Can be: "production", #' "staging", or "development". #' @@ -24,7 +23,7 @@ #' #' # List user data packages #' edi_id <- "EDI-543afa80c859825d35d37d9111c24a4a65a0ff9e" -#' packageIds <- list_user_data_packages(edi_id = edi_id) +#' packageIds <- list_user_data_packages(edi_id) #' packageIds #' #> [1] "edi.948.1" "edi.949.1" #' } diff --git a/R/utilities.R b/R/utilities.R index 62300270..3636b1fe 100644 --- a/R/utilities.R +++ b/R/utilities.R @@ -123,10 +123,9 @@ config_test_eml <- function(userId, url) { #' written to file #' @param packageId (character) Package identifier, of the form #' "scope.identifier.revision", for the new EML file -#' @param edi_id (character) The EDI-ID of the user. This ID can be obtained by -#' logging into the EDI Identity and Access Manager -#' (\url{https://auth.edirepository.org/auth/ui/signin}) and copying the -#' "EDI-ID" string from your profile home page. +#' @param edi_id (character) The EDI ID of the user creating the test EML. +#' An EDI ID can be obtained from the EDI Identity and Access +#' Manager (\url{https://auth.edirepository.org/auth/ui/signin}). #' #' @return (character) Full path to EML file written by this function to #' \code{path}. Should be \code{tempdir()} if executed in a testthat context. diff --git a/codemeta.json b/codemeta.json index afef49c5..d92c3c6a 100644 --- a/codemeta.json +++ b/codemeta.json @@ -8,7 +8,7 @@ "codeRepository": "https://github.com/ropensci/EDIutils", "issueTracker": "https://github.com/ropensci/EDIutils/issues", "license": "https://spdx.org/licenses/MIT", - "version": "1.1.0", + "version": "2.0.0", "programmingLanguage": { "@type": "ComputerLanguage", "name": "R", @@ -174,7 +174,7 @@ }, "SystemRequirements": null }, - "fileSize": "662.381KB", + "fileSize": "757.246KB", "citation": [ { "@type": "SoftwareSourceCode", diff --git a/man/create_dn.Rd b/man/create_dn.Rd index 5d2fd258..024b52e2 100644 --- a/man/create_dn.Rd +++ b/man/create_dn.Rd @@ -17,11 +17,9 @@ Can be "EDI" or "LTER". All \code{userId} issued after "2020-05-01" have (character) Distinguished name } \description{ -This function is defunct. Distinguished names are no longer used in EDI -authentication. Use an EDI ID token instead. This ID can be obtained by -logging into the EDI Identity and Access -Manager (\url{https://auth.edirepository.org/auth/ui/signin}) and -copying the "EDI-ID" string from your profile home page. +This function is defunct. Distinguished names are deprecated in favor of EDI +IDs. An EDI ID can be obtained from the EDI Identity and Access +Manager (\url{https://auth.edirepository.org/auth/ui/signin}). } \examples{ # For an EDI account diff --git a/man/list_principal_owner_citations.Rd b/man/list_principal_owner_citations.Rd index fb72bf00..83802290 100644 --- a/man/list_principal_owner_citations.Rd +++ b/man/list_principal_owner_citations.Rd @@ -11,10 +11,9 @@ list_principal_owner_citations( ) } \arguments{ -\item{principalOwner}{(character) The EDI-ID of the principal owner. -This ID can be obtained by logging into the EDI Identity and Access -Manager (\url{https://auth.edirepository.org/auth/ui/signin}) and -copying the "EDI-ID" string from your profile home page.} +\item{principalOwner}{(character) The EDI ID of the principal owner. +EDI IDs can be obtained from the EDI Identity and Access +Manager (\url{https://auth.edirepository.org/auth/ui/signin}).} \item{as}{(character) Format of the returned object. Can be: "data.frame" or "xml".} diff --git a/man/list_user_data_packages.Rd b/man/list_user_data_packages.Rd index d93bcf7d..93cf9b13 100644 --- a/man/list_user_data_packages.Rd +++ b/man/list_user_data_packages.Rd @@ -7,10 +7,9 @@ list_user_data_packages(edi_id, env = "production") } \arguments{ -\item{edi_id}{(character) The EDI-ID of the user. This ID can be obtained by -logging into the EDI Identity and Access Manager -(\url{https://auth.edirepository.org/auth/ui/signin}) and copying the -"EDI-ID" string from your profile home page.} +\item{edi_id}{(character) The EDI ID of the user. An EDI ID can be obtained +from the EDI Identity and Access Manager +(\url{https://auth.edirepository.org/auth/ui/signin}).} \item{env}{(character) Repository environment. Can be: "production", "staging", or "development".} @@ -30,7 +29,7 @@ but have since been deleted are excluded from the list. # List user data packages edi_id <- "EDI-543afa80c859825d35d37d9111c24a4a65a0ff9e" -packageIds <- list_user_data_packages(edi_id = edi_id) +packageIds <- list_user_data_packages(edi_id) packageIds #> [1] "edi.948.1" "edi.949.1" } From f289d3b7f00727259134b913016dcb2b95fef842 Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Fri, 9 Jan 2026 12:34:18 -0500 Subject: [PATCH 11/11] Update release candidate * Don't run defunct function examples * Update docs and package artifacts * Update cran comments --- R/create_dn.R | 2 ++ codemeta.json | 2 +- cran-comments.md | 18 ++++++++++++++---- man/create_dn.Rd | 2 ++ 4 files changed, 19 insertions(+), 5 deletions(-) diff --git a/R/create_dn.R b/R/create_dn.R index 6717949e..5d508126 100644 --- a/R/create_dn.R +++ b/R/create_dn.R @@ -16,6 +16,7 @@ #' @export #' #' @examples +#' \dontrun{ #' # For an EDI account #' dn <- create_dn(userId = "my_userid", ou = "EDI") #' dn @@ -23,6 +24,7 @@ #' # For an LTER account #' dn <- create_dn(userId = "my_userid", ou = "LTER") #' dn +#' } create_dn <- function(userId, ou = "EDI") { .Defunct(msg = "'create_dn()' is defunct. Distinguished names are no longer used in EDI authentication. Use an EDI ID token instead.") diff --git a/codemeta.json b/codemeta.json index d92c3c6a..fc8cebfe 100644 --- a/codemeta.json +++ b/codemeta.json @@ -174,7 +174,7 @@ }, "SystemRequirements": null }, - "fileSize": "757.246KB", + "fileSize": "757.276KB", "citation": [ { "@type": "SoftwareSourceCode", diff --git a/cran-comments.md b/cran-comments.md index baef4fa9..a4a26f72 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,7 +1,17 @@ -## Revision -This release updates authentication methods to use the NEW EDI Identity and -Access Management (IAM) system and deprecates a function. These changes maintain -backward compatibility. +## Release Summary +This significant EDIutils release, version 2.0.0, implements a fundamental +update to the authentication method, as we have transitioned to the +**NEW EDI Identity and Access Management (IAM) system**. This change introduces +backwards incompatibility with previous package versions for a few functions. +To continue using EDI services, users must now create an IAM account and +generate API tokens for authentication. Detailed instructions for setting up +IAM accounts and generating tokens are available in the relevant sections of the +documentation. + +These changes are necessary to ensure the long-term stability and +maintainability of the package. We have incremented the **MAJOR** version number +(following SemVer principles) to clearly indicate these incompatible API +changes. ## Test environments diff --git a/man/create_dn.Rd b/man/create_dn.Rd index 024b52e2..ece5a7fe 100644 --- a/man/create_dn.Rd +++ b/man/create_dn.Rd @@ -22,6 +22,7 @@ IDs. An EDI ID can be obtained from the EDI Identity and Access Manager (\url{https://auth.edirepository.org/auth/ui/signin}). } \examples{ +\dontrun{ # For an EDI account dn <- create_dn(userId = "my_userid", ou = "EDI") dn @@ -30,6 +31,7 @@ dn dn <- create_dn(userId = "my_userid", ou = "LTER") dn } +} \seealso{ Other Miscellaneous: \code{\link{create_data_package_archive}()},