larkmoments

package
v3.4.51 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 25, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UserIdTypeUserId  = "user_id"  // 以user_id来识别用户
	UserIdTypeUnionId = "union_id" // 以union_id来识别用户
	UserIdTypeOpenId  = "open_id"  // 以open_id来识别用户
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Category

type Category struct {
	Id *string `json:"id,omitempty"` // 板块的ID

	Name *string `json:"name,omitempty"` // 板块名

	Description *string `json:"description,omitempty"` // 板块描述

	CreateTime *string `json:"create_time,omitempty"` // 板块创建时间

	PostCount *int `json:"post_count,omitempty"` // 板块下帖子总数

	ParticipantCount *int `json:"participant_count,omitempty"` // 板块参与人数
}

type CategoryBuilder

type CategoryBuilder struct {
	// contains filtered or unexported fields
}

func NewCategoryBuilder

func NewCategoryBuilder() *CategoryBuilder

func (*CategoryBuilder) Build

func (builder *CategoryBuilder) Build() *Category

func (*CategoryBuilder) CreateTime

func (builder *CategoryBuilder) CreateTime(createTime string) *CategoryBuilder

板块创建时间

示例值:2022-05-23T00:00:00+08:00

func (*CategoryBuilder) Description

func (builder *CategoryBuilder) Description(description string) *CategoryBuilder

板块描述

示例值:一个有趣的板块描述

func (*CategoryBuilder) Id

func (builder *CategoryBuilder) Id(id string) *CategoryBuilder

板块的ID

示例值:6560906191909683220

func (*CategoryBuilder) Name

func (builder *CategoryBuilder) Name(name string) *CategoryBuilder

板块名

示例值:示例板块

func (*CategoryBuilder) ParticipantCount

func (builder *CategoryBuilder) ParticipantCount(participantCount int) *CategoryBuilder

板块参与人数

示例值:10

func (*CategoryBuilder) PostCount

func (builder *CategoryBuilder) PostCount(postCount int) *CategoryBuilder

板块下帖子总数

示例值:5

type Comment

type Comment struct {
	UserId *string `json:"user_id,omitempty"` // 评论所属用户ID

	Content *string `json:"content,omitempty"` // 评论内容

	ImageKey *string `json:"image_key,omitempty"` // 评论图片的key

	IsHot *bool `json:"is_hot,omitempty"` // 是否热评

	ReactionSet *ReactionSet `json:"reaction_set,omitempty"` // 评论 reactions

	Id *string `json:"id,omitempty"` // 评论 ID

	CreateTime *string `json:"create_time,omitempty"` // 评论创建时间

	PostId *string `json:"post_id,omitempty"` // 评论所属实体的ID

	ReplyCommentId *string `json:"reply_comment_id,omitempty"` // 回复的评论ID

	RootCommentId *string `json:"root_comment_id,omitempty"` // 根评论ID

	Cid *string `json:"cid,omitempty"` // 创建评论时去重

	UserType *int `json:"user_type,omitempty"` // 表情回复人类型
}

type CommentBuilder

type CommentBuilder struct {
	// contains filtered or unexported fields
}

func NewCommentBuilder

func NewCommentBuilder() *CommentBuilder

func (*CommentBuilder) Build

func (builder *CommentBuilder) Build() *Comment

func (*CommentBuilder) Cid

func (builder *CommentBuilder) Cid(cid string) *CommentBuilder

创建评论时去重

示例值:"generate-a-uuid-here"

func (*CommentBuilder) Content

func (builder *CommentBuilder) Content(content string) *CommentBuilder

评论内容

示例值:"[[{\"tag\":\"text\",\"text\":\"豪华中型车…………\"},{\"tag\":\"a\",\"text\":\"查看原文\",\"href\":\"https://www.autohome.com.cn/advice/202204/1244455.html\"}]]"

func (*CommentBuilder) CreateTime

func (builder *CommentBuilder) CreateTime(createTime string) *CommentBuilder

评论创建时间

示例值:"2022-05-23T00:00:00+08:00"

func (*CommentBuilder) Id

func (builder *CommentBuilder) Id(id string) *CommentBuilder

