Add FollowRequestAuthorize and FollowRequestReject

This commit is contained in:
178inaba 2017-04-17 00:04:25 +09:00
parent 104663d1e6
commit f5194b9ebb
2 changed files with 58 additions and 0 deletions

View file

@ -241,3 +241,13 @@ func (c *Client) GetFollowRequests() ([]*Account, error) {
}
return accounts, nil
}
// FollowRequestAuthorize is authorize the follow request of user with id.
func (c *Client) FollowRequestAuthorize(id int64) error {
return c.doAPI(http.MethodPost, fmt.Sprintf("/api/v1/follow_requests/%d/authorize", id), nil, nil)
}
// FollowRequestReject is rejects the follow request of user with id.
func (c *Client) FollowRequestReject(id int64) error {
return c.doAPI(http.MethodPost, fmt.Sprintf("/api/v1/follow_requests/%d/reject", id), nil, nil)
}