This function allows you to obtain data from the BNM API.
bnm_api(path, ...)
path | Specifies the API path per https://api.bnm.gov.my/ |
---|---|
... | Additional arguments to httr::GET() |
https://api.bnm.gov.my/, https://cran.r-project.org/web/packages/httr/vignettes/api-packages.html
bnm_api("/welcome")#> $content #> $content$name #> [1] "BNM.API" #> #> $content$api #> [1] "v1" #> #> $content$description #> [1] "The APIs enable you to extract the relevant datasets on the BNM website for your applications and systems in a seamless manner. BNM will progressively release more datasets as APIs. If you are interested in a particular dataset or if you wish to provide feedback on the site, you may write to us." #> #> $content$contact #> $content$contact$name #> [1] "BNM.API" #> #> $content$contact$email #> [1] "[email protected]" #> #> #> $content$disclaimer #> [1] "https://api.bnm.gov.my/disclaimer" #> #> #> $path #> [1] "/welcome" #> #> $response #> Response [https://api.bnm.gov.my/public/welcome] #> Date: 2019-05-03 05:55 #> Status: 200 #> Content-Type: application/json #> Size: 451 B #> #> #> attr(,"class") #> [1] "bnm_api"