add GetAccountStatuses

This commit is contained in:
Yasuhiro Matsumoto 2017-04-16 21:42:54 +09:00
parent 6651ec3363
commit 8a1347fad6
2 changed files with 11 additions and 1 deletions

View file

@ -82,6 +82,16 @@ func (c *Client) AccountUpdate(profile *Profile) (*Account, error) {
return &account, nil
}
// GetAccountStatuses return statuses by specified accuont.
func (c *Client) GetAccountStatuses(id int64) ([]*Status, error) {
var statuses []*Status
err := c.doAPI(http.MethodGet, fmt.Sprintf("/api/v1/accounts/%d/statuses", id), nil, &statuses)
if err != nil {
return nil, err
}
return statuses, nil
}
// GetAccountFollowers return followers list.
func (c *Client) GetAccountFollowers(id int64) ([]*Account, error) {
var accounts []*Account