larkdocs

package
v3.4.7 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2025 License: MIT Imports: 4 Imported by: 1

Documentation

Index

Constants

View Source
const (
	LangZH = "zh" // 中文
	LangEN = "en" // 英文
	LangJA = "ja" // 日文
)
View Source
const (
	ContentTypeMarkdown = "markdown" // Markdown 格式
)
View Source
const (
	DocTypeDOCX = "docx" // 新版文档
)

Variables

This section is empty.

Functions

This section is empty.

Types

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 GetContentReq

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

type GetContentReqBuilder

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

func NewGetContentReqBuilder

func NewGetContentReqBuilder() *GetContentReqBuilder

func (*GetContentReqBuilder) Build

func (builder *GetContentReqBuilder) Build() *GetContentReq

func (*GetContentReqBuilder) ContentType

func (builder *GetContentReqBuilder) ContentType(contentType string) *GetContentReqBuilder

内容类型

示例值:markdown

func (*GetContentReqBuilder) DocToken

func (builder *GetContentReqBuilder) DocToken(docToken string) *GetContentReqBuilder

文档唯一标识

示例值:B4EPdAYx8oi8HRxgPQQbM15UcBf

func (*GetContentReqBuilder) DocType

func (builder *GetContentReqBuilder) DocType(docType string) *GetContentReqBuilder

文档类型

示例值:docx

func (*GetContentReqBuilder) Lang

func (builder *GetContentReqBuilder) Lang(lang string) *GetContentReqBuilder

语言

示例值:zh

type GetContentResp

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

func (*GetContentResp) Success

func (resp *GetContentResp) Success() bool

type GetContentRespData

type GetContentRespData struct {
	Content *string `json:"content,omitempty"` // 内容
}

type Meta

type Meta struct {
	DocToken *string `json:"doc_token,omitempty"` // 文档 Token

	DocType *string `json:"doc_type,omitempty"` // 文档类型

	Title *string `json:"title,omitempty"` // 标题

	OwnerId *string `json:"owner_id,omitempty"` // 文档所有者

	LatestModifyUser *string `json:"latest_modify_user,omitempty"` // 最后编辑者

	LatestModifyTime *string `json:"latest_modify_time,omitempty"` // 最后编辑时间(Unix 时间戳)

	Url *string `json:"url,omitempty"` // 文档链接

	SecLabelName *string `json:"sec_label_name,omitempty"` // 文档密级标签名称
}

type MetaBuilder

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

func NewMetaBuilder

func NewMetaBuilder() *MetaBuilder

func (*MetaBuilder) Build

func (builder *MetaBuilder) Build() *Meta

func (*MetaBuilder) DocToken

func (builder *MetaBuilder) DocToken(docToken string) *MetaBuilder

文档 Token

示例值:doccnfYZzTlvXqZIGTdAHKabcef

func (*MetaBuilder) DocType

func (builder *MetaBuilder) DocType(docType string) *MetaBuilder

文档类型

示例值:docx

func (*MetaBuilder) LatestModifyTime

func (builder *MetaBuilder) LatestModifyTime(latestModifyTime string) *MetaBuilder

最后编辑时间(Unix 时间戳)

示例值:1652066345

func (*MetaBuilder) LatestModifyUser

func (builder *MetaBuilder) LatestModifyUser(latestModifyUser string) *MetaBuilder

最后编辑者

示例值:ou_b13d41c02edc52ce66aaae67bf1abcef

func (*MetaBuilder) OwnerId

func (builder *MetaBuilder) OwnerId(ownerId string) *MetaBuilder

文档所有者

示例值:ou_b13d41c02edc52ce66aaae67bf1abcef

func (*MetaBuilder) SecLabelName

func (builder *MetaBuilder) SecLabelName(secLabelName string) *MetaBuilder

文档密级标签名称

示例值:L2-内部

func (*MetaBuilder) Title

func (builder *MetaBuilder) Title(title string) *MetaBuilder

标题

示例值:sampletitle

func (*MetaBuilder) Url

func (builder *MetaBuilder) Url(url string) *MetaBuilder

文档链接

示例值:https://sample.feishu.cn/docs/doccnfYZzTlvXqZIGTdAHKabcef

type V1

type V1 struct {
	Content *content // content
}

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