MixerBox ChatVideo

MixerBox ChatVideo · GPT 작업

MixerBox ChatVideo

This plugin enables users to efficiently get information from an online video.

  • GET /api/gpt_plugins/videoThe plugin enables users to search information of videos by urls. It can also provide subtitles if available.

    After users search for a video by a url, the plugin delivers search results including description, publish date, subtitles, viewCount, etc.

  • GET /api/gpt_plugins/video/queryThis api can only be used if the 'searchVideo' API returns 'useQuery' as true. The plugin enables users to query information of a video by video id.

    When users query a video, the plugin delivers answers based on the video and users' question.

원본 API 스키마
{
  "openapi": "3.1.0",
  "info": {
    "title": "MixerBox ChatVideo",
    "description": "This plugin enables users to efficiently get information from an online video.",
    "version": "v1"
  },
  "servers": [
    {
      "url": "https://chatvideo.mixerbox.com"
    }
  ],
  "paths": {
    "/api/gpt_plugins/video": {
      "get": {
        "summary": "The plugin enables users to search information of videos by urls. It can also provide subtitles if available.",
        "description": "After users search for a video by a url, the plugin delivers search results including description, publish date, subtitles, viewCount, etc.",
        "operationId": "searchVideo",
        "parameters": [
          {
            "in": "query",
            "name": "q",
            "schema": {
              "type": "string"
            },
            "description": "Searched video id, please parse it from the url provided by the user.",
            "required": true
          },
          {
            "in": "query",
            "name": "src",
            "schema": {
              "type": "string",
              "enum": [
                "youtube"
              ]
            },
            "description": "The source of the url, please parse it from the url provided by the user. If there is no valid source, tell the user that this is not supported.",
            "required": true
          },
          {
            "in": "query",
            "name": "language",
            "schema": {
              "type": "string"
            },
            "description": "The language of response contents.",
            "required": false
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SearchVideoResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/gpt_plugins/video/query": {
      "get": {
        "summary": "This api can only be used if the 'searchVideo' API returns 'useQuery' as true. The plugin enables users to query information of a video by video id.",
        "description": "When users query a video, the plugin delivers answers based on the video and users' question.",
        "operationId": "queryVideo",
        "parameters": [
          {
            "in": "query",
            "name": "q",
            "schema": {
              "type": "string"
            },
            "description": "Queried video id, use the same id of the 'searchVideo' api.",
            "required": true
          },
          {
            "in": "query",
            "name": "src",
            "schema": {
              "type": "string",
              "enum": [
                "youtube"
              ]
            },
            "description": "The source of the url, please parse it from the url provided by the user. If there is no valid source, tell the user that this is not supported.",
            "required": true
          },
          {
            "in": "query",
            "name": "question",
            "schema": {
              "type": "string"
            },
            "description": "The question to ask about the video.",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QueryVideoResponse"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "SearchVideoResponse": {
        "title": "SearchVideoResponse",
        "type": "object",
        "properties": {
          "items": {
            "title": "Search results.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/VideoItem"
            },
            "description": "The search results of the video."
          },
          "rules": {
            "title": "The array of rules which recommend gpt to follow.",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The array of rules which recommend gpt to follow."
          }
        }
      },
      "VideoItem": {
        "type": "object",
        "properties": {
          "details": {
            "$ref": "#/components/schemas/VideoDetails"
          },
          "subtitles": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "List of video subtitles, please generate a summary for the user based on this."
          },
          "subtitlesProcessing": {
            "type": "boolean",
            "description": "Flag indicating if subtitles are under processing. If true, tell the user that the request is being processed and will take some time, please check back later for the summary."
          },
          "subtitlesSupported": {
            "type": "boolean",
            "description": "Flag indicating if subtitles are supported."
          },
          "useQuery": {
            "type": "boolean",
            "description": "Flag indicating if you should use the 'queryVideo' API to get more information. Only call the 'queryVideo' API afterwards if this is true. Tell the user he/she can ask further questions, and do not tell the user that subtitles are not supported."
          }
        }
      },
      "VideoDetails": {
        "type": "object",
        "properties": {
          "author": {
            "type": "string",
            "description": "The author of the video"
          },
          "category": {
            "type": "string",
            "description": "The category of the video"
          },
          "description": {
            "type": "string",
            "description": "The description of the video"
          },
          "keywords": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "List of keywords related to the video"
          },
          "lengthSeconds": {
            "type": "string",
            "description": "The duration of the video in seconds"
          },
          "ownerChannelName": {
            "type": "string",
            "description": "The name of the video owner's channel"
          },
          "publishDate": {
            "type": "string",
            "format": "date",
            "description": "The publish date of the video"
          },
          "title": {
            "type": "string",
            "description": "The title of the video"
          },
          "viewCount": {
            "type": "string",
            "description": "The number of views the video has"
          }
        }
      },
      "QueryVideoResponse": {
        "title": "QueryVideoResponse",
        "type": "object",
        "properties": {
          "items": {
            "title": "Query answers.",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The queried answers based on the video and users' question."
          },
          "rules": {
            "title": "The array of rules which recommend gpt to follow.",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The array of rules which recommend gpt to follow."
          }
        }
      }
    }
  }
}