tests/testthat/setup-webchem.R

library("vcr")
invisible(vcr::vcr_configure(
  filter_sensitive_data = list("<<my_api_key>>" = Sys.getenv("CHEMSPIDER_KEY")),
  dir = vcr::vcr_test_path("fixtures")
))

vcr::check_cassette_names()

if (!nzchar(Sys.getenv("CHEMSPIDER_KEY"))) {
  Sys.setenv("CHEMSPIDER_KEY" = "<<my_api_key>>")
}

Try the webchem package in your browser

Any scripts or data that you put into this service are public.

webchem documentation built on July 9, 2023, 5:30 p.m.