[create-pull-request] automated change (#143)
Co-authored-by: joshuaspence <joshuaspence@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
aed72d864b
commit
f3077d3b3c
7
unifi/device.generated.go
generated
7
unifi/device.generated.go
generated
@@ -51,7 +51,6 @@ type Device struct {
|
||||
LcmIDleTimeout int `json:"lcm_idle_timeout,omitempty"` // [1-9][0-9]|[1-9][0-9][0-9]|[1-2][0-9][0-9][0-9]|3[0-5][0-9][0-9]|3600
|
||||
LcmIDleTimeoutOverride bool `json:"lcm_idle_timeout_override,omitempty"`
|
||||
LcmNightModeBegins string `json:"lcm_night_mode_begins,omitempty"` // (^$)|(^(0[1-9])|(1[0-9])|(2[0-3])):([0-5][0-9]$)
|
||||
LcmNightModeEnabled bool `json:"lcm_night_mode_enabled,omitempty"`
|
||||
LcmNightModeEnds string `json:"lcm_night_mode_ends,omitempty"` // (^$)|(^(0[1-9])|(1[0-9])|(2[0-3])):([0-5][0-9]$)
|
||||
LcmSettingsRestrictedAccess bool `json:"lcm_settings_restricted_access,omitempty"`
|
||||
LcmTrackerEnabled bool `json:"lcm_tracker_enabled,omitempty"`
|
||||
@@ -244,11 +243,14 @@ type DevicePortOverrides struct {
|
||||
Dot1XIDleTimeout int `json:"dot1x_idle_timeout,omitempty"` // [0-9]|[1-9][0-9]{1,3}|[1-5][0-9]{4}|6[0-4][0-9]{3}|65[0-4][0-9]{2}|655[0-2][0-9]|6553[0-5]
|
||||
EgressRateLimitKbps int `json:"egress_rate_limit_kbps,omitempty"` // 6[4-9]|[7-9][0-9]|[1-9][0-9]{2,6}
|
||||
EgressRateLimitKbpsEnabled bool `json:"egress_rate_limit_kbps_enabled,omitempty"`
|
||||
ExcludedNetworkIDs []string `json:"excluded_networkconf_ids,omitempty"`
|
||||
Forward string `json:"forward,omitempty"` // all|native|customize|disabled
|
||||
FullDuplex bool `json:"full_duplex,omitempty"`
|
||||
Isolation bool `json:"isolation,omitempty"`
|
||||
LldpmedEnabled bool `json:"lldpmed_enabled,omitempty"`
|
||||
LldpmedNotifyEnabled bool `json:"lldpmed_notify_enabled,omitempty"`
|
||||
MirrorPortIDX int `json:"mirror_port_idx,omitempty"` // [1-9]|[1-4][0-9]|5[0-2]
|
||||
NATiveNetworkID string `json:"native_networkconf_id,omitempty"`
|
||||
Name string `json:"name,omitempty"` // .{0,128}
|
||||
OpMode string `json:"op_mode,omitempty"` // switch|mirror|aggregate
|
||||
PoeMode string `json:"poe_mode,omitempty"` // auto|pasv24|passthrough|off
|
||||
@@ -260,6 +262,8 @@ type DevicePortOverrides struct {
|
||||
PriorityQueue2Level int `json:"priority_queue2_level,omitempty"` // [0-9]|[1-9][0-9]|100
|
||||
PriorityQueue3Level int `json:"priority_queue3_level,omitempty"` // [0-9]|[1-9][0-9]|100
|
||||
PriorityQueue4Level int `json:"priority_queue4_level,omitempty"` // [0-9]|[1-9][0-9]|100
|
||||
SettingPreference string `json:"setting_preference,omitempty"` // auto|manual
|
||||
ShowTrafficRestrictionAsAllowlist bool `json:"show_traffic_restriction_as_allowlist,omitempty"`
|
||||
Speed int `json:"speed,omitempty"` // 10|100|1000|2500|5000|10000|20000|25000|40000|50000|100000
|
||||
StormctrlBroadcastastEnabled bool `json:"stormctrl_bcast_enabled,omitempty"`
|
||||
StormctrlBroadcastastLevel int `json:"stormctrl_bcast_level,omitempty"` // [0-9]|[1-9][0-9]|100
|
||||
@@ -272,6 +276,7 @@ type DevicePortOverrides struct {
|
||||
StormctrlUcastLevel int `json:"stormctrl_ucast_level,omitempty"` // [0-9]|[1-9][0-9]|100
|
||||
StormctrlUcastRate int `json:"stormctrl_ucast_rate,omitempty"` // [0-9]|[1-9][0-9]{1,6}|1[0-3][0-9]{6}|14[0-7][0-9]{5}|148[0-7][0-9]{4}|14880000
|
||||
StpPortMode bool `json:"stp_port_mode,omitempty"`
|
||||
VoiceNetworkID string `json:"voice_networkconf_id,omitempty"`
|
||||
}
|
||||
|
||||
func (dst *DevicePortOverrides) UnmarshalJSON(b []byte) error {
|
||||
|
||||
26
unifi/network.generated.go
generated
26
unifi/network.generated.go
generated
@@ -26,7 +26,6 @@ type Network struct {
|
||||
NoEdit bool `json:"attr_no_edit,omitempty"`
|
||||
|
||||
AutoScaleEnabled bool `json:"auto_scale_enabled"`
|
||||
ClientMACList []string `json:"client_mac_list,omitempty"` // ^([0-9A-Fa-f]{2}:){5}([0-9A-Fa-f]{2})$
|
||||
DHCPDBootEnabled bool `json:"dhcpd_boot_enabled"`
|
||||
DHCPDBootFilename string `json:"dhcpd_boot_filename,omitempty"` // .{1,256}
|
||||
DHCPDBootServer string `json:"dhcpd_boot_server"` // ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$|^$|(?=^.{3,253}$)(^((?!-)[a-zA-Z0-9-]{1,63}(?<!-)\.)+[a-zA-Z]{2,63}$)|[a-zA-Z0-9-]{1,63}|^$
|
||||
@@ -80,13 +79,15 @@ type Network struct {
|
||||
IGMPGroupmembership int `json:"igmp_groupmembership,omitempty"` // [2-9]|[1-9][0-9]{1,2}|[1-2][0-9]{3}|3[0-5][0-9]{2}|3600|^$
|
||||
IGMPMaxresponse int `json:"igmp_maxresponse,omitempty"` // [1-9]|1[0-9]|2[0-5]|^$
|
||||
IGMPMcrtrexpiretime int `json:"igmp_mcrtrexpiretime,omitempty"` // [0-9]|[1-9][0-9]{1,2}|[1-2][0-9]{3}|3[0-5][0-9]{2}|3600|^$
|
||||
IGMPProxyDownstream bool `json:"igmp_proxy_downstream"`
|
||||
IGMPProxyUpstream bool `json:"igmp_proxy_upstream"`
|
||||
IGMPQuerier string `json:"igmp_querier"` // ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$|^$
|
||||
IGMPSnooping bool `json:"igmp_snooping"`
|
||||
IGMPSupression bool `json:"igmp_supression"`
|
||||
IPSecDhGroup int `json:"ipsec_dh_group,omitempty"` // 2|5|14|15|16|19|20|21|25|26
|
||||
IPSecDynamicRouting bool `json:"ipsec_dynamic_routing"`
|
||||
IPSecEncryption string `json:"ipsec_encryption,omitempty"` // aes128|aes192|aes256|3des
|
||||
IPSecEspDhGroup int `json:"ipsec_esp_dh_group,omitempty"` // 1|2|5|14|15|16|17|18
|
||||
IPSecEspDhGroup int `json:"ipsec_esp_dh_group,omitempty"` // 1|2|5|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30|31|32
|
||||
IPSecHash string `json:"ipsec_hash,omitempty"` // sha1|md5|sha256|sha384|sha512
|
||||
IPSecIkeDhGroup int `json:"ipsec_ike_dh_group,omitempty"` // 1|2|5|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30|31|32
|
||||
IPSecInterface string `json:"ipsec_interface,omitempty"` // wan|wan2
|
||||
@@ -107,8 +108,6 @@ type Network struct {
|
||||
IPV6RaValidLifetime int `json:"ipv6_ra_valid_lifetime,omitempty"` // ^([0-9]|[1-8][0-9]|9[0-9]|[1-8][0-9]{2}|9[0-8][0-9]|99[0-9]|[1-8][0-9]{3}|9[0-8][0-9]{2}|99[0-8][0-9]|999[0-9]|[1-8][0-9]{4}|9[0-8][0-9]{3}|99[0-8][0-9]{2}|999[0-8][0-9]|9999[0-9]|[1-8][0-9]{5}|9[0-8][0-9]{4}|99[0-8][0-9]{3}|999[0-8][0-9]{2}|9999[0-8][0-9]|99999[0-9]|[1-8][0-9]{6}|9[0-8][0-9]{5}|99[0-8][0-9]{4}|999[0-8][0-9]{3}|9999[0-8][0-9]{2}|99999[0-8][0-9]|999999[0-9]|[12][0-9]{7}|30[0-9]{6}|31[0-4][0-9]{5}|315[0-2][0-9]{4}|3153[0-5][0-9]{3}|31536000)$|^$
|
||||
IPV6Subnet string `json:"ipv6_subnet,omitempty"`
|
||||
InternetAccessEnabled bool `json:"internet_access_enabled"`
|
||||
IntraNetworkAccessEnabled bool `json:"intra_network_access_enabled"`
|
||||
IntraNetworks []string `json:"intra_networks,omitempty"` // [\d\w]+
|
||||
IsNAT bool `json:"is_nat"`
|
||||
L2TpAllowWeakCiphers bool `json:"l2tp_allow_weak_ciphers"`
|
||||
L2TpInterface string `json:"l2tp_interface,omitempty"` // wan|wan2
|
||||
@@ -121,10 +120,13 @@ type Network struct {
|
||||
NATOutboundIPAddresses []NetworkNATOutboundIPAddresses `json:"nat_outbound_ip_addresses,omitempty"`
|
||||
Name string `json:"name,omitempty"` // .{1,128}
|
||||
NetworkGroup string `json:"networkgroup,omitempty"` // LAN[2-8]?
|
||||
NetworkIsolationEnabled bool `json:"network_isolation_enabled"`
|
||||
OpenVPNConfiguration string `json:"openvpn_configuration,omitempty"`
|
||||
OpenVPNConfigurationFilename string `json:"openvpn_configuration_filename,omitempty"`
|
||||
OpenVPNInterface string `json:"openvpn_interface,omitempty"` // wan|wan2
|
||||
OpenVPNLocalAddress string `json:"openvpn_local_address,omitempty"` // ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$
|
||||
OpenVPNLocalPort int `json:"openvpn_local_port,omitempty"` // ^([1-9][0-9]{0,3}|[1-5][0-9]{4}|[6][0-4][0-9]{3}|[6][5][0-4][0-9]{2}|[6][5][5][0-2][0-9]|[6][5][5][3][0-5])$
|
||||
OpenVPNLocalWANIP string `json:"openvpn_local_wan_ip,omitempty"` // ^any$|^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$
|
||||
OpenVPNMode string `json:"openvpn_mode,omitempty"` // site-to-site|client|server
|
||||
OpenVPNRemoteAddress string `json:"openvpn_remote_address,omitempty"` // ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$
|
||||
OpenVPNRemoteHost string `json:"openvpn_remote_host,omitempty"` // [^\"\' ]+|^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$
|
||||
@@ -150,10 +152,12 @@ type Network struct {
|
||||
VLANEnabled bool `json:"vlan_enabled"`
|
||||
VPNClientDefaultRoute bool `json:"vpn_client_default_route"`
|
||||
VPNClientPullDNS bool `json:"vpn_client_pull_dns"`
|
||||
VPNType string `json:"vpn_type,omitempty"` // auto|ipsec-vpn|openvpn-client|openvpn-vpn|pptp-client|l2tp-server|pptp-server|uid-server|wireguard-server
|
||||
VPNProtocol string `json:"vpn_protocol,omitempty"` // tcp|udp
|
||||
VPNType string `json:"vpn_type,omitempty"` // auto|ipsec-vpn|openvpn-client|openvpn-server|openvpn-vpn|pptp-client|l2tp-server|pptp-server|uid-server|wireguard-server
|
||||
VrrpIPSubnetGw1 string `json:"vrrp_ip_subnet_gw1,omitempty"` // ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\/([1-9]|[1-2][0-9]|30)$
|
||||
VrrpIPSubnetGw2 string `json:"vrrp_ip_subnet_gw2,omitempty"` // ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\/([1-9]|[1-2][0-9]|30)$
|
||||
VrrpVrid int `json:"vrrp_vrid,omitempty"` // [1-9]|[1-9][0-9]
|
||||
WANDHCPCos int `json:"wan_dhcp_cos,omitempty"` // [0-7]|^$
|
||||
WANDHCPOptions []NetworkWANDHCPOptions `json:"wan_dhcp_options,omitempty"`
|
||||
WANDHCPv6PDSize int `json:"wan_dhcpv6_pd_size,omitempty"` // ^(4[89]|5[0-9]|6[0-4])$|^$
|
||||
WANDNS1 string `json:"wan_dns1"` // ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$|^$
|
||||
@@ -184,10 +188,18 @@ type Network struct {
|
||||
WireguardInterface string `json:"wireguard_interface,omitempty"` // wan|wan2
|
||||
WireguardLocalWANIP string `json:"wireguard_local_wan_ip,omitempty"` // ^any$|^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$
|
||||
WireguardPublicKey string `json:"wireguard_public_key,omitempty"`
|
||||
XAuthKey string `json:"x_auth_key,omitempty"`
|
||||
XCaCrt string `json:"x_ca_crt,omitempty"`
|
||||
XCaKey string `json:"x_ca_key,omitempty"`
|
||||
XDhKey string `json:"x_dh_key,omitempty"`
|
||||
XIPSecPreSharedKey string `json:"x_ipsec_pre_shared_key,omitempty"` // [^\"\' ]+
|
||||
XOpenVPNPassword string `json:"x_openvpn_password,omitempty"`
|
||||
XOpenVPNSharedSecretKey string `json:"x_openvpn_shared_secret_key,omitempty"` // [0-9A-Fa-f]{512}
|
||||
XPptpcPassword string `json:"x_pptpc_password,omitempty"` // [^\"\' ]+
|
||||
XServerCrt string `json:"x_server_crt,omitempty"`
|
||||
XServerKey string `json:"x_server_key,omitempty"`
|
||||
XSharedClientCrt string `json:"x_shared_client_crt,omitempty"`
|
||||
XSharedClientKey string `json:"x_shared_client_key,omitempty"`
|
||||
XWANPassword string `json:"x_wan_password,omitempty"` // [^"' ]+
|
||||
XWireguardPrivateKey string `json:"x_wireguard_private_key,omitempty"`
|
||||
}
|
||||
@@ -207,7 +219,6 @@ func (dst *Network) UnmarshalJSON(b []byte) error {
|
||||
IPV6RaPreferredLifetime emptyStringInt `json:"ipv6_ra_preferred_lifetime"`
|
||||
IPV6RaValidLifetime emptyStringInt `json:"ipv6_ra_valid_lifetime"`
|
||||
InternetAccessEnabled *bool `json:"internet_access_enabled"`
|
||||
IntraNetworkAccessEnabled *bool `json:"intra_network_access_enabled"`
|
||||
LocalPort emptyStringInt `json:"local_port"`
|
||||
OpenVPNLocalPort emptyStringInt `json:"openvpn_local_port"`
|
||||
OpenVPNRemotePort emptyStringInt `json:"openvpn_remote_port"`
|
||||
@@ -216,6 +227,7 @@ func (dst *Network) UnmarshalJSON(b []byte) error {
|
||||
RouteDistance emptyStringInt `json:"route_distance"`
|
||||
VLAN emptyStringInt `json:"vlan"`
|
||||
VrrpVrid emptyStringInt `json:"vrrp_vrid"`
|
||||
WANDHCPCos emptyStringInt `json:"wan_dhcp_cos"`
|
||||
WANDHCPv6PDSize emptyStringInt `json:"wan_dhcpv6_pd_size"`
|
||||
WANEgressQOS emptyStringInt `json:"wan_egress_qos"`
|
||||
WANLoadBalanceWeight emptyStringInt `json:"wan_load_balance_weight"`
|
||||
@@ -245,7 +257,6 @@ func (dst *Network) UnmarshalJSON(b []byte) error {
|
||||
dst.IPV6RaPreferredLifetime = int(aux.IPV6RaPreferredLifetime)
|
||||
dst.IPV6RaValidLifetime = int(aux.IPV6RaValidLifetime)
|
||||
dst.InternetAccessEnabled = emptyBoolToTrue(aux.InternetAccessEnabled)
|
||||
dst.IntraNetworkAccessEnabled = emptyBoolToTrue(aux.IntraNetworkAccessEnabled)
|
||||
dst.LocalPort = int(aux.LocalPort)
|
||||
dst.OpenVPNLocalPort = int(aux.OpenVPNLocalPort)
|
||||
dst.OpenVPNRemotePort = int(aux.OpenVPNRemotePort)
|
||||
@@ -254,6 +265,7 @@ func (dst *Network) UnmarshalJSON(b []byte) error {
|
||||
dst.RouteDistance = int(aux.RouteDistance)
|
||||
dst.VLAN = int(aux.VLAN)
|
||||
dst.VrrpVrid = int(aux.VrrpVrid)
|
||||
dst.WANDHCPCos = int(aux.WANDHCPCos)
|
||||
dst.WANDHCPv6PDSize = int(aux.WANDHCPv6PDSize)
|
||||
dst.WANEgressQOS = int(aux.WANEgressQOS)
|
||||
dst.WANLoadBalanceWeight = int(aux.WANLoadBalanceWeight)
|
||||
|
||||
5
unifi/port_profile.generated.go
generated
5
unifi/port_profile.generated.go
generated
@@ -30,6 +30,7 @@ type PortProfile struct {
|
||||
Dot1XIDleTimeout int `json:"dot1x_idle_timeout,omitempty"` // [0-9]|[1-9][0-9]{1,3}|[1-5][0-9]{4}|6[0-4][0-9]{3}|65[0-4][0-9]{2}|655[0-2][0-9]|6553[0-5]
|
||||
EgressRateLimitKbps int `json:"egress_rate_limit_kbps,omitempty"` // 6[4-9]|[7-9][0-9]|[1-9][0-9]{2,6}
|
||||
EgressRateLimitKbpsEnabled bool `json:"egress_rate_limit_kbps_enabled"`
|
||||
ExcludedNetworkIDs []string `json:"excluded_networkconf_ids,omitempty"`
|
||||
Forward string `json:"forward,omitempty"` // all|native|customize|disabled
|
||||
FullDuplex bool `json:"full_duplex"`
|
||||
Isolation bool `json:"isolation"`
|
||||
@@ -38,7 +39,7 @@ type PortProfile struct {
|
||||
NATiveNetworkID string `json:"native_networkconf_id"`
|
||||
Name string `json:"name,omitempty"`
|
||||
OpMode string `json:"op_mode,omitempty"` // switch
|
||||
PoeMode string `json:"poe_mode,omitempty"` // auto|pasv24|passthrough|off
|
||||
PoeMode string `json:"poe_mode,omitempty"` // auto|off
|
||||
PortSecurityEnabled bool `json:"port_security_enabled"`
|
||||
PortSecurityMACAddress []string `json:"port_security_mac_address,omitempty"` // ^([0-9A-Fa-f]{2}[:]){5}([0-9A-Fa-f]{2})$
|
||||
PriorityQueue1Level int `json:"priority_queue1_level,omitempty"` // [0-9]|[1-9][0-9]|100
|
||||
@@ -46,6 +47,7 @@ type PortProfile struct {
|
||||
PriorityQueue3Level int `json:"priority_queue3_level,omitempty"` // [0-9]|[1-9][0-9]|100
|
||||
PriorityQueue4Level int `json:"priority_queue4_level,omitempty"` // [0-9]|[1-9][0-9]|100
|
||||
SettingPreference string `json:"setting_preference,omitempty"` // auto|manual
|
||||
ShowTrafficRestrictionAsAllowlist bool `json:"show_traffic_restriction_as_allowlist"`
|
||||
Speed int `json:"speed,omitempty"` // 10|100|1000|2500|5000|10000|20000|25000|40000|50000|100000
|
||||
StormctrlBroadcastastEnabled bool `json:"stormctrl_bcast_enabled"`
|
||||
StormctrlBroadcastastLevel int `json:"stormctrl_bcast_level,omitempty"` // [0-9]|[1-9][0-9]|100
|
||||
@@ -58,7 +60,6 @@ type PortProfile struct {
|
||||
StormctrlUcastLevel int `json:"stormctrl_ucast_level,omitempty"` // [0-9]|[1-9][0-9]|100
|
||||
StormctrlUcastRate int `json:"stormctrl_ucast_rate,omitempty"` // [0-9]|[1-9][0-9]{1,6}|1[0-3][0-9]{6}|14[0-7][0-9]{5}|148[0-7][0-9]{4}|14880000
|
||||
StpPortMode bool `json:"stp_port_mode"`
|
||||
TaggedNetworkIDs []string `json:"tagged_networkconf_ids,omitempty"`
|
||||
VoiceNetworkID string `json:"voice_networkconf_id"`
|
||||
}
|
||||
|
||||
|
||||
7
unifi/schedule_task.generated.go
generated
7
unifi/schedule_task.generated.go
generated
@@ -25,15 +25,10 @@ type ScheduleTask struct {
|
||||
NoDelete bool `json:"attr_no_delete,omitempty"`
|
||||
NoEdit bool `json:"attr_no_edit,omitempty"`
|
||||
|
||||
Action string `json:"action,omitempty"` // stream|upgrade
|
||||
AdditionalSoundsEnabled bool `json:"additional_sounds_enabled"`
|
||||
BroadcastgroupID string `json:"broadcastgroup_id"`
|
||||
Action string `json:"action,omitempty"` // upgrade
|
||||
CronExpr string `json:"cron_expr,omitempty"`
|
||||
ExecuteOnlyOnce bool `json:"execute_only_once"`
|
||||
MediafileID string `json:"mediafile_id"`
|
||||
Name string `json:"name,omitempty"`
|
||||
SampleFilename string `json:"sample_filename,omitempty"`
|
||||
StreamType string `json:"stream_type,omitempty"` // media|sample
|
||||
UpgradeTargets []ScheduleTaskUpgradeTargets `json:"upgrade_targets,omitempty"`
|
||||
}
|
||||
|
||||
|
||||
33
unifi/setting_guest_access.generated.go
generated
33
unifi/setting_guest_access.generated.go
generated
@@ -29,7 +29,6 @@ type SettingGuestAccess struct {
|
||||
|
||||
AllowedSubnet string `json:"allowed_subnet_,omitempty"`
|
||||
Auth string `json:"auth,omitempty"` // none|hotspot|facebook_wifi|custom
|
||||
AuthorizeUseSandbox bool `json:"authorize_use_sandbox"`
|
||||
CustomIP string `json:"custom_ip"` // ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$|^$
|
||||
EcEnabled bool `json:"ec_enabled"`
|
||||
Expire string `json:"expire,omitempty"` // [\d]+|custom
|
||||
@@ -41,31 +40,35 @@ type SettingGuestAccess struct {
|
||||
FacebookWifiBlockHttps bool `json:"facebook_wifi_block_https"`
|
||||
FacebookWifiGwID string `json:"facebook_wifi_gw_id"`
|
||||
FacebookWifiGwName string `json:"facebook_wifi_gw_name,omitempty"`
|
||||
Gateway string `json:"gateway,omitempty"` // paypal|stripe|authorize|quickpay|merchantwarrior|ippay
|
||||
Gateway string `json:"gateway,omitempty"` // stripe
|
||||
GoogleClientID string `json:"google_client_id"`
|
||||
GoogleDomain string `json:"google_domain,omitempty"`
|
||||
GoogleEnabled bool `json:"google_enabled"`
|
||||
GoogleScopeEmail bool `json:"google_scope_email"`
|
||||
IPpayUseSandbox bool `json:"ippay_use_sandbox"`
|
||||
MerchantwarriorUseSandbox bool `json:"merchantwarrior_use_sandbox"`
|
||||
PasswordEnabled bool `json:"password_enabled"`
|
||||
PaymentEnabled bool `json:"payment_enabled"`
|
||||
PaypalUseSandbox bool `json:"paypal_use_sandbox"`
|
||||
PortalCustomized bool `json:"portal_customized"`
|
||||
PortalCustomizedAuthenticationText string `json:"portal_customized_authentication_text,omitempty"`
|
||||
PortalCustomizedBgColor string `json:"portal_customized_bg_color"` // ^#[a-zA-Z0-9]{6}$|^#[a-zA-Z0-9]{3}$|^$
|
||||
PortalCustomizedBgImageEnabled bool `json:"portal_customized_bg_image_enabled"`
|
||||
PortalCustomizedBgImageFilename string `json:"portal_customized_bg_image_filename,omitempty"`
|
||||
PortalCustomizedBgImageTile bool `json:"portal_customized_bg_image_tile"`
|
||||
PortalCustomizedBgType string `json:"portal_customized_bg_type,omitempty"` // color|image|gallery
|
||||
PortalCustomizedBoxColor string `json:"portal_customized_box_color"` // ^#[a-zA-Z0-9]{6}$|^#[a-zA-Z0-9]{3}$|^$
|
||||
PortalCustomizedBoxLinkColor string `json:"portal_customized_box_link_color"` // ^#[a-zA-Z0-9]{6}$|^#[a-zA-Z0-9]{3}$|^$
|
||||
PortalCustomizedBoxOpacity int `json:"portal_customized_box_opacity,omitempty"` // ^[1-9][0-9]?$|^100$|^$
|
||||
PortalCustomizedBoxRADIUS int `json:"portal_customized_box_radius,omitempty"` // [0-9]|[1-4][0-9]|50
|
||||
PortalCustomizedBoxTextColor string `json:"portal_customized_box_text_color"` // ^#[a-zA-Z0-9]{6}$|^#[a-zA-Z0-9]{3}$|^$
|
||||
PortalCustomizedButtonColor string `json:"portal_customized_button_color"` // ^#[a-zA-Z0-9]{6}$|^#[a-zA-Z0-9]{3}$|^$
|
||||
PortalCustomizedButtonText string `json:"portal_customized_button_text,omitempty"`
|
||||
PortalCustomizedButtonTextColor string `json:"portal_customized_button_text_color"` // ^#[a-zA-Z0-9]{6}$|^#[a-zA-Z0-9]{3}$|^$
|
||||
PortalCustomizedLanguages []string `json:"portal_customized_languages,omitempty"` // ^[a-z]{2}(_[A-Z]{2})*$
|
||||
PortalCustomizedLanguages []string `json:"portal_customized_languages,omitempty"` // ^[a-z]{2}([_-][a-zA-Z]{2,4})*$
|
||||
PortalCustomizedLinkColor string `json:"portal_customized_link_color"` // ^#[a-zA-Z0-9]{6}$|^#[a-zA-Z0-9]{3}$|^$
|
||||
PortalCustomizedLogoEnabled bool `json:"portal_customized_logo_enabled"`
|
||||
PortalCustomizedLogoFilename string `json:"portal_customized_logo_filename,omitempty"`
|
||||
PortalCustomizedLogoPosition string `json:"portal_customized_logo_position,omitempty"` // left|center|right
|
||||
PortalCustomizedLogoSize int `json:"portal_customized_logo_size,omitempty"` // 6[4-9]|[7-9][0-9]|1[0-8][0-9]|19[0-2]
|
||||
PortalCustomizedSuccessText string `json:"portal_customized_success_text,omitempty"`
|
||||
PortalCustomizedTextColor string `json:"portal_customized_text_color"` // ^#[a-zA-Z0-9]{6}$|^#[a-zA-Z0-9]{3}$|^$
|
||||
PortalCustomizedTitle string `json:"portal_customized_title,omitempty"`
|
||||
PortalCustomizedTos string `json:"portal_customized_tos,omitempty"`
|
||||
@@ -78,7 +81,6 @@ type SettingGuestAccess struct {
|
||||
PortalEnabled bool `json:"portal_enabled"`
|
||||
PortalHostname string `json:"portal_hostname"` // ^[a-zA-Z0-9.-]+$|^$
|
||||
PortalUseHostname bool `json:"portal_use_hostname"`
|
||||
QuickpayTestmode bool `json:"quickpay_testmode"`
|
||||
RADIUSAuthType string `json:"radius_auth_type,omitempty"` // chap|mschapv2
|
||||
RADIUSDisconnectEnabled bool `json:"radius_disconnect_enabled"`
|
||||
RADIUSDisconnectPort int `json:"radius_disconnect_port,omitempty"` // [1-9][0-9]{0,3}|[1-5][0-9]{4}|[6][0-4][0-9]{3}|[6][5][0-4][0-9]{2}|[6][5][5][0-2][0-9]|[6][5][5][3][0-5]
|
||||
@@ -91,29 +93,16 @@ type SettingGuestAccess struct {
|
||||
RestrictedDNSEnabled bool `json:"restricted_dns_enabled"`
|
||||
RestrictedDNSServers []string `json:"restricted_dns_servers,omitempty"` // ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$|^$
|
||||
RestrictedSubnet string `json:"restricted_subnet_,omitempty"`
|
||||
SettingPreference string `json:"setting_preference,omitempty"` // auto|manual
|
||||
TemplateEngine string `json:"template_engine,omitempty"` // jsp|angular
|
||||
VoucherCustomized bool `json:"voucher_customized"`
|
||||
VoucherEnabled bool `json:"voucher_enabled"`
|
||||
WechatAppID string `json:"wechat_app_id"`
|
||||
WechatEnabled bool `json:"wechat_enabled"`
|
||||
WechatShopID string `json:"wechat_shop_id"`
|
||||
XAuthorizeLoginid string `json:"x_authorize_loginid,omitempty"`
|
||||
XAuthorizeTransactionkey string `json:"x_authorize_transactionkey,omitempty"`
|
||||
XFacebookAppSecret string `json:"x_facebook_app_secret,omitempty"`
|
||||
XFacebookWifiGwSecret string `json:"x_facebook_wifi_gw_secret,omitempty"`
|
||||
XGoogleClientSecret string `json:"x_google_client_secret,omitempty"`
|
||||
XIPpayTerminalid string `json:"x_ippay_terminalid,omitempty"`
|
||||
XMerchantwarriorApikey string `json:"x_merchantwarrior_apikey,omitempty"`
|
||||
XMerchantwarriorApipassphrase string `json:"x_merchantwarrior_apipassphrase,omitempty"`
|
||||
XMerchantwarriorMerchantuuid string `json:"x_merchantwarrior_merchantuuid,omitempty"`
|
||||
XPassword string `json:"x_password,omitempty"`
|
||||
XPaypalPassword string `json:"x_paypal_password,omitempty"`
|
||||
XPaypalSignature string `json:"x_paypal_signature,omitempty"`
|
||||
XPaypalUsername string `json:"x_paypal_username,omitempty"`
|
||||
XQuickpayAgreementid string `json:"x_quickpay_agreementid,omitempty"`
|
||||
XQuickpayApikey string `json:"x_quickpay_apikey,omitempty"`
|
||||
XQuickpayMerchantid string `json:"x_quickpay_merchantid,omitempty"`
|
||||
XStripeApiKey string `json:"x_stripe_api_key,omitempty"`
|
||||
XWechatAppSecret string `json:"x_wechat_app_secret,omitempty"`
|
||||
XWechatSecretKey string `json:"x_wechat_secret_key,omitempty"`
|
||||
@@ -125,6 +114,8 @@ func (dst *SettingGuestAccess) UnmarshalJSON(b []byte) error {
|
||||
ExpireNumber emptyStringInt `json:"expire_number"`
|
||||
ExpireUnit emptyStringInt `json:"expire_unit"`
|
||||
PortalCustomizedBoxOpacity emptyStringInt `json:"portal_customized_box_opacity"`
|
||||
PortalCustomizedBoxRADIUS emptyStringInt `json:"portal_customized_box_radius"`
|
||||
PortalCustomizedLogoSize emptyStringInt `json:"portal_customized_logo_size"`
|
||||
RADIUSDisconnectPort emptyStringInt `json:"radius_disconnect_port"`
|
||||
|
||||
*Alias
|
||||
@@ -139,6 +130,8 @@ func (dst *SettingGuestAccess) UnmarshalJSON(b []byte) error {
|
||||
dst.ExpireNumber = int(aux.ExpireNumber)
|
||||
dst.ExpireUnit = int(aux.ExpireUnit)
|
||||
dst.PortalCustomizedBoxOpacity = int(aux.PortalCustomizedBoxOpacity)
|
||||
dst.PortalCustomizedBoxRADIUS = int(aux.PortalCustomizedBoxRADIUS)
|
||||
dst.PortalCustomizedLogoSize = int(aux.PortalCustomizedLogoSize)
|
||||
dst.RADIUSDisconnectPort = int(aux.RADIUSDisconnectPort)
|
||||
|
||||
return nil
|
||||
|
||||
87
unifi/setting_magic_site_to_site_vpn.generated.go
generated
Normal file
87
unifi/setting_magic_site_to_site_vpn.generated.go
generated
Normal file
@@ -0,0 +1,87 @@
|
||||
// Code generated from ace.jar fields *.json files
|
||||
// DO NOT EDIT.
|
||||
|
||||
package unifi
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// just to fix compile issues with the import
|
||||
var (
|
||||
_ context.Context
|
||||
_ fmt.Formatter
|
||||
_ json.Marshaler
|
||||
)
|
||||
|
||||
type SettingMagicSiteToSiteVpn struct {
|
||||
ID string `json:"_id,omitempty"`
|
||||
SiteID string `json:"site_id,omitempty"`
|
||||
|
||||
Hidden bool `json:"attr_hidden,omitempty"`
|
||||
HiddenID string `json:"attr_hidden_id,omitempty"`
|
||||
NoDelete bool `json:"attr_no_delete,omitempty"`
|
||||
NoEdit bool `json:"attr_no_edit,omitempty"`
|
||||
|
||||
Key string `json:"key"`
|
||||
|
||||
Enabled bool `json:"enabled"`
|
||||
}
|
||||
|
||||
func (dst *SettingMagicSiteToSiteVpn) UnmarshalJSON(b []byte) error {
|
||||
type Alias SettingMagicSiteToSiteVpn
|
||||
aux := &struct {
|
||||
*Alias
|
||||
}{
|
||||
Alias: (*Alias)(dst),
|
||||
}
|
||||
|
||||
err := json.Unmarshal(b, &aux)
|
||||
if err != nil {
|
||||
return fmt.Errorf("unable to unmarshal alias: %w", err)
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func (c *Client) getSettingMagicSiteToSiteVpn(ctx context.Context, site string) (*SettingMagicSiteToSiteVpn, error) {
|
||||
var respBody struct {
|
||||
Meta meta `json:"meta"`
|
||||
Data []SettingMagicSiteToSiteVpn `json:"data"`
|
||||
}
|
||||
|
||||
err := c.do(ctx, "GET", fmt.Sprintf("s/%s/get/setting/magic_site_to_site_vpn", site), nil, &respBody)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if len(respBody.Data) != 1 {
|
||||
return nil, &NotFoundError{}
|
||||
}
|
||||
|
||||
d := respBody.Data[0]
|
||||
return &d, nil
|
||||
}
|
||||
|
||||
func (c *Client) updateSettingMagicSiteToSiteVpn(ctx context.Context, site string, d *SettingMagicSiteToSiteVpn) (*SettingMagicSiteToSiteVpn, error) {
|
||||
var respBody struct {
|
||||
Meta meta `json:"meta"`
|
||||
Data []SettingMagicSiteToSiteVpn `json:"data"`
|
||||
}
|
||||
|
||||
d.Key = "magic_site_to_site_vpn"
|
||||
err := c.do(ctx, "PUT", fmt.Sprintf("s/%s/set/setting/magic_site_to_site_vpn", site), d, &respBody)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if len(respBody.Data) != 1 {
|
||||
return nil, &NotFoundError{}
|
||||
}
|
||||
|
||||
new := respBody.Data[0]
|
||||
|
||||
return &new, nil
|
||||
}
|
||||
2
unifi/user.generated.go
generated
2
unifi/user.generated.go
generated
@@ -42,6 +42,8 @@ type User struct {
|
||||
Note string `json:"note,omitempty"`
|
||||
UseFixedIP bool `json:"use_fixedip"`
|
||||
UserGroupID string `json:"usergroup_id"`
|
||||
VirtualNetworkOverrideEnabled bool `json:"virtual_network_override_enabled"`
|
||||
VirtualNetworkOverrideID string `json:"virtual_network_override_id"`
|
||||
}
|
||||
|
||||
func (dst *User) UnmarshalJSON(b []byte) error {
|
||||
|
||||
2
unifi/version.generated.go
generated
2
unifi/version.generated.go
generated
@@ -2,4 +2,4 @@
|
||||
|
||||
package unifi
|
||||
|
||||
const UnifiVersion = "7.3.83"
|
||||
const UnifiVersion = "7.4.156"
|
||||
|
||||
1
unifi/wlan.generated.go
generated
1
unifi/wlan.generated.go
generated
@@ -73,7 +73,6 @@ type WLAN struct {
|
||||
Priority string `json:"priority,omitempty"` // medium|high|low
|
||||
ProxyArp bool `json:"proxy_arp"`
|
||||
RADIUSDasEnabled bool `json:"radius_das_enabled"`
|
||||
RADIUSFilterIDEnabled bool `json:"radius_filter_id_enabled"`
|
||||
RADIUSMACAuthEnabled bool `json:"radius_mac_auth_enabled"`
|
||||
RADIUSMACaclEmptyPassword bool `json:"radius_macacl_empty_password"`
|
||||
RADIUSMACaclFormat string `json:"radius_macacl_format,omitempty"` // none_lower|hyphen_lower|colon_lower|none_upper|hyphen_upper|colon_upper
|
||||
|
||||
Reference in New Issue
Block a user