评论 ID

示例值:"248381240"

func (*CommentBuilder) ImageKey

func (builder *CommentBuilder) ImageKey(imageKey string) *CommentBuilder

评论图片的key

示例值:"img_v2_xxxxxx"

func (*CommentBuilder) IsHot

func (builder *CommentBuilder) IsHot(isHot bool) *CommentBuilder

是否热评

示例值:false

func (*CommentBuilder) PostId

func (builder *CommentBuilder) PostId(postId string) *CommentBuilder

评论所属实体的ID

示例值:"248381241"

func (*CommentBuilder) ReactionSet

func (builder *CommentBuilder) ReactionSet(reactionSet *ReactionSet) *CommentBuilder

评论 reactions

示例值:

func (*CommentBuilder) ReplyCommentId

func (builder *CommentBuilder) ReplyCommentId(replyCommentId string) *CommentBuilder

回复的评论ID

示例值:""

func (*CommentBuilder) RootCommentId

func (builder *CommentBuilder) RootCommentId(rootCommentId string) *CommentBuilder

根评论ID

示例值:""

func (*CommentBuilder) UserId

func (builder *CommentBuilder) UserId(userId string) *CommentBuilder

评论所属用户ID

示例值:"ou_xxxxx"

func (*CommentBuilder) UserType

func (builder *CommentBuilder) UserType(userType int) *CommentBuilder

表情回复人类型

示例值:1

type DepartmentId

type DepartmentId struct {
	DepartmentId *string `json:"department_id,omitempty"` //

	OpenDepartmentId *string `json:"open_department_id,omitempty"` //
}

type DepartmentIdBuilder

type DepartmentIdBuilder struct {
	// contains filtered or unexported fields
}

func NewDepartmentIdBuilder

func NewDepartmentIdBuilder() *DepartmentIdBuilder

func (*DepartmentIdBuilder) Build

func (builder *DepartmentIdBuilder) Build() *DepartmentId

func (*DepartmentIdBuilder) DepartmentId

func (builder *DepartmentIdBuilder) DepartmentId(departmentId string) *DepartmentIdBuilder

示例值:

func (*DepartmentIdBuilder) OpenDepartmentId

func (builder *DepartmentIdBuilder) OpenDepartmentId(openDepartmentId string) *DepartmentIdBuilder

示例值:

type Dislike

type Dislike struct {
	EntityType *int `json:"entity_type,omitempty"` // 点踩所属实体类型

	EntityId *string `json:"entity_id,omitempty"` // 点踩所属实体ID

	CreateTime *string `json:"create_time,omitempty"` // 点踩时间

	UserId *string `json:"user_id,omitempty"` // 点踩人ID

	Id *string `json:"id,omitempty"` // Dislike的ID
}

type DislikeBuilder

type DislikeBuilder struct {
	// contains filtered or unexported fields
}

func NewDislikeBuilder

func NewDislikeBuilder() *DislikeBuilder

func (*DislikeBuilder) Build

func (builder *DislikeBuilder) Build() *Dislike

func (*DislikeBuilder) CreateTime

func (builder *DislikeBuilder) CreateTime(createTime string) *DislikeBuilder

点踩时间

示例值:"2022-05-23T00:00:00+08:00"

func (*DislikeBuilder) EntityId

func (builder *DislikeBuilder) EntityId(entityId string) *DislikeBuilder

点踩所属实体ID

示例值:"111111"

func (*DislikeBuilder) EntityType

func (builder *DislikeBuilder) EntityType(entityType int) *DislikeBuilder

点踩所属实体类型

示例值:1

func (*DislikeBuilder) Id

func (builder *DislikeBuilder) Id(id string) *DislikeBuilder

Dislike的ID

示例值:"2222222"

func (*DislikeBuilder) UserId

func (builder *DislikeBuilder) UserId(userId string) *DislikeBuilder

点踩人ID

示例值:"ou_xxxxx"

type GetPostReq

type GetPostReq struct {
	// contains filtered or unexported fields
}

type GetPostReqBuilder

type GetPostReqBuilder struct {
	// contains filtered or unexported fields
}

