## not specifying 'api' will add the key to the 'api_key' list element
set_key(key = "xxx_your_api_key_xxx")
## api key for directions
set_key(key = "xxx_your_api_key_xxx", api = "directions")
## api key for maps
set_key(key = "xxx_your_api_key_xxx", api = "map")
Run the code above in your browser using DataLab