Documentation ¶ Index ¶ type Client func NewClient(c HTTPClient, baseURL string) *Client func (c *Client) Insert(ctx context.Context, p Paper) (Paper, error) type HTTPClient type Paper Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ This section is empty. Types ¶ type Client ¶ type Client struct { // contains filtered or unexported fields } func NewClient ¶ func NewClient(c HTTPClient, baseURL string) *Client func (*Client) Insert ¶ func (c *Client) Insert(ctx context.Context, p Paper) (Paper, error) type HTTPClient ¶ type HTTPClient interface { Do(*http.Request) (*http.Response, error) } type Paper ¶ type Paper struct { ID int `json:"id"` Title string `json:"title"` Summary string `json:"summary"` Authors []string `json:"authors"` Tags []string `json:"tags"` References []string `json:"references"` } Source Files ¶ View all Source files client.go Click to show internal directories. Click to hide internal directories.