Documentation
¶
Index ¶
- func NewMccCardControlRequest() *mccCardControlRequest
- func NewVelocityCardControlRequest() *velocityCardControlRequest
- type CardControlCommon
- type CardControlData
- type CardControlRequest
- type CardControlResponse
- type CardControlTypeRequest
- type CardControlsQuery
- type CardControlsQueryResponse
- type CardLimit
- type ControlType
- type MccControlType
- type MccLimit
- type UpdateCardControlRequest
- type VelocityLimit
- type VelocityWindow
- type VelocityWindowType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewMccCardControlRequest ¶
func NewMccCardControlRequest() *mccCardControlRequest
func NewVelocityCardControlRequest ¶
func NewVelocityCardControlRequest() *velocityCardControlRequest
Types ¶
type CardControlCommon ¶
type CardControlCommon struct {
ControlType ControlType `json:"control_type,omitempty"`
Description string `json:"description,omitempty"`
TargetId string `json:"target_id,omitempty"`
}
type CardControlData ¶
type CardControlData struct {
HttpMetadata common.HttpMetadata
ControlType ControlType `json:"control_type,omitempty"`
Id string `json:"id,omitempty"`
Description string `json:"description,omitempty"`
TargetId string `json:"target_id,omitempty"`
CreatedDate *time.Time `json:"created_date,omitempty"`
LastModifiedDate *time.Time `json:"last_modified_date,omitempty"`
}
type CardControlRequest ¶
type CardControlRequest interface {
GetControlType() ControlType
}
type CardControlResponse ¶
type CardControlResponse struct {
CardControlData
Limit CardLimit `json:"limit,omitempty"`
}
func (*CardControlResponse) UnmarshalJSON ¶
func (s *CardControlResponse) UnmarshalJSON(data []byte) error
type CardControlTypeRequest ¶
type CardControlTypeRequest struct {
CardControlRequest
}
type CardControlsQuery ¶
type CardControlsQuery struct {
TargetId string `url:"target_id,omitempty"`
}
type CardControlsQueryResponse ¶
type CardControlsQueryResponse struct {
HttpMetadata common.HttpMetadata
Controls []CardControlResponse `json:"controls,omitempty"`
}
type CardLimit ¶
type CardLimit interface {
GetType() ControlType
}
type ControlType ¶
type ControlType string
const ( VelocityLimitType ControlType = "velocity_limit" MccLimitType ControlType = "mcc_limit" )
type MccControlType ¶
type MccControlType string
const ( Allow MccControlType = "allow" Block MccControlType = "block" )
type MccLimit ¶
type MccLimit struct {
Type MccControlType `json:"type,omitempty"`
MccList []string `json:"mcc_list,omitempty"`
}
func (MccLimit) GetType ¶
func (l MccLimit) GetType() ControlType
type UpdateCardControlRequest ¶
type UpdateCardControlRequest struct {
Description string `json:"description,omitempty"`
VelocityLimit *VelocityLimit `json:"velocity_limit,omitempty"`
MccLimit *MccLimit `json:"mcc_limit,omitempty"`
}
type VelocityLimit ¶
type VelocityLimit struct {
AmountLimit int `json:"amount_limit,omitempty"`
VelocityWindow VelocityWindow `json:"velocity_window"`
MccList []string `json:"mcc_list,omitempty"`
}
func (VelocityLimit) GetType ¶
func (l VelocityLimit) GetType() ControlType
type VelocityWindow ¶
type VelocityWindow struct {
Type VelocityWindowType `json:"type,omitempty" :"type"`
}
type VelocityWindowType ¶
type VelocityWindowType string
const ( Daily VelocityWindowType = "daily" Weekly VelocityWindowType = "weekly" Monthly VelocityWindowType = "monthly" AllTime VelocityWindowType = "all_time" )
Click to show internal directories.
Click to hide internal directories.