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

# Get groups



## OpenAPI

````yaml /openapi/main.json get /v1/crm/groups/
openapi: 3.0.3
info:
  title: Yume API — Основное
  version: 1.0.0
  description: Базовые сущности и бизнес-логика CRM.
servers:
  - url: https://api.yume.cloud
    description: Production
  - url: https://api.stage.yume.cloud
    description: Stage
security: []
paths:
  /v1/crm/groups/:
    get:
      tags:
        - groups
      summary: Get groups
      operationId: groups_list
      parameters:
        - in: query
          name: available
          schema:
            type: boolean
        - in: query
          name: category
          schema:
            type: integer
        - in: query
          name: category__in
          schema:
            type: array
            items:
              type: integer
          description: Несколько значений могут быть разделены запятыми.
          explode: false
          style: form
        - in: query
          name: disable__isnull
          schema:
            type: boolean
        - in: query
          name: disabled
          schema:
            type: boolean
        - in: query
          name: discount
          schema:
            type: integer
        - in: query
          name: discount__in
          schema:
            type: array
            items:
              type: integer
          description: Несколько значений могут быть разделены запятыми.
          explode: false
          style: form
        - in: query
          name: end_at
          schema:
            type: string
            format: date-time
          description: >-
            Конец окна доступности. Момент времени или дата, от которой берётся
            полночь. По умолчанию — текущий момент.
        - in: query
          name: free
          schema:
            type: boolean
        - in: query
          name: has_sublease
          schema:
            type: boolean
        - in: query
          name: id
          schema:
            type: integer
        - in: query
          name: id__exclude
          schema:
            type: array
            items:
              type: integer
          description: Несколько значений могут быть разделены запятыми.
          explode: false
          style: form
        - in: query
          name: id__in
          schema:
            type: array
            items:
              type: integer
          description: Несколько значений могут быть разделены запятыми.
          explode: false
          style: form
        - name: ordering
          required: false
          in: query
          description: Which field to use when ordering the results.
          schema:
            type: string
        - name: page
          required: false
          in: query
          description: A page number within the paginated result set.
          schema:
            type: integer
        - name: pageSize
          required: false
          in: query
          description: Number of results to return per page.
          schema:
            type: integer
        - in: query
          name: rental_point
          schema:
            type: integer
        - in: query
          name: saleable
          schema:
            type: boolean
        - name: search
          required: false
          in: query
          description: A search term.
          schema:
            type: string
        - in: query
          name: shareable
          schema:
            type: boolean
        - in: query
          name: start_at
          schema:
            type: string
            format: date-time
          description: >-
            Начало окна доступности. Момент времени или дата, от которой берётся
            полночь. По умолчанию — текущий момент.
        - in: query
          name: status
          schema:
            type: number
        - in: query
          name: type
          schema:
            type: integer
            title: Тип
            enum:
              - 0
              - 1
          description: |-
            * `0` - Аренда
            * `1` - Продажа
        - $ref: '#/components/parameters/TenantId'
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaginatedInventoryGroupList'
          description: ''
      security:
        - jwtAuth: []
components:
  parameters:
    TenantId:
      name: X-Tenant-Id
      in: header
      required: false
      schema:
        type: integer
      description: >-
        Компания, в контексте которой выполняется запрос — её id из `GET
        /v1/tenant/`. Пользователь должен состоять в этой компании: чужой id
        доступа к данным не даёт. Без заголовка компания определяется по домену
        запроса.
  schemas:
    PaginatedInventoryGroupList:
      type: object
      required:
        - count
        - results
      properties:
        count:
          type: integer
          example: 123
        next:
          type: string
          nullable: true
          format: uri
          example: http://api.example.org/accounts/?page=4
        previous:
          type: string
          nullable: true
          format: uri
          example: http://api.example.org/accounts/?page=2
        results:
          type: array
          items:
            $ref: '#/components/schemas/InventoryGroup'
    InventoryGroup:
      type: object
      properties:
        id:
          type: integer
          readOnly: true
        name:
          type: string
          nullable: true
          title: Название
          maxLength: 512
        created_at:
          type: string
          format: date-time
          readOnly: true
          title: Создан
        updated_at:
          type: string
          format: date-time
          readOnly: true
          title: Обновлен
        category:
          type: integer
          nullable: true
          title: Категория
        type:
          allOf:
            - $ref: '#/components/schemas/Type9ddEnum'
          title: Тип
          minimum: 0
          maximum: 32767
        price:
          type: string
          format: decimal
          pattern: ^-?\d{0,14}(?:\.\d{0,2})?$
        lifetime:
          type: integer
          maximum: 2147483647
          minimum: -2147483648
          nullable: true
          title: Срок службы, дней
        image:
          type: string
          format: uri
          nullable: true
          title: Изображение
        unique_id:
          type: string
          nullable: true
          title: Артикул
          maxLength: 255
        barcode:
          type: string
          nullable: true
          title: Штрихкод
          maxLength: 255
        extra:
          title: Доп. данные
        filters:
          type: array
          items:
            type: string
            maxLength: 32
          nullable: true
          title: Фильтры
        points:
          type: array
          items:
            type: integer
            maximum: 2147483647
            minimum: -2147483648
          title: Баллы
        published:
          type: boolean
          title: Опубликовано
        tarifs:
          type: array
          items:
            $ref: '#/components/schemas/BaseTariff'
        disabled:
          nullable: true
          oneOf:
            - $ref: '#/components/schemas/DisabledEnum'
            - $ref: '#/components/schemas/NullEnum'
        deleted:
          type: boolean
          readOnly: true
        inventories_count:
          type: integer
          readOnly: true
          default: 0
        inventories_free:
          type: integer
          readOnly: true
          default: 0
        unit_type:
          allOf:
            - $ref: '#/components/schemas/UnitTypeEnum'
          title: Единица измерения
        unit_price:
          type: string
          format: decimal
          pattern: ^-?\d{0,14}(?:\.\d{0,2})?$
          title: Цена за единицу
        unit_count:
          type: string
          format: decimal
          pattern: ^-?\d{0,14}(?:\.\d{0,2})?$
          title: Количество единиц
        unit_sum:
          type: string
          format: decimal
          pattern: ^-?\d{0,14}(?:\.\d{0,2})?$
          title: Итого за единицы
        has_sublease:
          type: boolean
          readOnly: true
        rent_count:
          type: string
          readOnly: true
      required:
        - created_at
        - deleted
        - has_sublease
        - id
        - inventories_count
        - inventories_free
        - rent_count
        - updated_at
    Type9ddEnum:
      enum:
        - 0
        - 1
      type: integer
      description: |-
        * `0` - Аренда
        * `1` - Продажа
    BaseTariff:
      type: object
      properties:
        id:
          type: integer
          readOnly: true
        name:
          type: string
          title: Название
          maxLength: 255
        price:
          type: string
          format: decimal
          pattern: ^-?\d{0,14}(?:\.\d{0,2})?$
        time_period:
          type: integer
          nullable: true
          title: Период
      required:
        - id
    DisabledEnum:
      enum:
        - 0
        - 1
        - 2
      type: integer
      description: |-
        * `0` - удалить
        * `1` - Архив
        * `2` - Списано
    NullEnum:
      enum:
        - null
    UnitTypeEnum:
      enum:
        - litre
        - kg
        - g
        - ml
        - piece
        - m3
      type: string
      description: |-
        * `litre` - Литр
        * `kg` - Килограмм
        * `g` - Грамм
        * `ml` - Миллилитр
        * `piece` - Штука
        * `m3` - Кубический метр
  securitySchemes:
    jwtAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````