简要描述:

-课程供应链--章节目录

请求域名:

  • http://xx.com

请求URL:

plugin.course-supply.api.course.chapter-list

请求 参数::

参数名 是否必须 类型 说明
id int 课程id
not_paginate int 不分页 1是 0否

not_pageinate为0或者不传时返回示例:

正确时返回:

{
    "result": 1,
    "msg": "success",
    "data": {
        "current_page": 1,
        "data": [
            {
                "id": 2,
                "chapter_id": "123485345345123123236",
                "name": "测试章节2",
                "sort": 2,
                "created_at": 0,
                "updated_at": 0,
                "course_id": 1,
                "section": [
                    {
                        "id": 3,
                        "chapter_id": "2",
                        "section_id": "55",
                        "img": "https://img2.baidu.com/it/u=2172426948,177733952&fm=253&fmt=auto&app=138&f=PNG?w=454&h=500",
                        "name": "测试小节333",
                        "can_try": 1,
                        "try_time": 2147483647,
                        "sort": 1,
                        "video_minute": 1,
                        "video_second": 3,
                        "created_at": 0,
                        "updated_at": 0
                    }
                ]
            }
        ],
        "first_page_url": "http://119.91.205.224//addons/yun_shop/api.php?page=1",
        "from": 1,
        "last_page": 1,
        "last_page_url": "http://119.91.205.224//addons/yun_shop/api.php?page=1",
        "next_page_url": null,
        "path": "http://119.91.205.224//addons/yun_shop/api.php",
        "per_page": 10,
        "prev_page_url": null,
        "to": 2,
        "total": 2,
        "chapter_count": 2,
        "section_count": 4,
        "deadline": 1680217627,
        "course_status": 1
    }
}

not_pageinate为1时返回示例:

正确时返回:

{
    "result": 1,
    "msg": "success",
    "data": {
        "data": [
            {
                "id": 1,
                "chapter_id": "4d221b62-abb2-4a10-8a7e-25b84da8512c",
                "course_id": 1,
                "name": "gqer",
                "sort": 1,
                "created_at": 1683361659,
                "updated_at": 0,
                "section": [
                    {
                        "id": 1,
                        "chapter_id": "1",
                        "section_id": "3d6c754b-6bf7-4db6-98ff-7e7db4c940c3",
                        "img": "https://supply.yunzmall.com/uploads/file/f26ef914245883c80f181c4aade2ed04_20230426224601.png",
                        "name": "grqgq",
                        "can_try": 0,
                        "try_time": 0,
                        "url": "",
                        "sort": 1,
                        "video_minute": 1,
                        "video_second": 61,
                        "created_at": 1683361659,
                        "updated_at": 0
                    }
                ]
            }
        ],
        "deadline": 0,
        "course_status": 0,
        "chapter_count": null,
        "section_count": null,
        "is_ios_sell": "0"
    }
}

返回参数data说明:

参数名 类型 说明
chapter_id string 章节id
name string 章节名称
chapter_count int 章节数
section_count int 小节数
deadline int 有效截止日期时间戳 没有购买或者该课程为免费时为0
course_status int 0没购买 1已购买 2免费

返回参数section说明:

参数名 类型 说明
chapter_id string 章节id
section_id string 小节id
name string 小节名称
img string 小节封面
video_minute int 视频分钟数
video_second int 视频秒数
can_try int 能否试看 0 否 1是
try_time int 试看秒数