openbahn_auth: Store the API key in an environment variable

Description Usage Arguments Details Author(s) Examples

Description

openbahn_auth() stores the API key in an environment variable to make it accessible for all openbahn functions.

Usage

1

Arguments

key

character, the API key provided by http://data.deutschebahn.com/

Details

The API key is stored in the environment variable OPENBAHN_KEY. In addition, openbahn_auth() sets another environment variable (OPENBAHN_USER_AGENT) holding the user agent which is used for HTTP calls.

Author(s)

Philipp Ottolinger

Examples

1
2
3
4
## Not run: 
openbahn_auth("YOUR_API_KEY_HERE")

## End(Not run)

ottlngr/openbahn documentation built on May 7, 2019, 9 p.m.