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

# Sessions counted per channel, campaign, landing page, sector and more

> Sessions of the window counted per group, with distinct companies, bounce (at most one page) and averages; the grouped view of /sessions with the same filters. Without group_by: one row with the window's totals. Sectors are SIC major groups of the visiting companies.



## OpenAPI

````yaml /api-reference/openapi.json get /v1/trackers/{tracker_code}/sessions/counts
openapi: 3.1.0
info:
  title: Leadinfo Data API
  version: 0.1.0
  x-logo:
    url: https://asset.leadinfo.com/assets/email_logo.png
servers:
  - url: https://data.leadinfo.com
    description: Production
security: []
paths:
  /v1/trackers/{tracker_code}/sessions/counts:
    get:
      tags:
        - traffic
      summary: Sessions counted per channel, campaign, landing page, sector and more
      description: >-
        Sessions of the window counted per group, with distinct companies,
        bounce (at most one page) and averages; the grouped view of /sessions
        with the same filters. Without group_by: one row with the window's
        totals. Sectors are SIC major groups of the visiting companies.
      operationId: get_session_counts_v1_trackers__tracker_code__sessions_counts_get
      parameters:
        - name: tracker_code
          in: path
          required: true
          schema:
            type: string
            title: Tracker Code
        - name: start_date
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date
              - type: 'null'
            title: Start Date
        - name: end_date
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date
              - type: 'null'
            title: End Date
        - name: offset
          in: query
          required: false
          schema:
            type: integer
            maximum: 100000
            minimum: 0
            default: 0
            title: Offset
        - name: group_by
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                enum:
                  - channel
                  - source
                  - medium
                  - campaign
                  - term
                  - content
                  - referrer_host
                  - click_provider
                  - landing_page
                  - sector
                  - country
                  - city
                  - company
                  - day
                  - week
                  - month
                  - hour
                  - weekday
              - type: 'null'
            title: Group By
        - name: domain_filter
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Domain Filter
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            maximum: 500
            minimum: 1
            title: Limit
            default: 50
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SessionCountsResponse'
        '401':
          description: Invalid credentials.
        '403':
          description: Tracker not owned by this client.
        '422':
          description: Invalid query parameters.
      security:
        - HTTPBearer: []
components:
  schemas:
    SessionCountsResponse:
      properties:
        data:
          items:
            $ref: '#/components/schemas/SessionCount'
          type: array
          title: Data
        meta:
          $ref: '#/components/schemas/SessionCountsMeta'
      type: object
      required:
        - data
        - meta
      title: SessionCountsResponse
    SessionCount:
      properties:
        group:
          type: string
          title: Group
          description: The value counted; '(none)' when it is empty.
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: 'sector: the SIC major group; company: its name.'
        company_id:
          anyOf:
            - type: integer
            - type: 'null'
          title: Company Id
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
          description: 'city: its country.'
        sessions:
          type: integer
          title: Sessions
        companies:
          type: integer
          title: Companies
          description: Distinct companies behind the sessions.
        bounce_sessions:
          type: integer
          title: Bounce Sessions
          description: Sessions with at most one page.
        bounce_rate:
          type: number
          title: Bounce Rate
        avg_pages:
          type: number
          title: Avg Pages
        avg_active_seconds:
          type: number
          title: Avg Active Seconds
      type: object
      required:
        - group
        - sessions
        - companies
        - bounce_sessions
        - bounce_rate
        - avg_pages
        - avg_active_seconds
      title: SessionCount
    SessionCountsMeta:
      properties:
        total:
          anyOf:
            - type: integer
            - type: 'null'
          title: Total
        has_more:
          type: boolean
          title: Has More
        returned:
          type: integer
          title: Returned
        limit:
          anyOf:
            - type: integer
            - type: 'null'
          title: Limit
        offset:
          type: integer
          title: Offset
          default: 0
        next_offset:
          anyOf:
            - type: integer
            - type: 'null'
          title: Next Offset
          description: The offset of the next page; null on the last page.
        group_by:
          anyOf:
            - type: string
            - type: 'null'
          title: Group By
      type: object
      required:
        - has_more
        - returned
      title: SessionCountsMeta
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````

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