Due to variability in SMS deliverability across countries, admins may want to be able to audit contact methods across the user base of their accounts filtering by country.
Proposed Solution
Add a new flag to pd user list which filters to only include users in a given country, identified by its ISO country code. This flag should support multiple values.
E.g.
pd user list --contact_country_code CA -- lists users with a Canadian phone number in either phone or SMS contacts.
Alternatives Considered
Once #57 is fixed, something similar is possible using the --filter flag, e.g. pd user list --filter "Contact sms=\\+351 "
This, however, is less-than-ideal since this doesn't enable differentiation between countries that share a country code, most significantly +1 is ambiguous, and because the filter flag looks for a regex, + has to be escaped.
Problem Statement
Due to variability in SMS deliverability across countries, admins may want to be able to audit contact methods across the user base of their accounts filtering by country.
Proposed Solution
Add a new flag to
pd user list
which filters to only include users in a given country, identified by its ISO country code. This flag should support multiple values.E.g.
pd user list --contact_country_code CA
-- lists users with a Canadian phone number in either phone or SMS contacts.Alternatives Considered
Once #57 is fixed, something similar is possible using the
--filter
flag, e.g.pd user list --filter "Contact sms=\\+351 "
This, however, is less-than-ideal since this doesn't enable differentiation between countries that share a country code, most significantly
+1
is ambiguous, and because the filter flag looks for a regex,+
has to be escaped.