package v1



type TcpForwardingDataRequest struct {
	Id                int      `form:"id" json:"id"`
	CdnWebId          int      `form:"cdnWebId" json:"cdnWebId"`
	Port              string   `form:"port" json:"port" validate:"required,isPortStringValid"`
	BackendList       []string `form:"backendList" json:"backendList" validate:"required,dive,hostport"`
	Comment           string   `form:"comment" json:"comment" validate:"max=50"`
	Proxy             bool     `form:"proxy" json:"proxy" default:"false"`
}

type DeleteTcpForwardingRequest struct {
	Ids    []int `form:"ids" json:"ids" validate:"required,min=1,dive,required"`
	Uid    int   `form:"uid" json:"uid" validate:"required"`
	HostId int   `form:"hostId" json:"hostId" validate:"required"`
}

type TcpForwardingRequest struct {
	HostId            int                      `form:"hostId" json:"hostId" validate:"required"`
	Uid               int                      `form:"uid" json:"uid" validate:"required"`
	TcpForwardingData TcpForwardingDataRequest `form:"data" json:"data" validate:"required"`
}
