Skip to content

mazylol/pokego

Repository files navigation

PokeGO

Go Reference Go Report Card CI

PokeGO is a Go package that provides bindings to the Pokeapi. It caches to a local SQLite database.

Getting Started

Installing

go get github.com/mazylol/pokego

Usage

Import the package into your project.

import "github.com/mazylol/pokego"

Use the GetPokemon function to get a Pokemon of the provided name.

pokemon, err := pokego.GetPokemon("slugma")

// Print out name
fmt.Println(pokemon.Name)

You can also get a list of every Pokemon name.

pokemonList, err := pokego.GetResourceList("pokemon", 35) // 35 is how many pokemon it will get
	
// Print out the first Pokemons name
fmt.Println(pokemonList.Results[0].Name)

Features

  • Resource Lists/Pagination

  • Berries
  • Contests
  • Encounters
  • Evolution
  • Games
  • Items
  • Locations
  • Machines
  • Moves
  • Pokemon

  • Utility

Contributions <3

Contributors are very welcome. I still have a lot of ground to cover and any help is greatly appreciated. Refer to the features to see what needs done.

About

A go wrapper for the pokeapi. (With caching)

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages