Get Temperature data from device

hi,
i would like to log the data on my sonoff device such as temperature, humidity, power usage, etc for me to use in other apps

i’ve following step by step mentioned in ewelink-api-next and the developer guide
but i encounter problem with getting authorization code and authorization token

could somebody help me, whats wrong with my step?