A way to know if the floating server is expired


#1

Hello,

I used services/api/stats API and check daysLeftToExpiration attribute to know if the server is expired.
But, daysLeftToExpiration can be 0 in both of following case:

  1. the server is expired
  2. the server’s expiration date is set to “no expiracy”

So, I cannot differentiate the condition.

How should I do to differentiate above cases?


#2

It depends on the context, the user would know if the license is time limited or perpetual.


#3

Sorry for confusion…
Let me clarify my question…

I want to know if the floating server is expired PROGRAMATICALLY. So I can warn users when license is expired. (The warning will be shown in Floating client machine as user’s convenience)

Currently I’m checking the result JSON from services/api/stats API, but as I mentioned previously, daysLeftToExpiration =0 will be returned in both of following cases:

  1. the server is expired
  2. the server’s expiration date is set to “no expiracy”

So, programatically, I cannot know if the license is expired.

How can I solve this issue?

Please let me know


#4

Ideally, it should return -1 in case expiry is “no expiry”. Will fix this in the next release


#5

I agreed with you to return -1. Please do similar changes to node-Locked case as well which is returned from GetDaysLeft~ API, for consistency if possible


#6

Also, when would be the upcoming release’sETA?


#7

It would be by the end of Jan


#8

Cool! :slight_smile:


#9

Hi,

Instead of returning -1, we have added a status property which can be used to differentiate the “0” case. if status is"ok" and daysLeftToExpiration is “0” means no expiry, if status is"expired" and daysLeftToExpiration is “0” means expired.