Added create and destroy api functionality