api-referenceGET
GEThttps://analytics.flowsery.com/api/v1/countries

Fetch analytics data segmented by country.

Bearer Token (API key)

Query parameters

ParameterTypeDescription
startAtstringISO 8601 start date/time (e.g. 2024-01-01T00:00:00Z). Defaults to the last 30 days when omitted.
endAtstringISO 8601 end date/time. Defaults to now when omitted.
timezonestringTimezone for aggregation (e.g., UTC, America/New_York). Falls back to the site's configured timezone.
limitnumberMaximum rows to return (1-1000, default: 100).
offsetnumberRows to skip for pagination (min 0, default: 0).

Filter parameters

ParameterTypeDescription
filter_countrystringCountry name or code. Use | for multiple values and ! to exclude.
filter_regionstringRegion or state.
filter_citystringCity name.
filter_devicestringDevice type. Use backend values such as Desktop|Mobile|Tablet, and ! to exclude.
filter_browserstringBrowser name. Safari includes Mobile Safari automatically.
filter_osstringOperating system (Mac OS, Windows, iOS, Android).
filter_referrerstringReferrer domain or well-known name.
filter_refstringThe ref URL parameter value.
filter_sourcestringThe source URL parameter value.
filter_viastringThe via URL parameter value.
filter_utm_sourcestringUTM source.
filter_utm_mediumstringUTM medium.
filter_utm_campaignstringUTM campaign.
filter_utm_termstringUTM term.
filter_utm_contentstringUTM content.
filter_pagestringPage path or URL.
filter_entry_pagestringEntry page path or URL.
filter_hostnamestringHostname/domain.
filter_channelstringMarketing channel.
filter_goalstringGoal name.

Response fields

Each item in the <code>data</code> array contains the country name, an SVG flag image URL, visitor count, and revenue attributed to that country.

Combining filters

Pass comma-separated values within a single filter parameter to match multiple items. Combine different filter parameters to narrow results further (e.g., <code>filter_country=United States,Canada&filter_device=mobile</code>).
Example request (curl)
curl --request GET \
  --url 'https://analytics.flowsery.com/api/v1/countries?limit=5' \
  --header 'Authorization: Bearer <api-key>'
200
{
  "status": "success",
  "data": [
    {
      "value": "United States",
      "countryCode": "US",
      "visitors": 2840,
      "revenue": 6780,
      "renewalRevenue": 1740,
      "percentage": 44.1
    },
    {
      "value": "France",
      "countryCode": "FR",
      "visitors": 1230,
      "revenue": 2450,
      "renewalRevenue": 530,
      "percentage": 19.1
    },
    {
      "value": "United Kingdom",
      "countryCode": "GB",
      "visitors": 920,
      "revenue": 1450,
      "renewalRevenue": 320,
      "percentage": 14.3
    },
    {
      "value": "Germany",
      "countryCode": "DE",
      "visitors": 780,
      "revenue": 1230,
      "renewalRevenue": 210,
      "percentage": 12.1
    },
    {
      "value": "Spain",
      "countryCode": "ES",
      "visitors": 650,
      "revenue": 980,
      "renewalRevenue": 140,
      "percentage": 10.1
    }
  ],
  "pagination": {
    "limit": 5,
    "offset": 0,
    "total": 148
  }
}