API Docs

Get Stats/Analytics (monthly) GET

This endpoint allows you to get stats/analytics data for a single tag or list of URLs for a given month.

https://t2mio.com/api/v1/stats/monthly

Request

Parameter Type Position Constraint Description
apikey string Header Required Your 20-30 characters unique api key.
apisecret string Header Required Your 12-20 characters unique api secret.
tag
or
url_keys
string Query Required Enter the tag name for which you want to see the stats data.
or
Enter a comma-separated list of short URL keys (slashtags only) for which you want to see the stats data. Max 100 keys.
For example, your short URLs are:
  • https://yourdomain.co/offer2020
  • https://yourdomain.co/Ghkr3dU
Then url_keys value can be offer2020,Ghkr3dU
year string Query Required Enter 4-digits of year (YYYY). Example: 2020
month string Query Required Enter 2-digits of month (MM). Example: 10
timezone string Query Optional Enter the timezone in UTC format. Example: -06:00. Default is +00:00

Sample GET requests

1. https://t2mio.com/api/v1/stats?tag=tag1&year=2020&month=10
2. https://t2mio.com/api/v1/stats?url_keys=key1,key2,key3&year=2020&month=10&timezone=-06:00

Response

{
  "status": 200,
  "message": "ok",
  "data": {
    "clicks_total": 957,
    "clicks_unique": 0,
    "clicks_repeated": 0,
    "clicks_breakdown": {
      "Dec 1": 14,
      "Dec 2": 8,
      "Dec 3": 4,
      "Dec 4": 11,
      "Dec 5": 4,
      "Dec 6": 167,
      "Dec 7": 209,
      "Dec 8": 110,
      "Dec 9": 105,
      "Dec 10": 114,
      "Dec 11": 61,
      "Dec 12": 68,
      "Dec 13": 5,
      "Dec 14": 4,
      "Dec 15": 6,
      "Dec 16": 2,
      "Dec 17": 6,
      "Dec 18": 6,
      "Dec 19": 8,
      "Dec 20": 4,
      "Dec 21": 0,
      "Dec 22": 5,
      "Dec 23": 4,
      "Dec 24": 0,
      "Dec 25": 2,
      "Dec 26": 8,
      "Dec 27": 4,
      "Dec 28": 2,
      "Dec 29": 9,
      "Dec 30": 3,
      "Dec 31": 4
    },
    "browser": {
      "Chrome": "875",
      "Safari": "35",
      "Firefox": "13",
      "Internet Explorer": "12",
      "Opera": "10",
      "Mozilla": "6",
      "iPhone": "4",
      "unknown.": "2"
    },
    "country": {
      "TH": "775",
      "US": "36",
      "RO": "32",
      "ID": "23",
      "CN": "14",
      ...
    },
    "device": {
      "Desktop": "89",
      "Tablet": "16",
      "Mobile": "852"
    },
    "languages": {},
    "platform": {
      "Android": "829",
      "Windows": "56",
      "iPhone": "33",
      "Apple": "20",
      "iPad": "7",
      "Linux": "6",
      "unknown.": "5",
      "iPhone/iPad": "1"
    },
    "referrer": {
      "Direct": 954,
      "facebook.com": "3"
    },
    "timezone": {}
  }
}