riskcontrol

package
v2.1.11 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 28, 2023 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RiskControl

type RiskControl struct {
	*context.Context
}

RiskControl 安全风控

func NewRiskControl

func NewRiskControl(ctx *context.Context) *RiskControl

NewRiskControl init

func (*RiskControl) GetUserRiskRank

func (riskControl *RiskControl) GetUserRiskRank(in *UserRiskRankRequest) (res UserRiskRank, err error)

GetUserRiskRank 根据提交的用户信息数据获取用户的安全等级 risk_rank,无需用户授权。

type UserRiskRank

type UserRiskRank struct {
	util.CommonError
	UnionID  int64 `json:"union_id"`  // 唯一请求标识
	RiskRank uint8 `json:"risk_rank"` // 用户风险等级
}

UserRiskRank 用户安全等级

type UserRiskRankRequest

type UserRiskRankRequest struct {
	AppID    string `json:"appid"`     // 小程序 app id
	OpenID   string `json:"openid"`    // 用户的 openid
	Scene    uint8  `json:"scene"`     // 场景值,0:注册,1:营销作弊
	ClientIP string `json:"client_ip"` // 用户访问源ip

	Mobile       string `json:"mobile_no"`     // 用户手机号
	Email        string `json:"email_address"` // 用户邮箱地址
	ExtendedInfo string `json:"extended_info"` // 额外补充信息
	IsTest       bool   `json:"is_test"`       // false:正式调用,true:测试调用
}

UserRiskRankRequest 获取用户安全等级请求

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL