Documentation ¶
Index ¶
- type Client
- func (comp *Client) Register(ctx context.Context, data *request.RequestShakeAroundAccountRegister) (*response.ResponseShakeAroundAccountRegister, error)
- func (comp *Client) Status(ctx context.Context) (*response.ResponseShakeAroundAccountRegister, error)
- func (comp *Client) User(ctx context.Context, data *request.RequestShakeAroundUser) (*response.ResponseShakeAroundUser, error)
- func (comp *Client) UserWithPoi(ctx context.Context, ticket string) (*response.ResponseShakeAroundUser, error)
- type DeviceClient
- func (comp *DeviceClient) Apply(ctx context.Context, data *request.RequestDeviceApply) (*response.ResponseDeviceApply, error)
- func (comp *DeviceClient) BindPoi(ctx context.Context, deviceIdentifier *request.RequestDeviceIdentifier, ...) (*response.ResponseDeviceBindPoi, error)
- func (comp *DeviceClient) BindThirdPoi(ctx context.Context, deviceIdentifier *request.RequestDeviceIdentifier, ...) (*response.ResponseDeviceBindPoi, error)
- func (comp *DeviceClient) DeviceUpdate(ctx context.Context, deviceIdentifier *request.RequestDeviceIdentifier, ...) (*response.ResponseDeviceApplyStatus, error)
- func (comp *DeviceClient) List(ctx context.Context, lastID int, count int) (*response.ResponseDeviceApplyStatus, error)
- func (comp *DeviceClient) ListByApplyID(ctx context.Context, applyID int, lastID int, count int) (*response.ResponseDeviceApplyStatus, error)
- func (comp *DeviceClient) ListByIDs(ctx context.Context, deviceIdentifier []*request.RequestDeviceIdentifier) (*response.ResponseDeviceApplyStatus, error)
- func (comp *DeviceClient) Status(ctx context.Context, data *request.RequestDeviceApplyStatus) (*response.ResponseDeviceApplyStatus, error)
- type GroupClient
- func (comp *GroupClient) AddDevice(ctx context.Context, groupID int, ...) (*response.ResponseGroup, error)
- func (comp *GroupClient) Create(ctx context.Context, name string) (*response.ResponseGroup, error)
- func (comp *GroupClient) Delete(ctx context.Context, groupID string) (*response.ResponseGroup, error)
- func (comp *GroupClient) Get(ctx context.Context, groupID int, begin int, count int) (*response.ResponseGroupDetail, error)
- func (comp *GroupClient) List(ctx context.Context, begin int, count int) (*response.ResponseGroupList, error)
- func (comp *GroupClient) RemoveDevices(ctx context.Context, groupID int, ...) (*response.ResponseGroup, error)
- func (comp *GroupClient) Update(ctx context.Context, groupID string, name string) (*response.ResponseGroup, error)
- type MaterialClient
- type PageClient
- func (comp *PageClient) Create(ctx context.Context, data *request.RequestPageInfo) (*response.ResponsePage, error)
- func (comp *PageClient) Delete(ctx context.Context, pageID string) (*response.ResponsePage, error)
- func (comp *PageClient) List(ctx context.Context, begin int, count int) (*response.ResponsePageList, error)
- func (comp *PageClient) Update(ctx context.Context, data request.RequestPageUpdate) (*response.ResponsePage, error)
- type RelationClient
- func (comp *RelationClient) BindPages(ctx context.Context, data *request.RequestDeviceIdentifier, pageIDs []int) (*response.ResponsePage, error)
- func (comp *RelationClient) ListByDeviceID(ctx context.Context, data *request.RequestDeviceIdentifier) (*response.ResponseRelationSearch, error)
- func (comp *RelationClient) ListByPageId(ctx context.Context, pageID int, begin int, count int) (*response.ResponseRelationSearch, error)
- type ShakeAround
- type StatsClient
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
BaseClient *kernel.BaseClient
}
func (*Client) Register ¶
func (comp *Client) Register(ctx context.Context, data *request.RequestShakeAroundAccountRegister) (*response.ResponseShakeAroundAccountRegister, error)
申请开通摇一摇周边功能 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Apply/Application_for_opening_function.html
func (*Client) Status ¶
func (*Client) User ¶
func (comp *Client) User(ctx context.Context, data *request.RequestShakeAroundUser) (*response.ResponseShakeAroundUser, error)
func (*Client) UserWithPoi ¶
type DeviceClient ¶
type DeviceClient struct {
BaseClient *kernel.BaseClient
}
func NewDeviceClient ¶
func NewDeviceClient(app kernel.ApplicationInterface) (*DeviceClient, error)
func (*DeviceClient) Apply ¶
func (comp *DeviceClient) Apply(ctx context.Context, data *request.RequestDeviceApply) (*response.ResponseDeviceApply, error)
func (*DeviceClient) BindPoi ¶
func (comp *DeviceClient) BindPoi(ctx context.Context, deviceIdentifier *request.RequestDeviceIdentifier, poiID int) (*response.ResponseDeviceBindPoi, error)
func (*DeviceClient) BindThirdPoi ¶
func (comp *DeviceClient) BindThirdPoi(ctx context.Context, deviceIdentifier *request.RequestDeviceIdentifier, poiID int, appID string) (*response.ResponseDeviceBindPoi, error)
func (*DeviceClient) DeviceUpdate ¶
func (comp *DeviceClient) DeviceUpdate(ctx context.Context, deviceIdentifier *request.RequestDeviceIdentifier, comment string) (*response.ResponseDeviceApplyStatus, error)
查询设备 ID 申请的审核状态 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Devices_management/Query_the_audit_status_of_the_device_ID.html
func (*DeviceClient) List ¶
func (comp *DeviceClient) List(ctx context.Context, lastID int, count int) (*response.ResponseDeviceApplyStatus, error)
func (*DeviceClient) ListByApplyID ¶
func (comp *DeviceClient) ListByApplyID(ctx context.Context, applyID int, lastID int, count int) (*response.ResponseDeviceApplyStatus, error)
func (*DeviceClient) ListByIDs ¶
func (comp *DeviceClient) ListByIDs(ctx context.Context, deviceIdentifier []*request.RequestDeviceIdentifier) (*response.ResponseDeviceApplyStatus, error)
func (*DeviceClient) Status ¶
func (comp *DeviceClient) Status(ctx context.Context, data *request.RequestDeviceApplyStatus) (*response.ResponseDeviceApplyStatus, error)
查询设备 ID 申请的审核状态 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Devices_management/Query_the_audit_status_of_the_device_ID.html
type GroupClient ¶
type GroupClient struct {
BaseClient *kernel.BaseClient
}
func NewGroupClient ¶
func NewGroupClient(app kernel.ApplicationInterface) (*GroupClient, error)
func (*GroupClient) AddDevice ¶
func (comp *GroupClient) AddDevice(ctx context.Context, groupID int, deviceIdentifiers []*request.RequestDeviceIdentifier) (*response.ResponseGroup, error)
func (*GroupClient) Create ¶
func (comp *GroupClient) Create(ctx context.Context, name string) (*response.ResponseGroup, error)
新建设备分组 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Active_from_Html5/New_groups.html
func (*GroupClient) Delete ¶
func (comp *GroupClient) Delete(ctx context.Context, groupID string) (*response.ResponseGroup, error)
删除设备分组 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Active_from_Html5/New_groups.html
func (*GroupClient) Get ¶
func (comp *GroupClient) Get(ctx context.Context, groupID int, begin int, count int) (*response.ResponseGroupDetail, error)
func (*GroupClient) List ¶
func (comp *GroupClient) List(ctx context.Context, begin int, count int) (*response.ResponseGroupList, error)
func (*GroupClient) RemoveDevices ¶
func (comp *GroupClient) RemoveDevices(ctx context.Context, groupID int, deviceIdentifiers []*request.RequestDeviceIdentifier) (*response.ResponseGroup, error)
func (*GroupClient) Update ¶
func (comp *GroupClient) Update(ctx context.Context, groupID string, name string) (*response.ResponseGroup, error)
更新设备分组 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Active_from_Html5/New_groups.html
type MaterialClient ¶
type MaterialClient struct {
BaseClient *kernel.BaseClient
}
func NewMaterialClient ¶
func NewMaterialClient(app kernel.ApplicationInterface) (*MaterialClient, error)
func (*MaterialClient) UploadImage ¶
func (comp *MaterialClient) UploadImage(ctx context.Context, path string, Type string) (*response.ResponseMaterialUpload, error)
上传在摇一摇功能中需使用到的图片素材 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Uploading_Image_Assets.html
type PageClient ¶
type PageClient struct {
BaseClient *kernel.BaseClient
}
func NewPageClient ¶
func NewPageClient(app kernel.ApplicationInterface) (*PageClient, error)
func (*PageClient) Create ¶
func (comp *PageClient) Create(ctx context.Context, data *request.RequestPageInfo) (*response.ResponsePage, error)
新增摇一摇出来的页面信息 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Pages_management/Page_management.html
func (*PageClient) Delete ¶
func (comp *PageClient) Delete(ctx context.Context, pageID string) (*response.ResponsePage, error)
删除已有的页面 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Pages_management/Delete_page.html
func (*PageClient) List ¶
func (comp *PageClient) List(ctx context.Context, begin int, count int) (*response.ResponsePageList, error)
更新设备分组 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Pages_management/Query_page_list.html
func (*PageClient) Update ¶
func (comp *PageClient) Update(ctx context.Context, data request.RequestPageUpdate) (*response.ResponsePage, error)
编辑摇一摇出来的页面信息 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Pages_management/Edit_page_information.html
type RelationClient ¶
type RelationClient struct {
BaseClient *kernel.BaseClient
}
func NewRelationClient ¶
func NewRelationClient(app kernel.ApplicationInterface) (*RelationClient, error)
func (*RelationClient) BindPages ¶
func (comp *RelationClient) BindPages(ctx context.Context, data *request.RequestDeviceIdentifier, pageIDs []int) (*response.ResponsePage, error)
新增摇一摇出来的页面信息 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Pages_management/Page_management.html
func (*RelationClient) ListByDeviceID ¶
func (comp *RelationClient) ListByDeviceID(ctx context.Context, data *request.RequestDeviceIdentifier) (*response.ResponseRelationSearch, error)
func (*RelationClient) ListByPageId ¶
func (comp *RelationClient) ListByPageId(ctx context.Context, pageID int, begin int, count int) (*response.ResponseRelationSearch, error)
type ShakeAround ¶
type ShakeAround struct { *Client Device *DeviceClient Page *PageClient Material *MaterialClient Group *GroupClient Relation *RelationClient Stats *StatsClient }
func RegisterProvider ¶
func RegisterProvider(app kernel.ApplicationInterface) (*ShakeAround, error)
type StatsClient ¶
type StatsClient struct {
BaseClient *kernel.BaseClient
}
func NewStatsClient ¶
func NewStatsClient(app kernel.ApplicationInterface) (*StatsClient, error)
func (*StatsClient) DeviceSummary ¶
func (comp *StatsClient) DeviceSummary(ctx context.Context, data *request.RequestDeviceIdentifier, beginTime int, endTime int) (*response.ResponseStatsSummary, error)
查询单个设备进行摇周边操作的人数、次数,点击摇周边消息的人数、次数 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Analytics/Using_devices_as_a_dimension_for_the_data_statistics_interface.html
func (*StatsClient) PageSummary ¶
func (comp *StatsClient) PageSummary(ctx context.Context, pageID int, beginTime int, endTime int) (*response.ResponseStatsPage, error)
查询单个页面通过摇周边摇出来的人数、次数,点击摇周边页面的人数、次数 https://developers.weixin.qq.com/doc/offiaccount/Shake_Nearby/Analytics/Using_pages_as_a_dimension_for_the_data_statistics_interface.html