Number insights response unusable with non-zero status code?
ryan-mend opened this issue · 7 comments
We've noticed that on the Vonage API Dashboard there lies a link to take you to a Getting started with Number Insight
page here.
When we enter this number (18104967360) into the Getting started with Number Insight
page and press the Look up number
button, the look up appears to succeed and this gets displayed on the page:
However when trying to look that same number (18104967360) up via this SDK, because the status code coming back in the look up response is 44
(non-zero) an exception is thrown and the response is obfuscated from the consuming application. This behavior seems consistent in all versions of this SDK.
This leads me to a few questions/concerns:
- Why would the php sdk library be written in such a way that you wouldn't be able to glean the same information about the number being looked up as is exposed on the number lookup page available from the api dashboard for the exact same number?
- When the php sdk library lookup fails in this way I presume we are still charged or the lookup despite the exception being thrown and response being made unavailable to the application leveraging this sdk library?
- If this exception throwing was by design, and not an oversight, is that indicative of the response of the lookup being unreliable and unusable? If that is true then why display the data like you do on the number lookup page available from the api dashboard?
vonage-php-sdk-core/src/Insights/Client.php
Line 119 in 28e0566