Documentation
¶
Index ¶
- type Annotation
- type Annotations
- type Client
- func (c *Client) AuthHeader() (string, error)
- func (c *Client) ExportEntry(id int, format string, w io.Writer) error
- func (c *Client) Get(url string, data interface{}) error
- func (c *Client) GetEntries(param url.Values) ([]Item, error)
- func (c *Client) GetEntry(id int) (Item, error)
- func (c *Client) GetToken() error
- func (c *Client) Patch(url string, data map[string]interface{}) error
- func (c *Client) PatchEntry(id int, data map[string]interface{}) error
- func (c *Client) RefreshToken() error
- func (c *Client) Request(method, url string, body io.Reader) (*http.Response, error)
- type CredentialStore
- type Embedded
- type Entries
- type HttpClient
- type Item
- type Link
- type Links
- type Range
- type Tag
- type Time
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Annotation ¶
type Annotations ¶
type Annotations struct { Rows []Annotation `json:"rows"` Total int `json:"total"` }
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func New ¶
func New(log logr.Logger, httpClient HttpClient, baseURL, clientId, clientSecret string, credentials CredentialStore) *Client
func (*Client) AuthHeader ¶
func (*Client) RefreshToken ¶
type CredentialStore ¶
type HttpClient ¶
type Item ¶
type Item struct { Links Links `json:"_links"` Annotations []Annotation `json:"annotations"` CreatedAt Time `json:"created_at"` Content string `json:"content"` DomainName string `json:"domain_name"` ID int `json:"id"` IsArchived int `json:"is_archived"` IsStarred int `json:"is_starred"` Language string `json:"language"` Mimetype string `json:"mimetype"` PreviewPicture string `json:"preview_picture"` ReadingTime int `json:"reading_time"` Tags []Tag `json:"tags"` Title string `json:"title"` UpdatedAt Time `json:"updated_at"` URL string `json:"url"` UserEmail string `json:"user_email"` UserID int `json:"user_id"` UserName string `json:"user_name"` }
Click to show internal directories.
Click to hide internal directories.