update tutorial to save state with id