update variable of API