add REST functionality