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

# Просмотр или поиск по публичному каталогу каналов

> Зеркала "Найти каналы" официальных клиентов. Без
`search_text` он просматривает `view` и требует хотя бы одного кода страны
; с помощью `search_text` производится поиск каналов по названию (коды стран
не поддерживаются поиском). Paginate с `cursor`, а
`has_more` правда. Использует недокументированные запросы WhatsApp, взятые из
WhatsApp Web, которые могут быть изменены без предварительного уведомления.




## OpenAPI

````yaml /ru/openapi.yml get /newsletter/directory
openapi: 3.0.0
info:
  title: WhatsApp API MultiDevice
  version: 9.7.0
  description: >
    Этот API используется для отправки whatsapp через API.


    Веб-панель инструментов это отдельный проект (gowa-ui); сервер загружает
    свой последний релиз

    и служит в `/` (или возвращает баннер JSON, когда

    APP_UI_ENABLED=false).


    Привязка устройства:

    - Отправляйте `X-Device-Id` при всех вызовах с прикрепленными устройствами.

    - WebSocket: подключиться к `/ws?device_id=<id>`.

    - Аутентификация WebSocket (когда включена основная аутентификация):
    браузеры не могут установить
      Заголовок авторизации при соединениях WebSocket, так же передает
      `&authorization=<base64(user:pass)>` в строке запроса. Использовать TLS в производстве
      так как учетные данные видны на URL.
servers:
  - url: http://localhost:3000
security:
  - basicAuth: []
tags:
  - name: app
    description: Первоначальное подключение к серверу Whatsapp
  - name: device
    description: Управление устройством для поддержки нескольких устройств
  - name: user
    description: Получение информации
  - name: send
    description: Отправить сообщение (Text/Image/Файл/Видео).
  - name: message
    description: Управление сообщениями (отозвать/изменить/обновить).
  - name: call
    description: Управление звонками (отклонить входящие вызовы)
  - name: chat
    description: Общение и обмен сообщениями
  - name: group
    description: Настройки группы
  - name: newsletter
    description: настройка рассылки
  - name: chatwoot
    description: Интеграция с Chatwoot для поддержки клиентов
