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

# Get All Segments

> Fetches all Segments for account



## OpenAPI

````yaml /api-reference/segments-openapi.json get /prod/segments/{idSite}
openapi: 3.1.0
info:
  title: segmentation
  version: '1.1'
servers:
  - url: https://api.aimtell.com
security:
  - sec0: []
tags:
  - name: Segments
    description: Audience segmentation
  - name: Subscribers
    description: Subscriber management and tracking
paths:
  /prod/segments/{idSite}:
    get:
      tags:
        - Segments
      summary: Get All Segments
      description: Fetches all Segments for account
      operationId: get-available-segments
      parameters:
        - name: idSite
          in: path
          description: Site ID
          required: true
          schema:
            type: string
      responses:
        '200':
          description: '200'
          content:
            application/json:
              examples:
                Result:
                  value:
                    - idsegment: 245
                      owner: 76cedd11b19e
                      name: 'Sample Segment #1 - Lives In California'
                      definition: region==California
                      idSite: 179
                      createdAt: '2015-12-28 17:54:42'
                      updatedAt: '2015-12-28 17:54:42'
                      deleted: 0
                    - idsegment: 246
                      owner: 76cedd11b19e
                      name: 'Sample Segment #2 - Viewed Tutorial Video'
                      definition: eventCategory==video,eventAction==tutorial
                      idSite: 179
                      createdAt: '2015-12-28 17:54:42'
                      updatedAt: '2015-12-28 17:54:42'
                      deleted: 0
                    - idsegment: 5909
                      owner: 76cedd11b19e
                      name: Campaign for people who click certain links
                      definition: pageUrl==https://josephmurphybrasil.com/
                      idSite: 179
                      createdAt: '2017-01-02 18:50:54'
                      updatedAt: '2017-01-02 18:52:39'
                      deleted: 0
        '401':
          description: '401'
          content:
            application/json:
              examples:
                Result:
                  value:
                    result: error
                    message: Invalid token.
                    error_code: 71831
      deprecated: false
components:
  securitySchemes:
    sec0:
      type: apiKey
      name: X-Authorization-Api-Key
      in: header
      x-default: ''

````