import "github.com/dueros/bot-sdk-go/bot/model"
- type Request
- func (this *Request) GetAccessToken() string
- func (this *Request) GetAudioPlayerContext() data.AudioPlayerContext
- func (this *Request) GetBotId() string
- func (this *Request) GetDeviceId() string
- func (this *Request) GetRequestId() string
- func (this *Request) GetSupportedInterfaces() map[string]interface{}
- func (this *Request) GetTimestamp() int
- func (this *Request) GetUserId() string
- func (this *Request) GetVideoPlayerContext() data.VideoPlayerContext
- func (this *Request) IsSupportAudio() bool
- func (this *Request) IsSupportDisplay() bool
- func (this *Request) IsSupportVideo() bool
- func (this *Request) VerifyBotID(myBotID string) bool
- func (this *Request) VerifyTimestamp() bool
dialog.go intent.go request.go response.go session.go ssml_builder.go
type Request struct {
Type string
Common data.RequestPart
}
func (*Request) GetAccessToken
func (this *Request) GetAccessToken() string
获取access token
func (*Request) GetAudioPlayerContext
func (this *Request) GetAudioPlayerContext() data.AudioPlayerContext
获取音频播放上下文
func (this *Request) GetBotId() string
获取技能id
func (*Request) GetDeviceId
func (this *Request) GetDeviceId() string
获取设备id
func (*Request) GetRequestId
func (this *Request) GetRequestId() string
获取请求id
func (*Request) GetSupportedInterfaces
func (this *Request) GetSupportedInterfaces() map[string]interface{}
获取设备支持的接口类型
func (*Request) GetTimestamp
func (this *Request) GetTimestamp() int
获取请求的时间戳
func (this *Request) GetUserId() string
获取用户id
func (*Request) GetVideoPlayerContext
func (this *Request) GetVideoPlayerContext() data.VideoPlayerContext
获取视频播放上下文
func (*Request) IsSupportAudio
func (this *Request) IsSupportAudio() bool
检查是否支持音频播放
func (*Request) IsSupportDisplay
func (this *Request) IsSupportDisplay() bool
检查是否支持展现
func (*Request) IsSupportVideo
func (this *Request) IsSupportVideo() bool
检查是否支持视频播放
func (*Request) VerifyBotID
func (this *Request) VerifyBotID(myBotID string) bool
验证技能id合法性
func (*Request) VerifyTimestamp
func (this *Request) VerifyTimestamp() bool
验证请求时间戳合法性
Generated by godoc2md
import "github.com/dueros/bot-sdk-go/bot/model"
dialog.go intent.go request.go response.go session.go ssml_builder.go
type LaunchRequest struct {
Data data.LaunchRequest
Request
}
Generated by godoc2md
import "github.com/dueros/bot-sdk-go/bot/model"
dialog.go intent.go request.go response.go session.go ssml_builder.go
type IntentRequest struct {
Data data.IntentRequest
Dialog *Dialog
Request
}
func (*IntentRequest) GetIntentName
func (this *IntentRequest) GetIntentName() (string, bool)
获取意图名
func (this *IntentRequest) GetQuery() string
获取用户请求query
func (*IntentRequest) IsDialogStateCompleted
func (this *IntentRequest) IsDialogStateCompleted() bool
槽位填充是否完成
Generated by godoc2md
import "github.com/dueros/bot-sdk-go/bot/model"
dialog.go intent.go request.go response.go session.go ssml_builder.go
type SessionEndedRequest struct {
Data data.SessionEndedRequest
Request
}
Generated by godoc2md
import "github.com/dueros/bot-sdk-go/bot/model"
dialog.go intent.go request.go response.go session.go ssml_builder.go
type EventRequest struct {
Data data.EventRequest
Request
}
func (this *EventRequest) GetName() string
func (this *EventRequest) GetUrl() string
Generated by godoc2md