The helper function api_url() is used to create urls to InfectX openBIS API endpoints and docs_link() generates latex links to documentation pages. Both functions support the following endpoints which are abbreviated as

api_url(api_endpoint = c("gis", "gics", "qas", "wis", "dsrg", "sas",
  "dsrs"), host_url = "https://infectx.biozentrum.unibas.ch",
  full_url = NULL, ...)

docs_link(api_endpoint = c("gis", "gics", "qas", "wis", "dsrg", "sas",
  "dsrs"), method_name = NULL, version = "13.04.0")

Arguments

api_endpoint

Abbreviated name of the API section (e.g. gis for IGeneralInformationService).

host_url

Host url.

full_url

Instead of constructing the API endpoint url, a string can be passed which will be returned again.

...

Further arguments are ignored.

method_name

Name of the method for which the link is created.

version

OpenBIS version number.

Value

A character vector of length 1.

Details

If for some reason an url is desired from api_url() that cannot be constructed by pasting host_url and one of the hard-coded API endpoints together, this can be passed as full_url, which will simply be returned.

See also

Other utility functions: login_openbis, make_requests

Examples

# default endpoint is the GeneralInformationService interface api_url()
#> [1] "https://infectx.biozentrum.unibas.ch/openbis/openbis/rmi-general-information-v1.json"
# base url can be customized api_url(host_url = "https://foobar.xyz")
#> [1] "https://foobar.xyz/openbis/openbis/rmi-general-information-v1.json"
# ScreeningApiServer interface endpoint api_url("sas")
#> [1] "https://infectx.biozentrum.unibas.ch/openbis/openbis/rmi-screening-api-v1.json"
# manual url api_url(full_url = "https://foobar.xyz/openbis/new-api-section-v1.json")
#> [1] "https://foobar.xyz/openbis/new-api-section-v1.json"
# link to GeneralInformationService interface docs docs_link()
#> [1] "\\href{https://svnsis.ethz.ch/doc/openbis/13.04.0/ch/systemsx/cisd/openbis/generic/shared/api/v1/IGeneralInformationService.html}{IGeneralInformationService}"
# add a method name (only to the link text) docs_link(method_name = "foo_bar")
#> [1] "\\href{https://svnsis.ethz.ch/doc/openbis/13.04.0/ch/systemsx/cisd/openbis/generic/shared/api/v1/IGeneralInformationService.html}{IGeneralInformationService:foo_bar}"
# link to ScreeningApiServer interface docs docs_link("sas")
#> [1] "\\href{https://svnsis.ethz.ch/doc/openbis/13.04.0/ch/systemsx/cisd/openbis/plugin/screening/shared/api/v1/IScreeningApiServer.html}{IScreeningApiServer}"
# link to most recent version of docs docs_link("sas", version = "16.05.6")
#> [1] "\\href{https://svnsis.ethz.ch/doc/openbis/16.05.6/ch/systemsx/cisd/openbis/plugin/screening/shared/api/v1/IScreeningApiServer.html}{IScreeningApiServer}"