mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-07-07 04:08:13 +08:00
删除录像相关api
@@ -20,9 +20,6 @@ MediaServer是ZLMediaKit的主进程,目前支持以下http api接口,这些
|
||||
"/index/api/restartServer",
|
||||
"/index/api/setServerConfig",
|
||||
"/index/api/isMediaOnline",
|
||||
"/index/api/startRecord",
|
||||
"/index/api/stopRecord",
|
||||
"/index/api/getRecordStatus",
|
||||
"/index/api/getMediaInfo",
|
||||
"/index/api/getSsrcInfo",
|
||||
"/index/api/getMp4RecordFile"
|
||||
@@ -284,7 +281,7 @@ MediaServer是ZLMediaKit的主进程,目前支持以下http api接口,这些
|
||||
"vhost" : "__defaultVhost__"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
@@ -584,92 +581,8 @@ MediaServer是ZLMediaKit的主进程,目前支持以下http api接口,这些
|
||||
```
|
||||
|
||||
|
||||
### 17、`/index/api/startRecord`
|
||||
|
||||
- 功能:开始录制hls或MP4
|
||||
|
||||
- 范例:[http://127.0.0.1/index/api/startRecord?type=1&vhost=`__defaultVhost__`&app=live&stream=obs&wait_for_record=1&continue_record=1](http://127.0.0.1/index/api/startRecord?type=1&vhost=__defaultVhost__&app=live&stream=obs&wait_for_record=1&continue_record=1)
|
||||
|
||||
- 参数:
|
||||
|
||||
| 参数 | 是否必选 | 释意 | 类型 |
|
||||
| :-------------: | :------: | :----------------------------------------------------------: | ------ |
|
||||
| secret | Y | api操作密钥(配置文件配置),如果操作ip是127.0.0.1,则不需要此参数 | string |
|
||||
| type | Y | 0为hls,1为mp4 | 0/1 |
|
||||
| vhost | Y | 虚拟主机,例如`__defaultVhost__` | string |
|
||||
| app | Y | 应用名,例如 live | string |
|
||||
| stream | Y | 流id,例如 obs | string |
|
||||
| wait_for_record | Y | 1代表等待流注册后再录制,置0在流未注册时返回失败 | 0/1 |
|
||||
| continue_record | Y | 流注销时是否继续等待录制还是立即停止录制 | 0/1 |
|
||||
| customized_path | N | 录像保存目录 | string |
|
||||
|
||||
|
||||
- 响应:
|
||||
|
||||
```json
|
||||
{
|
||||
"code" : 0,
|
||||
"result" : 0 # 0代表成功,负数代表失败及原因
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
### 18、`/index/api/stopRecord`
|
||||
|
||||
- 功能:停止录制流
|
||||
|
||||
- 范例:[http://127.0.0.1/index/api/stopRecord?type=1&vhost=`__defaultVhost__`&app=live&stream=obs](http://127.0.0.1/index/api/stopRecord?type=1&vhost=__defaultVhost__&app=live&stream=obs)
|
||||
|
||||
- 参数:
|
||||
|
||||
| 参数 | 是否必选 | 释意 |
|
||||
| :----: | :------: | :----------------------------------------------------------: |
|
||||
| secret | Y | api操作密钥(配置文件配置),如果操作ip是127.0.0.1,则不需要此参数 |
|
||||
| type | Y | 0为hls,1为mp4 |
|
||||
| vhost | Y | 虚拟主机,例如`__defaultVhost__` |
|
||||
| app | Y | 应用名,例如 live |
|
||||
| stream | Y | 流id,例如 obs |
|
||||
|
||||
|
||||
- 响应:
|
||||
|
||||
```json
|
||||
{
|
||||
"code" : 0,
|
||||
"result" : 1 # 1:停止录制成功,0:失败,原因是不存在该录制行为
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
|
||||
### 19、`/index/api/getRecordStatus`
|
||||
|
||||
- 功能:获取流录制状态
|
||||
|
||||
- 范例:[http://127.0.0.1/index/api/getRecordStatus?type=1&vhost=`__defaultVhost__`&app=live&stream=obs](http://127.0.0.1/index/api/getRecordStatus?type=1&vhost=__defaultVhost__&app=live&stream=obs)
|
||||
|
||||
- 参数:
|
||||
|
||||
| 参数 | 是否必选 | 释意 |
|
||||
| :----: | :------: | :----------------------------------------------------------: |
|
||||
| secret | Y | api操作密钥(配置文件配置),如果操作ip是127.0.0.1,则不需要此参数 |
|
||||
| type | Y | 0为hls,1为mp4 |
|
||||
| vhost | Y | 虚拟主机,例如`__defaultVhost__` |
|
||||
| app | Y | 应用名,例如 live |
|
||||
| stream | Y | 流id,例如 obs |
|
||||
|
||||
|
||||
- 响应:
|
||||
|
||||
```json
|
||||
{
|
||||
"code" : 0,
|
||||
"status" : 1 # 0:未录制,1:等待流注册,注册成功后立即开始录制,2:流已注册,并且正在录制
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
### 20、`/index/api/getMediaInfo`
|
||||
### 17、`/index/api/getMediaInfo`
|
||||
|
||||
- 功能:获取流相关信息
|
||||
|
||||
@@ -709,7 +622,7 @@ MediaServer是ZLMediaKit的主进程,目前支持以下http api接口,这些
|
||||
}
|
||||
```
|
||||
|
||||
### 21、`/index/api/getSsrcInfo`
|
||||
### 18、`/index/api/getSsrcInfo`
|
||||
|
||||
- 功能:获取rtp代理时的某路ssrc rtp信息
|
||||
|
||||
@@ -735,7 +648,7 @@ MediaServer是ZLMediaKit的主进程,目前支持以下http api接口,这些
|
||||
```
|
||||
|
||||
|
||||
### 22、`/index/api/getMp4RecordFile`
|
||||
### 19、`/index/api/getMp4RecordFile`
|
||||
|
||||
- 功能:搜索文件系统,获取流对应的录像文件列表或日期文件夹列表
|
||||
- 范例:[http://127.0.0.1/index/api/getMp4RecordFile?vhost=`__defaultVhost__`&app=live&stream=ss&period=2020-01](http://127.0.0.1/index/api/getMp4RecordFile?vhost=__defaultVhost__&app=live&stream=ss&period=2020-01)
|
||||
@@ -785,3 +698,4 @@ MediaServer是ZLMediaKit的主进程,目前支持以下http api接口,这些
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user