getToken: Get a Connection Token from the NI Database

getTokenR Documentation

Get a Connection Token from the NI Database

Description

This function tries to connect to the NI database API and retrieves a token that is later used to communicate with the database.

Usage

getToken(
  username = NULL,
  password = NULL,
  url = "https://www8.nina.no/NaturindeksNiCalc"
)

Arguments

username

character Your username

password

character Your password

url

character API address.

Value

The function sets the variables niToken and url, which both are used in other functions that communicate with the database through the API.

Author(s)

Jens Åström

Examples

## Not run: 
getToken("test.user", "test.password")

## End(Not run)


NINAnor/NIcalc documentation built on Oct. 26, 2023, 9:37 a.m.