Skip to content

Latest commit

 

History

History
47 lines (38 loc) · 714 Bytes

README.md

File metadata and controls

47 lines (38 loc) · 714 Bytes

World Bank API Client

Library provides access to the World Bank API. No registration key is necessary.

###Usage

package main

import (
	bank "github.com/openwonk/worldbank"
	"fmt"
)

func main() {
	s := bank.Series{
		Language: "en",

		Countries: []string{
			"bra",
			"chn",
		},
		Indicators: []string{
			"SP.POP.TOTL",
		},
		Start:     bank.Date{Year: "2011", Subunit: "Q2"},
		End:       bank.Date{Year: "2013", Subunit: "Q4"},
		Format:    "json",
		Frequency: "Q",
	}

	s.Querify()
	s.Request()
	s.Write("test.json")
	s.Reset()
	fmt.Println(s)

}



OpenWonk © 2015 MIT License