Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
Locales = []string{
"ar",
"am",
"au",
"at",
"by",
"be",
"bo",
"br",
"bg",
"ca",
"cl",
"cn",
"co",
"hr",
"cz",
"ec",
"eg",
"fr",
"de",
"gr",
"hn",
"hk",
"in",
"id",
"ir",
"ie",
"il",
"it",
"jp",
"kr",
"mx",
"nl",
"nz",
"ni",
"pk",
"pa",
"pe",
"pl",
"pt",
"qa",
"ro",
"ru",
"sa",
"za",
"es",
"ch",
"sy",
"tw",
"th",
"tr",
"ua",
"gb",
"us",
"uy",
"ve",
}
)
Functions ¶
This section is empty.
Types ¶
type Article ¶
type Article struct { UUID string `json:"uuid,omitempty"` Title string `json:"title,omitempty"` Description string `json:"description,omitempty"` Keywords string `json:"keywords,omitempty"` Snippet string `json:"snippet,omitempty"` Url string `json:"url,omitempty"` ImageUrl string `json:"image_url,omitempty"` PublishedAt string `json:"published_at,omitempty"` Source string `json:"source,omitempty"` Categories []string `json:"categories,omitempty"` Language string `json:"language,omitempty"` Locale string `json:"locale,omitempty"` Similar []*Article `json:"similar,omitempty"` }
type News ¶
type News struct {
// contains filtered or unexported fields
}
func (*News) Headlines ¶
func (n *News) Headlines(ctx context.Context, req *pb.HeadlinesRequest, rsp *pb.HeadlinesResponse) error
func (*News) TopStories ¶ added in v1.4.0
func (n *News) TopStories(ctx context.Context, req *pb.TopStoriesRequest, rsp *pb.TopStoriesResponse) error
type TopStories ¶ added in v1.4.0
type TopStories struct {
Data []*Article `json:"data"`
}
Click to show internal directories.
Click to hide internal directories.