Nexmo's API is inconsistent when dealing with edge cases. I've had to relax the validation to avoid throwing exceptions during perfectly valid API responses.
In Account/Numbers.php, if the account has no numbers attached, the 'count' will be zero and further validation would fail. Here we just exit validation if the count is zero.
In Account/Numbers.php, the 'moHttpUrl' value may not exist if a number has been added without one (in which case the account's default moHttpUrl will be used). We cannot expect this value to exist.
In Account/Pricing/Country.php the country parameter should always be uppercase (Nexmo will error if it is not).
In Account/Pricing/Country.php, some countries do not have a 'mt' price value set (e.g., BV) so we can't expect it.
Nexmo's API is inconsistent when dealing with edge cases. I've had to relax the validation to avoid throwing exceptions during perfectly valid API responses.