func NewGetPostReqBuilder

func NewGetPostReqBuilder() *GetPostReqBuilder

func (*GetPostReqBuilder) Build

func (builder *GetPostReqBuilder) Build() *GetPostReq

func (*GetPostReqBuilder) PostId

func (builder *GetPostReqBuilder) PostId(postId string) *GetPostReqBuilder

post的id

示例值:6934510454161014804

func (*GetPostReqBuilder) UserIdType

func (builder *GetPostReqBuilder) UserIdType(userIdType string) *GetPostReqBuilder

此次调用中使用的用户ID的类型

示例值:

type GetPostResp

type GetPostResp struct {
	*larkcore.ApiResp `json:"-"`
	larkcore.CodeError
	Data *GetPostRespData `json:"data"` // 业务数据
}

func (*GetPostResp) Success

func (resp *GetPostResp) Success() bool

type GetPostRespData

type GetPostRespData struct {
	Post *Post `json:"post,omitempty"` // 帖子实体
}

type P2CommentCreatedV1

type P2CommentCreatedV1 struct {
	*larkevent.EventV2Base                         // 事件基础数据
	*larkevent.EventReq                            // 请求原生数据
	Event                  *P2CommentCreatedV1Data `json:"event"` // 事件内容
}

func (*P2CommentCreatedV1) RawReq

func (m *P2CommentCreatedV1) RawReq(req *larkevent.EventReq)

type P2CommentCreatedV1Data

type P2CommentCreatedV1Data struct {
	UserId *UserId `json:"user_id,omitempty"` // 评论所属用户ID

	Id *string `json:"id,omitempty"` // 评论 ID

	CreateTime *string `json:"create_time,omitempty"` // 评论创建时间

	PostId *string `json:"post_id,omitempty"` // 评论所属帖子的ID

	ReplyCommentId *string `json:"reply_comment_id,omitempty"` // 回复的评论ID

	RootCommentId *string `json:"root_comment_id,omitempty"` // 根评论ID

	UserType *int `json:"user_type,omitempty"` // 表情回复人类型
}

type P2CommentCreatedV1Handler

type P2CommentCreatedV1Handler struct {
	// contains filtered or unexported fields
}

消息处理器定义

func NewP2CommentCreatedV1Handler

func NewP2CommentCreatedV1Handler(handler func(context.Context, *P2CommentCreatedV1) error) *P2CommentCreatedV1Handler

func (*P2CommentCreatedV1Handler) Event

func (h *P2CommentCreatedV1Handler) Event() interface{}

返回事件的消息体的实例,用于反序列化用

func (*P2CommentCreatedV1Handler) Handle

func (h *P2CommentCreatedV1Handler) Handle(ctx context.Context, event interface{}) error

回调开发者注册的handle

type P2CommentDeletedV1

type P2CommentDeletedV1 struct {
	*larkevent.EventV2Base                         // 事件基础数据
	*larkevent.EventReq                            // 请求原生数据
	Event                  *P2CommentDeletedV1Data `json:"event"` // 事件内容
}

func (*P2CommentDeletedV1) RawReq

func (m *P2CommentDeletedV1) RawReq(req *larkevent.EventReq)

type P2CommentDeletedV1Data

type P2CommentDeletedV1Data struct {
	Id *string `json:"id,omitempty"` // 评论 ID

	PostId *string `json:"post_id,omitempty"` // 评论所属帖子的ID
}

type P2CommentDeletedV1Handler

type P2CommentDeletedV1Handler struct {
	// contains filtered or unexported fields
}

消息处理器定义

func NewP2CommentDeletedV1Handler

func NewP2CommentDeletedV1Handler(handler func(context.Context, *P2CommentDeletedV1) error) *P2CommentDeletedV1Handler

func (*P2CommentDeletedV1Handler) Event

func (h *P2CommentDeletedV1Handler) Event() interface{}

返回事件的消息体的实例,用于反序列化用

func (*P2CommentDeletedV1Handler) Handle

func (h *P2CommentDeletedV1Handler) Handle(ctx context.Context, event interface{}) error

回调开发者注册的handle

