get_current_goldprice function

Retrieves the current gold price.

Retrieves the current gold price.

get_current_goldprice()

Returns

nbp_api_response object containing the current gold price.

Examples

tryCatch( { ## Fetch the current gold price response <- get_current_goldprice() ## Retrieve the current gold price value response$content$cena }, error = function(e) message(e) )

See Also

https://api.nbp.pl/#cenyZlota

Other goldprice: get_goldprice_from(), get_goldprice_from_interval(), get_last_n_goldprices(), get_todays_goldprice()

  • Maintainer: Ryszard Szymanski
  • License: GPL-3
  • Last published: 2025-03-23