Rscript -e 'u<-"https://query1.finance.yahoo.com/v8/finance/chart/%5EGSPC?period1=1262304000&period2=1656633600&interval=1d";x<-paste(readLines(u,warn=FALSE),collapse="");cat(nchar(x),"\n");cat(substr(x,1,300),"\n");r<-regexec('"timestamp":\[([^]]+)\]',x,perl=TRUE);print(regmatches(x,r)[[1]][1:2])'