重装系统
POST
server/reinstall
请求参数
Authorization
在 Header 添加参数
Authorization
,其值为在 Bearer 之后拼接 Token示例:
Authorization: Bearer ********************
Body 参数application/json
system_id
integer
系统镜像ID
password
string
必需
remote_port
integer
必需
dns
string
可选
hd_type
integer
可选
hd_lvm
integer
可选
hd_config
array [object {5}]
分区配置
path
string
必需
format
string
必需
size
number
必需
unit
string
必需
boot
string
必需
示例
{
"system_id": 0,
"password": "string",
"remote_port": 0,
"dns": "string",
"hd_type": 0,
"hd_lvm": 0,
"hd_config": [
{
"path": "string",
"format": "string",
"size": 0,
"unit": "string",
"boot": "string"
}
]
}
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'http://probill.local/api/server/reinstall' \
--header 'Content-Type: application/json' \
--data-raw '{
"system_id": 0,
"password": "string",
"remote_port": 0,
"dns": "string",
"hd_type": 0,
"hd_lvm": 0,
"hd_config": [
{
"path": "string",
"format": "string",
"size": 0,
"unit": "string",
"boot": "string"
}
]
}'
返回响应
🟢200成功
application/json
Body
code
integer
必需
msg
string
必需
time
integer
必需
data
object
必需
task_id
integer
必需
示例
{
"code": 0,
"msg": "安装任务提交成功,等待队列任务执行",
"time": 1741847521,
"data": {
"task_id": 20723
}
}
修改于 2025-03-13 08:38:40