Documentation ¶
Overview ¶
Package security 内容安全
Index ¶
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ImgSecCheck ¶
func ImgSecCheck(ctx *miniprogram.Miniprogram, media string) (resp []byte, err error)
校验一张图片是否含有违法违规内容。
POST(@media) https://api.weixin.qq.com/wxa/img_sec_check?access_token=ACCESS_TOKEN
Example ¶
package main import ( "fmt" "github.com/fastwego/miniprogram" "github.com/fastwego/miniprogram/minigame/apis/security" ) func main() { var ctx *miniprogram.Miniprogram media := "" resp, err := security.ImgSecCheck(ctx, media) fmt.Println(resp, err) }
Output:
func MediaCheckAsync ¶
func MediaCheckAsync(ctx *miniprogram.Miniprogram, payload []byte) (resp []byte, err error)
异步校验图片/音频是否含有违法违规内容。
POST https://api.weixin.qq.com/wxa/media_check_async?access_token=ACCESS_TOKEN
Example ¶
package main import ( "fmt" "github.com/fastwego/miniprogram" "github.com/fastwego/miniprogram/minigame/apis/security" ) func main() { var ctx *miniprogram.Miniprogram payload := []byte("{}") resp, err := security.MediaCheckAsync(ctx, payload) fmt.Println(resp, err) }
Output:
func MsgSecCheck ¶
func MsgSecCheck(ctx *miniprogram.Miniprogram, payload []byte) (resp []byte, err error)
检查一段文本是否含有违法违规内容。
POST https://api.weixin.qq.com/wxa/msg_sec_check?access_token=ACCESS_TOKEN
Example ¶
package main import ( "fmt" "github.com/fastwego/miniprogram" "github.com/fastwego/miniprogram/minigame/apis/security" ) func main() { var ctx *miniprogram.Miniprogram payload := []byte("{}") resp, err := security.MsgSecCheck(ctx, payload) fmt.Println(resp, err) }
Output:
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.