google

package
v0.22.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 11, 2021 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GoogleService

type GoogleService struct {
	// contains filtered or unexported fields
}

func NewGoogleService

func NewGoogleService(token string) *GoogleService

func (*GoogleService) Search

func (t *GoogleService) Search(request *SearchRequest) (*SearchResponse, error)

Search for videos on Google

type SearchRequest

type SearchRequest struct {
	// Query to search for
	Query string `json:"query"`
}

type SearchResponse

type SearchResponse struct {
	// List of results for the query
	Results []SearchResult `json:"results"`
}

type SearchResult

type SearchResult struct {
	// abridged version of this search result’s URL, e.g. www.exampe.com
	DisplayUrl string `json:"displayUrl"`
	// id of the result
	Id string `json:"id"`
	// kind of result; "search"
	Kind string `json:"kind"`
	// the result snippet
	Snippet string `json:"snippet"`
	// title of the result
	Title string `json:"title"`
	// the full url for the result
	Url string `json:"url"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL