Set token on generate