Skip to content

Go Client of the very Popular World Weather Online's Weather and TimeZone APIs

License

Notifications You must be signed in to change notification settings

zivost/worldweatheronline_go_client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

World Weather Online's API Client [wwogc]

-- Build Status

import "github.com/Rohithzr/worldweatheronline_go_client"

Usage

create Client

credentials := wwogc.Credentials{
			"your_key",
			"json",
			"premium",
			"EN"
			}

create Query

param1 := wwogc.Params{"q","Delhi"}
param2 := wwogc.Params("num_of_days", "1"}
query := []wwogc.Params{param1, param2}	

Methods

Methods available are:

  1. Search API (searchApi)
  2. Local Weather API (localWeatherApi)
  3. Time Zone API (tizeZoneApi)
  4. Ski Weather API (skiWeatherApi)
  5. Marine Weather API (marineWeatherApi)
  6. Historical Weather API (historicalWeatherApi)

func GetData

Pass the Above created query and credentials variable and the method you want to call

 code, data := GetData(query, credentials, "searchApi")

Gets the data from official world weather online servers and returns

  • code: HTTP Status Code (0 if error)
  • data: HTTP Body (blank if error)

About

Go Client of the very Popular World Weather Online's Weather and TimeZone APIs

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages