Versions in this module Expand all Collapse all v3 v3.0.0 Mar 16, 2023 Changes in this version + const TypePost + const TypePrompt + const TypePromptArchive + const TypeSubmission + const TypeSubmissionDraft + const Version + type AuthUser struct + AccessToken string + Password string + User *User + type Author struct + Name string + Slug string + User *User + type AuthorParams struct + Name string + OrgAlias string + Slug string + type BatchPostResult struct + Code int + ErrorMessage string + ID string + type BodyResponse struct + Body string + type Category struct + Hashtag string + Slug string + Title string + type ClaimPostResult struct + Code int + ErrorMessage string + ID string + Post *Post + type Client struct + UserAgent string + func NewClient() *Client + func NewClientWith(c Config) *Client + func NewDevClient() *Client + func NewTorClient(port int) *Client + func (c *Client) BaseURL() string + func (c *Client) ClaimPosts(sp *[]OwnedPostParams) (*[]ClaimPostResult, error) + func (c *Client) CreateCollection(sp *CollectionParams) (*Collection, error) + func (c *Client) CreateContributor(sp *AuthorParams) (*Author, error) + func (c *Client) CreatePost(sp *PostParams) (*Post, error) + func (c *Client) DeleteCollection(alias string) error + func (c *Client) DeletePost(id, token string) error + func (c *Client) GetCollection(alias string) (*Collection, error) + func (c *Client) GetCollectionPost(alias, slug string) (*Post, error) + func (c *Client) GetCollectionPosts(alias string, page int) (*[]Post, error) + func (c *Client) GetMe(verbose bool) (*User, error) + func (c *Client) GetPost(id string) (*Post, error) + func (c *Client) GetUserCollections() (*[]Collection, error) + func (c *Client) GetUserPosts() (*[]Post, error) + func (c *Client) LogIn(username, pass string) (*AuthUser, error) + func (c *Client) LogOut() error + func (c *Client) Markdown(body, collectionURL string) (string, error) + func (c *Client) PinPost(alias string, pp *PinnedPostParams) error + func (c *Client) SetApplicationKey(key string) + func (c *Client) SetClient(cl *http.Client) + func (c *Client) SetToken(token string) + func (c *Client) Token() string + func (c *Client) UnpinPost(alias string, pp *PinnedPostParams) error + func (c *Client) UpdatePost(id, token string, sp *PostParams) (*Post, error) + type Collection struct + Alias string + Description string + Domain string + Email string + Posts *[]Post + Private bool + StyleSheet string + Title string + TotalPosts int + URL string + Views int64 + type CollectionParams struct + Alias string + Description string + Title string + type Config struct + Token string + TorPort int + URL string + type OrgMember struct + Email string + Role Role + type OrgMemberParams struct + Email string + Role Role + Username string + type OwnedPostParams struct + ID string + Token string + type PinnedPostParams struct + ID string + Position int + type Post struct + Collection *Collection + Content string + Created time.Time + Font string + ID string + Images []string + Language *string + Listed bool + OwnerName string + RTL *bool + Slug string + Tags []string + Title string + Token string + Type PostType + Updated time.Time + Views int64 + type PostParams struct + AuthorSlug *string + Categories []Category + Collection string + Content string + Created *time.Time + Crosspost []map[string]string + Font string + ID string + IsRTL *bool + Language *string + Slug string + Title string + Token string + Updated *time.Time + type PostType string + type Role string + const RoleAdmin + const RoleAuthor + const RoleEditor + type User struct + Created time.Time + Email string + Subscription *UserSubscription + Username string + type UserSubscription struct + Active bool + AutoRenew bool + Begin time.Time + Delinquent bool + End time.Time + Name string Other modules containing this package github.com/writeas/go-writeas github.com/writeas/go-writeas/v2