> ## Documentation Index
> Fetch the complete documentation index at: https://snowseo.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Analytics (SnowAnalytics)

> Pull your website visitor data from SnowAnalytics - users, pageviews, sessions, sources, and devices.

Get your website analytics from **SnowAnalytics**. These endpoints power the Traffic dashboard's **Analytics** tab when SnowAnalytics is your connected provider - users, pageviews, sessions, traffic sources, top pages, and device breakdowns.

> [!NOTE]
>
> You need a **SnowAnalytics** integration connected to your team. Connect it from **Settings → Integrations → Analytics & Performance**. Using **Google Analytics 4** instead? See [Analytics (Google Analytics 4)](https://snowseo.com/docs/api-reference/endpoints/ga-traffic.md). Using **PostHog**? See [Analytics (PostHog)](https://snowseo.com/docs/api-reference/endpoints/posthog-traffic.md). Using **Plausible**? See [Analytics (Plausible)](https://snowseo.com/docs/api-reference/endpoints/plausible-traffic.md).

These routes require an active plan; without one they return `403`.

Pass `startDate` and `endDate` or `days`; see [Date Windows](https://snowseo.com/docs/api-reference/introduction.md#date-windows).

### Filters Parameter

The `filters` query parameter accepts URL-encoded JSON: an object keyed by dimension, each with a list of selected values. Dimensions: `page`, `referrer`, `channel`, `campaign`, `deviceCategory`, `browser`, `os`. Invalid JSON, an unknown dimension, or a value that is not a list returns `400` with code `INVALID_FILTERS` naming the supported dimensions.

```
filters={"channel":["Organic Search"],"browser":["Chrome"]}
```

SnowAnalytics takes one value per dimension, and `channel` and `referrer` share one filter. A list with more than one value, or `channel` and `referrer` together, returns `400` with code `INVALID_FILTERS`.

Call [`GET /v3/integrations/snow-analytics/filter-values`](https://snowseo.com/docs/api-reference/endpoints/snow-analytics-traffic-filter-values) for the available dimension values.

***

## Traffic Chart

`GET /v3/integrations/snow-analytics/chart`

Get daily visitor, pageview, session, and bounce-rate data for the selected date range. The response also carries `totals` for the whole range, where visitors are counted once across the period rather than once per day. `incompleteFrom` is today in the site's time zone; days from it onward are still being collected.


## OpenAPI

````yaml GET /v3/integrations/snow-analytics/chart
openapi: 3.0.0
info:
  title: SnowSEO API
  description: API documentation for SnowSEO
  version: 1.0.0
servers:
  - url: https://api.snowseo.com
    description: Production server
security:
  - bearerAuth: []
  - apiKey: []
externalDocs:
  url: https://snowseo.com/docs
  description: Find more info here
paths:
  /v3/integrations/snow-analytics/chart:
    get:
      tags:
        - SnowAnalytics
      summary: Get SnowAnalytics traffic chart
      description: >-
        Returns SnowAnalytics sessions, visitors and pageviews per day for the
        window.
      parameters:
        - schema:
            type: string
          in: query
          name: teamId
          required: false
          description: Team ID
        - schema:
            type: integer
            minimum: 1
            default: 30
          in: query
          name: days
          required: false
          description: >-
            Days back from today on the team's calendar, converted to
            startDate/endDate. Ignored when startDate or endDate is set.
            Defaults to 30.
        - schema:
            type: string
          in: query
          name: startDate
          required: false
          description: Start date (YYYY-MM-DD)
        - schema:
            type: string
          in: query
          name: endDate
          required: false
          description: End date (YYYY-MM-DD)
        - schema:
            type: string
          in: query
          name: country
          required: false
          description: Country filter
        - schema:
            anyOf:
              - type: string
              - type: array
                items:
                  type: string
          in: query
          name: filters
          required: false
          description: >-
            A JSON object, sent as a string, mapping a dimension to the values
            to keep, e.g.
            {"page":["/blog/my-post"],"deviceCategory":["mobile"]}. Dimensions:
            page, referrer, channel, campaign, deviceCategory, browser, os.
            Several values for one dimension match any of them; several
            dimensions must all match. Use values the provider's filter_values
            tool returns for that dimension; page values are paths without query
            string or trailing slash. Filter by country with `country`. Invalid
            JSON, an unknown dimension or a non-list value returns 400 (code
            INVALID_FILTERS) naming the supported dimensions.
      responses:
        '200':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                required:
                  - chartData
                properties:
                  chartData:
                    type: array
                    items:
                      type: object
                      properties:
                        date:
                          type: string
                        users:
                          type: number
                        pageviews:
                          type: number
                        sessions:
                          type: number
                        bounceRate:
                          type: number
                  totals:
                    type: object
                    properties:
                      users:
                        type: number
                      sessions:
                        type: number
                      pageviews:
                        type: number
                      bounceRate:
                        type: number
                      avgDuration:
                        type: number
                  incompleteFrom:
                    type: string
                    nullable: true
                    description: >-
                      Today on the provider's own calendar (YYYY-MM-DD). Days
                      from here on are still being collected. Null when the
                      provider's time zone is unknown.
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Your SnowSEO API key (sk_...).
    apiKey:
      type: apiKey
      name: x-api-key
      in: header

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.