type P2DislikeCreatedV1

type P2DislikeCreatedV1 struct {
	*larkevent.EventV2Base                         // 事件基础数据
	*larkevent.EventReq                            // 请求原生数据
	Event                  *P2DislikeCreatedV1Data `json:"event"` // 事件内容
}

func (*P2DislikeCreatedV1) RawReq

func (m *P2DislikeCreatedV1) RawReq(req *larkevent.EventReq)

type P2DislikeCreatedV1Data

type P2DislikeCreatedV1Data struct {
	EntityType *int `json:"entity_type,omitempty"` // 点踩所属实体类型

	EntityId *string `json:"entity_id,omitempty"` // 点踩所属实体ID

	CreateTime *string `json:"create_time,omitempty"` // 点踩时间

	UserId *UserId `json:"user_id,omitempty"` // 点踩人ID

	Id *string `json:"id,omitempty"` // Dislike的ID
}

type P2DislikeCreatedV1Handler

type P2DislikeCreatedV1Handler struct {
	// contains filtered or unexported fields
}

消息处理器定义

func NewP2DislikeCreatedV1Handler

func NewP2DislikeCreatedV1Handler(handler func(context.Context, *P2DislikeCreatedV1) error) *P2DislikeCreatedV1Handler

func (*P2DislikeCreatedV1Handler) Event

func (h *P2DislikeCreatedV1Handler) Event() interface{}

返回事件的消息体的实例,用于反序列化用

func (*P2DislikeCreatedV1Handler) Handle

func (h *P2DislikeCreatedV1Handler) Handle(ctx context.Context, event interface{}) error

回调开发者注册的handle

type P2DislikeDeletedV1

type P2DislikeDeletedV1 struct {
	*larkevent.EventV2Base                         // 事件基础数据
	*larkevent.EventReq                            // 请求原生数据
	Event                  *P2DislikeDeletedV1Data `json:"event"` // 事件内容
}

func (*P2DislikeDeletedV1) RawReq

func (m *P2DislikeDeletedV1) RawReq(req *larkevent.EventReq)

type P2DislikeDeletedV1Data

type P2DislikeDeletedV1Data struct {
	EntityType *int `json:"entity_type,omitempty"` // 点踩所属实体类型

	EntityId *string `json:"entity_id,omitempty"` // 点踩所属实体ID

	UserId *UserId `json:"user_id,omitempty"` // 点踩人ID

	Id *string `json:"id,omitempty"` // Dislike的ID
}

type P2DislikeDeletedV1Handler

type P2DislikeDeletedV1Handler struct {
	// contains filtered or unexported fields
}

消息处理器定义

func NewP2DislikeDeletedV1Handler

func NewP2DislikeDeletedV1Handler(handler func(context.Context, *P2DislikeDeletedV1) error) *P2DislikeDeletedV1Handler

func (*P2DislikeDeletedV1Handler) Event

func (h *P2DislikeDeletedV1Handler) Event() interface{}

返回事件的消息体的实例,用于反序列化用

func (*P2DislikeDeletedV1Handler) Handle

func (h *P2DislikeDeletedV1Handler) Handle(ctx context.Context, event interface{}) error

回调开发者注册的handle

type P2PostCreatedV1

type P2PostCreatedV1 struct {
	*larkevent.EventV2Base                      // 事件基础数据
	*larkevent.EventReq                         // 请求原生数据
	Event                  *P2PostCreatedV1Data `json:"event"` // 事件内容
}

func (*P2PostCreatedV1) RawReq

func (m *P2PostCreatedV1) RawReq(req *larkevent.EventReq)

type P2PostCreatedV1Data

type P2PostCreatedV1Data struct {
	Id *string `json:"id,omitempty"` // 帖子ID

	UserId *UserId `json:"user_id,omitempty"` // 发帖用户ID

	CreateTime *string `json:"create_time,omitempty"` // 帖子创建时间

	CategoryIds []string `json:"category_ids,omitempty"` // 帖子所属板块

	Link *string `json:"link,omitempty"` // 帖子链接

	UserType *int `json:"user_type,omitempty"` // 发帖人类型
}

