Smart IP Not showing Country of the user
To address your edit about the Views filter requirement, there's a submodule included with the main module, called &quot;Smart IP Views Bridge&quot;. It has the functionality you're looking for. An extract from its README:

Smart IP Views Bridge exposes Smart IP visitor's location details to
Views field (coordinates, country, ISO 3166 2-character country code,
region, region code (FIPS), city and zip) and filter (country, ISO 3166
2-character country code, region, region code (FIPS), city and zip).

Enable that module and the filters you need will become available in Views.
The README goes on to provide full installation and configuration instructions for Views integration, so it's worth reading it thoroughly.
If solving programatically becomes a requirement:

It's right in the module description:
Other modules can use the function smart_ip_get_location($ip_address) in Drupal 6 and 7 and \Drupal\smart_ip\SmartIp::query($ipAddress) in Drupal 8 that returns an array containing the visitor's ISO 3166 2-character country code, longitude, latitude, region (FIPS), city and postal code.