added all rest functionality