From da22d19fb45b5504f4191ad06d4e7637bfbc3916 Mon Sep 17 00:00:00 2001 From: r Date: Sun, 27 Sep 2020 09:29:17 +0000 Subject: Add bookmarks - Add bookmark/unbookmark link on mouse hover - Add bookmarks section on user profile page --- mastodon/accounts.go | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'mastodon/accounts.go') diff --git a/mastodon/accounts.go b/mastodon/accounts.go index 7a44e2b..c5eb227 100644 --- a/mastodon/accounts.go +++ b/mastodon/accounts.go @@ -353,3 +353,13 @@ func (c *Client) UnSubscribe(ctx context.Context, id string) (*Relationship, err } return relationship, nil } + +// GetBookmarks returns the list of bookmarked statuses +func (c *Client) GetBookmarks(ctx context.Context, pg *Pagination) ([]*Status, error) { + var statuses []*Status + err := c.doAPI(ctx, http.MethodGet, "/api/v1/bookmarks", nil, &statuses, pg) + if err != nil { + return nil, err + } + return statuses, nil +} -- cgit v1.2.3