Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API v4 #58

Closed
michitobler opened this issue Sep 19, 2024 · 4 comments · Fixed by #57
Closed

API v4 #58

michitobler opened this issue Sep 19, 2024 · 4 comments · Fixed by #57

Comments

@michitobler
Copy link

michitobler commented Sep 19, 2024

Hi
IUCN has switched from API v3 to API v4 (https://api.iucnredlist.org/). I keep getting an error in R (Token not valid!). I reached out to IUCN, and they mentioned that everything seems to be correct on their end. They suggested reaching out to you as the package developer. Is there a reason to assume that the switch to API v4 somehow interferes with how the package runs?

Session Info

R version 4.4.1 (2024-06-14)
Platform: x86_64-apple-darwin20
Running under: macOS Sonoma 14.6.1

Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.4-x86_64/Resources/lib/libRlapack.dylib; LAPACK version 3.12.0

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

time zone: America/Chicago
tzcode source: internal

attached base packages:
[1] stats graphics grDevices utils datasets
[6] methods base

other attached packages:
[1] rfishbase_5.0.0 dplyr_1.1.4 rredlist_0.7.1

loaded via a namespace (and not attached):
[1] sass_0.4.9 utf8_1.2.4 generics_0.1.3
[4] stringi_1.8.4 httpcode_0.3.0 digest_0.6.37
[7] magrittr_2.0.3 evaluate_0.24.0 grid_4.4.1
[10] pkgload_1.4.0 blob_1.2.4 fastmap_1.2.0
[13] jsonlite_1.8.8 processx_3.8.4 pkgbuild_1.4.4
[16] crul_1.5.0 DBI_1.2.3 urltools_1.7.3
[19] ps_1.8.0 purrr_1.0.2 fansi_1.0.6
[22] jquerylib_0.1.4 duckdb_1.0.0-2 cli_3.6.3
[25] rlang_1.1.4 triebeard_0.4.1 dbplyr_2.5.0
[28] remotes_2.5.0 withr_3.0.1 cachem_1.1.0
[31] yaml_2.3.10 tools_4.4.1 memoise_2.0.1
[34] curl_5.2.2 vctrs_0.6.5 duckdbfs_0.0.7
[37] R6_2.5.1 lifecycle_1.0.4 stringr_1.5.1
[40] fs_1.6.4 pkgconfig_2.0.3 desc_1.4.3
[43] callr_3.7.6 pillar_1.9.0 bslib_0.8.0
[46] Rcpp_1.0.13 glue_1.7.0 xfun_0.47
[49] tibble_3.2.1 tidyselect_1.2.1 rstudioapi_0.16.0
[52] knitr_1.48 htmltools_0.5.8.1 rmarkdown_2.28
[55] compiler_4.4.1

@willgearty
Copy link
Contributor

It sounds like you haven't supplied a valid API key. See the discussion in #52 and report back if you are still experiencing issues.

@willgearty
Copy link
Contributor

If you are trying to use a key for API version 4, you can use the development version of the rredlist package, although be aware that the functionality has changed quite a bit:

remotes::install_github("ropensci/rredlist@api_v4")

@michitobler
Copy link
Author

michitobler commented Sep 23, 2024 via email

@willgearty
Copy link
Contributor

Great to hear, and thanks for reporting back!

@willgearty willgearty mentioned this issue Sep 23, 2024
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants