WuBook Community Forum

Full Version: Return Values for is_token_valid
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,

What are the values returned by the is_token_valid method in Wired return? Submitting a request with a valid token gives a response with a "Returncode" of zero (which says success), but the Info part of the response contains an integer (2). What does the value returned in Info mean?

Thanks in advance for your reply.
Hello,

sorry for the delay of the response.

The second value is the usage counter. As you can read on the docs, a token can be used for a lmiited number of calls. This can be useful to understand how many times a token has been used.

Notice that a correct implementation, which implies common sense, probably does not require the counter. If you open a token when you need to make operations and if you correctly compact your call, there will be no need to take care about token usage limits.

Let me know if I can help you fiurther!