paths:
  /newsletter/directory:
    get:
      tags:
        - newsletter
      summary: Просмотр или поиск по публичному каталогу каналов
      description: >
        Зеркала "Найти каналы" официальных клиентов. Без

        `search_text` он просматривает `view` и требует хотя бы одного кода
        страны

        ; с помощью `search_text` производится поиск каналов по названию (коды
        стран

        не поддерживаются поиском). Paginate с `cursor`, а

        `has_more` правда. Использует недокументированные запросы WhatsApp,
        взятые из

        WhatsApp Web, которые могут быть изменены без предварительного
        уведомления.
      operationId: searchNewsletterDirectory
      parameters:
        - $ref: '#/components/parameters/DeviceIdHeader'
        - name: view
          in: query
          required: false
          schema:
            type: string
            enum:
              - RECOMMENDED
              - TRENDING
              - POPULAR
              - NEW
              - FEATURED
            default: RECOMMENDED
        - name: search_text
          in: query
          required: false
          schema:
            type: string
          example: news
        - name: country_codes
          in: query
          required: false
          description: >-
            ISO 3166-1 alpha-2 коды, повторяемые или разделенные запятыми.
            Требуется при просмотре изображения.
          schema:
            type: array
            items:
              type: string
          example:
            - ID
        - name: categories
          in: query
          required: false
          schema:
            type: array
            items:
              type: string
              enum:
                - BUSINESS
                - ENTERTAINMENT
                - LIFESTYLE
                - NEWS
                - ORGANIZATIONS
                - PEOPLE
                - SPORTS
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            default: 20
            minimum: 1
            maximum: 50
        - name: cursor
          in: query
          required: false
          description: next_cursor с предыдущей страницы
          schema:
            type: string
      responses:
        '200':
          description: ОК
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/NewsletterDirectoryResponse'
        '400':
          description: Плохой запрос
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBadRequest'
        '500':
          description: Внутренняя ошибка сервера
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorInternalServer'
components:
  parameters:
    DeviceIdHeader:
      name: X-Device-Id
      in: header
      required: false
      description: >
        Идентификатор устройства для поддержки нескольких устройств. Требуется
        при регистрации нескольких устройств.

        Если только одно устройство зарегистрировано, оно будет использоваться
        по умолчанию.

        Можно также задать параметр `device_id` запроса.
      schema:
        type: string
        example: my-device-id
  schemas:
    NewsletterDirectoryResponse:
      type: object
      properties:
        code:
          type: string
          example: SUCCESS
        message:
          type: string
          example: Success search newsletter directory
        results:
          type: object
          properties:
            data:
              type: array
              items:
                $ref: '#/components/schemas/Newsletter'
            next_cursor:
              type: string
              example: GTby6Oiy0/jOqwPYxYXQtvjOqwPC0uaVue3OqwMZ
            has_more:
              type: boolean
              example: true
    ErrorBadRequest:
      type: object
      properties:
        code:
          type: string
          example: 400
          description: Код состояния HTTP
        message:
          type: string
          example: field cannot be blank
          description: Подробное сообщение об ошибке
        results:
          type: object
          example: null
          description: дополнительные данные
    ErrorInternalServer:
      type: object
      properties:
        code:
          type: string
          example: INTERNAL_SERVER_ERROR
          description: SYSTEM_CODE_ERROR
        message:
          type: string
          example: you are not loggin
          description: Подробное сообщение об ошибке
        results:
          type: object
          example: null
          description: дополнительные данные
    Newsletter:
      type: object
      properties:
        id:
          type: string
          example: 120363144038483540@newsletter
        state:
          type: object
          properties:
            type:
              type: string
              example: active
        thread_metadata:
          type: object
          properties:
            creation_time:
              type: string
              example: '1688746895'
            invite:
              type: string
              example: 0029Va4K0PZ5a245NkngBA2M
            name:
              type: object
              properties:
                text:
                  type: string
                  example: WhatsApp
                id:
                  type: string
                  example: '1688746895480511'
                update_time:
                  type: string
                  example: '1688746895480511'
            description:
              type: object
              properties:
                text:
                  type: string
                  example: >-
                    WhatsApp's official channel. Follow for our latest feature
                    launches, updates, exclusive drops and more.
                id:
                  type: string
                  example: '1689653839450668'
                update_time:
                  type: string
                  example: '1689653839450668'
            subscribers_count:
              type: string
              example: '0'
            verification:
              type: string
              example: verified
            picture:
              type: object
              properties:
                url:
                  type: string
                  example: ''
                id:
                  type: string
                  example: '1707950960975554'
                type:
                  type: string
                  example: IMAGE
                direct_path:
                  type: string
                  example: >-
                    /v/t61.24694-24/416962407_970228831134395_8869146381947923973_n.jpg?ccb=11-4&oh=01_Q5AaIIvOIeu3l0HCZWILrmr-dGR_vXFqnhUeytw0-ojPc4hL&oe=670D95B1&_nc_sid=5e03e0&_nc_cat=110
            preview:
              type: object
              properties:
                url:
                  type: string
                  example: ''
                id:
                  type: string
                  example: '1707950960975554'
                type:
                  type: string
                  example: PREVIEW
                direct_path:
                  type: string
                  example: >-
                    /v/t61.24694-24/416962407_970228831134395_8869146381947923973_n.jpg?stp=dst-jpg_s192x192&ccb=11-4&oh=01_Q5AaIHO-DQklqm3q3awF7xwji_WAn9DkgZASQA0B2Ct0qbSa&oe=670D95B1&_nc_sid=5e03e0&_nc_cat=110
            settings:
              type: object
              properties:
                reaction_codes:
                  type: object
                  properties:
                    value:
                      type: string
                      example: ALL
        viewer_metadata:
          type: object
          nullable: true
          description: Null при недоступности метаданных, специфичных для просмотра.
          properties:
            mute:
              type: string
              example: 'off'
            role:
              type: string
              example: subscriber
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic

````

## Related topics

- [WhatsApp каналы](https://gowa-docs.mintlify.site/ru/examples/newsletters.md)
- [Справочник по API](https://gowa-docs.mintlify.site/ru/api-reference/introduction.md)
- [Получение сообщений](https://gowa-docs.mintlify.site/ru/examples/receiving-messages.md)
- [MCP сервер](https://gowa-docs.mintlify.site/ru/integrations/mcp.md)
- [Обработка файлов](https://gowa-docs.mintlify.site/ru/examples/media-handling.md)


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