renamed file; state functions added; REST calls modified; user cache added