type P2PostCreatedV1Handler

type P2PostCreatedV1Handler struct {
	// contains filtered or unexported fields
}

消息处理器定义

func NewP2PostCreatedV1Handler

func NewP2PostCreatedV1Handler(handler func(context.Context, *P2PostCreatedV1) error) *P2PostCreatedV1Handler

func (*P2PostCreatedV1Handler) Event

func (h *P2PostCreatedV1Handler) Event() interface{}

返回事件的消息体的实例,用于反序列化用

func (*P2PostCreatedV1Handler) Handle

func (h *P2PostCreatedV1Handler) Handle(ctx context.Context, event interface{}) error

回调开发者注册的handle

type P2PostDeletedV1

type P2PostDeletedV1 struct {
	*larkevent.EventV2Base                      // 事件基础数据
	*larkevent.EventReq                         // 请求原生数据
	Event                  *P2PostDeletedV1Data `json:"event"` // 事件内容
}

func (*P2PostDeletedV1) RawReq

func (m *P2PostDeletedV1) RawReq(req *larkevent.EventReq)

type P2PostDeletedV1Data

type P2PostDeletedV1Data struct {
	Id *string `json:"id,omitempty"` // 帖子ID
}

type P2PostDeletedV1Handler

type P2PostDeletedV1Handler struct {
	// contains filtered or unexported fields
}

消息处理器定义

func NewP2PostDeletedV1Handler

func NewP2PostDeletedV1Handler(handler func(context.Context, *P2PostDeletedV1) error) *P2PostDeletedV1Handler

func (*P2PostDeletedV1Handler) Event

func (h *P2PostDeletedV1Handler) Event() interface{}

返回事件的消息体的实例,用于反序列化用

func (*P2PostDeletedV1Handler) Handle

func (h *P2PostDeletedV1Handler) Handle(ctx context.Context, event interface{}) error

回调开发者注册的handle

type P2PostStatisticsUpdatedV1

type P2PostStatisticsUpdatedV1 struct {
	*larkevent.EventV2Base                                // 事件基础数据
	*larkevent.EventReq                                   // 请求原生数据
	Event                  *P2PostStatisticsUpdatedV1Data `json:"event"` // 事件内容
}

func (*P2PostStatisticsUpdatedV1) RawReq

func (m *P2PostStatisticsUpdatedV1) RawReq(req *larkevent.EventReq)

type P2PostStatisticsUpdatedV1Data

type P2PostStatisticsUpdatedV1Data struct {
	PostId *string `json:"post_id,omitempty"` // 帖子ID

	StatisticsType *int `json:"statistics_type,omitempty"` // 变更统计数据类型

	Statistics *PostStatistics `json:"statistics,omitempty"` // 帖子统计数据
}

type P2PostStatisticsUpdatedV1Handler

type P2PostStatisticsUpdatedV1Handler struct {
	// contains filtered or unexported fields
}

消息处理器定义

func (*P2PostStatisticsUpdatedV1Handler) Event

func (h *P2PostStatisticsUpdatedV1Handler) Event() interface{}

返回事件的消息体的实例,用于反序列化用

func (*P2PostStatisticsUpdatedV1Handler) Handle

func (h *P2PostStatisticsUpdatedV1Handler) Handle(ctx context.Context, event interface{}) error

回调开发者注册的handle

type P2ReactionCreatedV1

type P2ReactionCreatedV1 struct {
	*larkevent.EventV2Base                          // 事件基础数据
	*larkevent.EventReq                             // 请求原生数据
	Event                  *P2ReactionCreatedV1Data `json:"event"` // 事件内容
}

func (*P2ReactionCreatedV1) RawReq

func (m *P2ReactionCreatedV1) RawReq(req *larkevent.EventReq)

type P2ReactionCreatedV1Data

type P2ReactionCreatedV1Data struct {
	Type *string `json:"type,omitempty"` // reaction 类型

	UserId *UserId `json:"user_id,omitempty"` // reaction 所属用户ID

	EntityId *string `json:"entity_id,omitempty"` // reaction 所属实体ID

	Id *string `json:"id,omitempty"` // Reaction的ID

	EntityType *int `json:"entity_type,omitempty"` // 表情回复所属实体类型

	UserType *int `json:"user_type,omitempty"` // 表情回复人类型

	CreateTime *string `json:"create_time,omitempty"` // reaction创建时间
}

