Versions in this module Expand all Collapse all v0 v0.0.6 Mar 11, 2021 v0.0.5 Mar 11, 2021 Changes in this version + const VisibilityDirectMessage + const VisibilityFollowersOnly + const VisibilityPublic + const VisibilityUnlisted + func Base64Encode(file *os.File) (string, error) + func Base64EncodeFileName(filename string) (string, error) + func String(v string) *string + type Account struct + Acct string + Avatar string + AvatarStatic string + Bot bool + CreatedAt time.Time + DisplayName string + Emojis []Emoji + Fields []Field + FollowersCount int64 + FollowingCount int64 + Header string + HeaderStatic string + ID ID + Locked bool + Moved *Account + Note string + StatusesCount int64 + URL string + Username string + type AccountSource struct + Fields *[]Field + Language *string + Note *string + Privacy *string + Sensitive *bool + type AppConfig struct + ClientName string + RedirectURIs string + Scopes string + Server string + Website string + type Application struct + AuthURI string + ClientID string + ClientSecret string + ID ID + RedirectURI string + func RegisterApp(ctx context.Context, appConfig *AppConfig) (*Application, error) + type Attachment struct + Description string + ID ID + Meta AttachmentMeta + PreviewURL string + RemoteURL string + TextURL string + Type string + URL string + type AttachmentMeta struct + Original AttachmentSize + Small AttachmentSize + type AttachmentSize struct + Aspect float64 + Height int64 + Size string + Width int64 + type Card struct + AuthorName string + AuthorURL string + Description string + HTML string + Height int64 + Image string + ProviderName string + ProviderURL string + Title string + Type string + URL string + Width int64 + type Client struct + Config *Config + UserAgent string + func NewClient(config *Config) *Client + func (c *Client) AccountBlock(ctx context.Context, id ID) (*Relationship, error) + func (c *Client) AccountFollow(ctx context.Context, id ID) (*Relationship, error) + func (c *Client) AccountMute(ctx context.Context, id ID) (*Relationship, error) + func (c *Client) AccountUnblock(ctx context.Context, id ID) (*Relationship, error) + func (c *Client) AccountUnfollow(ctx context.Context, id ID) (*Relationship, error) + func (c *Client) AccountUnmute(ctx context.Context, id ID) (*Relationship, error) + func (c *Client) AccountUpdate(ctx context.Context, profile *Profile) (*Account, error) + func (c *Client) AccountsSearch(ctx context.Context, q string, limit int64) ([]*Account, error) + func (c *Client) AddPushSubscription(ctx context.Context, endpoint string, public ecdsa.PublicKey, shared []byte, ...) (*PushSubscription, error) + func (c *Client) AddToList(ctx context.Context, list ID, accounts ...ID) error + func (c *Client) Authenticate(ctx context.Context, username, password string) error + func (c *Client) AuthenticateToken(ctx context.Context, authCode, redirectURI string) error + func (c *Client) ClearNotifications(ctx context.Context) error + func (c *Client) CreateList(ctx context.Context, title string) (*List, error) + func (c *Client) DeleteConversation(ctx context.Context, id ID) error + func (c *Client) DeleteList(ctx context.Context, id ID) error + func (c *Client) DeleteStatus(ctx context.Context, id ID) error + func (c *Client) DismissNotification(ctx context.Context, id ID) error + func (c *Client) Favourite(ctx context.Context, id ID) (*Status, error) + func (c *Client) FollowRemoteUser(ctx context.Context, uri string) (*Account, error) + func (c *Client) FollowRequestAuthorize(ctx context.Context, id ID) error + func (c *Client) FollowRequestReject(ctx context.Context, id ID) error + func (c *Client) GetAccount(ctx context.Context, id ID) (*Account, error) + func (c *Client) GetAccountCurrentUser(ctx context.Context) (*Account, error) + func (c *Client) GetAccountFollowers(ctx context.Context, id ID, pg *Pagination) ([]*Account, error) + func (c *Client) GetAccountFollowing(ctx context.Context, id ID, pg *Pagination) ([]*Account, error) + func (c *Client) GetAccountLists(ctx context.Context, id ID) ([]*List, error) + func (c *Client) GetAccountRelationships(ctx context.Context, ids []string) ([]*Relationship, error) + func (c *Client) GetAccountStatuses(ctx context.Context, id ID, pg *Pagination) ([]*Status, error) + func (c *Client) GetBlocks(ctx context.Context, pg *Pagination) ([]*Account, error) + func (c *Client) GetConversations(ctx context.Context, pg *Pagination) ([]*Conversation, error) + func (c *Client) GetFavouritedBy(ctx context.Context, id ID, pg *Pagination) ([]*Account, error) + func (c *Client) GetFavourites(ctx context.Context, pg *Pagination) ([]*Status, error) + func (c *Client) GetFollowRequests(ctx context.Context, pg *Pagination) ([]*Account, error) + func (c *Client) GetInstance(ctx context.Context) (*Instance, error) + func (c *Client) GetInstanceActivity(ctx context.Context) ([]*WeeklyActivity, error) + func (c *Client) GetInstancePeers(ctx context.Context) ([]string, error) + func (c *Client) GetList(ctx context.Context, id ID) (*List, error) + func (c *Client) GetListAccounts(ctx context.Context, id ID) ([]*Account, error) + func (c *Client) GetLists(ctx context.Context) ([]*List, error) + func (c *Client) GetMutes(ctx context.Context, pg *Pagination) ([]*Account, error) + func (c *Client) GetNotification(ctx context.Context, id ID) (*Notification, error) + func (c *Client) GetNotifications(ctx context.Context, pg *Pagination) ([]*Notification, error) + func (c *Client) GetPushSubscription(ctx context.Context) (*PushSubscription, error) + func (c *Client) GetRebloggedBy(ctx context.Context, id ID, pg *Pagination) ([]*Account, error) + func (c *Client) GetReports(ctx context.Context) ([]*Report, error) + func (c *Client) GetStatus(ctx context.Context, id ID) (*Status, error) + func (c *Client) GetStatusCard(ctx context.Context, id ID) (*Card, error) + func (c *Client) GetStatusContext(ctx context.Context, id ID) (*Context, error) + func (c *Client) GetTimelineDirect(ctx context.Context, pg *Pagination) ([]*Status, error) + func (c *Client) GetTimelineHashtag(ctx context.Context, tag string, isLocal bool, pg *Pagination) ([]*Status, error) + func (c *Client) GetTimelineHome(ctx context.Context, pg *Pagination) ([]*Status, error) + func (c *Client) GetTimelineList(ctx context.Context, id ID, pg *Pagination) ([]*Status, error) + func (c *Client) GetTimelineMedia(ctx context.Context, isLocal bool, pg *Pagination) ([]*Status, error) + func (c *Client) GetTimelinePublic(ctx context.Context, isLocal bool, pg *Pagination) ([]*Status, error) + func (c *Client) MarkConversationAsRead(ctx context.Context, id ID) error + func (c *Client) NewWSClient() *WSClient + func (c *Client) PostStatus(ctx context.Context, toot *Toot) (*Status, error) + func (c *Client) Reblog(ctx context.Context, id ID) (*Status, error) + func (c *Client) RemoveFromList(ctx context.Context, list ID, accounts ...ID) error + func (c *Client) RemovePushSubscription(ctx context.Context) error + func (c *Client) RenameList(ctx context.Context, id ID, title string) (*List, error) + func (c *Client) Report(ctx context.Context, accountID ID, ids []ID, comment string) (*Report, error) + func (c *Client) Search(ctx context.Context, q string, resolve bool) (*Results, error) + func (c *Client) StreamingHashtag(ctx context.Context, tag string, isLocal bool) (chan Event, error) + func (c *Client) StreamingList(ctx context.Context, id ID) (chan Event, error) + func (c *Client) StreamingPublic(ctx context.Context, isLocal bool) (chan Event, error) + func (c *Client) StreamingUser(ctx context.Context) (chan Event, error) + func (c *Client) Unfavourite(ctx context.Context, id ID) (*Status, error) + func (c *Client) Unreblog(ctx context.Context, id ID) (*Status, error) + func (c *Client) UpdatePushSubscription(ctx context.Context, alerts *PushAlerts) (*PushSubscription, error) + func (c *Client) UploadMedia(ctx context.Context, file string) (*Attachment, error) + func (c *Client) UploadMediaFromMedia(ctx context.Context, media *Media) (*Attachment, error) + func (c *Client) UploadMediaFromReader(ctx context.Context, reader io.Reader) (*Attachment, error) + type Config struct + AccessToken string + ClientID string + ClientSecret string + Server string + type Context struct + Ancestors []*Status + Descendants []*Status + type Conversation struct + Accounts []*Account + ID ID + LastStatus *Status + Unread bool + type DeleteEvent struct + ID ID + type Emoji struct + ShortCode string + StaticURL string + URL string + VisibleInPicker bool + type ErrorEvent struct + func (e *ErrorEvent) Error() string + type Event interface + type Field struct + Name string + Value string + VerifiedAt time.Time + type History struct + Accounts string + Day string + Uses string + type ID string + func (id *ID) UnmarshalJSON(data []byte) error + type Instance struct + ContactAccount *Account + Description string + EMail string + Languages []string + Stats *InstanceStats + Thumbnail string + Title string + URI string + URLs map[string]string + Version string + type InstanceStats struct + DomainCount int64 + StatusCount int64 + UserCount int64 + type List struct + ID ID + Title string + type Media struct + Description string + File io.Reader + Focus string + Thumbnail io.Reader + type Mention struct + Acct string + ID ID + URL string + Username string + type Notification struct + Account Account + CreatedAt time.Time + ID ID + Status *Status + Type string + type NotificationEvent struct + Notification *Notification + type Pagination struct + Limit int64 + MaxID ID + MinID ID + SinceID ID + type Poll struct + Expired bool + ExpiresAt time.Time + ID ID + Multiple bool + Options []PollOption + Voted bool + VotesCount int64 + type PollOption struct + Title string + VotesCount int64 + type Profile struct + Avatar string + DisplayName *string + Fields *[]Field + Header string + Locked *bool + Note *string + Source *AccountSource + type PushAlerts struct + Favourite *Sbool + Follow *Sbool + Mention *Sbool + Reblog *Sbool + type PushSubscription struct + Alerts *PushAlerts + Endpoint string + ID ID + ServerKey string + type Relationship struct + Blocking bool + DomainBlocking bool + Endorsed bool + FollowedBy bool + Following bool + ID ID + Muting bool + MutingNotifications bool + Requested bool + ShowingReblogs bool + type Report struct + ActionTaken bool + ID int64 + type Results struct + Accounts []*Account + Hashtags []*Tag + Statuses []*Status + type Sbool bool + func (s *Sbool) UnmarshalJSON(data []byte) error + type Status struct + Account Account + Application Application + Card *Card + Content string + CreatedAt time.Time + Emojis []Emoji + Favourited interface{} + FavouritesCount int64 + ID ID + InReplyToAccountID interface{} + InReplyToID interface{} + Language string + MediaAttachments []Attachment + Mentions []Mention + Muted interface{} + Pinned interface{} + Poll *Poll + Reblog *Status + Reblogged interface{} + ReblogsCount int64 + RepliesCount int64 + Sensitive bool + SpoilerText string + Tags []Tag + URI string + URL string + Visibility string + type Stream struct + Event string + Payload interface{} + type Tag struct + History []History + Name string + URL string + type Toot struct + InReplyToID ID + MediaIDs []ID + ScheduledAt *time.Time + Sensitive bool + SpoilerText string + Status string + Visibility string + type Unixtime time.Time + func (t *Unixtime) UnmarshalJSON(data []byte) error + type UpdateEvent struct + Status *Status + type WSClient struct + func (c *WSClient) StreamingWSHashtag(ctx context.Context, tag string, isLocal bool) (chan Event, error) + func (c *WSClient) StreamingWSList(ctx context.Context, id ID) (chan Event, error) + func (c *WSClient) StreamingWSPublic(ctx context.Context, isLocal bool) (chan Event, error) + func (c *WSClient) StreamingWSUser(ctx context.Context) (chan Event, error) + type WeeklyActivity struct + Logins int64 + Registrations int64 + Statuses int64 + Week Unixtime