Add GetBlocks

pull/9/head
178inaba 2017-04-15 02:23:17 +09:00
parent 5d72d54344
commit 70efe09ff4
1 changed files with 10 additions and 0 deletions

View File

@ -66,6 +66,16 @@ func (c *Client) GetAccountFollowing(id int64) ([]*Account, error) {
return accounts, nil
}
// GetBlocks return block list.
func (c *Client) GetBlocks() ([]*Account, error) {
var accounts []*Account
err := c.doAPI(http.MethodGet, "/api/v1/blocks", nil, &accounts)
if err != nil {
return nil, err
}
return accounts, nil
}
// Relationship hold information for relation-ship to the account.
type Relationship struct {
ID int64 `json:"id"`