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

# Search articles

> Ranked search over the published articles of the help center this hostname
resolves to.

The only inputs read from the request are `q` and `limit`. The help center
is never one of them: were it a parameter, this endpoint would be a reader
for any customer's content, since it takes no authentication at all.



## OpenAPI

````yaml /api/helpdesk.yaml get /v1/public/search
openapi: 3.0.3
info:
  description: >-
    Help center API for the Talqui Helpdesk plugin. Two surfaces with different
    audiences: authenticated authoring routes under /v1/tenants/:tenantID, and
    anonymous public reads under /v1/public resolved from the request hostname.
  license:
    name: ISC
    url: https://opensource.org/license/isc-license-txt
  title: Talqui Helpdesk API
  version: 0.9.0
servers:
  - description: Production
    url: https://plugins-api.talqui.chat/helpdesk
security: []
tags:
  - name: Install
  - name: Public
  - name: Helpdesk
  - name: Categories
  - name: Articles
paths:
  /v1/public/search:
    get:
      tags:
        - Public
      summary: Search articles
      description: >-
        Ranked search over the published articles of the help center this
        hostname

        resolves to.


        The only inputs read from the request are `q` and `limit`. The help
        center

        is never one of them: were it a parameter, this endpoint would be a
        reader

        for any customer's content, since it takes no authentication at all.
      operationId: SearchArticlesController
      parameters:
        - in: query
          name: q
          required: false
          schema:
            default: ''
            maxLength: 120
            type: string
        - in: query
          name: limit
          required: false
          schema:
            default: 8
            maximum: 20
            minimum: 1
            type: integer
      responses:
        '200':
          content:
            application/json:
              schema:
                additionalProperties: false
                properties:
                  results:
                    items:
                      additionalProperties: false
                      properties:
                        articleDescription:
                          type: string
                        articleID:
                          type: string
                        articleSlug:
                          type: string
                        articleTitle:
                          type: string
                        categoryID:
                          type: string
                        searchScore:
                          type: number
                      required:
                        - articleID
                        - categoryID
                        - articleSlug
                        - articleTitle
                        - articleDescription
                        - searchScore
                      type: object
                    type: array
                  searchQuery:
                    type: string
                required:
                  - searchQuery
                  - results
                type: object
          description: Response for status 200.
        '400':
          content:
            application/json:
              schema:
                properties:
                  errors:
                    items:
                      oneOf:
                        - $ref: '#/components/schemas/MissingHelpdeskHostnameError'
                        - $ref: '#/components/schemas/RequestValidationError'
                    maxItems: 1
                    minItems: 1
                    type: array
                required:
                  - errors
                type: object
          description: >-
            MissingHelpdeskHostnameError (error_code 1106): no hostname on the
            request. | RequestValidationError (error_code 1002): `q` is over 120
            characters, or `limit` is not an integer in 1..20.
        '404':
          content:
            application/json:
              schema:
                properties:
                  errors:
                    items:
                      $ref: '#/components/schemas/HelpdeskNotFoundError'
                    maxItems: 1
                    minItems: 1
                    type: array
                required:
                  - errors
                type: object
          description: >-
            HelpdeskNotFoundError (error_code 1107): the hostname maps to no
            help center.
        '429':
          content:
            application/json:
              schema:
                properties:
                  errors:
                    items:
                      $ref: '#/components/schemas/TooManyRequestsError'
                    maxItems: 1
                    minItems: 1
                    type: array
                required:
                  - errors
                type: object
          description: >-
            TooManyRequestsError (error_code 1113): more than 30 searches in a
            minute from this visitor.
        '500':
          content:
            application/json:
              schema:
                properties:
                  errors:
                    items:
                      $ref: '#/components/schemas/UnknownError'
                    maxItems: 1
                    minItems: 1
                    type: array
                required:
                  - errors
                type: object
          description: >-
            UnknownError (error_code 5999): Unexpected internal error not
            otherwise documented for this endpoint.
components:
  schemas:
    MissingHelpdeskHostnameError:
      additionalProperties: false
      properties:
        error:
          enum:
            - MissingHelpdeskHostnameError
          type: string
        error_code:
          enum:
            - 1106
          type: number
        message:
          example: The X-Helpdesk-Host header is required.
          type: string
        statusCode:
          enum:
            - 400
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
      type: object
    RequestValidationError:
      additionalProperties: false
      properties:
        error:
          enum:
            - RequestValidationError
          type: string
        error_code:
          enum:
            - 1002
          type: number
        fields:
          items:
            additionalProperties: false
            properties:
              allowed:
                type: string
              field:
                type: string
              received:
                type: string
            required:
              - field
              - received
              - allowed
            type: object
          type: array
        message:
          example: Invalid request data.
          type: string
        statusCode:
          enum:
            - 400
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
        - fields
      type: object
    HelpdeskNotFoundError:
      additionalProperties: false
      properties:
        error:
          enum:
            - HelpdeskNotFoundError
          type: string
        error_code:
          enum:
            - 1107
          type: number
        message:
          example: No help center answers on this address.
          type: string
        statusCode:
          enum:
            - 404
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
      type: object
    TooManyRequestsError:
      additionalProperties: false
      properties:
        error:
          enum:
            - TooManyRequestsError
          type: string
        error_code:
          enum:
            - 1113
          type: number
        message:
          example: Too many requests. Please slow down and try again shortly.
          type: string
        statusCode:
          enum:
            - 429
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
      type: object
    UnknownError:
      additionalProperties: false
      properties:
        error:
          enum:
            - UnknownError
          type: string
        error_code:
          enum:
            - 5999
          type: number
        message:
          example: For some unknown reason your request has not succeeded.
          type: string
        statusCode:
          enum:
            - 500
          type: number
      required:
        - statusCode
        - error
        - error_code
        - message
      type: object

````

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