# 获取 PPT 数据结构

## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /api/generate/data:
    post:
      summary: 获取 PPT 数据结构
      deprecated: false
      description: |
        此接口是获取任务的大纲内容对应的PPT树形结构。
      tags: []
      parameters:
        - name: x-api-key
          in: header
          description: ''
          required: true
          example: '{{apiKey}}'
          schema:
            type: string
        - name: x-channel
          in: header
          description: ''
          required: true
          example: ''
          schema:
            type: string
        - name: x-token
          in: header
          description: ''
          required: true
          example: '{{token}}'
          schema:
            type: string
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                task_id:
                  description: |
                    任务ID
                  example: '{{taskID}}'
                  type: string
              required:
                - task_id
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                    description: 返回码，0表示成功，非0表示异常
                  data:
                    type: object
                    properties:
                      children:
                        type: array
                        items:
                          type: object
                          properties:
                            children:
                              type: array
                              items:
                                type: object
                                properties:
                                  children:
                                    type: array
                                    items:
                                      type: object
                                      properties:
                                        children:
                                          type: array
                                          items:
                                            type: string
                                        depth:
                                          type: integer
                                        direction:
                                          type: integer
                                        expanded:
                                          type: boolean
                                        id:
                                          type: integer
                                        index:
                                          type: integer
                                        lastLevel:
                                          type: boolean
                                        parentId:
                                          type: integer
                                        showTip:
                                          type: boolean
                                        sort:
                                          type: integer
                                        type:
                                          type: string
                                        value:
                                          type: string
                                      required:
                                        - children
                                        - depth
                                        - direction
                                        - expanded
                                        - id
                                        - index
                                        - lastLevel
                                        - parentId
                                        - showTip
                                        - sort
                                        - type
                                        - value
                                      x-apifox-orders:
                                        - children
                                        - depth
                                        - direction
                                        - expanded
                                        - id
                                        - index
                                        - lastLevel
                                        - parentId
                                        - showTip
                                        - sort
                                        - type
                                        - value
                                  depth:
                                    type: integer
                                  direction:
                                    type: integer
                                  expanded:
                                    type: boolean
                                  id:
                                    type: integer
                                  parentId:
                                    type: integer
                                  showTip:
                                    type: boolean
                                  sort:
                                    type: integer
                                  type:
                                    type: string
                                  value:
                                    type: string
                                  index:
                                    type: integer
                                  lastLevel:
                                    type: boolean
                                  pageIndex:
                                    type: integer
                                required:
                                  - children
                                  - depth
                                  - direction
                                  - expanded
                                  - id
                                  - parentId
                                  - showTip
                                  - sort
                                  - type
                                  - value
                                  - index
                                  - pageIndex
                                  - lastLevel
                                x-apifox-orders:
                                  - children
                                  - depth
                                  - direction
                                  - expanded
                                  - id
                                  - parentId
                                  - showTip
                                  - sort
                                  - type
                                  - value
                                  - index
                                  - lastLevel
                                  - pageIndex
                            depth:
                              type: integer
                            direction:
                              type: integer
                            expanded:
                              type: boolean
                            id:
                              type: integer
                            pageIndex:
                              type: integer
                            parentId:
                              type: integer
                            showTip:
                              type: boolean
                            sort:
                              type: integer
                            type:
                              type: string
                            value:
                              type: string
                            index:
                              type: integer
                          required:
                            - children
                            - depth
                            - direction
                            - expanded
                            - id
                            - pageIndex
                            - parentId
                            - showTip
                            - sort
                            - type
                            - value
                          x-apifox-orders:
                            - children
                            - depth
                            - direction
                            - expanded
                            - id
                            - pageIndex
                            - parentId
                            - showTip
                            - sort
                            - type
                            - value
                            - index
                      depth:
                        type: integer
                      direction:
                        type: integer
                      expanded:
                        type: boolean
                      id:
                        type: integer
                      index:
                        type: integer
                      pageIndex:
                        type: integer
                      parentId:
                        type: integer
                      showTip:
                        type: boolean
                      sort:
                        type: integer
                      type:
                        type: string
                      value:
                        type: string
                    required:
                      - children
                      - depth
                      - direction
                      - expanded
                      - id
                      - index
                      - pageIndex
                      - parentId
                      - showTip
                      - sort
                      - type
                      - value
                    x-apifox-orders:
                      - children
                      - depth
                      - direction
                      - expanded
                      - id
                      - index
                      - pageIndex
                      - parentId
                      - showTip
                      - sort
                      - type
                      - value
                    description: 根据Markdown文本生成的PPT树形结构
                  msg:
                    type: string
                    description: 返回提示信息
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 0
                data:
                  children:
                    - children:
                        - children: []
                          depth: 3
                          direction: 1
                          expanded: true
                          id: 3
                          parentId: 2
                          showTip: false
                          sort: 0
                          type: title
                          value: 协议公示
                      depth: 2
                      direction: 1
                      expanded: true
                      id: 2
                      pageIndex: 2
                      parentId: 1
                      showTip: false
                      sort: 0
                      type: catalog
                      value: 目录
                    - children:
                        - children: []
                          depth: 3
                          direction: 1
                          expanded: true
                          id: 5
                          index: 0
                          lastLevel: true
                          pageIndex: 4
                          parentId: 4
                          showTip: false
                          sort: 0
                          type: title
                          value: ''
                        - children:
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 7
                              index: 0
                              lastLevel: true
                              parentId: 6
                              showTip: false
                              sort: 0
                              type: title
                              value: 默认标题“天鹅到家协议公示
                          depth: 3
                          direction: 1
                          expanded: true
                          id: 6
                          index: 0
                          pageIndex: 5
                          parentId: 4
                          showTip: false
                          sort: 1
                          type: title
                          value: 标题
                        - children:
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 9
                              index: 0
                              lastLevel: true
                              parentId: 8
                              showTip: false
                              sort: 0
                              type: title
                              value: 展示所有协议，数据来源单独配置数据，不读取已有的协议管理后台数据
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 10
                              index: 0
                              lastLevel: true
                              parentId: 8
                              showTip: false
                              sort: 1
                              type: title
                              value: 元素：标题、顺序来源于配置；
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 11
                              index: 0
                              lastLevel: true
                              parentId: 8
                              showTip: false
                              sort: 2
                              type: title
                              value: 点击互相切换协议目录，右侧子目录切换对应数据；
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 12
                              index: 0
                              lastLevel: true
                              parentId: 8
                              showTip: false
                              sort: 3
                              type: title
                              value: 样式：默认颜色、选中颜色+小图标
                          depth: 3
                          direction: 1
                          expanded: true
                          id: 8
                          index: 0
                          pageIndex: 6
                          parentId: 4
                          showTip: false
                          sort: 2
                          type: title
                          value: 公示协议tab
                        - children:
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 14
                              index: 0
                              lastLevel: true
                              parentId: 13
                              showTip: false
                              sort: 0
                              type: title
                              value: 元素：标题、跳转地址、顺序来源于配置；
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 15
                              index: 0
                              lastLevel: true
                              parentId: 13
                              showTip: false
                              sort: 1
                              type: title
                              value: 点击跳转协议详情页：样式同PC隐私协议、只展示协议内容、不展示撤销入口、不展示公示信息等；
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 16
                              index: 0
                              lastLevel: true
                              parentId: 13
                              showTip: false
                              sort: 2
                              type: title
                              value: 样式：默认颜色、鼠标指针浮动标红、最大折行，最多3行；
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 17
                              index: 0
                              lastLevel: true
                              parentId: 13
                              showTip: false
                              sort: 3
                              type: title
                              value: 全部展示
                          depth: 3
                          direction: 1
                          expanded: true
                          id: 13
                          index: 0
                          pageIndex: 7
                          parentId: 4
                          showTip: false
                          sort: 3
                          type: title
                          value: 内容
                        - children:
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 19
                              index: 0
                              lastLevel: true
                              parentId: 18
                              showTip: false
                              sort: 0
                              type: title
                              value: ''
                            - children: []
                              depth: 4
                              direction: 1
                              expanded: true
                              id: 20
                              index: 0
                              lastLevel: true
                              parentId: 18
                              showTip: false
                              sort: 1
                              type: title
                              value: ''
                          depth: 3
                          direction: 1
                          expanded: true
                          id: 18
                          index: 0
                          pageIndex: 8
                          parentId: 4
                          showTip: false
                          sort: 4
                          type: title
                          value: 空态样式
                        - children: []
                          depth: 3
                          direction: 1
                          expanded: true
                          id: 21
                          index: 0
                          lastLevel: true
                          pageIndex: 9
                          parentId: 4
                          showTip: false
                          sort: 5
                          type: title
                          value: 底部复用底部导航
                      depth: 2
                      direction: 1
                      expanded: true
                      id: 4
                      index: 0
                      pageIndex: 3
                      parentId: 1
                      showTip: false
                      sort: 1
                      type: title
                      value: 协议公示
                    - children: []
                      depth: 2
                      direction: 1
                      expanded: true
                      id: 22
                      pageIndex: 10
                      parentId: 1
                      showTip: false
                      sort: 2
                      type: ending
                      value: 结语
                  depth: 1
                  direction: 1
                  expanded: true
                  id: 1
                  index: 0
                  pageIndex: 1
                  parentId: 0
                  showTip: false
                  sort: 0
                  type: title
                  value: 官网
                msg: 获取成功
          headers: {}
          x-apifox-name: 成功
      security: []
      x-apifox-folder: ''
      x-apifox-status: released
      x-run-in-apifox: https://app.apifox.com/web/project/4285308/apis/api-165843992-run
components:
  schemas: {}
  securitySchemes: {}
servers:
  - url: http://dev-cn.your-api-server.com
    description: 开发环境
  - url: http://test-cn.your-api-server.com
    description: 测试环境
  - url: https://co.aippt.cn
    description: 正式环境
security: []

```
