Documentation
¶
Index ¶
- Variables
- func WithBaseURL(url string) clientOption
- func WithLogin(login string) clientOption
- func WithToken(token string) clientOption
- func WithUserAgent(userAgent string) clientOption
- type AbilitiesSerializer
- type BookDetailSerializer
- type BookSerializer
- type Client
- type DocDetailSerializer
- type DocSerializer
- type Document
- func (d *Document) Create(namespace string, options ...DocumentOption) (*ResponseDocDetailSerializer, error)
- func (d *Document) Delete(namespace, slug string) (*ResponseDocDetailSerializer, error)
- func (d *Document) GetInfo(namespace, slug string) (*ResponseDocDetailSerializer, error)
- func (d *Document) ListAll(namespace string) (*ResponseDocSerializer, error)
- func (d *Document) Update(namespace, slug string, options ...DocumentOption) (*ResponseDocDetailSerializer, error)
- type DocumentCreate
- type DocumentOption
- type EditorSerializer
- type Group
- func (g *Group) Create(groupLogin, groupName string, options ...GroupOption) (*ResponseUserDetailSerializer, error)
- func (g *Group) Delete(groupLogin string) (*ResponseUserDetailSerializer, error)
- func (g *Group) DeleteMember(groupLogin, login string) (*ResponseGroupUserDetailSerializer, error)
- func (g *Group) GetInfo(groupLogin string) (*ResponseUserDetailSerializer, error)
- func (g *Group) GetMember(groupLogin string) (*ResponseGroupUserSerializer, error)
- func (g *Group) ListAll() (*ResponseUserSerializer, error)
- func (g *Group) ListPublic() (*ResponseUserSerializer, error)
- func (g *Group) Update(groupLogin string, options ...GroupOption) (*ResponseUserDetailSerializer, error)
- func (g *Group) UpdateMember(groupLogin, login string, role int) (*ResponseGroupUserDetailSerializer, error)
- type GroupOption
- type GroupUserDetailSerializer
- type GroupUserSerializer
- type MetaSerializer
- type Repo
- func (r *Repo) CreateUnderGroup(repoSlug, repoKind, repoName string, options ...RepoOption) (*ResponseBookDetailSerializer, error)
- func (r *Repo) CreateUnderUser(repoSlug, repoKind, repoName string, options ...RepoOption) (*ResponseBookDetailSerializer, error)
- func (r *Repo) Delete(namespace string) (*ResponseBookDetailSerializer, error)
- func (r *Repo) GetDir(namespace string) (*ResponseBookDirectoryStructure, error)
- func (r *Repo) GetInfo(namespace string) (*ResponseBookDetailSerializer, error)
- func (r *Repo) ListAllUnderGroup() (*ResponseBookSerializer, error)
- func (r *Repo) ListAllUnderUser() (*ResponseBookSerializer, error)
- func (r *Repo) Update(namespace string, options ...RepoOption) (*ResponseBookDetailSerializer, error)
- type RepoDetailSerializer
- type RepoOption
- type ResponseBookDetailSerializer
- type ResponseBookDirectoryStructure
- type ResponseBookSerializer
- type ResponseDocDetailSerializer
- type ResponseDocSerializer
- type ResponseGroupUserDetailSerializer
- type ResponseGroupUserSerializer
- type ResponseUserDetailSerializer
- type ResponseUserSerializer
- type SearchSerializer
- type Searcher
- type SearcherOption
- type User
- type UserDetailSerializer
- type UserSerializer
- type WebHookAddCommentReplySerializer
- type WebHookAddCommentSerializer
- type WebHookDeleteCommentReplySerializer
- type WebHookDeleteCommentSerializer
- type WebHookDeleteDocSerializer
- type WebHookPublishDocSerializer
- type WebHookUpdateCommentReplySerializer
- type WebHookUpdateCommentSerializer
- type WebHookUpdateDocSerializer
Constants ¶
This section is empty.
Variables ¶
var ( ErrTooManyOptions = errors.New("options length more than one") ErrGetDocumentID = errors.New("Error get documentID") )
Functions ¶
func WithBaseURL ¶ added in v1.0.0
func WithBaseURL(url string) clientOption
func WithUserAgent ¶ added in v1.0.0
func WithUserAgent(userAgent string) clientOption
Types ¶
type AbilitiesSerializer ¶ added in v1.0.0
type AbilitiesSerializer struct {
Update bool `json:"update"`
Destroy bool `json:"destroy"`
Doc DocumentCreate `json:"doc"`
Read bool `json:"read"`
GroupUser GroupUserDetailSerializer `json:"group_user"`
Repo RepoDetailSerializer `json:"repo"`
}
type BookDetailSerializer ¶ added in v1.0.0
type BookDetailSerializer struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
Toc string `json:"toc"`
TocYml string `json:"toc_yml"`
CreatorID int `json:"creator_id"`
Public int `json:"public"`
ItemsCount int `json:"items_count"`
LikesCount int `json:"likes_count"`
WatchesCount int `json:"watched_count"`
PinnedAt string `json:"pinned_at"`
Archived string `json:"archived"`
ContentUpdatedAt string `json:"content_updated_at"`
UpdatedAt string `json:"updated_at"`
CreatedAt string `json:"created_at"`
Namespace string `json:"namespace"`
User UserSerializer `json:"user"`
Serializer string `json:"_serializer"`
}
yuque BookDetailSerializer
type BookSerializer ¶ added in v1.0.0
type BookSerializer struct {
Type string `json:"type"`
Title string `json:"title"`
UUID string `json:"uuid"`
URL string `json:"url"`
PrevUUID string `json:"prev_uuid"`
SiblingUUID string `json:"sibling_uuid"`
ChildUUID string `json:"child_uuid"`
ParentUUID string `json:"parent_uuid"`
DocID int `json:"doc_id"`
Level int `json:"level"`
ID int `json:"id"`
OpenWindow int `json:"open_window"`
Visible int `json:"visible"`
Depth int `json:"depth"`
Slug string `json:"slug"`
}
type Client ¶ added in v1.0.0
type DocDetailSerializer ¶ added in v1.0.0
type DocDetailSerializer struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
BookID int `json:"book_id"`
Book BookDetailSerializer `json:"book"`
UserID int `json:"user_id"`
Creator UserSerializer `json:"creator"`
Format string `json:"format"`
Body string `json:"body"`
BodyDraft string `json:"body_draft"`
BodyHTML string `json:"body_html"`
BodyLake string `json:"body_lake"`
BodyDraftLake string `json:"body_draft_lake"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikeCount int `json:"like_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt string `json:"content_updated_at"`
DeletedAt string `json:"deleted_at"`
CreatedAt string `json:"created_at"`
UpdatedAt string `json:"updated_at"`
PublishedAt string `json:"published_at"`
FirstPublishedAt string `json:"first_published_at"`
WordCount int `json:"word_count"`
Cover string `json:"cover"`
Description string `json:"description"`
CustonDescription string `json:"custon_description"`
Hits int `json:"hits"`
Serializer string `json:"serializer"`
}
yuque DocDetailSerializer
type DocSerializer ¶ added in v1.0.0
type DocSerializer struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
Description string `json:"description"`
UserID int `json:"user_id"`
BookID int `json:"book_id"`
Format string `json:"format"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt string `json:"content_updated_at"`
CreatedAt string `json:"created_at"`
UpdatedAt string `json:"updated_at"`
PublishedAt string `json:"published_at"`
FirstPublishedAt string `json:"first_published_at"`
DraftVersion int `json:"draft_version"`
LastEditorID int `json:"last_editor_id"`
WordCount int `json:"word_count"`
Cover string `json:"cover"`
CustomDescription string `json:"custom_description"`
LastEditor EditorSerializer `json:"last_editor"`
Book string `json:"book"`
Serializer string `json:"_serializer"`
}
yuque DocSerializer
type Document ¶
type Document struct {
*Client
}
func (*Document) Create ¶
func (d *Document) Create(namespace string, options ...DocumentOption) (*ResponseDocDetailSerializer, error)
Create create a document
func (*Document) Delete ¶
func (d *Document) Delete(namespace, slug string) (*ResponseDocDetailSerializer, error)
Delete delete a document
func (*Document) GetInfo ¶ added in v1.0.0
func (d *Document) GetInfo(namespace, slug string) (*ResponseDocDetailSerializer, error)
Get get document detail info
func (*Document) ListAll ¶
func (d *Document) ListAll(namespace string) (*ResponseDocSerializer, error)
ListAll list all documents in a repo
func (*Document) Update ¶
func (d *Document) Update(namespace, slug string, options ...DocumentOption) (*ResponseDocDetailSerializer, error)
Update update a document
type DocumentCreate ¶ added in v1.0.0
type DocumentCreate struct {
Create bool `json:"create"`
}
type DocumentOption ¶ added in v1.0.0
type DocumentOption struct {
Slug string
Title string
Body string
/*
"markdown", "lake", "html"
default is markdown
*/
Format string
/*
0 - private
1 - public
*/
Public int
/*
If you edit the document on the page, then the document will turn into a Lake format,
if you can use MarkDown to update, this is what you need to add _force_asl = 1 to
ensure the correct conversion of the content.
*/
ForceASL int
}
type EditorSerializer ¶ added in v1.0.0
type EditorSerializer struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description string `json:"description"`
AvatarURL string `json:"avatar_url"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt string `json:"created_at"`
UpdatedAt string `json:"updated_at"`
Serializer string `json:"_serializer"`
}
type Group ¶
type Group struct {
*Client
}
func (*Group) Create ¶
func (g *Group) Create(groupLogin, groupName string, options ...GroupOption) (*ResponseUserDetailSerializer, error)
Create create a group
func (*Group) Delete ¶
func (g *Group) Delete(groupLogin string) (*ResponseUserDetailSerializer, error)
Delete delete group
func (*Group) DeleteMember ¶
func (g *Group) DeleteMember(groupLogin, login string) (*ResponseGroupUserDetailSerializer, error)
DeleteMember delete group member
func (*Group) GetInfo ¶ added in v1.0.0
func (g *Group) GetInfo(groupLogin string) (*ResponseUserDetailSerializer, error)
Get get single group info
func (*Group) GetMember ¶ added in v1.1.0
func (g *Group) GetMember(groupLogin string) (*ResponseGroupUserSerializer, error)
GetMember get group member info
func (*Group) ListAll ¶
func (g *Group) ListAll() (*ResponseUserSerializer, error)
ListAll list all groups that user join in
func (*Group) ListPublic ¶
func (g *Group) ListPublic() (*ResponseUserSerializer, error)
ListPublic list all public group
func (*Group) Update ¶
func (g *Group) Update(groupLogin string, options ...GroupOption) (*ResponseUserDetailSerializer, error)
Update update group info
func (*Group) UpdateMember ¶
func (g *Group) UpdateMember(groupLogin, login string, role int) (*ResponseGroupUserDetailSerializer, error)
UpdateMember update group member authority role: 0 - manager 1 - ordinary
type GroupOption ¶ added in v1.0.0
type GroupUserDetailSerializer ¶ added in v1.0.0
type GroupUserDetailSerializer struct {
Create bool `json:"create"`
Update bool `json:"update"`
Destroy bool `json:"destroy"`
ID int `json:"id"`
GroupID int `json:"group_id"`
UserID int `json:"user_id"`
User UserSerializer `json:"user"`
Role int `json:"role"`
Status int `json:"status"`
CreatedAt string `json:"created_at"`
Updatedat string `json:"updated_at"`
Group UserSerializer `json:"group"`
Serializer string `json:"_serializer"`
}
type GroupUserSerializer ¶ added in v1.0.0
type GroupUserSerializer struct {
ID int `json:"id"`
GroupID int `json:"group_id"`
UserID int `json:"user_id"`
User UserSerializer `json:"user"`
Role int `json:"role"`
Status int `json:"status"`
CreatedAt string `json:"created_at"`
UpdatedAt string `json:"updated_at"`
Group UserSerializer `json:"group"`
Serializer string `json:"_serializer"`
}
yuque groupUserSerializer
type MetaSerializer ¶ added in v1.0.0
type MetaSerializer struct {
TopicEnable int `json:"topic_enable"`
}
type Repo ¶
type Repo struct {
*Client
}
func (*Repo) CreateUnderGroup ¶
func (r *Repo) CreateUnderGroup(repoSlug, repoKind, repoName string, options ...RepoOption) (*ResponseBookDetailSerializer, error)
CreateUnderGroup create repo under the group
func (*Repo) CreateUnderUser ¶
func (r *Repo) CreateUnderUser(repoSlug, repoKind, repoName string, options ...RepoOption) (*ResponseBookDetailSerializer, error)
CreateUnderUser create repo under the user
func (*Repo) Delete ¶
func (r *Repo) Delete(namespace string) (*ResponseBookDetailSerializer, error)
Delete delete repo
func (*Repo) GetDir ¶
func (r *Repo) GetDir(namespace string) (*ResponseBookDirectoryStructure, error)
GetDir get repo's directory
func (*Repo) GetInfo ¶ added in v1.0.0
func (r *Repo) GetInfo(namespace string) (*ResponseBookDetailSerializer, error)
Get get repo info
func (*Repo) ListAllUnderGroup ¶
func (r *Repo) ListAllUnderGroup() (*ResponseBookSerializer, error)
ListAllUnderGroup list all repo under group
func (*Repo) ListAllUnderUser ¶
func (r *Repo) ListAllUnderUser() (*ResponseBookSerializer, error)
ListAllUnderUser list all repo under user
func (*Repo) Update ¶
func (r *Repo) Update(namespace string, options ...RepoOption) (*ResponseBookDetailSerializer, error)
Update update repo info
type RepoDetailSerializer ¶ added in v1.0.0
type RepoOption ¶ added in v1.0.0
type ResponseBookDetailSerializer ¶ added in v1.0.0
type ResponseBookDetailSerializer struct {
Abilities AbilitiesSerializer `json:"abilities"`
Data BookDetailSerializer `json:"data"`
}
type ResponseBookDirectoryStructure ¶ added in v1.0.0
type ResponseBookDirectoryStructure struct {
Data []BookSerializer `json:"data"`
}
type ResponseBookSerializer ¶ added in v1.0.0
type ResponseBookSerializer struct {
Data []BookDetailSerializer `json:"data"`
}
type ResponseDocDetailSerializer ¶ added in v1.0.0
type ResponseDocDetailSerializer struct {
Abilities AbilitiesSerializer `json:"abilities"`
Data DocDetailSerializer `json:"data"`
}
type ResponseDocSerializer ¶ added in v1.0.0
type ResponseDocSerializer struct {
Data []DocSerializer `json:"data"`
}
get a repo's doc list
type ResponseGroupUserDetailSerializer ¶ added in v1.0.0
type ResponseGroupUserDetailSerializer struct {
Data GroupUserDetailSerializer `json:"data"`
}
type ResponseGroupUserSerializer ¶ added in v1.0.0
type ResponseGroupUserSerializer struct {
Data []GroupUserSerializer `json:"data"`
}
type ResponseUserDetailSerializer ¶ added in v1.0.0
type ResponseUserDetailSerializer struct {
Abilities AbilitiesSerializer `json:"abilities"`
Meta MetaSerializer `json:"meta"`
Data UserDetailSerializer `json:"data"`
}
type ResponseUserSerializer ¶ added in v1.0.0
type ResponseUserSerializer struct {
Data []UserSerializer `json:"data"`
}
type SearchSerializer ¶ added in v1.0.0
type SearchSerializer struct {
Meta struct {
Total int `json:"total"`
} `json:"meta"`
Data []struct {
ID int `json:"id"`
Type string `json:"type"`
Title string `json:"title"`
Summary string `json:"summary"`
URL string `json:"url"`
Info string `json:"info"`
Target struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
Description string `json:"description"`
UserID int `json:"user_id"`
BookID int `json:"book_id"`
Format string `json:"format"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
ReadCount int `json:"read_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PublishedAt time.Time `json:"published_at"`
FirstPublishedAt time.Time `json:"first_published_at"`
DraftVersion int `json:"draft_version"`
LastEditorID int `json:"last_editor_id"`
WordCount int `json:"word_count"`
Cover interface{} `json:"cover"`
CustomDescription interface{} `json:"custom_description"`
Hits int `json:"hits"`
LastEditor interface{} `json:"last_editor"`
Book struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
Public int `json:"public"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
UpdatedAt time.Time `json:"updated_at"`
CreatedAt time.Time `json:"created_at"`
Namespace string `json:"namespace"`
User struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description interface{} `json:"description"`
AvatarURL string `json:"avatar_url"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Serializer string `json:"_serializer"`
} `json:"user"`
Serializer string `json:"_serializer"`
} `json:"book"`
Serializer string `json:"_serializer"`
} `json:"target"`
Serializer string `json:"_serializer"`
} `json:"data"`
}
type Searcher ¶ added in v1.0.0
type Searcher struct {
*Client
}
func (*Searcher) Work ¶ added in v1.0.0
func (s *Searcher) Work(keyword string, options ...SearcherOption) (*SearchSerializer, error)
Get get user info
type SearcherOption ¶ added in v1.0.0
type User ¶
type User struct {
*Client
}
func (*User) GetInfo ¶ added in v1.0.0
func (u *User) GetInfo() (*ResponseUserDetailSerializer, error)
Get get user info
type UserDetailSerializer ¶ added in v1.0.0
type UserDetailSerializer struct {
ID int `json:"id"`
Type string `json:"type"`
SpaceID int `json:"space_id"`
AccountID int `json:"account_id"`
OrganizationID int `json:"organization_id"`
Login string `json:"login"`
Name string `json:"name"`
AvatarURL string `json:"avatar_url"`
OwnerID int `json:"owner_id"`
BooksCount int `json:"books_count"`
PublicBooksCount int `json:"public_books_count"`
PublicTopicsCount int `json:"public_topics_count"`
MembersCount int `json:"members_count"`
GrainsSum int `json:"grains_sum"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
Public int `json:"public"`
Description string `json:"description"`
CreatedAt string `json:"created_at"`
UpdatedAt string `json:"updated_at"`
Serializer string `json:"_serializer"`
}
yuque UserDetailSerializer
type UserSerializer ¶ added in v1.0.0
type UserSerializer struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description string `json:"description"`
AvatarURL string `json:"avatar_url"`
BooksCount int `json:"books_count"`
PublicBooksCount int `json:"public_books_count"`
TopicsCount int `json:"topics_count"`
PublicTopicsCount int `json:"public_topics_count"`
MembersCount int `json:"members_count"`
Public int `json:"public"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt string `json:"created_at"`
UpdatedAt string `json:"updated_at"`
Serializer string `json:"_serializer"`
}
yuque UserSerializer
type WebHookAddCommentReplySerializer ¶ added in v1.0.0
type WebHookAddCommentReplySerializer struct {
Data struct {
ID int `json:"id"`
UserID int `json:"user_id"`
ParentID int `json:"parent_id"`
BodyHTML string `json:"body_html"`
LikesCount int `json:"likes_count"`
Mood int `json:"mood"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Status int `json:"status"`
ToUserID interface{} `json:"to_user_id"`
Type interface{} `json:"type"`
User struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description interface{} `json:"description"`
AvatarURL string `json:"avatar_url"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Serializer string `json:"_serializer"`
} `json:"user"`
Serializer string `json:"_serializer"`
Commentable struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
BookID int `json:"book_id"`
Book struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
CreatorID int `json:"creator_id"`
Public int `json:"public"`
ItemsCount int `json:"items_count"`
LikesCount int `json:"likes_count"`
WatchesCount int `json:"watches_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
UpdatedAt time.Time `json:"updated_at"`
CreatedAt time.Time `json:"created_at"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
} `json:"book"`
UserID int `json:"user_id"`
Format string `json:"format"`
Body string `json:"body"`
BodyDraft string `json:"body_draft"`
BodyHTML string `json:"body_html"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
DeletedAt interface{} `json:"deleted_at"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PublishedAt time.Time `json:"published_at"`
FirstPublishedAt time.Time `json:"first_published_at"`
WordCount int `json:"word_count"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
Path string `json:"path"`
} `json:"commentable"`
Path string `json:"path"`
ActionType string `json:"action_type"`
WebhookSubjectType string `json:"webhook_subject_type"`
ActorID int `json:"actor_id"`
} `json:"data"`
}
type WebHookAddCommentSerializer ¶ added in v1.0.0
type WebHookAddCommentSerializer struct {
Data struct {
ID int `json:"id"`
UserID int `json:"user_id"`
ParentID interface{} `json:"parent_id"`
BodyHTML string `json:"body_html"`
LikesCount int `json:"likes_count"`
Mood int `json:"mood"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Status int `json:"status"`
ToUserID interface{} `json:"to_user_id"`
Type interface{} `json:"type"`
User struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description interface{} `json:"description"`
AvatarURL string `json:"avatar_url"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Serializer string `json:"_serializer"`
} `json:"user"`
Serializer string `json:"_serializer"`
Commentable struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
BookID int `json:"book_id"`
Book struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
CreatorID int `json:"creator_id"`
Public int `json:"public"`
ItemsCount int `json:"items_count"`
LikesCount int `json:"likes_count"`
WatchesCount int `json:"watches_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
UpdatedAt time.Time `json:"updated_at"`
CreatedAt time.Time `json:"created_at"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
} `json:"book"`
UserID int `json:"user_id"`
Format string `json:"format"`
Body string `json:"body"`
BodyDraft string `json:"body_draft"`
BodyHTML string `json:"body_html"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
DeletedAt interface{} `json:"deleted_at"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PublishedAt time.Time `json:"published_at"`
FirstPublishedAt time.Time `json:"first_published_at"`
WordCount int `json:"word_count"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
Path string `json:"path"`
} `json:"commentable"`
Path string `json:"path"`
ActionType string `json:"action_type"`
WebhookSubjectType string `json:"webhook_subject_type"`
ActorID int `json:"actor_id"`
} `json:"data"`
}
type WebHookDeleteCommentReplySerializer ¶ added in v1.0.0
type WebHookDeleteCommentReplySerializer struct {
Data struct {
ID int `json:"id"`
UserID int `json:"user_id"`
ParentID int `json:"parent_id"`
BodyHTML string `json:"body_html"`
LikesCount int `json:"likes_count"`
Mood int `json:"mood"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Status int `json:"status"`
ToUserID interface{} `json:"to_user_id"`
Type interface{} `json:"type"`
User struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description interface{} `json:"description"`
AvatarURL string `json:"avatar_url"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Serializer string `json:"_serializer"`
} `json:"user"`
Serializer string `json:"_serializer"`
Commentable struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
BookID int `json:"book_id"`
Book struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
CreatorID int `json:"creator_id"`
Public int `json:"public"`
ItemsCount int `json:"items_count"`
LikesCount int `json:"likes_count"`
WatchesCount int `json:"watches_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
UpdatedAt time.Time `json:"updated_at"`
CreatedAt time.Time `json:"created_at"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
} `json:"book"`
UserID int `json:"user_id"`
Format string `json:"format"`
Body string `json:"body"`
BodyDraft string `json:"body_draft"`
BodyHTML string `json:"body_html"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
DeletedAt interface{} `json:"deleted_at"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PublishedAt time.Time `json:"published_at"`
FirstPublishedAt time.Time `json:"first_published_at"`
WordCount int `json:"word_count"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
Path string `json:"path"`
} `json:"commentable"`
Path string `json:"path"`
ActionType string `json:"action_type"`
WebhookSubjectType string `json:"webhook_subject_type"`
ActorID int `json:"actor_id"`
} `json:"data"`
}
type WebHookDeleteCommentSerializer ¶ added in v1.0.0
type WebHookDeleteCommentSerializer struct {
Data struct {
ID int `json:"id"`
UserID int `json:"user_id"`
ParentID interface{} `json:"parent_id"`
BodyHTML string `json:"body_html"`
LikesCount int `json:"likes_count"`
Mood int `json:"mood"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Status int `json:"status"`
ToUserID interface{} `json:"to_user_id"`
Type interface{} `json:"type"`
User struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description interface{} `json:"description"`
AvatarURL string `json:"avatar_url"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Serializer string `json:"_serializer"`
} `json:"user"`
Serializer string `json:"_serializer"`
Commentable struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
BookID int `json:"book_id"`
Book struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
CreatorID int `json:"creator_id"`
Public int `json:"public"`
ItemsCount int `json:"items_count"`
LikesCount int `json:"likes_count"`
WatchesCount int `json:"watches_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
UpdatedAt time.Time `json:"updated_at"`
CreatedAt time.Time `json:"created_at"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
} `json:"book"`
UserID int `json:"user_id"`
Format string `json:"format"`
Body string `json:"body"`
BodyDraft string `json:"body_draft"`
BodyHTML string `json:"body_html"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
DeletedAt interface{} `json:"deleted_at"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PublishedAt time.Time `json:"published_at"`
FirstPublishedAt time.Time `json:"first_published_at"`
WordCount int `json:"word_count"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
Path string `json:"path"`
} `json:"commentable"`
Path string `json:"path"`
ActionType string `json:"action_type"`
WebhookSubjectType string `json:"webhook_subject_type"`
ActorID int `json:"actor_id"`
} `json:"data"`
}
type WebHookDeleteDocSerializer ¶ added in v1.0.0
type WebHookDeleteDocSerializer struct {
Data struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
BookID int `json:"book_id"`
Book struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
CreatorID int `json:"creator_id"`
Public int `json:"public"`
ItemsCount int `json:"items_count"`
LikesCount int `json:"likes_count"`
WatchesCount int `json:"watches_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
UpdatedAt time.Time `json:"updated_at"`
CreatedAt time.Time `json:"created_at"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
} `json:"book"`
UserID int `json:"user_id"`
User struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description interface{} `json:"description"`
AvatarURL string `json:"avatar_url"`
BooksCount int `json:"books_count"`
PublicBooksCount int `json:"public_books_count"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Serializer string `json:"_serializer"`
} `json:"user"`
Format string `json:"format"`
Body string `json:"body"`
BodyDraft string `json:"body_draft"`
BodyHTML string `json:"body_html"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
DeletedAt time.Time `json:"deleted_at"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PublishedAt time.Time `json:"published_at"`
FirstPublishedAt time.Time `json:"first_published_at"`
WordCount int `json:"word_count"`
Serializer string `json:"_serializer"`
Path string `json:"path"`
Publish bool `json:"publish"`
ActionType string `json:"action_type"`
WebhookSubjectType string `json:"webhook_subject_type"`
ActorID int `json:"actor_id"`
} `json:"data"`
}
type WebHookPublishDocSerializer ¶ added in v1.0.0
type WebHookPublishDocSerializer struct {
Data struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
BookID int `json:"book_id"`
Book struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
CreatorID int `json:"creator_id"`
Public int `json:"public"`
ItemsCount int `json:"items_count"`
LikesCount int `json:"likes_count"`
WatchesCount int `json:"watches_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
UpdatedAt time.Time `json:"updated_at"`
CreatedAt time.Time `json:"created_at"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
} `json:"book"`
UserID int `json:"user_id"`
User struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description interface{} `json:"description"`
AvatarURL string `json:"avatar_url"`
BooksCount int `json:"books_count"`
PublicBooksCount int `json:"public_books_count"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Serializer string `json:"_serializer"`
} `json:"user"`
Format string `json:"format"`
Body string `json:"body"`
BodyDraft string `json:"body_draft"`
BodyHTML string `json:"body_html"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
DeletedAt interface{} `json:"deleted_at"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PublishedAt time.Time `json:"published_at"`
FirstPublishedAt time.Time `json:"first_published_at"`
WordCount int `json:"word_count"`
Serializer string `json:"_serializer"`
Path string `json:"path"`
Publish bool `json:"publish"`
ActionType string `json:"action_type"`
WebhookSubjectType string `json:"webhook_subject_type"`
ActorID int `json:"actor_id"`
} `json:"data"`
}
type WebHookUpdateCommentReplySerializer ¶ added in v1.0.0
type WebHookUpdateCommentReplySerializer struct {
Data struct {
ID int `json:"id"`
UserID int `json:"user_id"`
ParentID int `json:"parent_id"`
BodyHTML string `json:"body_html"`
LikesCount int `json:"likes_count"`
Mood int `json:"mood"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Status int `json:"status"`
ToUserID interface{} `json:"to_user_id"`
Type interface{} `json:"type"`
User struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description interface{} `json:"description"`
AvatarURL string `json:"avatar_url"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Serializer string `json:"_serializer"`
} `json:"user"`
Serializer string `json:"_serializer"`
Commentable struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
BookID int `json:"book_id"`
Book struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
CreatorID int `json:"creator_id"`
Public int `json:"public"`
ItemsCount int `json:"items_count"`
LikesCount int `json:"likes_count"`
WatchesCount int `json:"watches_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
UpdatedAt time.Time `json:"updated_at"`
CreatedAt time.Time `json:"created_at"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
} `json:"book"`
UserID int `json:"user_id"`
Format string `json:"format"`
Body string `json:"body"`
BodyDraft string `json:"body_draft"`
BodyHTML string `json:"body_html"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
DeletedAt interface{} `json:"deleted_at"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PublishedAt time.Time `json:"published_at"`
FirstPublishedAt time.Time `json:"first_published_at"`
WordCount int `json:"word_count"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
Path string `json:"path"`
} `json:"commentable"`
Path string `json:"path"`
ActionType string `json:"action_type"`
WebhookSubjectType string `json:"webhook_subject_type"`
ActorID int `json:"actor_id"`
} `json:"data"`
}
type WebHookUpdateCommentSerializer ¶ added in v1.0.0
type WebHookUpdateCommentSerializer struct {
Data struct {
ID int `json:"id"`
UserID int `json:"user_id"`
ParentID interface{} `json:"parent_id"`
BodyHTML string `json:"body_html"`
LikesCount int `json:"likes_count"`
Mood int `json:"mood"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Status int `json:"status"`
ToUserID interface{} `json:"to_user_id"`
Type interface{} `json:"type"`
User struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description interface{} `json:"description"`
AvatarURL string `json:"avatar_url"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Serializer string `json:"_serializer"`
} `json:"user"`
Serializer string `json:"_serializer"`
Commentable struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
BookID int `json:"book_id"`
Book struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
CreatorID int `json:"creator_id"`
Public int `json:"public"`
ItemsCount int `json:"items_count"`
LikesCount int `json:"likes_count"`
WatchesCount int `json:"watches_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
UpdatedAt time.Time `json:"updated_at"`
CreatedAt time.Time `json:"created_at"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
} `json:"book"`
UserID int `json:"user_id"`
Format string `json:"format"`
Body string `json:"body"`
BodyDraft string `json:"body_draft"`
BodyHTML string `json:"body_html"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
DeletedAt interface{} `json:"deleted_at"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PublishedAt time.Time `json:"published_at"`
FirstPublishedAt time.Time `json:"first_published_at"`
WordCount int `json:"word_count"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
Path string `json:"path"`
} `json:"commentable"`
Path string `json:"path"`
ActionType string `json:"action_type"`
WebhookSubjectType string `json:"webhook_subject_type"`
ActorID int `json:"actor_id"`
} `json:"data"`
}
type WebHookUpdateDocSerializer ¶ added in v1.0.0
type WebHookUpdateDocSerializer struct {
Data struct {
ID int `json:"id"`
Slug string `json:"slug"`
Title string `json:"title"`
BookID int `json:"book_id"`
Book struct {
ID int `json:"id"`
Type string `json:"type"`
Slug string `json:"slug"`
Name string `json:"name"`
UserID int `json:"user_id"`
Description string `json:"description"`
CreatorID int `json:"creator_id"`
Public int `json:"public"`
ItemsCount int `json:"items_count"`
LikesCount int `json:"likes_count"`
WatchesCount int `json:"watches_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
UpdatedAt time.Time `json:"updated_at"`
CreatedAt time.Time `json:"created_at"`
User interface{} `json:"user"`
Serializer string `json:"_serializer"`
} `json:"book"`
UserID int `json:"user_id"`
User struct {
ID int `json:"id"`
Type string `json:"type"`
Login string `json:"login"`
Name string `json:"name"`
Description interface{} `json:"description"`
AvatarURL string `json:"avatar_url"`
BooksCount int `json:"books_count"`
PublicBooksCount int `json:"public_books_count"`
FollowersCount int `json:"followers_count"`
FollowingCount int `json:"following_count"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Serializer string `json:"_serializer"`
} `json:"user"`
Format string `json:"format"`
Body string `json:"body"`
BodyDraft string `json:"body_draft"`
BodyHTML string `json:"body_html"`
Public int `json:"public"`
Status int `json:"status"`
ViewStatus int `json:"view_status"`
ReadStatus int `json:"read_status"`
LikesCount int `json:"likes_count"`
CommentsCount int `json:"comments_count"`
ContentUpdatedAt time.Time `json:"content_updated_at"`
DeletedAt interface{} `json:"deleted_at"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
PublishedAt time.Time `json:"published_at"`
FirstPublishedAt time.Time `json:"first_published_at"`
WordCount int `json:"word_count"`
Serializer string `json:"_serializer"`
Path string `json:"path"`
Publish bool `json:"publish"`
ActionType string `json:"action_type"`
WebhookSubjectType string `json:"webhook_subject_type"`
ActorID int `json:"actor_id"`
} `json:"data"`
}