Documentation ¶
Index ¶
- Constants
- type Client
- func (c *Client) CreateSession(request *CreateSessionRequest) (response *CreateSessionResponse, err error)
- func (c *Client) DescribeStreamPlayInfoList(request *DescribeStreamPlayInfoListRequest) (response *DescribeStreamPlayInfoListResponse, err error)
- func (c *Client) DescribeWorkers(request *DescribeWorkersRequest) (response *DescribeWorkersResponse, err error)
- func (c *Client) ForbidLiveStream(request *ForbidLiveStreamRequest) (response *ForbidLiveStreamResponse, err error)
- func (c *Client) RegisterIM(request *RegisterIMRequest) (response *RegisterIMResponse, err error)
- func (c *Client) StopGame(request *StopGameRequest) (response *StopGameResponse, err error)
- type CreateSessionRequest
- type CreateSessionResponse
- type DayStreamPlayInfo
- type DescribeStreamPlayInfoListRequest
- type DescribeStreamPlayInfoListResponse
- type DescribeWorkersRequest
- type DescribeWorkersResponse
- type ForbidLiveStreamRequest
- type ForbidLiveStreamResponse
- type RegisterIMRequest
- type RegisterIMResponse
- type StopGameRequest
- type StopGameResponse
- type WorkerRegionInfo
Constants ¶
View Source
const APIVersion = "2019-03-13"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
func NewClient ¶
func NewClient(credential *common.Credential, region string, clientProfile *profile.ClientProfile) (client *Client, err error)
func NewClientWithSecretId ¶
Deprecated
func (*Client) CreateSession ¶
func (c *Client) CreateSession(request *CreateSessionRequest) (response *CreateSessionResponse, err error)
创建会话
func (*Client) DescribeStreamPlayInfoList ¶
func (c *Client) DescribeStreamPlayInfoList(request *DescribeStreamPlayInfoListRequest) (response *DescribeStreamPlayInfoListResponse, err error)
查询播放数据,支持按流名称查询详细播放数据,也可按播放域名查询详细总数据。
func (*Client) DescribeWorkers ¶
func (c *Client) DescribeWorkers(request *DescribeWorkersRequest) (response *DescribeWorkersResponse, err error)
查询空闲机器数量
func (*Client) ForbidLiveStream ¶
func (c *Client) ForbidLiveStream(request *ForbidLiveStreamRequest) (response *ForbidLiveStreamResponse, err error)
禁止某条流的推送,可以预设某个时刻将流恢复。
func (*Client) RegisterIM ¶
func (c *Client) RegisterIM(request *RegisterIMRequest) (response *RegisterIMResponse, err error)
注册聊天室
func (*Client) StopGame ¶
func (c *Client) StopGame(request *StopGameRequest) (response *StopGameResponse, err error)
强制退出游戏
type CreateSessionRequest ¶
type CreateSessionRequest struct { *tchttp.BaseRequest // 客户端session信息,从JSSDK请求中获得 ClientSession *string `json:"ClientSession,omitempty" name:"ClientSession"` // 游戏ID GameId *string `json:"GameId,omitempty" name:"GameId"` // 游戏用户ID UserId *string `json:"UserId,omitempty" name:"UserId"` // 游戏参数 GameParas *string `json:"GameParas,omitempty" name:"GameParas"` // 游戏区域 GameRegion *string `json:"GameRegion,omitempty" name:"GameRegion"` // 背景图url ImageUrl *string `json:"ImageUrl,omitempty" name:"ImageUrl"` // 分辨率 Resolution *string `json:"Resolution,omitempty" name:"Resolution"` }
func NewCreateSessionRequest ¶
func NewCreateSessionRequest() (request *CreateSessionRequest)
func (*CreateSessionRequest) FromJsonString ¶
func (r *CreateSessionRequest) FromJsonString(s string) error
func (*CreateSessionRequest) ToJsonString ¶
func (r *CreateSessionRequest) ToJsonString() string
type CreateSessionResponse ¶
type CreateSessionResponse struct { *tchttp.BaseResponse Response *struct { // 服务端session信息,返回给JSSDK ServerSession *string `json:"ServerSession,omitempty" name:"ServerSession"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 RequestId *string `json:"RequestId,omitempty" name:"RequestId"` } `json:"Response"` }
func NewCreateSessionResponse ¶
func NewCreateSessionResponse() (response *CreateSessionResponse)
func (*CreateSessionResponse) FromJsonString ¶
func (r *CreateSessionResponse) FromJsonString(s string) error
func (*CreateSessionResponse) ToJsonString ¶
func (r *CreateSessionResponse) ToJsonString() string
type DayStreamPlayInfo ¶
type DayStreamPlayInfo struct { // 带宽(单位Mbps)。 Bandwidth *float64 `json:"Bandwidth,omitempty" name:"Bandwidth"` // 流量 (单位MB)。 Flux *float64 `json:"Flux,omitempty" name:"Flux"` // 在线人数。 Online *uint64 `json:"Online,omitempty" name:"Online"` // 请求数。 Request *uint64 `json:"Request,omitempty" name:"Request"` // 数据时间点,格式:yyyy-mm-dd HH:MM:SS。 Time *string `json:"Time,omitempty" name:"Time"` }
type DescribeStreamPlayInfoListRequest ¶
type DescribeStreamPlayInfoListRequest struct { *tchttp.BaseRequest // 结束时间,北京时间,格式:2019-04-28 10:36:00 // 结束时间 和 开始时间 必须在同一天内。 EndTime *string `json:"EndTime,omitempty" name:"EndTime"` // 播放域名。 PlayDomain *string `json:"PlayDomain,omitempty" name:"PlayDomain"` // 开始时间,北京时间,格式:2019-04-28 10:36:00 // 当前时间 和 开始时间 间隔不超过30天。 StartTime *string `json:"StartTime,omitempty" name:"StartTime"` // 流名称,精确匹配。 // 若不填,则为查询总体播放数据。 StreamName *string `json:"StreamName,omitempty" name:"StreamName"` }
func NewDescribeStreamPlayInfoListRequest ¶
func NewDescribeStreamPlayInfoListRequest() (request *DescribeStreamPlayInfoListRequest)
func (*DescribeStreamPlayInfoListRequest) FromJsonString ¶
func (r *DescribeStreamPlayInfoListRequest) FromJsonString(s string) error
func (*DescribeStreamPlayInfoListRequest) ToJsonString ¶
func (r *DescribeStreamPlayInfoListRequest) ToJsonString() string
type DescribeStreamPlayInfoListResponse ¶
type DescribeStreamPlayInfoListResponse struct { *tchttp.BaseResponse Response *struct { // 统计信息列表。 DataInfoList []*DayStreamPlayInfo `json:"DataInfoList,omitempty" name:"DataInfoList" list` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 RequestId *string `json:"RequestId,omitempty" name:"RequestId"` } `json:"Response"` }
func NewDescribeStreamPlayInfoListResponse ¶
func NewDescribeStreamPlayInfoListResponse() (response *DescribeStreamPlayInfoListResponse)
func (*DescribeStreamPlayInfoListResponse) FromJsonString ¶
func (r *DescribeStreamPlayInfoListResponse) FromJsonString(s string) error
func (*DescribeStreamPlayInfoListResponse) ToJsonString ¶
func (r *DescribeStreamPlayInfoListResponse) ToJsonString() string
type DescribeWorkersRequest ¶
type DescribeWorkersRequest struct {
*tchttp.BaseRequest
}
func NewDescribeWorkersRequest ¶
func NewDescribeWorkersRequest() (request *DescribeWorkersRequest)
func (*DescribeWorkersRequest) FromJsonString ¶
func (r *DescribeWorkersRequest) FromJsonString(s string) error
func (*DescribeWorkersRequest) ToJsonString ¶
func (r *DescribeWorkersRequest) ToJsonString() string
type DescribeWorkersResponse ¶
type DescribeWorkersResponse struct { *tchttp.BaseResponse Response *struct { // 各个区域的机器情况 RegionDetail []*WorkerRegionInfo `json:"RegionDetail,omitempty" name:"RegionDetail" list` // 空闲机器总数量 Idle *uint64 `json:"Idle,omitempty" name:"Idle"` // 区域个数 RegionNum *uint64 `json:"RegionNum,omitempty" name:"RegionNum"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 RequestId *string `json:"RequestId,omitempty" name:"RequestId"` } `json:"Response"` }
func NewDescribeWorkersResponse ¶
func NewDescribeWorkersResponse() (response *DescribeWorkersResponse)
func (*DescribeWorkersResponse) FromJsonString ¶
func (r *DescribeWorkersResponse) FromJsonString(s string) error
func (*DescribeWorkersResponse) ToJsonString ¶
func (r *DescribeWorkersResponse) ToJsonString() string
type ForbidLiveStreamRequest ¶
type ForbidLiveStreamRequest struct { *tchttp.BaseRequest // 应用名称。 AppName *string `json:"AppName,omitempty" name:"AppName"` // 您的推流域名。 DomainName *string `json:"DomainName,omitempty" name:"DomainName"` // 流名称。 StreamName *string `json:"StreamName,omitempty" name:"StreamName"` // 恢复流的时间。UTC 格式,例如:2018-11-29T19:00:00Z。 // 注意:默认禁播90天,且最长支持禁播90天。 ResumeTime *string `json:"ResumeTime,omitempty" name:"ResumeTime"` }
func NewForbidLiveStreamRequest ¶
func NewForbidLiveStreamRequest() (request *ForbidLiveStreamRequest)
func (*ForbidLiveStreamRequest) FromJsonString ¶
func (r *ForbidLiveStreamRequest) FromJsonString(s string) error
func (*ForbidLiveStreamRequest) ToJsonString ¶
func (r *ForbidLiveStreamRequest) ToJsonString() string
type ForbidLiveStreamResponse ¶
type ForbidLiveStreamResponse struct { *tchttp.BaseResponse Response *struct { // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 RequestId *string `json:"RequestId,omitempty" name:"RequestId"` } `json:"Response"` }
func NewForbidLiveStreamResponse ¶
func NewForbidLiveStreamResponse() (response *ForbidLiveStreamResponse)
func (*ForbidLiveStreamResponse) FromJsonString ¶
func (r *ForbidLiveStreamResponse) FromJsonString(s string) error
func (*ForbidLiveStreamResponse) ToJsonString ¶
func (r *ForbidLiveStreamResponse) ToJsonString() string
type RegisterIMRequest ¶
type RegisterIMRequest struct { *tchttp.BaseRequest // 用户昵称 Nickname *string `json:"Nickname,omitempty" name:"Nickname"` // 用户唯一ID,建议采用用户小程序OpenID加盐形式 UserId *string `json:"UserId,omitempty" name:"UserId"` // 用户头像URL HeadImgUrl *string `json:"HeadImgUrl,omitempty" name:"HeadImgUrl"` // 用户身份,默认值:0,表示无特殊身份 Level *int64 `json:"Level,omitempty" name:"Level"` }
func NewRegisterIMRequest ¶
func NewRegisterIMRequest() (request *RegisterIMRequest)
func (*RegisterIMRequest) FromJsonString ¶
func (r *RegisterIMRequest) FromJsonString(s string) error
func (*RegisterIMRequest) ToJsonString ¶
func (r *RegisterIMRequest) ToJsonString() string
type RegisterIMResponse ¶
type RegisterIMResponse struct { *tchttp.BaseResponse Response *struct { // 用来传递给插件的关键字段 UserKey *string `json:"UserKey,omitempty" name:"UserKey"` // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 RequestId *string `json:"RequestId,omitempty" name:"RequestId"` } `json:"Response"` }
func NewRegisterIMResponse ¶
func NewRegisterIMResponse() (response *RegisterIMResponse)
func (*RegisterIMResponse) FromJsonString ¶
func (r *RegisterIMResponse) FromJsonString(s string) error
func (*RegisterIMResponse) ToJsonString ¶
func (r *RegisterIMResponse) ToJsonString() string
type StopGameRequest ¶
type StopGameRequest struct { *tchttp.BaseRequest // 游戏用户ID UserId *string `json:"UserId,omitempty" name:"UserId"` }
func NewStopGameRequest ¶
func NewStopGameRequest() (request *StopGameRequest)
func (*StopGameRequest) FromJsonString ¶
func (r *StopGameRequest) FromJsonString(s string) error
func (*StopGameRequest) ToJsonString ¶
func (r *StopGameRequest) ToJsonString() string
type StopGameResponse ¶
type StopGameResponse struct { *tchttp.BaseResponse Response *struct { // 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 RequestId *string `json:"RequestId,omitempty" name:"RequestId"` } `json:"Response"` }
func NewStopGameResponse ¶
func NewStopGameResponse() (response *StopGameResponse)
func (*StopGameResponse) FromJsonString ¶
func (r *StopGameResponse) FromJsonString(s string) error
func (*StopGameResponse) ToJsonString ¶
func (r *StopGameResponse) ToJsonString() string
type WorkerRegionInfo ¶
Click to show internal directories.
Click to hide internal directories.