Add GetBlocks
parent
5d72d54344
commit
70efe09ff4
10
accounts.go
10
accounts.go
|
@ -66,6 +66,16 @@ func (c *Client) GetAccountFollowing(id int64) ([]*Account, error) {
|
||||||
return accounts, nil
|
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.
|
// Relationship hold information for relation-ship to the account.
|
||||||
type Relationship struct {
|
type Relationship struct {
|
||||||
ID int64 `json:"id"`
|
ID int64 `json:"id"`
|
||||||
|
|
Loading…
Reference in New Issue