R/Tservertime.R

Tservertime <- function(api_key){
  # returns MBTA API server time
  # query <- "servertime"
  # base_url <- paste("http://realtime.mbta.com/developer/api/v2/",query,"?api_key=",api_key,"&format=json",sep="")
  # full_url <- paste(base_url)
  # rawdata <- readLines(full_url, warn = F)
  # dl <- jsonlite::fromJSON(txt=rawdata,simplifyDataFrame = T,flatten=F)
  # allout <- data.frame(server_dt=dl$server_dt)
  # return(allout)
  .Deprecated(msg = "Call no longer available in performance API")
}

Try the MBTAr package in your browser

Any scripts or data that you put into this service are public.

MBTAr documentation built on May 2, 2019, 6:59 a.m.