rest api working like a charm