definitions:
  pingchat.ChatInfo:
    properties:
      domain:
        items:
          enum:
          - tidb
          - tidbcloud
          - asktug
          - blog
          - community
          - knowledge-base-cn
          - kb
          type: string
        type: array
      messages:
        description: https://pkg.go.dev/gopkg.in/bluesuncorp/validator.v9#hdr-Dive
        items:
          $ref: '#/definitions/pingchat.ChatMessage'
        type: array
    required:
    - messages
    type: object
  pingchat.ChatMessage:
    properties:
      content:
        description: Dialogue content
        type: string
      role:
        description: User's input as "user", AI assistant's reply as "assistant",
          see https://github.com/gin-gonic/gin/issues/3234.
        enum:
        - user
        - assistant
        type: string
    required:
    - content
    - role
    type: object
  pingchat.ChatResponse:
    properties:
      content:
        type: string
      links:
        description: Reference Document Links
        items:
          $ref: '#/definitions/pingchat.Link'
        type: array
    type: object
  pingchat.Link:
    properties:
      link:
        type: string
      title:
        type: string
    type: object
host: api.tidbcloud.com
info:
  contact: {}
  termsOfService: http://swagger.io/terms/
  title: PingChat Swagger API
  version: "1.0"
paths:
  /ecosystem/api/internal/pingchat/chat:
    post:
      consumes:
      - application/json
      description: Chat with PingChat
      operationId: Chat
      parameters:
      - description: chat information
        in: body
        name: chatInfo
        required: true
        schema:
          $ref: '#/definitions/pingchat.ChatInfo'
      produces:
      - application/json
      responses:
        "200":
          description: ok
          schema:
            $ref: '#/definitions/pingchat.ChatResponse'
        "400":
          description: error
          schema:
            type: object
        "500":
          description: error
          schema:
            type: object
        default:
          description: other error
          schema:
            type: object
      tags:
      - PingChatService
schemes:
- https
swagger: "2.0"