type P2ReactionCreatedV1Handler

type P2ReactionCreatedV1Handler struct {
	// contains filtered or unexported fields
}

消息处理器定义

func NewP2ReactionCreatedV1Handler

func NewP2ReactionCreatedV1Handler(handler func(context.Context, *P2ReactionCreatedV1) error) *P2ReactionCreatedV1Handler

func (*P2ReactionCreatedV1Handler) Event

func (h *P2ReactionCreatedV1Handler) Event() interface{}

返回事件的消息体的实例,用于反序列化用

func (*P2ReactionCreatedV1Handler) Handle

func (h *P2ReactionCreatedV1Handler) Handle(ctx context.Context, event interface{}) error

回调开发者注册的handle

type P2ReactionDeletedV1

type P2ReactionDeletedV1 struct {
	*larkevent.EventV2Base                          // 事件基础数据
	*larkevent.EventReq                             // 请求原生数据
	Event                  *P2ReactionDeletedV1Data `json:"event"` // 事件内容
}

func (*P2ReactionDeletedV1) RawReq

func (m *P2ReactionDeletedV1) RawReq(req *larkevent.EventReq)

type P2ReactionDeletedV1Data

type P2ReactionDeletedV1Data struct {
	Type *string `json:"type,omitempty"` // reaction 类型

	UserId *UserId `json:"user_id,omitempty"` // reaction 所属用户ID

	EntityId *string `json:"entity_id,omitempty"` // reaction 所属实体ID

	Id *string `json:"id,omitempty"` // Reaction的ID

	EntityType *int `json:"entity_type,omitempty"` // 表情回复所属实体类型

	UserType *int `json:"user_type,omitempty"` // 表情回复人类型
}

type P2ReactionDeletedV1Handler

type P2ReactionDeletedV1Handler struct {
	// contains filtered or unexported fields
}

消息处理器定义

func NewP2ReactionDeletedV1Handler

func NewP2ReactionDeletedV1Handler(handler func(context.Context, *P2ReactionDeletedV1) error) *P2ReactionDeletedV1Handler

func (*P2ReactionDeletedV1Handler) Event

func (h *P2ReactionDeletedV1Handler) Event() interface{}

返回事件的消息体的实例,用于反序列化用

func (*P2ReactionDeletedV1Handler) Handle

func (h *P2ReactionDeletedV1Handler) Handle(ctx context.Context, event interface{}) error

回调开发者注册的handle

type Post

type Post struct {
	UserId *string `json:"user_id,omitempty"` // 发帖用户ID

	Content *string `json:"content,omitempty"` // 帖子内容

	ImageKeyList []string `json:"image_key_list,omitempty"` // 图片的key 列表

	MediaFileToken *string `json:"media_file_token,omitempty"` // 媒体文件的 token

	CommentCount *int `json:"comment_count,omitempty"` // 评论数

	ReactionSet *ReactionSet `json:"reaction_set,omitempty"` // 帖子的reaction及其数量

	Id *string `json:"id,omitempty"` // 帖子ID

	CreateTime *string `json:"create_time,omitempty"` // 帖子创建时间

	MediaCoverImageKey *string `json:"media_cover_image_key,omitempty"` // 视频封面图片

	Cid *string `json:"cid,omitempty"` // 创建帖子时去重用

	CategoryIds []string `json:"category_ids,omitempty"` // 帖子所属板块

	Link *string `json:"link,omitempty"` // 帖子链接

	UserType *int `json:"user_type,omitempty"` // 发帖人类型

	DislikeCount *int `json:"dislike_count,omitempty"` // 点踩数量
}

type PostBuilder

type PostBuilder struct {
	// contains filtered or unexported fields
}

func NewPostBuilder

func NewPostBuilder() *PostBuilder

func (*PostBuilder) Build

func (builder *PostBuilder) Build() *Post

