We were told to use /api/v2/billing/premiumapplistings/{integration} to check if a user is licensed for our product and that the property previousFreeTrialDate would be set for the start of a free trial. We're seeing customers who have started free trials who don't have that field set. Also on the API response isAppOnSubscription is set to false and inside the offering list isOnSubscription is also false.
What is the right way to tell the following scenarios via this API:
1 - an org is on a paid subscription
2 - an org is on a free trial
3 - an org was on a free trial and then cancelled before the end of the trial
for 1 i assume isOnSubscription would be true. for 3, I assume that a 404 would be returned from the API but would like confirmation.
Who told you to use that? That's not a public endpoint and is not acceptable for use externally. Still working on tracking down an answer to your question.
I don't have anything set up to test this, but I'm wondering if maybe the subscriptionType property might give you something useful. This endpoint isn't in the Public API, so it's undocumented except for what's in the link above.