交换机详情

概述


查询单个交换机详细信息


URL

/index.php?m=api&a=switchDetailed


▍请求参数


字段名
变量名
必填
类型
描述
交换机id
id

int
交换机ID
交换机日志
switch_log

boolean
是否获取交换机日志,默认不获取

返回参数


字段名
变量名
类型
描述
交换机详情
switch
array 
id  交换机id
sname  交换机名称
portnum  端口数量
version  型号
sname_tag   交换机内部标签
pwd  交换机密码
telnetuname  telnet账号
telnetpwd  telnet密码
vlan  交换机VLAN
vlanid  VLAN id
switch_sh_file  交换机脚本文件
type  交换机类型(1:自用公网,2:自用IPMI,3:自用内网,4:租用,5:托管,6:机柜,7:其他)
device  设备类型(switch:交换机,router:路由器,firewall:防火墙,other:其他)
conn  连接状态(on:正常,off:断开,nonsupport:不支持)
bind_mac  mac绑定(true,false)
bind_vlan  vlan绑定(true,false)
remarks 备注
snmp  SNMP团体名
attest 连接方式(telnet,ssh)
u  设备大小(多少U)
switch_num   上级交换机端口
vlanid  所占vlan
in_bw  进带宽
out_bw  出带宽
bandwidth  端口速率
port_status  端口状态(1:开,2:关,3:断开)
switch  上级交换机名称
switch_id  上级交换机ID
cabinet_id  所属机柜ID
cabinet  所属机柜名称
ip  分配IP的ID
ipaddress  分配的IP地址
subnetmask  子网掩码
gateway  网关
status  状态(1:空闲,2:到期,3:正常,4:故障)
email  客户邮箱
交换机的详细信息
交换机日志
switch_log
array
ip  操作地址
date  操作时间
description   描述
user  操作人(系统内部)
clients  操作客户(外部)
whmcs  WHMCS操作(外部)
api  api操作(外部)
交换机日志,最新10条
交换机ID
int
交换机ID

下级交换机
switchList
array
id 下级交换机id
sname  下级交换机名称
switch_num  下级交换机端口
下级交换机
自定义信息
system_custom_fields

array

id 自定义字段id

fieldtype 自定义字段类型 0文本框,1单选框,2单选按钮,3多选按钮,4多选框

fieldoptions 自定义字段选项,除文本框都有,value值,name名称,order排序

name 自定义字段名称

description 自定义字段描述

value 自定义字段值

show_value 显示的值

交换机自定义字段
状态
status
string
success 成功  error 失败
提示信息
msg
string
出错信息