func (*PostBuilder) CategoryIds

func (builder *PostBuilder) CategoryIds(categoryIds []string) *PostBuilder

帖子所属板块

示例值:

func (*PostBuilder) Cid

func (builder *PostBuilder) Cid(cid string) *PostBuilder

创建帖子时去重用

示例值:"generate-a-uuid-here"

func (*PostBuilder) CommentCount

func (builder *PostBuilder) CommentCount(commentCount int) *PostBuilder

评论数

示例值:1

func (*PostBuilder) Content

func (builder *PostBuilder) Content(content string) *PostBuilder

帖子内容

示例值:"[[{\"tag\":\"text\",\"text\":\"豪华中型车…………\"},{\"tag\":\"a\",\"text\":\"查看原文\",\"href\":\"https://www.autohome.com.cn/advice/202204/1244455.html\"}]]"

func (*PostBuilder) CreateTime

func (builder *PostBuilder) CreateTime(createTime string) *PostBuilder

帖子创建时间

示例值:"2022-05-23T00:00:00+08:00"

func (*PostBuilder) DislikeCount

func (builder *PostBuilder) DislikeCount(dislikeCount int) *PostBuilder

点踩数量

示例值:0

func (*PostBuilder) Id

func (builder *PostBuilder) Id(id string) *PostBuilder

帖子ID

示例值:"248381241"

func (*PostBuilder) ImageKeyList

func (builder *PostBuilder) ImageKeyList(imageKeyList []string) *PostBuilder

图片的key 列表

示例值:

func (builder *PostBuilder) Link(link string) *PostBuilder

帖子链接

示例值:"https://applink.feishu.cn/client/moments/detail?postId=7254"

func (*PostBuilder) MediaCoverImageKey

func (builder *PostBuilder) MediaCoverImageKey(mediaCoverImageKey string) *PostBuilder

视频封面图片

示例值:""

func (*PostBuilder) MediaFileToken

func (builder *PostBuilder) MediaFileToken(mediaFileToken string) *PostBuilder

媒体文件的 token

示例值:""

func (*PostBuilder) ReactionSet

func (builder *PostBuilder) ReactionSet(reactionSet *ReactionSet) *PostBuilder

帖子的reaction及其数量

示例值:

func (*PostBuilder) UserId

func (builder *PostBuilder) UserId(userId string) *PostBuilder

发帖用户ID

示例值:"ou_xxxxx"

func (*PostBuilder) UserType

func (builder *PostBuilder) UserType(userType int) *PostBuilder

发帖人类型

示例值:1

type PostStatistics

type PostStatistics struct {
	ShareCount *int `json:"share_count,omitempty"` // 分享次数
}

type PostStatisticsBuilder

type PostStatisticsBuilder struct {
	// contains filtered or unexported fields
}

func NewPostStatisticsBuilder

func NewPostStatisticsBuilder() *PostStatisticsBuilder

func (*PostStatisticsBuilder) Build

func (builder *PostStatisticsBuilder) Build() *PostStatistics

func (*PostStatisticsBuilder) ShareCount

func (builder *PostStatisticsBuilder) ShareCount(shareCount int) *PostStatisticsBuilder

分享次数

示例值:1

type Reaction

type Reaction struct {
	Type *string `json:"type,omitempty"` // reaction 类型

	UserId *string `json:"user_id,omitempty"` // reaction 所属用户ID

	EntityId *string `json:"entity_id,omitempty"` // reaction 所属实体ID

	Id *string `json:"id,omitempty"` // Reaction的ID

	CreateTime *string `json:"create_time,omitempty"` // reaction创建时间

	EntityType *int `json:"entity_type,omitempty"` // 表情回复所属实体类型

	UserType *int `json:"user_type,omitempty"` // 表情回复人类型
}

type ReactionBuilder

type ReactionBuilder struct {
	// contains filtered or unexported fields
}

func NewReactionBuilder

func NewReactionBuilder() *ReactionBuilder

func (*ReactionBuilder) Build

func (builder *ReactionBuilder) Build() *Reaction

func (*ReactionBuilder) CreateTime

