跳到正文
Navigation

查看网站密码访问保护状态

POST
https://your-panel.example.com:8888/site

查看或关闭网站的密码访问保护(HTTP Basic Auth)。

Request body application/x-www-form-urlencoded required

  • request_time
    string
    required

    Unix 时间戳。

  • request_token
    string
    required

    按 API 概览生成的签名。

Returns

default

接口响应,业务状态见下方详细说明。

各操作详细说明

GetHasPwd查看网站密码访问保护状态

GetHasPwd / CloseHasPwd

查看或关闭网站的密码访问保护(HTTP Basic Auth)。

  • 路由:POST /site

GetHasPwd

查看密码保护状态。

参数名称 必选 类型 描述
action 是 String GetHasPwd
id 是 Integer 网站 ID

输出

参数名称 类型 描述
(原始值) Boolean true = 已启用密码保护,false = 未启用
false

CloseHasPwd

关闭密码保护。

参数名称 必选 类型 描述
action 是 String CloseHasPwd
id 是 Integer 网站 ID

输出

参数名称 类型 描述
status Boolean true 设置成功
msg String 提示信息
{"status": true, "msg": "设置成功"}

相关接口

Type to search…

↑↓ navigate↵ selectEsc close