green

package
v1.20.76 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: 13 Imported by: 0

Documentation

Index

Constants

View Source
const MIME string = "application/json"

Variables

This section is empty.

Functions

func ErrorResult

func ErrorResult(error error) string

Types

type BizData

type BizData struct {
	BizType string   `json:"bizType"`
	Scenes  []string `json:"scenes"`
	Tasks   []Task   `json:"tasks"`
}

type ClinetInfo

type ClinetInfo struct {
	SdkVersion  string `json:"sdkVersion"`
	CfgVersion  string `json:"cfgVersion"`
	UserType    string `json:"userType"`
	UserId      string `json:"userId"`
	UserNick    string `json:"userNick"`
	Avatar      string `json:"avatar"`
	Imei        string `json:"imei"`
	Imsi        string `json:"imsi"`
	Umid        string `json:"umid"`
	Ip          string `json:"ip"`
	Os          string `json:"os"`
	Channel     string `json:"channel"`
	HostAppName string `json:"hostAppName"`
	HostPackage string `json:"hostPackage"`
	HostVersion string `json:"hostVersion"`
}

type DefaultClient

type DefaultClient struct {
	Profile Profile
}

func (DefaultClient) GetResponse

func (defaultClient DefaultClient) GetResponse(path string, clinetInfo ClinetInfo, bizData BizData) string

type IAliYunClient

type IAliYunClient interface {
	GetResponse(path string, clinetInfo ClinetInfo, bizData BizData) string
}

type Profile

type Profile struct {
	AccessKeyId     string
	AccessKeySecret string
}

type Task

type Task struct {
	DataId  string `json:"dataId"`
	Url     string `json:"url"`
	Content string `json:"content"`
	Type    string `json:"type"`
}

type VoiceTask

type VoiceTask struct {
	Scenes   []string `json:"scenes"`
	Callback string   `json:"callback"`
	Seed     string   `json:"seed"`
	Tasks    []Task   `json:"tasks"`
}

Jump to

Keyboard shortcuts

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