rscript demo API call