rename resume to flow and add optional token