func (builder *ReactionBuilder) CreateTime(createTime string) *ReactionBuilder

reaction创建时间

示例值:"2022-05-23T00:00:00+08:00"

func (*ReactionBuilder) EntityId

func (builder *ReactionBuilder) EntityId(entityId string) *ReactionBuilder

reaction 所属实体ID

示例值:"248381241"

func (*ReactionBuilder) EntityType

func (builder *ReactionBuilder) EntityType(entityType int) *ReactionBuilder

表情回复所属实体类型

示例值:1

func (*ReactionBuilder) Id

func (builder *ReactionBuilder) Id(id string) *ReactionBuilder

Reaction的ID

示例值:"MS8yL1NPQg=="

func (*ReactionBuilder) Type

func (builder *ReactionBuilder) Type(type_ string) *ReactionBuilder

reaction 类型

示例值:"OK"

func (*ReactionBuilder) UserId

func (builder *ReactionBuilder) UserId(userId string) *ReactionBuilder

reaction 所属用户ID

示例值:"ou_xxxxx"

func (*ReactionBuilder) UserType

func (builder *ReactionBuilder) UserType(userType int) *ReactionBuilder

表情回复人类型

示例值:1

type ReactionList

type ReactionList struct {
	Type *string `json:"type,omitempty"` // 表情类型

	Count *int `json:"count,omitempty"` // 回复该表情的人数
}

type ReactionListBuilder

type ReactionListBuilder struct {
	// contains filtered or unexported fields
}

func NewReactionListBuilder

func NewReactionListBuilder() *ReactionListBuilder

func (*ReactionListBuilder) Build

func (builder *ReactionListBuilder) Build() *ReactionList

func (*ReactionListBuilder) Count

func (builder *ReactionListBuilder) Count(count int) *ReactionListBuilder

回复该表情的人数

示例值:3

func (*ReactionListBuilder) Type

func (builder *ReactionListBuilder) Type(type_ string) *ReactionListBuilder

表情类型

示例值:OK

type ReactionSet

type ReactionSet struct {
	Reactions []*ReactionList `json:"reactions,omitempty"` // 表情列表

	TotalCount *int `json:"total_count,omitempty"` // 全部表情计数
}

type ReactionSetBuilder

type ReactionSetBuilder struct {
	// contains filtered or unexported fields
}

func NewReactionSetBuilder

func NewReactionSetBuilder() *ReactionSetBuilder

func (*ReactionSetBuilder) Build

func (builder *ReactionSetBuilder) Build() *ReactionSet

func (*ReactionSetBuilder) Reactions

func (builder *ReactionSetBuilder) Reactions(reactions []*ReactionList) *ReactionSetBuilder

表情列表

示例值:

func (*ReactionSetBuilder) TotalCount

func (builder *ReactionSetBuilder) TotalCount(totalCount int) *ReactionSetBuilder

全部表情计数

示例值:20

type UserId

type UserId struct {
	UserId *string `json:"user_id,omitempty"` //

	OpenId *string `json:"open_id,omitempty"` //

	UnionId *string `json:"union_id,omitempty"` //
}

type UserIdBuilder

type UserIdBuilder struct {
	// contains filtered or unexported fields
}

func NewUserIdBuilder

func NewUserIdBuilder() *UserIdBuilder

func (*UserIdBuilder) Build

func (builder *UserIdBuilder) Build() *UserId

func (*UserIdBuilder) OpenId

func (builder *UserIdBuilder) OpenId(openId string) *UserIdBuilder

示例值:

func (*UserIdBuilder) UnionId

func (builder *UserIdBuilder) UnionId(unionId string) *UserIdBuilder

示例值:

func (*UserIdBuilder) UserId

func (builder *UserIdBuilder) UserId(userId string) *UserIdBuilder

示例值:

type V1

type V1 struct {
	Comment        *comment        // comment
	Dislike        *dislike        // dislike
	Post           *post           // post
	PostStatistics *postStatistics // post_statistics
	Reaction       *reaction       // reaction
}

func New

func New(config *larkcore.Config) *V1

Jump to

Keyboard shortcuts

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