Find the countries a site can text

list_site_message_countries

Lists every country texts can go to, with its code, its name, what one SMS part to it costs and whether the site may text it now.

POST /v1/list_site_message_countriesScopeconfig:readRead only

It is the same list as Countries on the Settings tab of the Messages tab, more than 230 countries. Each one has its ISO code, its English name, credits, what one SMS part to it costs, and selected, whether the site may text it now. The countries the site may text come first, then the rest by name.

query keeps the countries whose name or code holds every word of it, ignoring case and accents, so port finds Portugal and PT finds it by its code. selectedOnly true keeps only the countries the site may text. The answer also carries selected, the codes the site may text, max, how many countries the site's plan lets it pick, and total, how many countries texts can go to. Pick countries with update_site_messages. See Countries.

Request

Call it with a POST to https://api.modulify.ai/v1/list_site_message_countries, sending the inputs below as a JSON object. The token needs the config:read scope.

It only reads and changes nothing, so retrying it is safe.

curl -X POST https://api.modulify.ai/v1/list_site_message_countries \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"projectId":"PROJECT_ID"}'

Over MCP, the same method is the list_site_message_countries tool.

Inputs

Input Type Required Description
projectId string Yes The site id.
query string No Words to find in the country name or code, such as port or PT.
selectedOnly boolean No True to list only the countries the site may text.

Response

Every call answers with the JSON envelope of success, message, data, code and version. data holds the result described above, and on a method that returns a total, count carries it. The response headers carry the call's X-Request-Id and what is left of your per-minute budget in X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset. Errors explains every status code a call can answer with.