bing

package module
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2022 License: MIT Imports: 5 Imported by: 1

README

Bing wallpaper golang client Go report card GoDoc

Golang bing daily wallpaper getter

Documentation

Index

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 *http.Client) *Client

func (*Client) GetDailyImage

func (b *Client) GetDailyImage(ctx context.Context, countryCode string) (*Image, error)

GetDailyImage get daily image based on contry code For example: en-EN

func (*Client) GetDailyImageRaw

func (b *Client) GetDailyImageRaw(ctx context.Context, countryCode string) ([]byte, error)

GetDailyImageRaw get daily image raw data based on contry code For example: en-EN

type Image

type Image struct {
	Startdate     string `json:"startdate"`
	Fullstartdate string `json:"fullstartdate"`
	Enddate       string `json:"enddate"`
	URL           string `json:"url"`
	Urlbase       string `json:"urlbase"`
	Copyright     string `json:"copyright"`
	Copyrightlink string `json:"copyrightlink"`
	Quiz          string `json:"quiz"`
	Wp            bool   `json:"wp"`
	Hsh           string `json:"hsh"`
}

Jump to

Keyboard shortcuts

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