Handle expiry correctly in json response

Go treats json numbers as `float64` not `int`, so currently expiry information is ignored for json responses since it's treated as an int.
Isn't the following if statement already covering this case?

If the expiry is not in the future, tok.Expired() will return true.