Get visitors by time
pirsch_get_time_distributionRead-only
Visitors by hour of the day, by minute (only when from and to are the same day), or by weekday and hour (Monday is 0). Shows when traffic peaks. GET /api/v1/statistics/hours, /minutes or /weekdays.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| by | Yes | hour = per hour of day, minute = per minute (needs a one-day range), weekday = weekday and hour. | |
| os | No | Operating system. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| to | Yes | Last day, yyyy-mm-dd, whole day included. | |
| tz | No | IANA time zone such as Europe/Berlin. Default: the dashboard's time zone. | |
| tag | No | Tag key to filter for. | |
| city | No | City name. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| from | Yes | First day, yyyy-mm-dd (in the dashboard time zone unless tz is set). | |
| path | No | Page path, for example /pricing. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| tags | No | Tag key/value pairs; only results with all pairs match. | |
| event | No | Event name. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| browser | No | Browser. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| channel | No | Traffic channel such as "Paid Search" or "Organic Search". Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| country | No | ISO 3166 alpha-2 country code such as jp. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| pattern | No | Regular expression that filters and groups pages, for example (?i)^/blog/[^/]+$. | |
| hostname | No | Hostname (useful for rollup views). Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| language | No | ISO 639-1 language code such as en. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| platform | No | Platform. | |
| referrer | No | Referrer, usually a URL. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| utm_term | No | UTM term. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| domain_id | Yes | Pirsch domain (dashboard) id. Get it from pirsch_list_domains. | |
| exit_path | No | Exit page path. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| entry_path | No | Entry page path. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| event_meta | No | Event metadata key/value pairs; only events with all pairs match. | |
| utm_medium | No | UTM medium. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| utm_source | No | UTM source. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| utm_content | No | UTM content. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| screen_class | No | Screen class XXL, XL, L, M or S. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| utm_campaign | No | UTM campaign. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). | |
| referrer_name | No | Referrer name, usually the hostname. Optional filter. A value may start with ! (is not), ~ (contains) or ^ (does not contain). |