Merge RestAPI with basic funcionality

also, as you do not need the item in the "return" expression, i guess you can also just close it before the return.