- auth
- fs
- public
- admin
创建存储
正式环境
正式环境
POST
/api/admin/storage/create
alist Copy/admin/storage
最后修改时间:2024-05-17 12:03:10
责任人:未设置
请求参数
Header 参数
Authorization
string
token
示例值:
{{alist_token}}
Body 参数application/json
id
string
ID
mount_path
string
挂载路径
order
integer
排序
driver
string
驱动
remark
string
备注名
cache_expiration
integer
缓存过期时间
status
string
必需
web_proxy
boolean
web代理
webdav_policy
string
webdav策略
down_proxy_url
string
下载代理
order_by
string
排序方式
extract_folder
string
提取目录
order_direction
string
排序方向
addition
string
额外信息
enable_sign
string
启用签名
示例
{
"mount_path": "/lll",
"order": 0,
"remark": "",
"cache_expiration": 30,
"web_proxy": false,
"webdav_policy": "native_proxy",
"down_proxy_url": "",
"extract_folder": "front",
"enable_sign": false,
"driver": "Local",
"order_by": "name",
"order_direction": "asc",
"addition": "{\"root_folder_path\":\"/\",\"thumbnail\":false,\"thumb_cache_folder\":\"\",\"show_hidden\":true,\"mkdir_perm\":\"777\"}"
}
示例代码
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://prod-cn.your-api-server.com/api/admin/storage/create' \
--header 'Authorization: {{alist_token}}' \
--header 'Content-Type: application/json' \
--data-raw '{
"mount_path": "/lll",
"order": 0,
"remark": "",
"cache_expiration": 30,
"web_proxy": false,
"webdav_policy": "native_proxy",
"down_proxy_url": "",
"extract_folder": "front",
"enable_sign": false,
"driver": "Local",
"order_by": "name",
"order_direction": "asc",
"addition": "{\"root_folder_path\":\"/\",\"thumbnail\":false,\"thumb_cache_folder\":\"\",\"show_hidden\":true,\"mkdir_perm\":\"777\"}"
}'
返回响应
🟢200成功
application/json
Body
code
integer
状态码
message
string
信息
data
object
data
id
integer
必需
示例
{
"code": 200,
"message": "success",
"data": {
"id": 7
}
}
修改于 2024-05-17 12:03:10