自定义个性提醒

添加
请求链接:
/api/lockVoiceShortcuts/add请求方式:
POST参数说明:
| 名称 | 类型 | 是否必需 | 示例 | 描述 |
|---|---|---|---|---|
| lock_id | Int | Y | 123456 | 锁ID |
| type | Int | Y | 10 | 语音类型 10:智能提醒 20:事件警告语 30:快捷回复语 |
| timbre_type | Int | Y | 1 | 音色类型 1:系统 2:自定义上传 3:自定义音色 |
| name | String | Y | "小仙女生日" | 语音名称 |
| voice_url | String | N | "https://example.com/voice.mp3" | 语音URL timbre_type=2时必填 |
| lang | String | N | "zh_CN" | 语种 timbre_type=1时必传 请通过/user/getSupportedLangs接口获取数据 |
| timbre | String | N | "zh-CN-XiaoxiaoNeural" | 音色 timbre_type=1,3时必传 请通过/user/getSupportedLangs或/customTimbre/getAvailableCustomTimbres接口获取数据 |
| dates | Array | N | ["2025-09-22","2025-09-22"] | 语音日期范围 type=10时必传 |
| content | String | N | "test" | 语音内容 timbre_type=1 时必传 |
| blessing_voice_id | Int | N | 1 | 祝福语音ID type=10时可传 请通过获取祝福语音列表接口获取 |
| open_mode | Int | N | 1 | 开门方式 type=10时必传 1:电子钥匙 2:密码 3:IC卡 4:指纹 5:人脸 6:掌静脉 7:遥控 |
| user_no | Int | N | 1 | 开门方式userNo type=10时必传 |
| event_type | Int | N | 1 | 事件类型 type=20时必传 |
- 返回参数及示例:
| 参数 | 类型 | 描述 |
|---|---|---|
| errorCode | Int | 错误码 |
| description | String | 描述信息 |
| errorMsg | String | 错误信息 |
| data | Object | 返回数据 |
| voice_url | String | 语音URL |
json
{
"errorCode": 0,
"description": "success",
"errorMsg": "success",
"data": {
"voice_url": "https://lock.xie.star-lock.cn/storage/star_voice_shortcut/1/1e03751b-0f47-4738-8c89-91599a8eafd5.mp3"
}
}列表
请求链接:
/api/lockVoiceShortcuts/list请求方式:
POST参数说明:
| 名称 | 类型 | 是否必需 | 示例 | 描述 |
|---|---|---|---|---|
| lock_id | Int | Y | 123456 | 锁ID |
| type | Int | Y | 10 | 语音类型 10:智能提醒 20:事件警告语 30:快捷回复语 |
| page_no | Int | N | 1 | 页码 |
| page_size | Int | N | 10 | 每页数量 |
- 返回参数及示例:
| 参数 | 类型 | 描述 |
|---|---|---|
| errorCode | Int | 错误码 |
| description | String | 描述信息 |
| errorMsg | String | 错误信息 |
| data | Object | 返回数据 |
| list | Array | 语音列表 |
| voice_id | Int | 语音ID |
| name | String | 语音名称 |
| voice_url | String | 语音URL |
| lang | String | 语种 |
| timbre | String | 音色 |
| timbre_type | Int | 音色类型 1:系统 2:自定义上传 3:自定义音色 |
| type | Int | 语音类型 10:智能提醒 20:事件警告语 30:快捷回复语 |
| content | String | 语音内容 |
| dates | Array | 语音日期范围 |
| blessing_voice_id | Int | 祝福语音ID |
| blessing_voice_url | String | 祝福语音URL |
| open_mode | Int | 开门方式 1:电子钥匙 2:密码 3:IC卡 4:指纹 5:人脸 6:掌静脉 7:遥控 |
| user_no | Int | 开门方式userNo |
| event_type | Int | 事件类型 |
| total | Int | 总数 |
| page_no | Int | 页码 |
| page_size | Int | 每页数量 |
json
{
"errorCode": 0,
"description": "success",
"errorMsg": "success",
"data": {
"list": [
{
"voice_id": 2,
"name": "小仙女生日",
"voice_url": "https://lock.xie.star-lock.cn/storage/star_voice_shortcut/1/1e03751b-0f47-4738-8c89-91599a8eafd5.mp3",
"lang": "zh_CN",
"timbre": "zh-CN-XiaoxiaoNeural",
"timbre_type": 1,
"type": 10,
"content": "test",
"dates": [
"2025-09-22"
],
"blessing_voice_id": 0,
"blessing_voice_url": "",
"open_mode": 1,
"user_no": 1,
"event_type": 0
},
{
"voice_id": 1,
"name": "小仙女生日",
"voice_url": "https://lock.xie.star-lock.cn/storage/star_voice_shortcut/1/c16c6e81-a9be-439e-921f-0742db32722f.mp3",
"lang": "zh_CN",
"timbre": "zh-CN-XiaoxiaoNeural",
"timbre_type": 1,
"type": 10,
"content": "test",
"dates": [
"2025-09-22"
],
"blessing_voice_id": 0,
"blessing_voice_url": "",
"open_mode": 1,
"user_no": 1,
"event_type": 0
}
],
"total": 2,
"page_no": 1,
"page_size": 10
}
}删除
请求链接:
/api/lockVoiceShortcuts/delete请求方式:
POST参数说明:
| 名称 | 类型 | 是否必需 | 示例 | 描述 |
|---|---|---|---|---|
| voice_id | Int | Y | 1 | 语音ID |
- 返回参数及示例:
| 参数 | 类型 | 描述 |
|---|---|---|
| errorCode | Int | 错误码 |
| description | String | 描述信息 |
| errorMsg | String | 错误信息 |
| data | Object | 返回数据 |
json
{
"errorCode": 0,
"description": "success",
"errorMsg": "success",
"data": {}
}