View source: R/check_api_access.R
check_api_access | R Documentation |
This function tests whether R can successfully connect to the Finna API by downloading
the OpenAPI specification from https://api.finna.fi/api/v1/?openapi
. It returns
a logical value indicating the accessibility of the API.
check_api_access()
A logical value:
TRUE
: The API is accessible.
FALSE
: The API is not accessible.
## Not run:
# Check if the API is accessible
access <- check_api_access()
if (access) {
message("Finna API is accessible")
} else {
message("Finna API is not accessible")
}
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.