now working: remote api

added javascript for remote api and example